From 824cff9e400820018f188bd31b3e14d16032bb36 Mon Sep 17 00:00:00 2001 From: Taylor R Campbell Date: Sat, 19 Jan 2019 08:03:41 +0000 Subject: [PATCH] Fix extraction of PC offset from branch instruction. --- src/microcode/cmpintmd/aarch64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/microcode/cmpintmd/aarch64.c b/src/microcode/cmpintmd/aarch64.c index b6610c10b..d9bed8e62 100644 --- a/src/microcode/cmpintmd/aarch64.c +++ b/src/microcode/cmpintmd/aarch64.c @@ -90,7 +90,7 @@ cc_return_address_to_entry_address (insn_t * pc) { insn_t insn = (pc[0]); if ((insn & 0xfc000000UL) == 0x14000000UL) /* B */ - return (pc + (insn & 0x3fffffff)); + return (pc + (insn & 0x03ffffff)); else /* XXX What if it got branch-tensioned? */ error_external_return (); -- 2.25.1