summaryrefslogtreecommitdiffstats
path: root/llvm/tools
Commit message (Collapse)AuthorAgeFilesLines
...
* Support for function summary index bitcode sections and files.Teresa Johnson2015-10-043-1/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The bitcode format is described in this document: https://drive.google.com/file/d/0B036uwnWM6RWdnBLakxmeDdOeXc/view For more info on ThinLTO see: https://sites.google.com/site/llvmthinlto The first customer is ThinLTO, however the data structures are designed and named more generally based on prior feedback. There are a few comments regarding how certain interfaces are used by ThinLTO, and the options added here to gold currently have ThinLTO-specific names as the behavior they provoke is currently ThinLTO-specific. This patch includes support for generating per-module function indexes, the combined index file via the gold plugin, and several tests (more are included with the associated clang patch D11908). Reviewers: dexonsmith, davidxl, joker.eph Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D13107 llvm-svn: 249270
* [llvm-size] Fix time to check if time of use bug.Davide Italiano2015-10-031-8/+0
| | | | | | This was the last tool relying on this pattern. llvm-svn: 249244
* [libFuzzer] make LLVMFuzzerTestOneInput (the fuzzer target function) return ↵Kostya Serebryany2015-10-022-4/+6
| | | | | | int instead of void. The actual return value is not *yet* used (and expected to be 0). This change is API breaking, so the fuzzers will need to be updated. llvm-svn: 249214
* [CMake] We need to explicitly add llvm-config before clang so that ↵Chris Bieneman2015-10-021-2/+3
| | | | | | | | LLVM_BUILD_EXTERNAL_COMPILER_RT can depend on llvm-config. This patch is a required stepping stone to fix PR14109. llvm-svn: 249202
* dsymutil: Also ignore the ByteSize when building the DeclContext cache forAdrian Prantl2015-10-021-59/+54
| | | | | | | | clang modules. Forward decls of ObjC interfaces don't have a bytesize. llvm-svn: 249110
* [PATCH] D13360: [llvm-objdump] Teach -d about AArch64 mapping symbolsDavide Italiano2015-10-011-0/+49
| | | | | | | | | | AArch64 uses $d* and $x* to interleave between text and data. llvm-objdump didn't know about this so it ended up printing garbage. This patch is a first step towards a solution of the problem. Differential Revision: http://reviews.llvm.org/D13360 llvm-svn: 249083
* Fix printing of 64 bit values and make test more strict.Rafael Espindola2015-10-011-5/+4
| | | | llvm-svn: 249043
* [llvm-objdump] Fix time of check to time of use bug.Davide Italiano2015-10-011-3/+0
| | | | | | | There's already a test that covers this situation, so we should be fine. llvm-svn: 248976
* InstrProf: Support for value profiling in the indexed profile formatJustin Bogner2015-09-291-7/+22
| | | | | | | | | Add support to the indexed instrprof reader and writer for the format that will be used for value profiling. Patch by Betul Buyukkurt, with minor modifications. llvm-svn: 248833
* [llvm-pdbdump] Add include-only filters.Zachary Turner2015-09-294-30/+64
| | | | | | | | | | | | | | | | PDB files have a lot of noise in them, with hundreds (or thousands) of symbols from system libraries and compiler generated types. If you're only looking for a specific type, this can be problematic. This CL allows you to display *only* types, variables, or compilands matching a particular pattern. These filters can even be combined with exclude filters. Include-only filters are given priority, so that first the set of items to display is limited only to those that match the include filters, and then the set of exclude filters is applied to those. If there are no include filters specified, then it means "display everything". llvm-svn: 248822
* Fix Clang-tidy modernize-use-nullptr warnings in examples and include ↵Hans Wennborg2015-09-291-4/+5
| | | | | | | | | | directories; other minor cleanups. Patch by Eugene Zelenko! Differential Revision: http://reviews.llvm.org/D13172 llvm-svn: 248811
* [llvm-mc-fuzzer] Fix -jobs option.Daniel Sanders2015-09-261-4/+1
| | | | | | | | | The fuzzer argument parser will ignore all options starting with '--' so operation mode options should begin with '--' and fuzzer options should begin with '-'. Fuzzer arguments must still follow --fuzzer-args so that they escape the parsing performed by the CommandLine library. llvm-svn: 248671
* dsymutil: Fix the condition to distinguish module imports form definitions.Adrian Prantl2015-09-241-1/+1
| | | | llvm-svn: 248512
* [objdump] Make iterator operator* return a reference.Benjamin Kramer2015-09-241-1/+1
| | | | | | | This is closer to the expected behavior of an iterator and avoids awkward warnings from clang's -Wrange-loop-analysis below. llvm-svn: 248497
* dsymutil: Don't prune forward declarations inside a module definition.Adrian Prantl2015-09-231-6/+9
| | | | llvm-svn: 248428
* dsymutil: Resolve forward decls for types defined in clang modules.Adrian Prantl2015-09-231-33/+91
| | | | | | | | | This patch extends llvm-dsymutil's ODR type uniquing machinery to also resolve forward decls for types defined in clang modules. http://reviews.llvm.org/D13038 llvm-svn: 248398
* dsymutil: print a warning when there is a module hash mismatch.Adrian Prantl2015-09-231-13/+34
| | | | | | | This also updates the module binaries in the test directory because their module hash mismatched. llvm-svn: 248396
* [dsymutil] Plug a memory leak.Benjamin Kramer2015-09-231-2/+2
| | | | llvm-svn: 248372
* dsymutil: Fix a comment. [-Wdocumentation]NAKAMURA Takumi2015-09-231-1/+1
| | | | llvm-svn: 248353
* dsymutil: Follow references to clang modules and recursively clone theAdrian Prantl2015-09-221-7/+135
| | | | | | | | debug info. This does not yet resolve external type references. llvm-svn: 248331
* dsymutil: Make -oso-prepend-path available to DwarfLinker.Adrian Prantl2015-09-222-0/+2
| | | | | | NFC llvm-svn: 248312
* dsymutil: Make resolveDIEReference and getUnitForOffset static functions.Adrian Prantl2015-09-221-16/+12
| | | | | | NFC. llvm-svn: 248311
* dsymutil: Make DwarfLinker::reportWarning() public. (NFC)Adrian Prantl2015-09-221-3/+3
| | | | llvm-svn: 248310
* Remove macho-dump. Its functionality is now covered by llvm-readobj.Davide Italiano2015-09-226-483/+1
| | | | | | | Approved by: Rafael Espindola, Eric Christopher, Jim Grosbach, Alex Rosenberg llvm-svn: 248302
* Fix a typo.Adrian Prantl2015-09-221-4/+4
| | | | llvm-svn: 248283
* [llvm-mc-fuzzer] Support untested instruction discovery for variable length ↵Daniel Sanders2015-09-221-0/+11
| | | | | | | | | | | | | | | | | | | | | instruction sets like microMIPS. Summary: For fixed length instructions, we can use -max_len to limit the fuzzer to a single instruction. This doesn't work for variable length instruction sets since a 4-byte input could consist of one 4-byte instruction or two 2-byte instructions. This patch adds a --insn-limit to llvm-mc-fuzzer to limit the input in terms of instructions processed. Reviewers: kcc Subscribers: kcc, llvm-commits Differential Revision: http://reviews.llvm.org/D12960 llvm-svn: 248253
* [llvm-readobj/MachO] Ensure we always have valid CmdName/SegmentName.Davide Italiano2015-09-221-2/+2
| | | | | | | | Otherwise we might end up printing garbage while dumping. Differential Revision: http://reviews.llvm.org/D13041 llvm-svn: 248239
* Avoid SEGFAULT if a requested symbol section is absent.Rafael Espindola2015-09-211-0/+2
| | | | | | Patch by Igor Kudrin! llvm-svn: 248194
* Use makeArrayRef or None to avoid unnecessarily mentioning the ArrayRef type ↵Craig Topper2015-09-214-14/+14
| | | | | | extra times. NFC llvm-svn: 248140
* [obj2yaml] Fix "time of check to time of use" bug. Add a test.Davide Italiano2015-09-191-3/+0
| | | | llvm-svn: 248096
* [llvm-readobj] Fix another "time of check to time of use bug".Davide Italiano2015-09-171-5/+0
| | | | | | It seems there's more copy-paste between tools than needed. llvm-svn: 247954
* Restore "Function bitcode index in Value Symbol Table and lazy reading support"Teresa Johnson2015-09-171-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit r247898 (which reverted r247894). Patch fixed to address two issues exposed by buildbots: - unused variable warning in NDEBUG mode - std::initializer_list lifetime issue causing test failures Original Summary: Support for including the function bitcode indices in the Value Symbol Table. This requires writing the VST after the function blocks, which in turn requires a new VST forward declaration record encoding the offset of the full VST (which is backpatched to contain the offset after the VST is written). This patch also enables the lazy function reader to use the new function indices out of the VST. This support will be used by ThinLTO as well, which will be in a follow on patch. Backwards compatibility with older bitcode files is maintained. A new test is also included. The bitcode format (used for the lazy reader as well as the upcoming ThinLTO patches) came out of discussions with Duncan and others and is described here: https://drive.google.com/file/d/0B036uwnWM6RWdnBLakxmeDdOeXc/view Reviewers: dexonsmith, davidxl, joker.eph Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D12536 llvm-svn: 247927
* Revert "Function bitcode index in Value Symbol Table and lazy reading support"Teresa Johnson2015-09-171-2/+0
| | | | | | | | | | Temporarily revert to fix some buildbot issues. One is a minor issue with a variable unused in NDEBUG mode. More concerning are some test failures on win7 that I need to dig into. This reverts commit 4e66a74543459832cfd571db42b4543580ae1d1d. llvm-svn: 247898
* Function bitcode index in Value Symbol Table and lazy reading supportTeresa Johnson2015-09-171-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Support for including the function bitcode indices in the Value Symbol Table. This requires writing the VST after the function blocks, which in turn requires a new VST forward declaration record encoding the offset of the full VST (which is backpatched to contain the offset after the VST is written). This patch also enables the lazy function reader to use the new function indices out of the VST. This support will be used by ThinLTO as well, which will be in a follow on patch. Backwards compatibility with older bitcode files is maintained. A new test is also included. The bitcode format (used for the lazy reader as well as the upcoming ThinLTO patches) came out of discussions with Duncan and others and is described here: https://drive.google.com/file/d/0B036uwnWM6RWdnBLakxmeDdOeXc/view Reviewers: dexonsmith, davidxl, joker.eph Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D12536 llvm-svn: 247894
* Check for errors after reading a sample profile in llvm-profdata.Diego Novillo2015-09-171-1/+3
| | | | | | | After reading the profile, check if the reader returned any errors before showing the profile. llvm-svn: 247873
* Disable the second verification run when performing LTO throughTeresa Johnson2015-09-161-1/+10
| | | | | | | | gold in NDEBUG mode. Follow on patch for r247729 - LTO: Disable extra verify runs in release builds. llvm-svn: 247824
* llvm-mc-fuzzer: A fuzzing tool for the MC layer.Daniel Sanders2015-09-162-0/+147
| | | | | | | | | | | | | | | Summary: Only the disassembler is supported in this patch but it has already found a few issues in the Mips disassembler (mostly invalid instructions being successfully disassembled). Reviewers: kcc Subscribers: russell.gallop, silvas, kcc, llvm-commits Differential Revision: http://reviews.llvm.org/D12723 llvm-svn: 247786
* [llvm-cxxdump] Remove duplicate code check.Davide Italiano2015-09-151-6/+0
| | | | | | | We already fail with 'No such file or directory' when we try to open the file -- if that doesn't exist. Also add a test to verify this behavior. llvm-svn: 247744
* Reapply "LTO: Disable extra verify runs in release builds"Duncan P. N. Exon Smith2015-09-152-8/+22
| | | | | | | This reverts commit r247730, effectively reapplying r247729. This time I have an lld commit ready to follow. llvm-svn: 247735
* Revert "LTO: Disable extra verify runs in release builds"Duncan P. N. Exon Smith2015-09-152-22/+8
| | | | | | | This temporarily reverts commit r247729, as it caused lld build failures. I'll recommit once I have an lld patch ready-to-go. llvm-svn: 247730
* LTO: Disable extra verify runs in release buildsDuncan P. N. Exon Smith2015-09-152-8/+22
| | | | | | | | | | | | | | | | | | | | | | The verifier currently runs three times in LTO: (1) after parsing, (2) at the beginning of the optimization pipeline, and (3) at the end of it. The first run is important, since we're not sure where the bitcode comes from and it's nice to validate it, but in release builds the extra runs aren't appropriate. This commit: - Allows these runs to be disabled in LTOCodeGenerator. - Adds command-line options to llvm-lto. - Adds command-line options to libLTO.dylib, and disables the verifier by default in release builds (based on NDEBUG). This shaves about 3.5% off the runtime of ld64 when linking verify-uselistorder with -flto -g. rdar://22509081 llvm-svn: 247729
* Revert r247692: Replace Triple with a new TargetTuple in MCTargetDesc/* and ↵Daniel Sanders2015-09-155-15/+13
| | | | | | | | related. NFC. Eric has replied and has demanded the patch be reverted. llvm-svn: 247702
* Re-commit r247683: Replace Triple with a new TargetTuple in MCTargetDesc/* ↵Daniel Sanders2015-09-155-13/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | and related. NFC. Summary: This is the first patch in the series to migrate Triple's (which are ambiguous) to TargetTuple's (which aren't). For the moment, TargetTuple simply passes all requests to the Triple object it holds. Once it has replaced Triple, it will start to implement the interface in a more suitable way. This change makes some changes to the public C++ API. In particular, InitMCSubtargetInfo(), createMCRelocationInfo(), and createMCSymbolizer() now take TargetTuples instead of Triples. The other public C++ API's have been left as-is for the moment to reduce patch size. This commit also contains a trivial patch to clang to account for the C++ API change. Thanks go to Pavel Labath for fixing LLDB for me. Reviewers: rengolin Subscribers: jyknight, dschuff, arsenm, rampitec, danalbert, srhines, javed.absar, dsanders, echristo, emaste, jholewinski, tberghammer, ted, jfb, llvm-commits, rengolin Differential Revision: http://reviews.llvm.org/D10969 llvm-svn: 247692
* Revert r247684 - Replace Triple with a new TargetTuple ...Daniel Sanders2015-09-155-15/+13
| | | | | | LLDB needs to be updated in the same commit. llvm-svn: 247686
* Replace Triple with a new TargetTuple in MCTargetDesc/* and related. NFC.Daniel Sanders2015-09-155-13/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This is the first patch in the series to migrate Triple's (which are ambiguous) to TargetTuple's (which aren't). For the moment, TargetTuple simply passes all requests to the Triple object it holds. Once it has replaced Triple, it will start to implement the interface in a more suitable way. This change makes some changes to the public C++ API. In particular, InitMCSubtargetInfo(), createMCRelocationInfo(), and createMCSymbolizer() now take TargetTuples instead of Triples. The other public C++ API's have been left as-is for the moment to reduce patch size. This commit also contains a trivial patch to clang to account for the C++ API change. Reviewers: rengolin Subscribers: jyknight, dschuff, arsenm, rampitec, danalbert, srhines, javed.absar, dsanders, echristo, emaste, jholewinski, tberghammer, ted, jfb, llvm-commits, rengolin Differential Revision: http://reviews.llvm.org/D10969 llvm-svn: 247683
* dsymutil: Remove the now obsolete RelocMgr argument from cloneDIE. (NFC)Adrian Prantl2015-09-141-8/+6
| | | | llvm-svn: 247636
* [llvm-cov] Disable name and path truncationVedant Kumar2015-09-142-6/+22
| | | | | | | | | | | Change the output of llvm-cov s.t it does not truncate function names and file paths when printing coverage reports. Differential Revision: http://reviews.llvm.org/D12647 rdar://22531141 llvm-svn: 247635
* [CMake] Refactor and cleanup generating and installing symlinks to tools.Chris Bieneman2015-09-142-58/+2
| | | | | | | | | | | | Summary: This change generalizes symlink generation and makes symlinks to tools obey LLVM_TOOLCHAIN_TOOLS. It makes it so that if you exclude llvm-ar from LLVM_TOOLCHAIN_TOOLS you don't end up with broken symlinks to llvm-lib and llvm-ranlib in your install. Reviewers: bogner, chapuni, rafael Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D12864 llvm-svn: 247632
* [CMake] Add llvm-ar subdirectory explicitly.Chris Bieneman2015-09-141-2/+3
| | | | | | This is required because ExternalProject_Add requires all targets specified in the DEPENDS argument must exist before calling ExternalProject_Add. llvm-svn: 247592
* [llvm-mc] Better error handling in ENOENT case + test.Davide Italiano2015-09-141-6/+1
| | | | | | | | | | | | | This is a follow up to r247518. As a general note, I think we could do a much better job testing for error conditions in tools. I already anticipated in a previous mail, but while implementing this I noticed that the code coverage we have for error checking is pretty low. I can arbitrarily remove checks from several tools and the suite still passes. Differential Revision: http://reviews.llvm.org/D12846 llvm-svn: 247582
OpenPOWER on IntegriCloud