aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorKyle Huey <khuey@pernos.co>2023-05-15 15:08:18 +0100
committerJ. Ryan Stinnett <jryans@gmail.com>2023-05-15 15:10:02 +0100
commitd421f5226048e4a5d88aab157d0f4d434c43f208 (patch)
treeff46016f7572fcb4967fab3df40d5b71c6f5fea5 /clang/lib/Frontend/CompilerInvocation.cpp
parentf516ad6154f77e417e9eab307cce63fe0416af64 (diff)
downloadllvm-d421f5226048e4a5d88aab157d0f4d434c43f208.zip
llvm-d421f5226048e4a5d88aab157d0f4d434c43f208.tar.gz
llvm-d421f5226048e4a5d88aab157d0f4d434c43f208.tar.bz2
[X86] Use the CFA as the DWARF frame base for better variable locations around calls.
Prior to this patch, for the DWARF frame base LLVM uses the frame pointer register if available, otherwise the stack pointer register. If the stack pointer register is being used and a call or other code modifies the stack pointer during the body of the function this results in the locations being wrong and the debugger displaying the wrong values for variables. By using DW_OP_call_frame_cfa in these situations the emitted location for the variable will automatically handle changes in the stack pointer. The CFA needs to be adjusted for the offset between the frame pointer/stack pointer to allow the variable locations themselves to remain unchanged by this patch. Reviewed By: #debug-info, scott.linder, jryans Differential Revision: https://reviews.llvm.org/D143463
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions