[RISCV] ELF attribute section for RISC-V.
authorKai Wang <kai.wang@sifive.com>
Tue, 4 Feb 2020 14:20:10 +0000 (22:20 +0800)
committerKai Wang <kai.wang@sifive.com>
Tue, 31 Mar 2020 08:16:19 +0000 (16:16 +0800)
commit581ba35291a658cd01e2cb39f6d415cac89a7656
tree047e1bd37131e7519e7eef3de5be549722fb4052
parent86b40760278e73710564135be8cd9c2c9e7ff080
[RISCV] ELF attribute section for RISC-V.

Leverage ARM ELF build attribute section to create ELF attribute section
for RISC-V. Extract the common part of parsing logic for this section
into ELFAttributeParser.[cpp|h] and ELFAttributes.[cpp|h].

Differential Revision: https://reviews.llvm.org/D74023
40 files changed:
lld/ELF/InputFiles.cpp
lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
llvm/include/llvm/BinaryFormat/ELF.h
llvm/include/llvm/Object/ELFObjectFile.h
llvm/include/llvm/Support/ARMAttributeParser.h
llvm/include/llvm/Support/ARMBuildAttributes.h
llvm/include/llvm/Support/ELFAttributeParser.h [new file with mode: 0644]
llvm/include/llvm/Support/ELFAttributes.h [new file with mode: 0644]
llvm/include/llvm/Support/RISCVAttributeParser.h [new file with mode: 0644]
llvm/include/llvm/Support/RISCVAttributes.h [new file with mode: 0644]
llvm/lib/Object/ELF.cpp
llvm/lib/Object/ELFObjectFile.cpp
llvm/lib/ObjectYAML/ELFYAML.cpp
llvm/lib/Support/ARMAttributeParser.cpp
llvm/lib/Support/ARMBuildAttrs.cpp
llvm/lib/Support/CMakeLists.txt
llvm/lib/Support/ELFAttributeParser.cpp [new file with mode: 0644]
llvm/lib/Support/ELFAttributes.cpp [new file with mode: 0644]
llvm/lib/Support/RISCVAttributeParser.cpp [new file with mode: 0644]
llvm/lib/Support/RISCVAttributes.cpp [new file with mode: 0644]
llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
llvm/lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp
llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
llvm/lib/Target/RISCV/MCTargetDesc/RISCVELFStreamer.cpp
llvm/lib/Target/RISCV/MCTargetDesc/RISCVELFStreamer.h
llvm/lib/Target/RISCV/MCTargetDesc/RISCVTargetStreamer.cpp
llvm/lib/Target/RISCV/MCTargetDesc/RISCVTargetStreamer.h
llvm/lib/Target/RISCV/RISCVAsmPrinter.cpp
llvm/test/CodeGen/RISCV/attributes.ll [new file with mode: 0644]
llvm/test/MC/RISCV/attribute-arch.s [new file with mode: 0644]
llvm/test/MC/RISCV/attribute-with-insts.s [new file with mode: 0644]
llvm/test/MC/RISCV/attribute.s [new file with mode: 0644]
llvm/test/MC/RISCV/invalid-attribute.s [new file with mode: 0644]
llvm/test/tools/llvm-objdump/RISCV/lit.local.cfg [new file with mode: 0644]
llvm/test/tools/llvm-objdump/RISCV/unknown-arch-attr.test [new file with mode: 0644]
llvm/tools/llvm-readobj/ELFDumper.cpp
llvm/unittests/Support/ARMAttributeParser.cpp
llvm/unittests/Support/CMakeLists.txt
llvm/unittests/Support/ELFAttributeParserTest.cpp [new file with mode: 0644]
llvm/unittests/Support/RISCVAttributeParserTest.cpp [new file with mode: 0644]