summaryrefslogtreecommitdiffstats
path: root/llvm/tools
Commit message (Collapse)AuthorAgeFilesLines
* [gold-plugin] - Fix compilation after LLVM update (r314883). NFC.George Rimar2017-10-041-8/+3
| | | | llvm-svn: 314899
* [llvm-cov] Fix showing title when filtering and not outputting to a directorySean Eveson2017-10-041-1/+1
| | | | | | Differential Revision: https://reviews.llvm.org/D38507 llvm-svn: 314885
* llvm-dwarfdump: implement the --regex option in combination with --name.Adrian Prantl2017-10-031-8/+30
| | | | llvm-svn: 314855
* AMDGPU: Add ELFOSABI_AMDGPU_MESA3DKonstantin Zhuravlyov2017-10-031-2/+3
| | | | | | Differential Revision: https://reviews.llvm.org/D38387 llvm-svn: 314846
* AMDGPU: Add ELFOSABI_AMDGPU_PALKonstantin Zhuravlyov2017-10-031-1/+2
| | | | llvm-svn: 314843
* Fix -Wcovered-switch-default warnings from r314821Hans Wennborg2017-10-031-2/+1
| | | | llvm-svn: 314826
* Revert r314817 "[dwarfdump] Add -lookup option"Hans Wennborg2017-10-031-36/+5
| | | | | | | | | | | | | | | | | The test fails on Linux; see follow-up email on the llvm-commits list. > Add the option to lookup an address in the debug information and print > out the file, function, block and line table details. > > Differential revision: https://reviews.llvm.org/D38409 This also reverts the follow-up r314818: > [test] Fix llvm-dwarfdump/cmdline.test > > Fixes test/tools/llvm-dwarfdump/cmdline.test llvm-svn: 314825
* CodeView: Provide a .def file with the register idsHans Wennborg2017-10-031-50/+5
| | | | | | | | | | | | | | The list of register ids was previously written out in a couple of dirrent places. This puts it in a .def file and also adds a few more registers (e.g. the x87 regs) which should lead to more readable dumps, but I didn't include the whole list since that seems unnecessary. X86_MC::initLLVMToSEHAndCVRegMapping is pretty ugly, but at least it's not relying on magic constants anymore. The TODO of using tablegen still stands. Differential revision: https://reviews.llvm.org/D38480 llvm-svn: 314821
* [dwarfdump] Add -lookup optionJonas Devlieghere2017-10-031-5/+36
| | | | | | | | | Add the option to lookup an address in the debug information and print out the file, function, block and line table details. Differential revision: https://reviews.llvm.org/D38409 llvm-svn: 314817
* Use sched_getaffinity instead of std::thread::hardware_concurrency.Rafael Espindola2017-10-031-2/+2
| | | | | | | | | | | | | | The issue with std::thread::hardware_concurrency is that it forwards to libc and some implementations (like glibc) don't take thread affinity into consideration. With this change a llvm program that can execute in only 2 cores will use 2 threads, even if the machine has 32 cores. This makes benchmarking a lot easier, but should also help if someone doesn't want to use all cores for compilation for example. llvm-svn: 314809
* [llvm-cov] Hide files with no coverage from the index when filtering by nameSean Eveson2017-10-037-12/+14
| | | | | | Differential Revision: https://reviews.llvm.org/D38457 llvm-svn: 314782
* [llvm-readobj][RISCV] Pretty-print RISCV e_flagsAlex Bradbury2017-10-031-0/+10
| | | | llvm-svn: 314772
* llvm-dwarfdump: support the --ignore-case option.Adrian Prantl2017-10-021-3/+12
| | | | llvm-svn: 314723
* Add ELFOSABI_FIRST_ARCH, ELFOSABI_LAST_ARCH and start using those in ↵Konstantin Zhuravlyov2017-10-021-10/+29
| | | | | | | | llvm-readobj Differential Revision: https://reviews.llvm.org/D38418 llvm-svn: 314717
* Move the stripping of invalid debug info from the Verifier to AutoUpgrade.Adrian Prantl2017-10-022-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | This came out of a recent discussion on llvm-dev (https://reviews.llvm.org/D38042). Currently the Verifier will strip the debug info metadata from a module if it finds the dbeug info to be malformed. This feature is very valuable since it allows us to improve the Verifier by making it stricter without breaking bcompatibility, but arguable the Verifier pass should not be modifying the IR. This patch moves the stripping of broken debug info into AutoUpgrade (UpgradeDebugInfo to be precise), which is a much better location for this since the stripping of malformed (i.e., produced by older, buggy versions of Clang) is a (harsh) form of AutoUpgrade. This change is mostly NFC in nature, the one big difference is the behavior when LLVM module passes are introducing malformed debug info. Prior to this patch, a NoAsserts build would have printed a warning and stripped the debug info, after this patch the Verifier will report a fatal error. I believe this behavior is actually more desirable anyway. Differential Revision: https://reviews.llvm.org/D38184 llvm-svn: 314699
* [dwarfdump] Add -show-formJonas Devlieghere2017-10-021-3/+10
| | | | | | | | | This enables printing of DWARF form types after the DWARF attribute types. Differential revision: https://reviews.llvm.org/D38459 llvm-svn: 314685
* [llvm-rc] Serialize DIALOG(EX) to .res files (serialization, pt 4).Marek Sokolowski2017-09-306-17/+229
| | | | | | | | | | | | | This is now able to serialize DIALOG and DIALOGEX resources to .res files. It still can't parse dialog-specific CAPTION, FONT, and STYLE optional statement - these will be added in the following patch. A limited set of controls is included. However, more can be easily added by extending SupportedCtls map defined in ResourceScriptStmt.cpp. Differential Revision: https://reviews.llvm.org/D37862 llvm-svn: 314578
* typosAdrian Prantl2017-09-301-3/+3
| | | | llvm-svn: 314577
* llvm-dwarfdump: implement the --name lookup option.Adrian Prantl2017-09-301-9/+39
| | | | llvm-svn: 314576
* Fix 80 column violationsAdrian Prantl2017-09-301-4/+8
| | | | llvm-svn: 314575
* Add commentsAdrian Prantl2017-09-301-0/+5
| | | | llvm-svn: 314574
* [llvm-rc] Serialize MENU resources to .res files (serialization, pt 3).Marek Sokolowski2017-09-294-4/+98
| | | | | | | | | | | | | | | | | | | | This allows MENU resources to be serialized. MENU resource statement doc: msdn.microsoft.com/en-us/library/windows/desktop/aa381025.aspx POPUP sub-statement doc: msdn.microsoft.com/en-us/library/windows/desktop/aa381030.aspx MENUITEM sub-statement doc: msdn.microsoft.com/en-us/library/windows/desktop/aa381024.aspx MENUHEADER structure: msdn.microsoft.com/en-us/library/windows/desktop/ms648018.aspx (and NORMALMENUITEM, POPUPMENUITEM structs). Thanks for Nico Weber for his original work in this area. Differential Revision: https://reviews.llvm.org/D37828 llvm-svn: 314562
* [llvm-rc] Serialize ACCELERATORS to .res files (serialization, pt 2).Marek Sokolowski2017-09-294-11/+205
| | | | | | | | | | | | | | | | | | | | This allows llvm-rc to serialize ACCELERATORS resources. Additionally, as this is the first type of resource to support basic optional resource statements (LANGUAGE, CHARACTERISTICS, VERSION), ACCELERATORS statement documentation: msdn.microsoft.com/en-us/library/windows/desktop/aa380610.aspx Accelerator table structure documentation: msdn.microsoft.com/en-us/library/windows/desktop/ms648010.aspx Optional resource statement fields are described in: msdn.microsoft.com/en-us/library/windows/desktop/ms648027.aspx Thanks for Nico Weber for his original work in this area. Differential Revision: https://reviews.llvm.org/D37824 llvm-svn: 314549
* [llvm-rc] Refactoring needed for ACCELERATORS and MENU resources.Marek Sokolowski2017-09-294-49/+72
| | | | | | | | | | | | | | | | | | | | This is a part of llvm-rc serialization patch set (serialization, pt 1.5). This: * Unifies the internal representation of flags in ACCELERATORS and MENU with the corresponding representation in .res files (noticed in https://reviews.llvm.org/D37828#inline-329828). * Creates an RCResource subclass, OptStatementsRCResource, describing resource statements that can declare resource-local optional statements (proposed in https://reviews.llvm.org/D37824#inline-329775). These modifications don't fit to any of the current patches, so I'm submitting them as a separate patch. Differential Revision: https://reviews.llvm.org/D37841 llvm-svn: 314541
* [llvm-rc] Serialize HTML resources to .res files (serialization, pt 1).Marek Sokolowski2017-09-297-5/+501
| | | | | | | | | | | | | | This allows to process HTML resources defined in .rc scripts and output them to resulting .res files. Additionally, some infrastructure allowing to output these files is created. This is the first resource type we can operate on. Thanks to Nico Weber for his original work in this area. Differential Revision: reviews.llvm.org/D37283 llvm-svn: 314538
* Display relative hotness with two decimal digits after the decimal pointAdam Nemet2017-09-291-1/+1
| | | | | | | | | I've seen cases where tiny inlined functions have such a high execution count that most everything would show up with a relative of hotness of 0%. Since the inlined functions effectively disappear you need to tune in the lower range, thus we need more precision. llvm-svn: 314537
* [WebAssembly] Allow each data segment to specify its own alignmentSam Clegg2017-09-293-18/+14
| | | | | | | | | Also, add a flags field as we will almost certainly be needing that soon too. Differential Revision: https://reviews.llvm.org/D38296 llvm-svn: 314534
* Make find_opt_files varargAdam Nemet2017-09-294-5/+5
| | | | | | | This is slightly less verbose for the common case of a single build directory and more intuitive when using this API directly from the interpreter. llvm-svn: 314491
* llvm-readobj: fix a few typos (NFC)Saleem Abdulrasool2017-09-291-3/+3
| | | | | | | | Correct the spelling of multiple in a couple of sites. Patch by Alex Langford! llvm-svn: 314485
* llvm-dwarfdump: support .apple-namespaces in --findAdrian Prantl2017-09-291-0/+2
| | | | llvm-svn: 314481
* [llvm-rc] Import all make_unique invocations from llvm namespace.Marek Sokolowski2017-09-291-20/+22
| | | | | | | | Previous patch fixed one of LLVM buildbots (lld-x86_64-win7). However, some others have already been failing because of make_unique compilation error (llvm-clang-x86_64-expensive-checks-win). llvm-svn: 314480
* llvm-dwarfdump: add support for .apple_types in --findAdrian Prantl2017-09-291-5/+14
| | | | llvm-svn: 314479
* [llvm-rc] Add user-defined resources parsing ability. [8/8]Marek Sokolowski2017-09-294-1/+55
| | | | | | | | | | | | | This allows llvm-rc to parse user-defined resources (ref: msdn.microsoft.com/en-us/library/windows/desktop/aa381054.aspx). These statements either import files, or put the specified raw data in the resulting resource file. Thanks to Nico Weber for his original work in this area. Differential Revision: https://reviews.llvm.org/D37033 llvm-svn: 314478
* [llvm-rc] Add integer expressions parsing ability. [7/8]Marek Sokolowski2017-09-284-4/+117
| | | | | | | | | | | | | | This allows the ints to be written as integer expressions evaluating to unsigned 16-bit/32-bit integers. All the expressions may use the following operators: + - & | ~, and parentheses. Minus token - can be also unary. There is no precedence of the operators other than the unary operators binding stronger than their binary counterparts. Differential Revision: https://reviews.llvm.org/D37022 llvm-svn: 314477
* [llvm-rc] Fix-up for r314468 (argument-dependent lookup in make_unique).Marek Sokolowski2017-09-281-4/+4
| | | | llvm-svn: 314472
* [llvm-rc] Add VERSIONINFO parsing ability. [6/8]Marek Sokolowski2017-09-284-0/+257
| | | | | | | | | | | | | This extends the set of llvm-rc parser's available resources by another one, VERSIONINFO. Ref: msdn.microsoft.com/en-us/library/windows/desktop/aa381058.aspx Thanks to Nico Weber for his original work in this area. Differential Revision: https://reviews.llvm.org/D37021 llvm-svn: 314468
* try and appease gccAdrian Prantl2017-09-281-1/+1
| | | | llvm-svn: 314442
* llvm-dwarfdump: implement --find for .apple_namesAdrian Prantl2017-09-281-1/+24
| | | | | | | | | | | | This patch implements the dwarfdump option --find=<name>. This option looks for a DIE in the accelerator tables and dumps it if found. This initial patch only adds support for .apple_names to keep the review small, adding the other sections and pubnames support should be trivial though. Differential Revision: https://reviews.llvm.org/D38282 llvm-svn: 314439
* [llvm-cov] Create directory structure when filtering using -name*= optionsSean Eveson2017-09-289-53/+84
| | | | | | | | | | | Before this change using any of the -name*= command line options with an output directory would result in a single file (functions.txt/functions.html) containing the coverage for those specific functions. Now you get the same directory structure as when not using any -name*= options. Differential Revision: https://reviews.llvm.org/D38280 llvm-svn: 314396
* Update the description of AVR32 for the ELFDumperDylan McKay2017-09-271-1/+1
| | | | | | AVR32 is an unrelated architecture with 32-bit addressing. llvm-svn: 314359
* Revert "[llvm-cov] Create directory structure when filtering using -name*= ↵Sean Eveson2017-09-279-84/+53
| | | | | | | | options" Test failures. llvm-svn: 314314
* [llvm-cov] Create directory structure when filtering using -name*= optionsSean Eveson2017-09-279-53/+84
| | | | | | | | | | | Before this change using any of the -name*= command line options with an output directory would result in a single file (functions.txt/functions.html) containing the coverage for those specific functions. Now you get the same directory structure as when not using any -name*= options. Differential Revision: https://reviews.llvm.org/D38280 llvm-svn: 314310
* [SimplifyCFG] add a struct to house optional folds (PR34603)Sanjay Patel2017-09-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was intended to be no-functional-change, but it's not - there's a test diff. So I thought I should stop here and post it as-is to see if this looks like what was expected based on the discussion in PR34603: https://bugs.llvm.org/show_bug.cgi?id=34603 Notes: 1. The test improvement occurs because the existing 'LateSimplifyCFG' marker is not carried through the recursive calls to 'SimplifyCFG()->SimplifyCFGOpt().run()->SimplifyCFG()'. The parameter isn't passed down, so we pick up the default value from the function signature after the first level. I assumed that was a bug, so I've passed 'Options' down in all of the 'SimplifyCFG' calls. 2. I split 'LateSimplifyCFG' into 2 bits: ConvertSwitchToLookupTable and KeepCanonicalLoops. This would theoretically allow us to differentiate the transforms controlled by those params independently. 3. We could stash the optional AssumptionCache pointer and 'LoopHeaders' pointer in the struct too. I just stopped here to minimize the diffs. 4. Similarly, I stopped short of messing with the pass manager layer. I have another question that could wait for the follow-up: why is the new pass manager creating the pass with LateSimplifyCFG set to true no matter where in the pipeline it's creating SimplifyCFG passes? // Create an early function pass manager to cleanup the output of the // frontend. EarlyFPM.addPass(SimplifyCFGPass()); --> /// \brief Construct a pass with the default thresholds /// and switch optimizations. SimplifyCFGPass::SimplifyCFGPass() : BonusInstThreshold(UserBonusInstThreshold), LateSimplifyCFG(true) {} <-- switches get converted to lookup tables and loops may not be in canonical form If this is unintended, then it's possible that the current behavior of dropping the 'LateSimplifyCFG' setting via recursion was masking this bug. Differential Revision: https://reviews.llvm.org/D38138 llvm-svn: 314308
* [llvm-cov] Improve const-correctness of filters. NFC.Sean Eveson2017-09-272-18/+21
| | | | llvm-svn: 314281
* [XRay] fix the -Werror build by handling all enum cases in switchesMartin Pelikan2017-09-272-1/+5
| | | | | | Followup to D32840. llvm-svn: 314270
* [XRay] convert FDR arg1 log entriesMartin Pelikan2017-09-273-3/+6
| | | | | | | | | | | | | | | | | | | | Summary: A new FDR metadata record will support logging a function call argument; appending multiple metadata records will represent a sequence of arguments meaning that "holes" are not representable by the buffer format. Each call argument is currently a 64-bit value (useful for "this" pointers and synchronization objects). If present, we put this argument to the function call "entry" record it belongs to, and alter its type to notify the user of its presence. Reviewers: dberris Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D32840 llvm-svn: 314269
* Reland: [llvm-objcopy] Add support for dynamic relocationsJake Ehrlich2017-09-271-8/+8
| | | | | | | | | This change adds support for dynamic relocations (allocated SHT_REL/SHT_RELA sections with a dynamic symbol table as their link). I had to reland this because of a I wasn't initilizing some pointers. llvm-svn: 314263
* Initialize the RelocationSectionBase::Section member.James Y Knight2017-09-261-0/+2
| | | | | | In r314227, it wasn't always, and would thus contain random garbage. llvm-svn: 314256
* [llvm-objcopy] Add support for dynamic relocationsJake Ehrlich2017-09-262-40/+53
| | | | | | | | | | | | | | | This change adds support for dynamic relocations (allocated SHT_REL/SHT_RELA sections with a dynamic symbol table as their link). The binary I added for the test is here: https://drive.google.com/file/d/0B3gtIAmiMwZXSjJUZE9pUjd4M0k/view?usp=sharing Unless support for dynamic symbol tables in yaml2obj is added this is needed. Differential Revision: https://reviews.llvm.org/D37915 llvm-svn: 314227
* [dsymutil] Better support for symbol aliasesJonas Devlieghere2017-09-261-0/+24
| | | | | | | | | | | This patch adds logic to follow a symbol's aliases when the symbol name cannot be found in the current object file. It checks the main binary for the symbol's address and queries the current object for its aliases (symbols with the same address) before printing out a warning. Differential revision: https://reviews.llvm.org/D38230 llvm-svn: 314198
OpenPOWER on IntegriCloud