llvm-project/llvm/lib/Target/BPF/MCTargetDesc
Yonghong Song 03e1c8b8f9 bpf: introduce -mattr=dwarfris to disable DwarfUsesRelocationsAcrossSections
Commit e4507fb8c94b ("bpf: disable DwarfUsesRelocationsAcrossSections")
disables MCAsmInfo DwarfUsesRelocationsAcrossSections unconditionally
so that dwarf will not use cross section (between dwarf and symbol table)
relocations. This new debug format enables pahole to dump structures
correctly as libdwarves.so does not have BPF backend support yet.

This new debug format, however, breaks bcc (https://github.com/iovisor/bcc)
source debug output as llvm in-memory Dwarf support has some issues to
handle it. More specifically, with DwarfUsesRelocationsAcrossSections
disabled, JIT compiler does not generate .debug_abbrev and Dwarf
DIE (debug info entry) processing is not happy about this.

This patch introduces a new flag -mattr=dwarfris
(dwarf relocation in section) to disable DwarfUsesRelocationsAcrossSections.
DwarfUsesRelocationsAcrossSections is true by default.

Signed-off-by: Yonghong Song <yhs@fb.com>
llvm-svn: 326505
2018-03-01 23:04:59 +00:00
..
BPFAsmBackend.cpp Thread MCSubtargetInfo through Target::createMCAsmBackend 2018-01-03 08:53:05 +00:00
BPFELFObjectWriter.cpp [bpf] allow direct and indirect calls 2017-11-19 01:35:00 +00:00
BPFMCAsmInfo.h bpf: introduce -mattr=dwarfris to disable DwarfUsesRelocationsAcrossSections 2018-03-01 23:04:59 +00:00
BPFMCCodeEmitter.cpp [bpf] allow direct and indirect calls 2017-11-19 01:35:00 +00:00
BPFMCTargetDesc.cpp bpf: print backward branch target properly 2017-11-16 19:15:36 +00:00
BPFMCTargetDesc.h Thread MCSubtargetInfo through Target::createMCAsmBackend 2018-01-03 08:53:05 +00:00
CMakeLists.txt
LLVMBuild.txt