aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorIgor Kudrin <ikudrin@accesssoftek.com>2020-07-17 12:46:47 +0700
committerIgor Kudrin <ikudrin@accesssoftek.com>2020-07-17 13:49:27 +0700
commitf76a0cd97aa2ee52dd7e0fccb0a6a33d3af2af77 (patch)
treea68b36667bb99c802d05f314ff7d66707ddf7d87 /clang/lib/Frontend/CompilerInvocation.cpp
parent16926115ed28d1370bca1085dfb1b20c842b0ffb (diff)
downloadllvm-f76a0cd97aa2ee52dd7e0fccb0a6a33d3af2af77.zip
llvm-f76a0cd97aa2ee52dd7e0fccb0a6a33d3af2af77.tar.gz
llvm-f76a0cd97aa2ee52dd7e0fccb0a6a33d3af2af77.tar.bz2
[DebugInfo] Fix a misleading usage of DWARF forms with DIEExpr. NFCI.
For now, DIEExpr is used only in two places: 1) in the debug info library unit test suite to emit a DW_AT_str_offsets_base attribute with the DW_FORM_sec_offset form, see dwarfgen::DIE::addStrOffsetsBaseAttribute(); 2) in DwarfCompileUnit::addLocationAttribute() to generate the location attribute for a TLS variable. The later case used an incorrect DWARF form of DW_FORM_udata, which implies storing an uleb128 value, not a 4/8 byte constant. The generated result was as expected because DIEExpr::SizeOf() did not handle the used form, but returned the size of the code pointer by default. The patch fixes the issue by using more appropriate DWARF forms for the problematic case and making DIEExpr::SizeOf() more straightforward. Differential Revision: https://reviews.llvm.org/D83958
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions