================
@@ -680,11 +682,19 @@ int
CompactUnwinder_arm64<A>::stepWithCompactEncodingFrame(
savedRegisterLoc -= 8;
}
- uint64_t fp = registers.getFP();
+ Registers_arm64::reg_t fp = registers.getFP();
// fp points to old fp
registers.setFP(addressSpace.get64(fp));
- // old sp is fp less saved fp and lr
+
+ // old sp is fp less saved fp and lr. Set this before FP & LR because in
+ // arm64e it's the discriminator used for those registers.
registers.setSP(fp + 16);
+
+ Registers_arm64::reg_t oldfp = addressSpace.get64(fp);
+
+ // fp points to old fp
+ registers.setFP(oldfp);
----------------
ojhunt wrote:
There was a period we experimented with frame signing (it was gated on a
ptrauth_frame feature test), and while prepping these I removed the defunct
code to avoid the appearance of it existing, or providing a no longer verified
to be working feature, it's possible some of the weird ordering isn't needed
for this anymore.
I'll update the comments to remove the reference to needing FP stuff.
https://github.com/llvm/llvm-project/pull/143230
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits