llvm-6502/test
Eric Christopher 76e70f340c Implements low-level object file format specific output for COFF and
ELF with support for:

- File headers
- Section headers + data
- Relocations
- Symbols
- Unwind data (only COFF/Win64)

The output format follows a few rules:
- Values are almost always output one per line (as elf-dump/coff-dump already do). - Many values are translated to something readable (like enum names), with the raw value in parentheses.
- Hex numbers are output in uppercase, prefixed with "0x".
- Flags are sorted alphabetically.
- Lists and groups are always delimited.

Example output:
---------- snip ----------
Sections [
  Section {
    Index: 1
    Name: .text (5)
    Type: SHT_PROGBITS (0x1)
    Flags [ (0x6)
      SHF_ALLOC (0x2)
      SHF_EXECINSTR (0x4)
    ]
    Address: 0x0
    Offset: 0x40
    Size: 33
    Link: 0
    Info: 0
    AddressAlignment: 16
    EntrySize: 0
    Relocations [
      0x6 R_386_32 .rodata.str1.1 0x0
      0xB R_386_PC32 puts 0x0
      0x12 R_386_32 .rodata.str1.1 0x0
      0x17 R_386_PC32 puts 0x0
    ]
    SectionData (
      0000: 83EC04C7 04240000 0000E8FC FFFFFFC7  |.....$..........|
      0010: 04240600 0000E8FC FFFFFF31 C083C404  |.$.........1....|
      0020: C3                                   |.|
    )
  }
]
---------- snip ----------

Relocations and symbols can be output standalone or together with the section header as displayed in the example.
This feature set supports all tests in test/MC/COFF and test/MC/ELF (and I suspect all additional tests using elf-dump), making elf-dump and coff-dump deprecated.

Patch by Nico Rieck!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@178679 91177308-0d34-0410-b5e6-96231b3b80d8
2013-04-03 18:31:38 +00:00
..
Analysis X86TTI: Add accurate costs for itofp operations, based on the actual instruction counts. 2013-04-01 10:23:49 +00:00
Archive
Assembler Correct invalid debug info metadata 2013-03-12 19:04:24 +00:00
Bindings/Ocaml Use the attribute group reference instead of the attribute directly. 2013-02-20 07:48:23 +00:00
Bitcode Unify clang/llvm attributes for asan/tsan/msan (LLVM part) 2013-02-26 06:58:09 +00:00
BugPoint
CodeGen R600: Fix last ALU of a clause being emitted in a separate clause 2013-04-03 18:24:47 +00:00
DebugInfo Support and test template arguments for unions. 2013-04-02 22:55:56 +00:00
ExecutionEngine Add support for vector data types in the LLVM interpreter. 2013-04-01 15:53:30 +00:00
Feature Modify the LLVM assembly output so that it uses references to represent function attributes. 2013-02-20 07:21:42 +00:00
FileCheck
Instrumentation [tsan] make sure memset/memcpy/memmove are not inlined in tsan mode 2013-03-28 11:21:13 +00:00
Integer
JitListener
Linker
MC Implements low-level object file format specific output for COFF and 2013-04-03 18:31:38 +00:00
Object Implements low-level object file format specific output for COFF and 2013-04-03 18:31:38 +00:00
Other Check isDiscardableIfUnused, rather than hasLocalLinkage, when bumping 2013-03-04 22:40:44 +00:00
Scripts
TableGen Allow TableGen DAG arguments to be just a name. 2013-03-24 19:36:51 +00:00
tools Implements low-level object file format specific output for COFF and 2013-04-03 18:31:38 +00:00
Transforms Remove an optimization where we were changing an objc_autorelease into an objc_autoreleaseReturnValue. 2013-04-03 02:57:24 +00:00
Unit Disable ASan/MSan symbolization of reports in tests. 2013-03-27 13:11:12 +00:00
Verifier
YAMLParser
CMakeLists.txt Add llvm-symbolizer as test dependency. 2013-03-13 09:35:18 +00:00
lit.cfg Disable ASan/MSan symbolization of reports in tests. 2013-03-27 13:11:12 +00:00
lit.site.cfg.in Add asan/msan to the list of available features in LIT test runner 2013-03-26 08:27:39 +00:00
Makefile Reverted r176374. In some cases the lit.site.cfg file does not get generated in tools/clang/tools/extra. 2013-03-22 18:54:14 +00:00
Makefile.tests
TestRunner.sh