summaryrefslogtreecommitdiffstats
path: root/llvm/tools
Commit message (Collapse)AuthorAgeFilesLines
...
* LTO: Change signature of LTOCodeGenerator::setCodePICModel() to take a ↵Peter Collingbourne2015-08-212-15/+17
| | | | | | | | | Reloc::Model. This allows us to remove a bunch of code in LTOCodeGenerator and llvm-lto and has the side effect of improving error handling in the libLTO C API. llvm-svn: 245756
* [llvm-readobj] Add support for MachO DataInCodeDataCommand.Davide Italiano2015-08-213-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Example output: File: <stdin> Format: Mach-O arm Arch: arm AddressSize: 32bit DataInCode { Data offset: 300 Data size: 32 Data Regions [ DICE { Index: 0 Offset: 0 Length: 4 Kind: 1 } DICE { Index: 1 Offset: 4 Length: 4 Kind: 4 } DICE { Index: 2 Offset: 8 Length: 2 Kind: 3 } DICE { Index: 3 Offset: 10 Length: 1 Kind: 2 } ] } Differential Revision: http://reviews.llvm.org/D12084 llvm-svn: 245732
* llvm-lto: Re-order code.Peter Collingbourne2015-08-211-12/+10
| | | | | | | This saves us from needing to asave a pointer, and will be needed for an upcoming ownership change. llvm-svn: 245722
* TransformUtils: Introduce module splitter.Peter Collingbourne2015-08-216-1/+120
| | | | | | | | | | | | | The module splitter splits a module into linkable partitions. It will be used to implement parallel LTO code generation. This initial version of the splitter does not attempt to deal with the somewhat subtle symbol visibility issues around module splitting. These will be dealt with in a future change. Differential Revision: http://reviews.llvm.org/D12132 llvm-svn: 245662
* Replace some calls to isa<LandingPadInst> with isEHPad()David Majnemer2015-08-191-1/+1
| | | | | | No functionality change is intended. llvm-svn: 245487
* [PM/AA] Remove the last relics of the separate IPA library from LLVM,Chandler Carruth2015-08-186-6/+1
| | | | | | | | | | | | | | | | | | | | | folding the code into the main Analysis library. There already wasn't much of a distinction between Analysis and IPA. A number of the passes in Analysis are actually IPA passes, and there doesn't seem to be any advantage to separating them. Moreover, it makes it hard to have interactions between analyses that are both local and interprocedural. In trying to make the Alias Analysis infrastructure work with the new pass manager, it becomes particularly awkward to navigate this split. I've tried to find all the places where we referenced this, but I may have missed some. I have also adjusted the C API to continue to be equivalently functional after this change. Differential Revision: http://reviews.llvm.org/D12075 llvm-svn: 245318
* [CMake] Fix PR14200, llvm-config output misses -fno-rttiChris Bieneman2015-08-141-6/+9
| | | | | | | | This change adds RTTI and Exception flags to llvm-config's cxxflags. This solution is a minimal patch to solve the issue, and is recommended for the 3.7 release branch. Tom Stellard's outstanding work is the longer term solution. Patch By: David Wiberg llvm-svn: 245064
* [llvm-cxxdump] Correctly process relocations when given multiple filesDavid Majnemer2015-08-131-16/+10
| | | | | | | Archive files wouldn't lead to us reprocessing the section relocations for the new object files. llvm-svn: 244932
* Remove and forbid raw_svector_ostream::flush() calls.Yaron Keren2015-08-131-2/+0
| | | | | | | | | | After r244870 flush() will only compare two null pointers and return, doing nothing but wasting run time. The call is not required any more as the stream and its SmallString are always in sync. Thanks to David Blaikie for reviewing. llvm-svn: 244928
* Remove raw_svector_ostream::resync and users. It's no-op after r244870.Yaron Keren2015-08-132-4/+0
| | | | llvm-svn: 244888
* [llvm-symbolizer] Remove underscores and other C mangling on WindowsReid Kleckner2015-08-102-29/+81
| | | | | | | | | | | | | | | Summary: This makes it so that reports symbolized after the fact with llvm-symbolizer are more similar to the ones we generate at runtime with in-process dbghelp. Reviewers: samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D11785 llvm-svn: 244512
* Don't iterate over all sections in the ELFFile constructor.Rafael Espindola2015-08-103-20/+51
| | | | | | | With this we finally have an ELFFile that is O(1) to construct. This is helpful for programs like lld which have to do their own section walk. llvm-svn: 244510
* Use higher level functions in llvm-objdump.Rafael Espindola2015-08-101-17/+12
| | | | | | | This matches the rest of llvm-objdump better and isolates it from upcoming changes to ELFFile. llvm-svn: 244500
* Delete getDotSymtabSec.Rafael Espindola2015-08-102-11/+19
| | | | | | Another step in avoiding iterating over all sections in the ELFFile constructor. llvm-svn: 244496
* Use continue to reduce indentation. NFC.Rafael Espindola2015-08-101-17/+19
| | | | llvm-svn: 244480
* Recommit r244470+ r244471 together, the bot failed between them.Yaron Keren2015-08-101-7/+5
| | | | llvm-svn: 244476
* Revert r244470 and 244471 while looking into it.Yaron Keren2015-08-101-5/+7
| | | | llvm-svn: 244472
* Second part of r244470 (source file was unsaved in editor).Yaron Keren2015-08-101-5/+5
| | | | llvm-svn: 244471
* Really implement David Blaikie suggestion in full of seperatingYaron Keren2015-08-101-3/+1
| | | | | | | variable initialization from its usage in the push_back making collapse of the two statements unlikely even without a comment. llvm-svn: 244470
* Fully apply David Blaikie suggestion and add comment explaining why.Yaron Keren2015-08-101-1/+3
| | | | llvm-svn: 244461
* Modify r244405 to clearer code, per David Blaikie suggestion.Yaron Keren2015-08-101-2/+2
| | | | llvm-svn: 244455
* elf2yaml: Use existing section walk to find the symbol table. NFC.Rafael Espindola2015-08-101-4/+7
| | | | llvm-svn: 244447
* Fix dangling reference in DwarfLinker.cpp. The original codeYaron Keren2015-08-081-0/+1
| | | | | | | | | | | | Seq.emplace_back(Seq.back()); does not work as planned, since Seq.back() may become a dangling reference when emplace_back is called and possibly reallocates vector. To avoid this, the vector allocation should be reserved first and only then used. This broke test/tools/dsymutil/X86/custom-line-table.test with Visual C++ 2013. llvm-svn: 244405
* Convert getSymbolSection to return an ErrorOr.Rafael Espindola2015-08-0710-32/+35
| | | | | | | This function can actually fail since the symbol contains an index to the section and that can be invalid. llvm-svn: 244375
* Don't look for a SHT_DYNSYM in the ELFFile's constructor.Rafael Espindola2015-08-071-2/+9
| | | | | | Yet another step in not having it scan every section. llvm-svn: 244353
* Remove the symbol iteration functions that don't take a symbol table.Rafael Espindola2015-08-073-4/+4
| | | | | | Another step in making ELFFile's constructor not iterate over all sections. llvm-svn: 244351
* Add dynamic_table iterators back to ELF.h.Rafael Espindola2015-08-071-22/+15
| | | | | | | | | In tree they are only used by llvm-readobj, but it is also used by https://github.com/mono/CppSharp. While at it, add some missing error checking. llvm-svn: 244320
* [dsymutil] Use the new MCDwarfLineTableParams customization to emit linetablesFrederic Riss2015-08-071-10/+17
| | | | | | | | llvm-dsymutil has to be able to process debug info produced by other compilers which use different line table settings. The testcase wasn't generated by another compiler, but by a modified clang. llvm-svn: 244319
* ELF: Add AMDGPU specific defintionsTom Stellard2015-08-071-2/+24
| | | | | | | | | | Reviewers: rafael Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D11458 llvm-svn: 244303
* [llvm-readobj] Convert to range-loops.Davide Italiano2015-08-072-6/+4
| | | | llvm-svn: 244300
* Move to llvm-readobj code that is only used there.Rafael Espindola2015-08-062-22/+215
| | | | | | | | | | lld might end up using a small part of this, but it will be in a much refactored form. For now this unblocks avoiding the full section scan in the ELFFile constructor. This also has a (very small) error handling improvement. llvm-svn: 244282
* [dsymutil] Implement dSYM bundle creationFrederic Riss2015-08-061-6/+101
| | | | | | | | | | | | | | A dSYM bundle is a file hierarchy that looks slike this: <bundle name>.dSYM/ Contents/ Info.plist Resources/ DWARF/ <DWARF file(s)> This is the default output mode of dsymutil. llvm-svn: 244270
* [dsymutil] Add (unimplemented) --flat optionFrederic Riss2015-08-061-2/+12
| | | | | | | | | | | | | | dsymutil should by default generate dSYM bundles which are filesystem hierarchies containing the debug info and an additional Info.plist. Currently llvm-dsymutil emits raw binaries containing the debug info. This is what we call the 'flat mode'. Add a -f/-flat option that is supposed to enable that flat mode, but don't wire it for now, only pass it to the tests that will need it to stay functional once we do bundle generation by default. This basically makes this commit NFC and removes the noise from the actual commit that adds support for bundle generation. llvm-svn: 244269
* [llvm-objdump] Add missing call to exit(1).Davide Italiano2015-08-061-0/+1
| | | | | | Reported by: Rafael Espindola. llvm-svn: 244184
* [dsymutil] Do not create temporary files in -no-output mode.Frederic Riss2015-08-051-5/+19
| | | | | | | | | The files were never written to and then deleted, but they were created nonetheless. To prevent that, create a wrapper around the 2 variants of createUniqueFile and use the one that only does an access(Exists) call to check for name unicity in -no-output mode. llvm-svn: 244172
* [dsymutil] Add support for the -arch option.Frederic Riss2015-08-053-13/+50
| | | | | | | | This option allows to select a subset of the architectures when performing a universal binary link. The filter is done completely in the mach-o specific part of the code. llvm-svn: 244160
* Replace &vector[0] with vector.data() to avoid invalid dereference caught by ↵Nick Lewycky2015-08-051-4/+5
| | | | | | debug STL. Also move a '*' for consistency and fix an 80-col violation. llvm-svn: 244134
* -Wdeprecated clean by making LogBuilder move constructible so it can be ↵David Blaikie2015-08-052-4/+9
| | | | | | returned by value (in DifferenceEngine::logf) llvm-svn: 244129
* Revert "Fix `llvm-config` to emit the linker flag for the combined shared ↵Richard Diamond2015-08-054-50/+2
| | | | | | | | | | object built by autoconfig/make instead of the individual components." It seems I was wrong thinking `autoconf`/`make` only installed shared libraries if configured with `--enable-shared`, even if `--disable-static` is present. I'll re-address with a followup patch. This reverts commit r243297 for causing PR#24154. llvm-svn: 244108
* [dsymutil] Implement support for handling mach-o universal binaries as main ↵Frederic Riss2015-08-058-40/+203
| | | | | | | | | | | | | | | | | input/output. The DWARF linker isn't touched by this, the implementation links individual files and merges them together into a fat binary by calling out to the 'lipo' utility. The main change is that the MachODebugMapParser can now return multiple debug maps for a single binary. The test just verifies that lipo would be invoked correctly, but doesn't actually generate a binary. This mimics the way clang tests its external iplatform tools integration. llvm-svn: 244087
* [dsymutil] Introduce exit helper. NFC.Frederic Riss2015-08-052-3/+12
| | | | | | | | llvm-dsymutil will start creating temporary files in a followup commit. To ease the correct cleanup of this files, introduce a helper called to exit dsymutil. llvm-svn: 244086
* [dsymutil] Split some logic into a helper function. NFCFrederic Riss2015-08-051-10/+10
| | | | llvm-svn: 244085
* [llvm-objdump] Call exit(1) on error, i.e. fail early.Davide Italiano2015-08-054-89/+42
| | | | | | | | | | | | | Previously we kept going on partly corrupted input, which might result in garbage being printed, or even worse, random crashes. Rafael mentioned that this is the GNU behavior as well, but after some discussion we both agreed it's probably better to emit a reasonable error message and exit. As a side-effect of this commit, now we don't rely on global state for error codes anymore. objdump was the last tool in the toolchain which needed to be converted. Hopefully the old behavior won't sneak into the tree again. llvm-svn: 244019
* [llvm-objdump] Range-loopify. NFC intended.Davide Italiano2015-08-031-3/+2
| | | | llvm-svn: 243905
* [dwarfdump] Add support for dumping mach-o universal objectfilesFrederic Riss2015-08-031-8/+16
| | | | llvm-svn: 243862
* [dwarfdump] Move dumping to a helper function NFCFrederic Riss2015-08-031-6/+10
| | | | llvm-svn: 243861
* DwarfLinker: Use DIEValueList instead of DIE, NFCDuncan P. N. Exon Smith2015-08-021-2/+3
| | | | | | | Use `DIEValueList` as a pointer to either `DIEBlock` or `DIELoc` instead of `DIE`, since soon they won't inherit from the latter. llvm-svn: 243857
* [Mips] Support DT_MIPS_RLD_MAP_REL dynamic section tag in the llvm-readobjSimon Atanasyan2015-08-011-0/+2
| | | | llvm-svn: 243833
* [dsymutil] Support multiple input files on the command lineFrederic Riss2015-07-311-23/+33
| | | | llvm-svn: 243777
* New EH representation for MSVC compatibilityDavid Majnemer2015-07-311-0/+5
| | | | | | | | | | This introduces new instructions neccessary to implement MSVC-compatible exception handling support. Most of the middle-end and none of the back-end haven't been audited or updated to take them into account. Differential Revision: http://reviews.llvm.org/D11097 llvm-svn: 243766
OpenPOWER on IntegriCloud