[DWARF5] Replace emission of strp with stx forms in debug_macro section
authorSourabh Singh Tomar <SourabhSingh.Tomar@amd.com>
Fri, 29 May 2020 18:52:40 +0000 (00:22 +0530)
committerSourabh Singh Tomar <SourabhSingh.Tomar@amd.com>
Fri, 29 May 2020 18:54:09 +0000 (00:24 +0530)
commitb47403c0a4c532554cf3d67ed1669fe00530aab3
tree1bd6d27ccb60e3a84557dd836a71424bf0bafe9b
parente7102eed20d969c7e75b7d3dc5192290f733797a
[DWARF5] Replace emission of strp with stx forms in debug_macro section

DW_MACRO_define_strx forms are supported now in llvm-dwarfdump and these
forms can be used in both debug_macro[.dwo] sections. An added advantage
for using strx forms over strp forms is that it uses indices
approach instead of a relocation to debug_str section.

This patch unify the emission for debug_macro section.

Reviewed by: dblaikie, ikudrin

Differential Revision: https://reviews.llvm.org/D78865
llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
llvm/test/DebugInfo/X86/debug-macro-v5.ll