| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
| |
This partially reverts r215844 by removing test objdump-reloc-shared.test which stated GNU objdump doesn't print relocations, it does.
In executable and shared object ELF files, relocations in the file contain the final virtual address rather than section offset so this is adjusted to display section offset.
Differential revision: http://reviews.llvm.org/D15965
llvm-svn: 263971
|
|
|
|
|
|
| |
X86 target supporting. NFC.
llvm-svn: 263781
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
to only print the first private header.
Which for Mach-O files only prints the Mach header and not the subsequent load
commands. Which is used by scripts to match what the darwin otool(1) with the
-h flag does without the -l flag.
For non-Mach-O files it has the same functionality as -private-headers (with
the trailing ’s’).
rdar://24158331
llvm-svn: 257548
|
|
|
|
|
|
|
|
|
| |
Most linked executables do not have a symbol table in COFF.
However, it is pretty typical to have some export entries. Use those
entries to inform the disassembler about potential function definitions
and call targets.
llvm-svn: 253429
|
|
|
|
|
|
|
|
| |
In `MachOObjectFile::getSymbolType` we currently always return `SymbolRef::ST_Function` for symbols from any section. In order for llvm-symbolizer to correctly symbolize Mach-O globals, symbols from data and BSS sections should return `SymbolRef::ST_Data`.
Differential Revision: http://reviews.llvm.org/D14576
llvm-svn: 252867
|
|
|
|
|
|
|
|
|
|
| |
ArchiveMemberHeader, suggestion by Rafael Espíndola.
Also The clang-x86-win2008-selfhost bot still does not like the
malformed-machos 00000031.a test, so removing it for now. All
the other bots are fine with it however.
llvm-svn: 250222
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
‘-arch x86_64’
flag as it was a Mach-O universal file.
The default as to which architecture slice that is dumped without an -arch flag
depends on the host architecture and the contents of the universal file. The
malformed archive 00000031.a file has both an x86_64 and i386 slice. So for
for x86_64 hosts only that slice is dumped, for non-x86_64 hosts, which is many
of the bots both slices are dumped.
The test is intended to only check that the malformation of the x86_64 which
has a non-decimal characters in the size field of the archive header so it no
longer crashes.
The problem turned out that the i388 slice of the malformed archive had a
different malformation which was causing the non-x86_64 bots to get this error:
llvm-objdump -macho -disassemble -arch i386 00000031.a
Archive : .00000031.a
00000031.a(c_start.o):
LLVM ERROR: Symbol name entry points before beginning or past end of file.
and causing the test as it was written to fail. So by adding ‘-arch x86_64’ it
should correct the test and the malformation on the i388 slice will not be
dumped.
Also the removal of the malformed-machos mem-crup-0261.macho was not causing
the issue so that is put back in.
Sorry for the churn on these tests, Kev
llvm-svn: 250184
|
|
|
|
|
|
| |
on some of the bots. I’ll remove this test for now.
llvm-svn: 250141
|
|
|
|
|
|
|
| |
restore the malformed-machos 00000031.a test. Hopefully this will get all the
build bots happy again. I’ll again keep an eye on them.
llvm-svn: 250130
|
|
|
|
|
|
| |
of the build bots get a different error on that malformed file.
llvm-svn: 250120
|
|
|
|
|
|
|
|
|
| |
that caused aborts. This was because of the characters of the ‘Size’ field in
the archive header did not contain decimal characters.
rdar://22983603
llvm-svn: 250117
|
|
|
|
|
|
| |
rdar://22983603
llvm-svn: 249927
|
|
|
|
|
|
|
|
|
|
|
| |
The COFFSymbolRef::isFunctionDefinition() function tests for several conditions
that are not related to whether a symbol is a function, but rather whether
the symbol meets the requirements for a function definition auxiliary record,
which excludes certain symbols such as internal functions and undefined
references. The test we need to determine the symbol type is much simpler:
we only need to compare the complex type against IMAGE_SYM_DTYPE_FUNCTION.
llvm-svn: 244195
|
|
|
|
| |
llvm-svn: 243049
|
|
|
|
|
|
|
|
|
|
|
| |
Only common symbol on MachO and COFF have a size.
For COFF we already had a custom format.
For MachO, there is no native objdump and we were printing it as ELF. Now
we only print the sizes for symbols that actually have them.
llvm-svn: 240422
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MachO and COFF quite reasonably only define the size for common symbols.
We used to try to figure out the "size" by computing the gap from one symbol to
the next.
This would not be correct in general, since a part of a section can belong to no
visible symbol (padding, private globals).
It was also really expensive, since we would walk every symbol to find the size
of one.
If a caller really wants this, it can sort all the symbols once and get all the
gaps ("size") in O(n log n) instead of O(n^2).
On MachO this also has the advantage of centralizing all the checks for an
invalid n_sect.
llvm-svn: 238028
|
|
|
|
|
|
|
|
|
|
| |
-non-verbose
option to print the archive headers using raw numeric values. Also add the -archive-member-offsets
for use with these to also trigger printing of the offset of the archive member from the start
of the archive.
llvm-svn: 236252
|
|
|
|
|
|
|
|
| |
Mach-O files
with the -section option as objc_protocol_t structs.
llvm-svn: 235141
|
|
|
|
|
|
| |
with the existing -objc-meta-data and -macho options for Mach-O files.
llvm-svn: 235119
|
|
|
|
|
|
| |
test macho-objc-meta-data.test had a line it shouldn't have had.
llvm-svn: 234190
|
|
|
|
|
|
| |
with the existing -objc-meta-data and -macho options for Mach-O files.
llvm-svn: 234185
|
|
|
|
|
|
|
|
|
|
| |
print the Objective-C runtime meta data for Mach-O files.
There are three types of Objective-C runtime meta data, Objc2 64-bit,
Objc2 32-bit and Objc1 32-bit. This prints the first of these types. The
changes to print the others will follow next.
llvm-svn: 233840
|
|
|
|
|
|
| |
-disassemble to not symbolic operands when disassembling.
llvm-svn: 232558
|
|
|
|
|
|
| |
-disassemble or -section to not print the leading addresses on each line.
llvm-svn: 232547
|
|
|
|
|
|
| |
-disassemble to disassemble just one symbol’s instructions.
llvm-svn: 232503
|
|
|
|
|
|
|
| |
to print the Mach-O dynamic shared libraries used by a linked image or the
library id of a shared library.
llvm-svn: 232406
|
|
|
|
|
|
|
|
|
|
| |
using numeric values and not their symbolic constant names.
The routines that print Mach-O stuff already had a verbose parameter and this
change is just changing the passing true to passing !NonVerbose. With just a
couple of fixes and a bunch of test case updates.
llvm-svn: 232182
|
|
|
|
|
|
| |
Mach-O info plist section as strings.
llvm-svn: 231974
|
|
|
|
|
|
|
|
|
|
|
| |
literal pointer sections
with the Mach-O S_LITERAL_POINTERS section type.
Also fix the printing of the leading addresses for literal sections to be consistent and
not print the 0x prefix. Updated test cases to match.
llvm-svn: 229548
|
|
|
|
|
|
| |
sections with the Mach-O S_{4,8,16}BYTE_LITERALS section types.
llvm-svn: 228465
|
|
|
|
|
|
|
|
| |
‘C’ string
sections with the Mach-O S_CSTRING_LITERALS section type.
llvm-svn: 228198
|
|
|
|
|
|
|
|
| |
sections
that have attributes indicating they contain instructions.
llvm-svn: 228101
|
|
|
|
|
|
|
|
|
|
| |
segname,sectname to specify a Mach-O section to print. The printing is based on
the section type or section attributes.
The printing of the module initialization and termination section types is printed
with this change. Printing of other section types will be added next.
llvm-svn: 227649
|
|
|
|
|
|
|
|
| |
archive header size field.
This problem showed up with the clang-cmake-armv7-a15-full bot. Thanks to Renato Golin for his help.
llvm-svn: 226936
|
|
|
|
|
|
| |
indirect symbol table to llvm-objdump.
llvm-svn: 226848
|
|
|
|
|
|
| |
Mach-O parser).
llvm-svn: 226612
|
|
|
|
|
|
|
|
|
| |
check the size
while I once again try to figure out why only the clang-cmake-armv7-a15-full bot
is getting that value wrong.
llvm-svn: 226345
|
|
|
|
|
|
|
|
| |
-archive-headers option
and tweak its use in llvm-objdump. Add back the test case for the -archive-headers option.
llvm-svn: 226332
|
|
|
|
|
|
|
| |
removing the macho-archive-headers.test added with r226228 that it is
failing on for now while I try to figure out what is going on.
llvm-svn: 226241
|
|
|
|
|
|
| |
the macho-archive-headers.test added with r226228.
llvm-svn: 226239
|
|
|
|
|
|
| |
archive headers to llvm-objdump.
llvm-svn: 226228
|
|
|
|
|
|
| |
universal headers to llvm-objdump.
llvm-svn: 225537
|
|
|
|
|
|
|
|
|
|
|
|
| |
used with
options other than just -disassemble so that universal files can be used with other
options combined with -arch options.
No functional change to existing options and use. One test case added for the
additional functionality with a universal file an a -arch option.
llvm-svn: 225383
|
|
|
|
| |
llvm-svn: 224792
|
|
|
|
|
|
| |
-private-headers.
llvm-svn: 224627
|
|
|
|
|
|
| |
-private-headers.
llvm-svn: 224616
|
|
|
|
|
|
| |
-private-headers.
llvm-svn: 224607
|
|
|
|
|
|
| |
-private-headers.
llvm-svn: 224548
|
|
|
|
|
|
| |
-private-headers.
llvm-svn: 224534
|
|
|
|
|
|
|
|
|
|
| |
-private-headers.
Also corrected the name of the load command to not end in an ’S’ as well as corrected
the name of the MachO::linker_option_command struct and other places that had the
word option as plural which did not match the Mac OS X headers.
llvm-svn: 224485
|