[Lldb-commits] [lldb] [lldb][Windows] Fix x86_64 default unwind plan (PR #210076)
Jason Molenda via lldb-commits
lldb-commits at lists.llvm.org
Thu Jul 16 10:50:15 PDT 2026
jasonmolenda wrote:
(even when omit-frame-pointer codegen is being done, you can force a frame pointer register to be used if you use a non-fixed stack frame size. On unix alloca() will do this, or with modern C, a variable length array VLA. e.g. `void foo(int size) { int array[size]; ... }` the size of the stack frame is unknown at compile time, so the comiler will spill rbp, copy rsp into rbp, then decrement rsp to make room for all the locals. And in the epilogue, it restores the rbp value into rsp without needing to know the size of the stack frame. I'm sure the Windows compiler does the same. VLA stack frames are so uncommon there's no point in making a ArchDefaultUnwindPlan that assumes they're in use, though.)
https://github.com/llvm/llvm-project/pull/210076
More information about the lldb-commits
mailing list