summaryrefslogtreecommitdiffstats
path: root/llvm/tools
Commit message (Collapse)AuthorAgeFilesLines
* [llvm-cxxdump] Don't rely on global stateDavide Italiano2015-07-171-41/+18
| | | | | | Differential Revision: http://reviews.llvm.org/D11227 llvm-svn: 242509
* Delete an unused function.Rafael Espindola2015-07-161-16/+0
| | | | | | Patch by Xan López! llvm-svn: 242429
* For new archive member we only need to store the full path.Rafael Espindola2015-07-151-9/+7
| | | | | | | We were storing both the path and the file name, which was redundant and easy to get confused up with. llvm-svn: 242347
* Simplify a few uses of remove_filename by using parent_path instead.Rafael Espindola2015-07-151-2/+1
| | | | llvm-svn: 242334
* Handle the error of trying to convert a regular archive to a thin one.Rafael Espindola2015-07-151-2/+13
| | | | | | While at it, test that we can add to a thin archive. llvm-svn: 242330
* Initial support for writing thin archives.Rafael Espindola2015-07-151-3/+7
| | | | llvm-svn: 242269
* Add support for reading members out of thin archives.Rafael Espindola2015-07-141-2/+4
| | | | | | | | | | For now the Archive owns the buffers of the thin archive members. This makes for a simple API, but all the buffers are destructed only when the archive is destructed. This should be fine since we close the files after mmap so we should not hit an open file limit. llvm-svn: 242215
* llvm-ar: Don't try to extract from thin archives.Rafael Espindola2015-07-141-0/+5
| | | | | | This matches the gnu ar behavior. llvm-svn: 242162
* llvm-ar: print an error when the requested member is not found.Rafael Espindola2015-07-141-3/+12
| | | | llvm-svn: 242156
* Use a range loop. NFC.Rafael Espindola2015-07-141-19/+17
| | | | llvm-svn: 242153
* Revert "Fix `llvm-config` to emit the linker flag for the combined shared ↵JF Bastien2015-07-144-50/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | object built by autoconfig/make instead of the individual components." This reverts commit 01446706b4c0a86bb64768f307079cab5c514aa3. Causes breakage, seems to be related to 'svn' in the file's name: CC=gcc CXX=g++ \ ../llvm/configure \ --prefix=/usr \ --sysconfdir=/etc \ --enable-shared \ --enable-libffi \ --enable-targets=all \ --disable-assertions \ --with-python=/usr/bin/python2 \ --enable-optimized make REQUIRES_RTTI=1 ENABLE_PIC=1 results: llvm[2]: Linking Release unit test Support (without symbols) llvm[2]: ======= Finished Linking Release Unit test Support (without symbols) make[3]: Entering directory '/build/llvm-svn/src/build/bindings/ocaml/llvm' make[3]: *** No rule to make target '/build/llvm- svn/src/build/Release/lib/ocaml/libLLVM-3.7.0svn.so', needed by 'build- deplibs'. Stop. make[3]: *** Waiting for unfinished jobs.... llvm[3]: Compiling llvm_ocaml.c for Release build make[3]: Leaving directory '/build/llvm-svn/src/build/bindings/ocaml/llvm' /build/llvm-svn/src/llvm/Makefile.rules:880: recipe for target 'all' failed /build/llvm-svn/src/llvm/Makefile.rules:965: recipe for target 'all' failed Differential Revision: http://reviews.llvm.org/D10716 llvm-svn: 242152
* Use std::make_tuple to reduce code duplication.Rafael Espindola2015-07-131-27/+8
| | | | | | Thanks to David Blaikie for the suggestion. llvm-svn: 242074
* Add support deterministic output in llvm-ar and make it the default.Rafael Espindola2015-07-131-2/+10
| | | | llvm-svn: 242061
* Revert "[CMake] Cleanup tools/CMakeLists.txt to take advantage of the ↵Chris Bieneman2015-07-131-21/+69
| | | | | | | | auto-registration that was already partially working." Reverting r242059 because it broke some bots. I'm attempting to reproduce the failures now. llvm-svn: 242060
* [CMake] Cleanup tools/CMakeLists.txt to take advantage of the ↵Chris Bieneman2015-07-131-69/+21
| | | | | | | | | | | | | | | | | | | auto-registration that was already partially working. Summary: This change re-lands r241621, with an additional fix that was required to allow tool sources to live outside the llvm checkout. It also no longer renames LLVM_EXTERNAL_*_SOURCE_DIR. This change was reverted in r241663, because it renamed several variables of the format LLVM_EXTERNAL_*_* to LLVM_TOOL_*_*. Original Summary: The tools CMakeLists file already had implicit tool registration, but there were a few things off about it that needed to be altered to make it work. This change addresses all that. The changes in this patch are: * factored out canonicalizing tool names from paths to CMake variables * removed the LLVM_IMPLICIT_PROJECT_IGNORE mechanism in favor of LLVM_EXTERNAL_${nameUPPER}_BUILD which I renamed to LLVM_TOOL_${nameUPPER}_BUILD because it applies to internal and external tools * removed ignore_llvm_tool_subdirectory() in favor of just setting LLVM_TOOL_${nameUPPER}_BUILD to Off * Added create_llvm_tool_options() to resolve a bug in add_llvm_external_project() - the old LLVM_EXTERNAL_${nameUPPER}_BUILD would not work on a clean CMake directory because the option could be created after it was set in code. * Removed all but the minimum required calls to add_llvm_external_project from tools/CMakeLists.txt Differential Revision: http://reviews.llvm.org/D10665 llvm-svn: 242059
* [CMake] Add missing DebugInfo libraries to llvm-shlibKeno Fischer2015-07-131-0/+2
| | | | | | | | | | Reviewers: beanz Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D11128 llvm-svn: 242054
* [llvm-stress] Remove unneeded llvm:: prefix. NFC.Pawel Bylica2015-07-131-1/+1
| | | | llvm-svn: 242020
* Fix `llvm-config` to emit the linker flag for the combined shared object ↵JF Bastien2015-07-104-2/+50
| | | | | | | | | | | | | | | | | built by autoconfig/make instead of the individual components. Summary: This fixes `llvm-config` instead of fixing the makefiles because, AIUI, LLVM's autoconfig/make build system is on the way out anyway. This change only affects builds that use autoconfig/make. Reviewers: jfb Subscribers: echristo, dschuff, llvm-commits Differential Revision: http://reviews.llvm.org/D10716 llvm-svn: 241938
* [llvm-stress] Enhance scalar type selection from command line.Pawel Bylica2015-07-101-39/+54
| | | | | | | | | | llvm-stress command line options like -generate-x86-fp80 has been replaced with one list-like option -types. E.g. llvm-stress -types=x86_fp80,i100,i256,half. Default types (i1, i8, i16, i32, i64, float, double) are always added at the beginning of that list. Reviewers: hfinkel Differential Revision: http://reviews.llvm.org/D10667 llvm-svn: 241896
* Revert the new EH instructionsDavid Majnemer2015-07-101-5/+0
| | | | | | This reverts commits r241888-r241891, I didn't mean to commit them. llvm-svn: 241893
* Add missing 'const'. I don't think this is strictly required, but someDaniel Jasper2015-07-101-1/+1
| | | | | | | compiler configuration is giving me an error and it seems to be recommended anyway. llvm-svn: 241892
* New EH representation for MSVC compatibilityDavid Majnemer2015-07-101-0/+5
| | | | | | | | | | | | | | | Summary: 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. Reviewers: rnk, JosephTremoulet, reames, nlewycky, rjmccall Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D11041 llvm-svn: 241888
* [Object][ELF] Support dumping hash-tables from files with no section table.Michael J. Spencer2015-07-094-2/+22
| | | | | | This time without breaking the bots. llvm-svn: 241869
* Expose sjlj preparation through opt for my own debugging purposesReid Kleckner2015-07-091-0/+1
| | | | llvm-svn: 241864
* Create BSD archives by default on OS X.Rafael Espindola2015-07-091-3/+9
| | | | | | | | | They should probably be created on anything that is not windows or linux, but I will test on freebsd before changing that. With this it is possible to bootstrap with llvm-ar instead of ar+ranlib on OS X. llvm-svn: 241849
* [llvm-readobj] Print MIPS PLT tableSimon Atanasyan2015-07-091-73/+164
| | | | | | Now the -mips-plt-got prints both MIPS GOT and PLT tables. llvm-svn: 241836
* [yaml2obj] Initialize sh_addralign field for the .symtab sectionSimon Atanasyan2015-07-091-0/+1
| | | | llvm-svn: 241835
* [llvm-readobj] Re-add sanity checking which was accidentally removed in r241764David Majnemer2015-07-091-2/+9
| | | | llvm-svn: 241831
* [llvm-objdump] Require that jump targets shown in -d are functionsDavid Majnemer2015-07-091-6/+17
| | | | | | | Don't let the disassembler pick call <.text> if a function happens to live at the start of the section by only using function symbols. llvm-svn: 241830
* llvm-readobj: Fix an unused variable after r241764Justin Bogner2015-07-091-2/+3
| | | | llvm-svn: 241783
* Temporarily reverting 241765, 241768, and 241772 to unbreak the build bots.Adrian Prantl2015-07-094-22/+2
| | | | llvm-svn: 241781
* [Object][ELF] Support dumping hash-tables from files with no section table.Michael J. Spencer2015-07-094-2/+22
| | | | llvm-svn: 241765
* [CodeView] Add support for emitting column informationDavid Majnemer2015-07-091-6/+14
| | | | | | | | | | Column information is present in CodeView when the line table subsection has bit 0 set to 1 in it's flags field. The column information is represented as a pair of 16-bit quantities: a starting and ending column. This information is present at the end of the chunk, after all the line-PC pairs. llvm-svn: 241764
* Disallow Archive::child_iterator that don't point to an archive.Rafael Espindola2015-07-081-1/+2
| | | | | | NFC, just less error prone. llvm-svn: 241747
* Start adding support for writing archives in BSD format.Rafael Espindola2015-07-081-2/+24
| | | | | | | | No support for the symbol table yet (but will hopefully add it today). We always use the long filename format so that we can align the member, which is an advantage of the BSD format. llvm-svn: 241721
* [yaml2obj] Align section content using AddressAlign field's valueSimon Atanasyan2015-07-081-9/+14
| | | | | | | | Use AddressAlign field's value to properly align sections content in the yaml2obj tool. Before this change the yaml2obj ignored AddressAlign and always aligned section on 16 bytes boundary. llvm-svn: 241674
* Revert r241621, "[CMake] Cleanup tools/CMakeLists.txt to take advantage of ↵NAKAMURA Takumi2015-07-081-21/+69
| | | | | | | | the auto-registration that was already partially working." It broke the build that relies on LLVM_EXTERNAL_CLANG_*. llvm-svn: 241663
* llvm-objdump: Replace the -macho -raw option with a generic -raw-clang-astAdrian Prantl2015-07-083-14/+53
| | | | | | | | | | | | | | | option that works with all object container formats. Now that clang modules/PCH are object containers this option is useful to to construct pipes like llvm-objdump -raw-clang-ast foo.pcm | llvm-bcanalyzer - to inspect the AST contents in a PCH container. Will be tested via clang. Belatedly addresses review feedback for r233390. llvm-svn: 241659
* [llvm-objdump] Print the call target next to the instructionDavid Majnemer2015-07-071-0/+36
| | | | | | | GNU binutils provides this behavior. objdump -r doesn't really help when you aren't dealing with relocation object files. llvm-svn: 241631
* [CMake] Cleanup tools/CMakeLists.txt to take advantage of the ↵Chris Bieneman2015-07-071-69/+21
| | | | | | | | | | | | | | | | | | | | | auto-registration that was already partially working. Summary: The tools CMakeLists file already had implicit tool registration, but there were a few things off about it that needed to be altered to make it work. This change addresses all that. The changes in this patch are: * factored out canonicalizing tool names from paths to CMake variables * removed the LLVM_IMPLICIT_PROJECT_IGNORE mechanism in favor of LLVM_EXTERNAL_${nameUPPER}_BUILD which I renamed to LLVM_TOOL_${nameUPPER}_BUILD because it applies to internal and external tools * removed ignore_llvm_tool_subdirectory() in favor of just setting LLVM_TOOL_${nameUPPER}_BUILD to Off * Added create_llvm_tool_options() to resolve a bug in add_llvm_external_project() - the old LLVM_EXTERNAL_${nameUPPER}_BUILD would not work on a clean CMake directory because the option could be created after it was set in code. * Removed all but the minimum required calls to add_llvm_external_project from tools/CMakeLists.txt Reviewers: bogner, samsonov, chapuni, beanz Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D10665 llvm-svn: 241621
* Fix the -DBUILD_SHARED_LIBS=ON build.Rafael Espindola2015-07-071-0/+4
| | | | llvm-svn: 241608
* Delete UnknownAddress. It is a perfectly valid symbol value.Rafael Espindola2015-07-076-44/+15
| | | | | | | | | | | getSymbolValue now returns a value that in convenient for most callers: * 0 for undefined * symbol size for common symbols * offset/address for symbols the rest Code that needs something more specific can check getSymbolFlags. llvm-svn: 241605
* Common symbols don't have a value.Rafael Espindola2015-07-072-5/+13
| | | | | | | | | | | | | At least not in the interface exposed by ObjectFile. This matches what ELF and COFF implement. Adjust existing code that was expecting them to have values. No overall functionality change intended. Another option would be to change the interface and the ELF and COFF implementations to say that the value of a common symbol is its size. llvm-svn: 241593
* llvm-nm: treat weak undefined as undefined.Rafael Espindola2015-07-061-12/+18
| | | | | | This matches the behavior of gnu ld. llvm-svn: 241512
* Swap operands instead of using !.Rafael Espindola2015-07-061-1/+1
| | | | | | | | This avoids returning true for A == B. Thanks to Benjamin Kramer for noticing it. llvm-svn: 241490
* When sorting by address, undefined symbols go first.Rafael Espindola2015-07-061-0/+4
| | | | | | This matches gnu nm. llvm-svn: 241488
* Reduce code duplication. NFC.Rafael Espindola2015-07-061-41/+17
| | | | llvm-svn: 241484
* Fix printing of common symbols.Rafael Espindola2015-07-061-4/+9
| | | | | | Printing the symbol size matches the behavior or both gnu nm and freebsd nm. llvm-svn: 241480
* llc: Add a 'run-pass' option.Alex Lorenz2015-07-061-12/+27
| | | | | | | | | | | | | | | This commit adds a 'run-pass' option to llc, which instructs the compiler to run one specific code generation pass only. Llc already has the 'start-after' and the 'stop-after' options, and this new option complements the other two by making it easier to write tests that want to invoke a single pass only. Reviewers: Duncan P. N. Exon Smith Differential Revision: http://reviews.llvm.org/D10776 llvm-svn: 241476
* Simplify. NFC.Rafael Espindola2015-07-061-3/+1
| | | | llvm-svn: 241458
OpenPOWER on IntegriCloud