[PATCH] D125649: [ARM SEH 7] [ARM] Adjust the frame pointer when it's needed for SEH unwinding

Martin Storsjö via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 25 13:27:40 PDT 2022


mstorsjo added inline comments.


================
Comment at: llvm/test/CodeGen/ARM/Windows/wineh-framepointer.ll:25
+; CHECK-NEXT:         sub.w   sp, sp, r4
+; CHECK-NEXT:         .seh_stackalloc_w       5024
+; CHECK-NEXT:         .seh_endprologue
----------------
mstorsjo wrote:
> efriedma wrote:
> > We probably shouldn't include this seh_stackalloc_w in the prologue; not sure if the unwinder actually cares, but at best it has no effect.
> Yeah, I thought about that, but I was wary of making the emitPrologue code more complex than necessary, since we do need to cover this bit for the cases where we don't restore from a stack pointer. But I guess I could add a condition to end the SEH range of the prologue earlier, at least for the `STI.splitFramePointerPush(MF)` cases.
Ok, it turned out to not be that bad after all.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D125649/new/

https://reviews.llvm.org/D125649



More information about the llvm-commits mailing list