summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-readobj/ELFDumper.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* [llvm-readobj] Use the new symbol API.Davide Italiano2015-06-081-7/+7
| | | | llvm-svn: 239286
* Fix the interpretation of a 0 st_name.Rafael Espindola2015-06-031-9/+13
| | | | | | | | | | | | | | The ELF spec is very clear: ----------------------------------------------------------------------------- If the value is non-zero, it represents a string table index that gives the symbol name. Otherwise, the symbol table entry has no name. -------------------------------------------------------------------------- In particular, a st_name of 0 most certainly doesn't mean that the symbol has the same name as the section. llvm-svn: 238899
* Simplify now that we always use an alignment of 2 for ELF files.Rafael Espindola2015-06-021-5/+3
| | | | | | This saves 123144 bytes out of llvm-nm on powerpc64le. llvm-svn: 238824
* [llvm-readobj/ELF] Teach how to decode DF_1_XXX flagsDavide Italiano2015-05-251-0/+32
| | | | | | | | | | | | | llvm-readobj -dynamic-table output. Before: 0x000000006FFFFFFB unknown After: 0x000000006FFFFFFB FLAGS_1 NOW ORIGIN Differential Revision: http://reviews.llvm.org/D9958 llvm-svn: 238151
* [llvm-readobj] Teach llvm-readobj to print PT_MIPS_ABIFLAGS program headerSimon Atanasyan2015-05-151-0/+1
| | | | llvm-svn: 237451
* [llvm-readobj/obj2yaml/yaml2obj] Support MIPS machine ELF header flagsSimon Atanasyan2015-05-081-1/+20
| | | | llvm-svn: 236807
* [llvm-readobj] Print .MIPS.abiflags section contentSimon Atanasyan2015-05-071-0/+121
| | | | | | | | | This change adds new flag -mips-abi-flags to the llvm-readobj. This flag forces printing of .MIPS.abiflags section content. https://dmz-portal.mips.com/wiki/MIPS_O32_ABI_-_FR0_and_FR1_Interlinking#10.2.1._.MIPS.abiflags llvm-svn: 236737
* [llvm-readobj/obj2yaml/yaml2obj] Support more MIPS ELF header flagsSimon Atanasyan2015-05-071-1/+6
| | | | llvm-svn: 236728
* [Mips] Support DT_MIPS_OPTIONS dynamic section tag in the llvm-readobjSimon Atanasyan2015-04-201-0/+2
| | | | llvm-svn: 235285
* Add support for Nuxi CloudABI.Ed Schouten2015-03-091-0/+1
| | | | | | | | | | | | | | CloudABI is a POSIX-like runtime environment built around the concept of capability-based security. More details: https://github.com/NuxiNL/cloudlibc CloudABI uses its own ELFOSABI number. This number has been allocated by the maintainers of ELF a couple of days ago. Reviewed by: echristo llvm-svn: 231681
* Add STB_GNU_UNIQUE to the ELF writer.Rafael Espindola2015-01-231-3/+4
| | | | | | This lets llvm-mc assemble files produced by gcc. llvm-svn: 226895
* Add a test that would have found the bug in r219829.Rafael Espindola2014-10-171-1/+2
| | | | llvm-svn: 220016
* Revert commit r219835 and r219829.Rafael Espindola2014-10-171-2/+1
| | | | | | | | | Revert "Correctly handle references to section symbols." Revert "Allow forward references to section symbols." Rui found a regression I am debugging. llvm-svn: 220010
* Correctly handle references to section symbols.Rafael Espindola2014-10-151-1/+2
| | | | | | | | | | | | | | | | | When processing assembly like .long .text we were creating a new undefined symbol .text. GAS on the other hand would handle that as a reference to the .text section. This patch implements that by creating the section symbols earlier so that they are visible during asm parsing. The patch also updates llvm-readobj to print the symbol number in the relocation dump so that the test can differentiate between two sections with the same name. llvm-svn: 219829
* Object: BSS/virtual sections don't have contentsDavid Majnemer2014-09-261-1/+1
| | | | | | | | | | | | Users of getSectionContents shouldn't try to pass in BSS or virtual sections. In all instances, this is a bug in the code calling this routine. N.B. Some COFF implementations (like CL) will mark their BSS sections as taking space on disk. This would confuse COFFObjectFile into thinking the section is larger than the file. llvm-svn: 218549
* [Mips] Support SHT_MIPS_ABIFLAGS section type flag in the llvm-readobj,Simon Atanasyan2014-07-131-0/+1
| | | | | | obj2yaml and yaml2obj tools. llvm-svn: 212908
* [llvm-readobj] Fix output of MIPS GOT without local and global entries.Simon Atanasyan2014-07-051-1/+1
| | | | llvm-svn: 212374
* [llvm-readobj] Fix member functions name style.Simon Atanasyan2014-06-181-13/+13
| | | | llvm-svn: 211152
* [llvm-readobj] Fix compile error.Simon Atanasyan2014-06-181-1/+1
| | | | llvm-svn: 211151
* [llvm-readobj][ELF] New `-mips-plt-got` command line option to outputSimon Atanasyan2014-06-181-0/+217
| | | | | | | | MIPS GOT section. Patch reviewed by Rafael Espindola. llvm-svn: 211150
* Remove 'using std::error_code' from tools.Rafael Espindola2014-06-131-6/+6
| | | | llvm-svn: 210876
* Remove all uses of 'using std::error_code' from headers.Rafael Espindola2014-06-131-0/+1
| | | | llvm-svn: 210866
* [llvm-readobj][ELF] Factor out the code retrieve ELF symbol informationSimon Atanasyan2014-06-101-35/+50
| | | | | | | | (section name, section index, full name) into the separate functions. No functional changes. llvm-svn: 210509
* [Object][ELF] Range-based loop simplification.Simon Atanasyan2014-06-041-13/+10
| | | | | | No functional changes. llvm-svn: 210164
* [Mips] Add more relocation types and MIPS specific e_flags constants.Simon Atanasyan2014-05-201-1/+3
| | | | llvm-svn: 209201
* [llvm-readobj] Print values of FLAGS and MIPS_FLAGS dynamic table tagsSimon Atanasyan2014-05-111-1/+61
| | | | | | in a human readable form. llvm-svn: 208489
* [llvm-readobj] Transform 'switch' with the only 'case' statementSimon Atanasyan2014-05-011-5/+2
| | | | | | | | to 'if' statement. No functional changes, llvm-svn: 207748
* [llvm-readobj] Add support for Mips specific ELF header e_flags.Simon Atanasyan2014-05-011-1/+29
| | | | llvm-svn: 207744
* [C++] Use 'nullptr'. Tools edition.Craig Topper2014-04-251-1/+2
| | | | llvm-svn: 207176
* Create .symtab_shndxr only when needed.Rafael Espindola2014-03-251-2/+4
| | | | | | | | | | | | | | | | | | | | | | | We need .symtab_shndxr if and only if a symbol references a section with an index >= 0xff00. The old code was trying to figure out if the section was needed ahead of time, making it a fairly dependent on the code actually writing the table. It was also somewhat conservative and would create the section in cases where it was not needed. If I remember correctly, the old structure was there so that the sections were created in the same order gas creates them. That was valuable when MC's support for ELF was new and we tested with elf-dump.py. This patch refactors the symbol table creation to another class and makes it obvious that .symtab_shndxr is really only created when we are about to output a reference to a section index >= 0xff00. While here, also improve the tests to use macros. One file is one section short of needing .symtab_shndxr, the second one has just the right number. llvm-svn: 204769
* Teach llvm-readobj to print human friendly description of reserved sections.Rafael Espindola2014-03-241-2/+22
| | | | llvm-svn: 204584
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-081-12/+12
| | | | | | class. llvm-svn: 203345
* Replace OwningPtr<T> with std::unique_ptr<T>.Ahmed Charles2014-03-061-4/+3
| | | | | | | | | | This compiles with no changes to clang/lld/lldb with MSVC and includes overloads to various functions which are used by those projects and llvm which have OwningPtr's as parameters. This should allow out of tree projects some time to move. There are also no changes to libs/Target, which should help out of tree targets have time to move, if necessary. llvm-svn: 203083
* Switch all uses of LLVM_OVERRIDE to just use 'override' directly.Craig Topper2014-03-021-12/+12
| | | | llvm-svn: 202621
* tools: remove unnecessary typenameSaleem Abdulrasool2014-01-301-2/+2
| | | | | | | This is acceptted by clang and gcc, but MSVC seems to balk at it. As it is unneeded, simply drop it. Fixes MSVC buildbots. llvm-svn: 200456
* tools: add support for decoding ARM attributesSaleem Abdulrasool2014-01-301-0/+44
| | | | | | | | Enhance the ARM specific parsing support in llvm-readobj to support attributes. This allows for simpler tests to validate encoding of the build attributes as specified in the ARM ELF specification. llvm-svn: 200450
* Re-sort #include lines again, prior to moving headers around.Chandler Carruth2014-01-131-2/+1
| | | | llvm-svn: 199080
* Use getError and remove the error_code operator.Rafael Espindola2014-01-081-2/+2
| | | | llvm-svn: 198799
* llvm-readobj: add support for ARM EHABI unwind infoSaleem Abdulrasool2014-01-081-0/+13
| | | | | | | | | | | | | | | This adds some preliminary support for decoding ARM EHABI unwinding information. The major functionality that remains from complete support is bytecode translation. Each Unwind Index Table is printed out as a separate entity along with its section index, name, offset, and entries. Each entry lists the function address, and if possible, the name, of the function to which it corresponds. The encoding model, personality routine or index, and byte code is also listed. llvm-svn: 198734
* [Mips] Add support for DT_MIPS_RLD_MAP and DT_MIPS_PLTGOT dynamicSimon Atanasyan2014-01-051-0/+4
| | | | | | section tags to the llvm-readobj. llvm-svn: 198561
* Add support for DT_VERxxx and DT_MIPS_xxx .dynamic section entries to theSimon Atanasyan2013-11-111-0/+22
| | | | | | | | | llvm-readobj. The patch reviewed by Michael Spencer. http://llvm-reviews.chandlerc.com/D2113 llvm-svn: 194421
* [Mips] Teach llvm-readobj to print MIPS-specific ELF program headers.Simon Atanasyan2013-10-071-21/+38
| | | | | | | The patch reviewed by Michael Spencer. http://llvm-reviews.chandlerc.com/D1846 llvm-svn: 192093
* Remove several unused variables.Rafael Espindola2013-10-011-5/+0
| | | | | | Patch by Alp Toker. llvm-svn: 191757
* ELF: Add support for the exclude section bit for gas compat.Benjamin Kramer2013-09-151-0/+1
| | | | llvm-svn: 190769
* Print string value for DT_RPATH and DT_RUNPATH.Joerg Sonnenberger2013-09-031-0/+4
| | | | llvm-svn: 189829
* [Object] Split the ELF interface into 3 parts.Michael J. Spencer2013-08-081-173/+127
| | | | | | | | * ELFTypes.h contains template magic for defining types based on endianess, size, and alignment. * ELFFile.h defines the ELFFile class which provides low level ELF specific access. * ELFObjectFile.h contains ELFObjectFile which uses ELFFile to implement the ObjectFile interface. llvm-svn: 188022
* Remove the mblaze backend from llvm.Rafael Espindola2013-07-251-3/+1
| | | | | | Approval in here http://lists.cs.uiuc.edu/pipermail/llvmdev/2013-July/064169.html llvm-svn: 187145
* Handle relocations that don't point to symbols.Rafael Espindola2013-06-051-3/+3
| | | | | | | | In ELF (as in MachO), not all relocations point to symbols. Represent this properly by using a symbol_iterator instead of a SymbolRef. Update llvm-readobj ELF's dumper to handle relocatios without symbols. llvm-svn: 183284
* Introduce convenience typedefs for the 4 ELF object types.Rafael Espindola2013-05-091-26/+16
| | | | llvm-svn: 181509
* Change getRelocationAdditionalInfo to be ELF only.Rafael Espindola2013-05-091-4/+4
| | | | | | | It was only implemented for ELF where it collected the Addend, so this patch also renames it to getRelocationAddend. llvm-svn: 181502
OpenPOWER on IntegriCloud