Fix accidental breakage of non-AARCH64 systems (#1036)

Co-authored-by: Your Name <you@example.com>
This commit is contained in:
WorksButNotTested 2023-02-01 08:46:12 +00:00 committed by GitHub
parent d0b4c39acd
commit 71f106be20
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -202,8 +202,11 @@ impl CoverageRuntime {
// these spilt registers. This, however, means we need to retard the
// code writer so that we can overwrite the so-called "restoration
// prologue".
let pc = writer.pc();
writer.reset(pc - 4);
#[cfg(target_arch = "aarch64")]
{
let pc = writer.pc();
writer.reset(pc - 4);
}
let code = self.generate_inline_code(h64 & (MAP_SIZE as u64 - 1));
writer.put_bytes(&code);