[DWARFLinker][DWARFv5] Add handling of DW_OP_addrx and DW_OP_constx expression operands.
authorAlexey Lapshin <a.v.lapshin@mail.ru>
Tue, 21 Mar 2023 17:55:57 +0000 (18:55 +0100)
committerAlexey Lapshin <a.v.lapshin@mail.ru>
Tue, 16 May 2023 17:27:16 +0000 (19:27 +0200)
commitbd0dd27bb5be0fbf60c1b2a4ce15188812388574
treeaec4363cb6755cc5e8c6016af0cb6aa53c984832
parentd225e6f40c8cc91089e6a837c273b3df1c3c6a43
[DWARFLinker][DWARFv5] Add handling of DW_OP_addrx and DW_OP_constx expression operands.

This patch adds handling of DW_OP_addrx and DW_OP_constx expression operands.
In --update case these operands are preserved as is. Otherwise they are
converted into the DW_OP_addr and DW_OP_const[*]u correspondingly.

Differential Revision: https://reviews.llvm.org/D147066
13 files changed:
llvm/include/llvm/DWARFLinker/DWARFLinker.h
llvm/include/llvm/DWARFLinker/DWARFLinkerCompileUnit.h
llvm/include/llvm/DWARFLinkerParallel/AddressesMap.h
llvm/lib/DWARFLinker/DWARFLinker.cpp
llvm/lib/DWARFLinker/DWARFLinkerCompileUnit.cpp
llvm/lib/DebugInfo/DWARF/DWARFExpression.cpp
llvm/test/tools/dsymutil/Inputs/dwarf5-dw-op-addrx.o [new file with mode: 0644]
llvm/test/tools/dsymutil/X86/dwarf5-dw-op-addrx.test [new file with mode: 0644]
llvm/test/tools/dsymutil/X86/op-convert-offset.test
llvm/test/tools/llvm-dwarfutil/ELF/X86/dwarf5-addresses.test [moved from llvm/test/tools/llvm-dwarfutil/ELF/X86/dwarf5-addrx.test with 71% similarity]
llvm/tools/dsymutil/DwarfLinkerForBinary.cpp
llvm/tools/dsymutil/DwarfLinkerForBinary.h
llvm/tools/llvm-dwarfutil/DebugInfoLinker.cpp