llvm-project/llvm/lib/Target/BPF
Yonghong Song 0d99031de0 [BPF] Fix .BTF.ext reloc type assigment issue
Commit f1db33c5c1a9 ("[BPF] Disable relocation for .BTF.ext section")
assigned relocation type R_BPF_NONE if the fixup type
is FK_Data_4 and the symbol is temporary.
The reason is we use FK_Data_4 as a fixup type
for insn offsets in .BTF.ext section.

Just checking whether the symbol is temporary is not enough.
For example, .debug_info may reference some strings whose
fixup is FK_Data_4 with a temporary symbol as well.

To truely reflect the case for .BTF.ext section,
this patch further checks that the section associateed with the symbol
must be SHF_ALLOC and SHF_EXECINSTR, i.e., in the text section.
This fixed the above-mentioned problem.

Signed-off-by: Yonghong Song <yhs@fb.com>
llvm-svn: 350637
2019-01-08 16:36:06 +00:00
..
AsmParser Fix clang -Wimplicit-fallthrough warnings across llvm, NFC 2018-11-01 19:54:45 +00:00
Disassembler [Target] Untangle disassemblers 2018-09-10 12:53:46 +00:00
InstPrinter Remove some unused includes to fix layering. 2018-03-29 00:29:45 +00:00
MCTargetDesc [BPF] Fix .BTF.ext reloc type assigment issue 2019-01-08 16:36:06 +00:00
TargetInfo
BPF.h bpf: check illegal usage of XADD insn return value 2018-09-20 22:24:27 +00:00
BPF.td bpf: introduce -mattr=dwarfris to disable DwarfUsesRelocationsAcrossSections 2018-03-01 23:04:59 +00:00
BPFAsmPrinter.cpp [BPF] Generate BTF DebugInfo under BPF target 2018-12-19 16:40:25 +00:00
BPFCallingConv.td
BPFFrameLowering.cpp
BPFFrameLowering.h
BPFISelDAGToDAG.cpp Rename DEBUG macro to LLVM_DEBUG. 2018-05-14 12:53:11 +00:00
BPFISelLowering.cpp bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFISelLowering.h bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFInstrFormats.td
BPFInstrInfo.cpp bpf: add missing RegState to notify MachineInstr verifier necessary register usage 2018-07-27 16:58:52 +00:00
BPFInstrInfo.h bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFInstrInfo.td bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFMCInstLower.cpp
BPFMCInstLower.h
BPFMIChecking.cpp bpf: check illegal usage of XADD insn return value 2018-09-20 22:24:27 +00:00
BPFMIPeephole.cpp Rename DEBUG macro to LLVM_DEBUG. 2018-05-14 12:53:11 +00:00
BPFRegisterInfo.cpp
BPFRegisterInfo.h [TargetRegisterInfo] Remove temporary hook enableMultipleCopyHints() 2018-10-05 14:23:11 +00:00
BPFRegisterInfo.td
BPFSelectionDAGInfo.cpp bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFSelectionDAGInfo.h bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFSubtarget.cpp bpf: introduce -mattr=dwarfris to disable DwarfUsesRelocationsAcrossSections 2018-03-01 23:04:59 +00:00
BPFSubtarget.h bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in order 2018-07-25 22:40:02 +00:00
BPFTargetMachine.cpp [Targets] Add errors for tiny and kernel codemodel on targets that don't support them 2018-12-07 12:10:23 +00:00
BPFTargetMachine.h
BTF.def [BPF] Generate BTF DebugInfo under BPF target 2018-12-19 16:40:25 +00:00
BTF.h [BPF] Generate BTF DebugInfo under BPF target 2018-12-19 16:40:25 +00:00
BTFDebug.cpp [BPF] Generate BTF DebugInfo under BPF target 2018-12-19 16:40:25 +00:00
BTFDebug.h [BPF] Generate BTF DebugInfo under BPF target 2018-12-19 16:40:25 +00:00
CMakeLists.txt [BPF] Generate BTF DebugInfo under BPF target 2018-12-19 16:40:25 +00:00
LLVMBuild.txt