| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
| |
llvm-svn: 349710
|
|
|
|
|
|
|
|
|
| |
Should fix the http://lab.llvm.org:8011/builders/polly-amd64-linux/builds/25876/steps/build/logs/stdio:
/home/grosser/buildslave/polly-amd64-linux/llvm.src/tools/llvm-objdump/llvm-objdump.cpp:539:25: error: conditional expression is ambiguous; 'std::string' (aka 'basic_string<char>') can be converted to 'typename std::remove_reference<StringRef>::type' (aka 'llvm::StringRef') and vice versa
Target = Demangle ? demangle(*SymName) : *SymName;
llvm-svn: 349617
|
|
|
|
|
|
| |
Move the helper method before the first incocation in the file.
llvm-svn: 349614
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
relocations.
This is https://bugs.llvm.org/show_bug.cgi?id=40009,
llvm-objdump does not demangle the symbols when prints symbol
table and/or relocations.
Patch teaches it to do that.
Differential revision: https://reviews.llvm.org/D55821
llvm-svn: 349613
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Add Swift 4.1, Swift 4.2, and Swift 5 version numbers to objdump's
MachODump's print_imae_info routines.
rdar://46548425
Reviewers: pete, lhames, bob.wilson
Reviewed By: pete, bob.wilson
Subscribers: bob.wilson, llvm-commits
Differential Revision: https://reviews.llvm.org/D55442
llvm-svn: 348632
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
When using option `-x` (--all-headers), it will print `Sections`, `Symbol Table`, `Program Header` ...
`Sections` and `Symbol Table` will be connected together.
Before:
```
Sections:
Idx Name Size Address Type
0 00000000 0000000000000000
...
29 .shstrtab 0000011a 0000000000000000
SYMBOL TABLE:
...
```
After:
```
Sections:
Idx Name Size Address Type
0 00000000 0000000000000000
...
29 .shstrtab 0000011a 0000000000000000
SYMBOL TABLE:
...
```
Reviewers: Higuoxing
Reviewed By: Higuoxing
Subscribers: llvm-commits, jhenderson
Differential Revision: https://reviews.llvm.org/D54665
llvm-svn: 347135
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
According to `MaskRay`, use `auto` for type inference, according to coding standards.
Delete some comments, because these comments can be easily inferred from codes.
Reviewers: jhenderson, MaskRay
Reviewed By: jhenderson
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D54573
llvm-svn: 346946
|
|
|
|
| |
llvm-svn: 346851
|
|
|
|
|
|
| |
Use helpers from Support/WithError.h to print errors.
llvm-svn: 346623
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Improve compatibility with GNU objdump by showing `O` next to
global symbol names, instead of a blank space.
Patch by Higuoxing (Xing).
Reviewers: MaskRay
Differential Revision: https://reviews.llvm.org/D54380
llvm-svn: 346610
|
|
|
|
|
|
|
|
| |
In a lot of places an empty string was passed as the ErrorBanner to
logAllUnhandledErrors. This patch makes that argument optional to
simplify the call sites.
llvm-svn: 346604
|
|
|
|
|
|
|
| |
Slight improvement to help output of llvm-objdump that exposes the
shorter -t flag for -syms instead of it being hidden away.
llvm-svn: 345704
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This addresses PR39407 (https://bugs.llvm.org/show_bug.cgi?id=39407)
improving compatibility with GNU binutils counterparts.
Reviewed By: kristina
Patch by Higuoxing (Xing).
Differential Revision: https://reviews.llvm.org/D53804
llvm-svn: 345703
|
|
|
|
|
|
|
|
|
|
|
| |
This adds support for '--syms' as an alias of '-t' for llvm-objdump,
fixing PR39406 (https://bugs.llvm.org/show_bug.cgi?id=39406).
Patch by Higuoxing (Xing).
Differential Revision: https://reviews.llvm.org/D53803
llvm-svn: 345697
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes PR39402. The crash was caused when dereferencing nullptr in
DumpObject and printArchiveChild.
Reviewed By: jhenderson
Differential Revision: https://reviews.llvm.org/D53690
Patch by Xing GUO
llvm-svn: 345503
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes PR39404.
Reviewed By: jhenderson
Patch by Xing Guo
Differential Revision: https://reviews.llvm.org/D53576
llvm-svn: 345495
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Changed the format call to match the surrounding code. Previously it was
printing an unsigned int while the return type being printed was
long unsigned int or wider. This caused problems for big-endian systems
which were discovered on mips64.
Also, the printed address had less characters than it should because the
character count was directly obtained from the number of bytes in the
address.
The tests were adapted to fit this fix and now use longer addresses.
Patch by Milos Stojanovic.
Differential Revision: https://reviews.llvm.org/D53403
llvm-svn: 344818
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: The convenience wrapper in STLExtras is available since rL342102.
Reviewers: dblaikie, javed.absar, JDevlieghere, andreadb
Subscribers: MatzeB, sanjoy, arsenm, dschuff, mehdi_amini, sdardis, nemanjai, jvesely, nhaehnle, sbc100, jgravelle-google, eraman, aheejin, kbarton, JDevlieghere, javed.absar, gbedwell, jrtc27, mgrang, atanasyan, steven_wu, george.burgess.iv, dexonsmith, kristina, jsji, llvm-commits
Differential Revision: https://reviews.llvm.org/D52573
llvm-svn: 343163
|
|
|
|
|
|
|
|
|
|
| |
When using -g and -dsym, llvm-objdump opens the dsym file and keeps the
MachOObjectFile alive, while the memory buffer that the MachOObjectFile
was based on gets destroyed.
Differential Revision: https://reviews.llvm.org/D51365
llvm-svn: 341209
|
|
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D50204
llvm-svn: 340611
|
|
|
|
| |
llvm-svn: 340340
|
|
|
|
| |
llvm-svn: 340221
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
LLVM triple normalization is handling "unknown" and empty components
differently; for example given "x86_64-unknown-linux-gnu" and
"x86_64-linux-gnu" which should be equivalent, triple normalization
returns "x86_64-unknown-linux-gnu" and "x86_64--linux-gnu". autoconf's
config.sub returns "x86_64-unknown-linux-gnu" for both
"x86_64-linux-gnu" and "x86_64-unknown-linux-gnu". This changes the
triple normalization to behave the same way, replacing empty triple
components with "unknown".
This addresses PR37129.
Differential Revision: https://reviews.llvm.org/D50219
llvm-svn: 339294
|
|
|
|
| |
llvm-svn: 338951
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
With Mach-O, there is a flag requirement discrepancy between working with
universal binaries and thin binaries. Many flags that don't require the `-macho`
flag (for example `-private-headers` and `-disassemble`) fail to work on
universal binaries unless `-macho` is given. When this happens, the error
message is unhelpful, stating:
The file was not recognized as a valid object file.
Which can lead to confusion.
This change allows generic flags to be used on universal binaries with and
without the `-macho` flag. This means flags that can be used for thin files can
be used consistently with fat files too.
To do this, the universal binary support within `ParseInputMachO()` is extracted
into a new function. This new function is called directly from `DumpInput()`
when the input binary is universal. Additionally the `-arch` flag validation in
`ParseInputMachO()` was extracted to be reused.
Reviewers: compnerd
Reviewed By: compnerd
Subscribers: keith, llvm-commits
Differential Revision: https://reviews.llvm.org/D48702
llvm-svn: 338792
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The standard library functions ::isprint/std::isprint have platform-
and locale-dependent behavior which makes LLVM's output less
predictable. In particular, regression tests my fail depending on the
implementation of these functions.
Implement llvm::isPrint in StringExtras.h with a standard behavior and
replace all uses of ::isprint/std::isprint by a call it llvm::isPrint.
The function is inlined and does not look up language settings so it
should perform better than the standard library's version.
Such a replacement has already been done for isdigit, isalpha, isxdigit
in r314883. gtest does the same in gtest-printers.cc using the following
justification:
// Returns true if c is a printable ASCII character. We test the
// value of c directly instead of calling isprint(), which is buggy on
// Windows Mobile.
inline bool IsPrintableAscii(wchar_t c) {
return 0x20 <= c && c <= 0x7E;
}
Similar issues have also been encountered by Julia:
https://github.com/JuliaLang/julia/issues/7416
I noticed the problem myself when on Windows isprint('\t') started to
evaluate to true (see https://stackoverflow.com/questions/51435249) and
thus caused several unit tests to fail. The result of isprint doesn't
seem to be well-defined even for ASCII characters. Therefore I suggest
to replace isprint by a platform-independent version.
Differential Revision: https://reviews.llvm.org/D49680
llvm-svn: 338034
|
|
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D49016
llvm-svn: 337902
|
|
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D49043
llvm-svn: 337401
|
|
|
|
|
|
|
|
|
|
|
| |
Seems r337361 is the reason of the following ARM BB failures:
http://lab.llvm.org:8011/builders/clang-cmake-armv8-quick
http://lab.llvm.org:8011/builders/clang-cmake-armv8-full/builds/4633
Reason is unclear to me, other bots are OK.
If this will not help, I'll revert r337361.
llvm-svn: 337371
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Imagine we have a file with few sections, and one of them is .foo
with index N != 0.
Problem is that when llvm-objdump is given a -section=.foo parameter
it lists .foo as a section at index 0. That makes impossible to write
test cases which needs to find the index of the particular section,
while ignoring dumping of others.
The patch fixes that.
Differential revision: https://reviews.llvm.org/D49372
llvm-svn: 337361
|
|
|
|
|
|
|
| |
This reverts commit 3a44ccd156e0edd2e89226f8ed63928e227900bb.
This reverts commit d5cfc836bb5552e20507d3612d13ff66ff9e36a0.
llvm-svn: 336829
|
|
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D49043
llvm-svn: 336816
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Add support for two additional ObjC image info flags: `IS_SIMULATED` and
`HAS_CATEGORY_CLASS_PROPERTIES`.
`IS_SIMULATED` indicates a Mach-O binary built for iOS simulator.
`HAS_CATEGORY_CLASS_PROPERTIES` indicates a Mach-O binary built by a compiler
that supports class properties in categories.
Reviewers: enderby, compnerd
Reviewed By: compnerd
Subscribers: keith, llvm-commits
Differential Revision: https://reviews.llvm.org/D48568
llvm-svn: 336411
|
|
|
|
|
|
| |
This reverts commit 8c4cc472e7a67bd3b2b20cc4cf32d31af29bc7e9.
llvm-svn: 336402
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Add support for two additional ObjC image info flags: `IS_SIMULATED` and
`HAS_CATEGORY_CLASS_PROPERTIES`.
`IS_SIMULATED` indicates a Mach-O binary built for iOS simulator.
`HAS_CATEGORY_CLASS_PROPERTIES` indicates a Mach-O binary built by a compiler
that supports class properties in categories.
Reviewers: enderby, compnerd
Reviewed By: compnerd
Subscribers: keith, llvm-commits
Differential Revision: https://reviews.llvm.org/D48568
llvm-svn: 336399
|
|
|
|
| |
llvm-svn: 336357
|
|
|
|
| |
llvm-svn: 336284
|
|
|
|
|
|
| |
https://reviews.llvm.org/D48554
llvm-svn: 335903
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: paulsemel, echristo
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D48622
llvm-svn: 335785
|
|
|
|
|
|
|
|
| |
This option prints dynamic relocation entries of the given file
Differential Revision: https://reviews.llvm.org/D47493
llvm-svn: 334196
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
"Unknown" for platforms that were not manually added into the switch
did not make sense at all. Now it prints Target + addend for all
elf-machines that were not explicitly mentioned.
Addresses PR21059 and PR25124.
Original author: fedor.sergeev
Reviewers: jyknight, espindola, fedor.sergeev
Reviewed By: jyknight
Subscribers: eraman, dcederman, jfb, dschuff, aheejin, llvm-commits
Differential Revision: https://reviews.llvm.org/D36464
llvm-svn: 333726
|
|
|
|
|
|
|
|
| |
Debug BUILD_SHARED_LIBS build was broken by rL332305
Differential Revision: https://reviews.llvm.org/D46859
llvm-svn: 332315
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Change relocation output so that relocation information follows
individual instructions rather than clustering them at the end
of packets.
This change required shifting block of code but the actual change
is in HexagonPrettyPrinter's PrintInst.
Differential Revision: https://reviews.llvm.org/D46728
llvm-svn: 332283
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a follow-up to r331272.
We've been running doxygen with the autobrief option for a couple of
years now. This makes the \brief markers into our comments
redundant. Since they are a visual distraction and we don't want to
encourage more \brief markers in new code either, this patch removes
them all.
Patch produced by
for i in $(git grep -l '\@brief'); do perl -pi -e 's/\@brief //g' $i & done
https://reviews.llvm.org/D46290
llvm-svn: 331275
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We've been running doxygen with the autobrief option for a couple of
years now. This makes the \brief markers into our comments
redundant. Since they are a visual distraction and we don't want to
encourage more \brief markers in new code either, this patch removes
them all.
Patch produced by
for i in $(git grep -l '\\brief'); do perl -pi -e 's/\\brief //g' $i & done
Differential Revision: https://reviews.llvm.org/D46290
llvm-svn: 331272
|
|
|
|
|
|
|
|
| |
Subscribers: jfb, dschuff, jgravelle-google, aheejin, sunfish, llvm-commits
Differential Revision: https://reviews.llvm.org/D46134
llvm-svn: 330959
|
|
|
|
|
|
|
|
| |
And use it in llvm-objdump.
Differential Revision: https://reviews.llvm.org/D46092
llvm-svn: 330957
|
|
|
|
| |
llvm-svn: 330364
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When disassembling with -D, skip virtual sections by printing "..." for
each symbol.
This patch also implements `MachOObjectFile::isSectionVirtual`.
Test case comes from:
```
.zerofill __DATA,__common,_data64unsigned,472,3
```
Differential Revision: https://reviews.llvm.org/D45824
llvm-svn: 330342
|
|
|
|
|
|
|
|
|
|
|
| |
We have a few functions that virtually all command wants to run on
process startup/shutdown. This patch adds InitLLVM class to do that
all at once, so that we don't need to copy-n-paste boilerplate code
to each llvm command's main() function.
Differential Revision: https://reviews.llvm.org/D45602
llvm-svn: 330046
|