summaryrefslogtreecommitdiffstats
path: root/llvm/test/tools
Commit message (Collapse)AuthorAgeFilesLines
...
* [X86][Btver2] (V)MPSADBW instructions take 3uops not 1Simon Pilgrim2018-09-272-4/+4
| | | | llvm-svn: 343238
* [X86][Btver2] BTC/BTR/BTS instructions take 2uops not 1Simon Pilgrim2018-09-271-18/+18
| | | | llvm-svn: 343234
* [X86][Btver2] BLSI/BLSMSK/BLSR instructions take 2uops not 1 (same as TZCNT)Simon Pilgrim2018-09-271-12/+12
| | | | llvm-svn: 343227
* [llvm-exegesis] Fix PR39096.Clement Courbet2018-09-272-0/+56
| | | | | | | | | | | | Summary: The key is now the resource name, not the resource id. Reviewers: gchatelet Subscribers: tschuett, RKSimon, llvm-commits Differential Revision: https://reviews.llvm.org/D52607 llvm-svn: 343208
* [X86][Btver2] TZCNT instructions take 2uops not 1Simon Pilgrim2018-09-271-4/+4
| | | | llvm-svn: 343200
* [llvm-exgesis][NFC] Do not pollute buildbots with messages whenClement Courbet2018-09-261-1/+1
| | | | | | the exegesis lit tests cannot run. llvm-svn: 343110
* [llvm-exegesis] Get rid of debug_string.Clement Courbet2018-09-262-0/+59
| | | | | | | | | | | | | | | | Summary: THis is a backwards-compatible change (existing files will work as expected). See PR39082. Reviewers: gchatelet Subscribers: tschuett, llvm-commits Differential Revision: https://reviews.llvm.org/D52546 llvm-svn: 343108
* [llvm-exegesis] Serializes registers initial values.Guillaume Chatelet2018-09-251-1/+4
| | | | | | | | | | | | Summary: Adds the registers initial values to the YAML output of llvm-exegesis. Reviewers: courbet Subscribers: tschuett, llvm-commits Differential Revision: https://reviews.llvm.org/D52460 llvm-svn: 342982
* [llvm-exegesis] Fix missing document separator in YAML output.Guillaume Chatelet2018-09-251-1/+3
| | | | | | | | | | Reviewers: courbet Subscribers: tschuett, llvm-commits Differential Revision: https://reviews.llvm.org/D52496 llvm-svn: 342981
* [llvm-exegesis] Add lit tests (v2).Clement Courbet2018-09-254-0/+43
| | | | | | | | | | | | Summary: This revisits rL342953 by adding detection of host support. Reviewers: gchatelet, lebedev.ri, alexshap Subscribers: mgorny, tschuett, llvm-commits Differential Revision: https://reviews.llvm.org/D52464 llvm-svn: 342975
* Revert rL342916: [X86] Remove shift/rotate by CL memory (RMW) overridesSimon Pilgrim2018-09-251-8/+8
| | | | | | | | As suggested by Craig Topper - I'm going to look at cleaning up the RMW sequences instead. The uops are slightly different to the register variant, so requires a +1uop tweak llvm-svn: 342969
* Revert rL342953 "[llvm-exegesis] Add lit tests."Clement Courbet2018-09-254-21/+0
| | | | | | We also need to make sure that we're on the right subtarget. llvm-svn: 342955
* [llvm-exegesis] Add lit tests.Clement Courbet2018-09-254-0/+21
| | | | | | | | | | | | | | | Summary: Right now we only have unit tests. This will allow testing the whole tool. Even though We can't really check actual values, this will avoid regressions such as PR39055. Reviewers: gchatelet, alexshap Subscribers: mgorny, tschuett, llvm-commits Differential Revision: https://reviews.llvm.org/D52407 llvm-svn: 342953
* [X86] Remove shift/rotate by CL memory (RMW) overridesSimon Pilgrim2018-09-241-8/+8
| | | | | | The uops are slightly different to the register variant, so requires a +1uop tweak llvm-svn: 342916
* [X86] Split WriteIMul into 8/16/32/64 implementations (PR36931)Simon Pilgrim2018-09-245-25/+25
| | | | | | | | Split WriteIMul by size and also by IMUL multiply-by-imm and multiply-by-reg cases. This removes all the scheduler overrides for gpr multiplies and stops WriteMULH being ignored for BMI2 MULX instructions. llvm-svn: 342892
* [dsymutil] Set LSan blacklist whenever sanitizers are enabled.Jonas Devlieghere2018-09-241-1/+1
| | | | | | | | LSan can be enabled by itself or as part of the address sanitizer. Rather than checking the enabled sanitizers for both, just set the LSan env options whenever a sanitizer is enabled. llvm-svn: 342881
* llvm-diff: Fix crash on anonymous functionsMatt Arsenault2018-09-241-0/+8
| | | | | | | Not sure what the correct behavior is for this. Skip them and report how many there were. llvm-svn: 342857
* [X86] ROR*mCL instruction models should match ROL*mCL etc.Simon Pilgrim2018-09-234-36/+36
| | | | | | | | Confirmed with Craig Topper - fix a typo that was missing a Port4 uop for ROR*mCL instructions on some Intel models. Yet another step on the scheduler model cleanup marathon...... llvm-svn: 342846
* [X86] Added missing RCL/RCR schedule overrides to the generic SNB modelSimon Pilgrim2018-09-232-194/+194
| | | | | | | | | | | | The SandyBridge model was missing schedule values for the RCL/RCR values - instead using the (incredibly optimistic) WriteShift (now WriteRotate) defaults. I've added overrides with more realistic (slow) values, based on a mixture of Agner/instlatx64 numbers and what later Intel models do as well. This is necessary to allow WriteRotate to be updated to remove other rotate overrides. It'd probably be a good idea to investigate a WriteRotateCarry class at some point but its not high priority given the unusualness of these instructions. llvm-svn: 342842
* [llvm-size] Berkeley formatting: use tabs instead of spaces as field delimeters.Jordan Rupprecht2018-09-211-0/+15
| | | | | | This matches GNU behavior for size and allows use of cut to parse the output of llvm-size. llvm-svn: 342791
* llvm-dwarfdump --statistics: Unique abstract origins across multiple CUs.Adrian Prantl2018-09-212-0/+378
| | | | | | | | Instead of indexing local variables by DIE offset, use the variable name + the path through the lexical block tree. This makes the lookup key consistent across duplicate abstract origins in different CUs. llvm-svn: 342776
* [X86][Sched] Add zero idiom sched data to the SNB model.Clement Courbet2018-09-211-0/+348
| | | | | | | | | | | | | | | | | | | | Summary: On SNB, renamer-based zeroing does not work for: - 16 and 8-bit GPRs[1]. - MMX [2]. - ANDN variants [3] [1] echo 'sub %ax, %ax' | /tmp/llvm-exegesis -mode=uops -snippets-file=- [2] echo 'pxor %mm0, %mm0' | /tmp/llvm-exegesis -mode=uops -snippets-file=- [3] echo 'andnps %xmm0, %xmm0' | /tmp/llvm-exegesis -mode=uops -snippets-file=- Reviewers: RKSimon, andreadb Subscribers: gbedwell, craig.topper, llvm-commits Differential Revision: https://reviews.llvm.org/D52358 llvm-svn: 342736
* [X86][BtVer2] Fix latency and resource cycles of AVX 256-bit zero-idioms.Andrea Di Biagio2018-09-211-42/+42
| | | | | | | | | | | | | | | | This patch introduces a SchedWriteVariant to describe zero-idiom VXORP(S|D)Yrr and VANDNP(S|D)Yrr. This is a follow-up of r342555. On Jaguar, a VXORPSYrr is 2 macro opcodes. Only one opcode is eliminated at register-renaming stage. The other opcode has to be executed to set the upper half of the destination YMM. Same for VANDNP(S|D)Yrr. Differential Revision: https://reviews.llvm.org/D52347 llvm-svn: 342728
* [dsymutil] Suppress CoreFoundation leaks in tests.Jonas Devlieghere2018-09-212-0/+8
| | | | | | | | | | This suppresses CoreFoundation originated leaks in the dsymutil tests. I'm not sure if this is a false positive or not, but either way we don't have control over it and shouldn't keep the bot red. http://lab.llvm.org:8080/green/job/clang-stage2-cmake-RgSan/ llvm-svn: 342724
* [dwarfdump] Verify DW_AT_type is set and points to a compatible DIE.Jonas Devlieghere2018-09-211-2/+20
| | | | | | | | | | | | | This extends the verifier to catch three new errors: * Missing DW_AT_type attributes for DW_TAG_formal_parameter, DW_TAG_variable and DW_TAG_array_type. * Valid references for DW_AT_type pointing to a non-type tag. Differential revision: https://reviews.llvm.org/D52223 llvm-svn: 342713
* [dwarfdump] Verify compatibility of attribute TAGs.Jonas Devlieghere2018-09-211-0/+386
| | | | | | | | | Verify that DW_AT_specification and DW_AT_abstract_origin reference a DIE with a compatible tag. Differential revision: https://reviews.llvm.org/D38719 llvm-svn: 342712
* [llvm-objcopy/llvm-strip]: handle --versionJordan Rupprecht2018-09-212-0/+8
| | | | | | | | | | | | | | | | | Summary: Implement --version for objcopy and strip. I think there are LLVM utilities that automatically handle this, but that doesn't seem to work with custom parsing since this binary handles both objcopy and strip, so it uses custom parsing. This fixes PR38298 Reviewers: jhenderson, alexshap, jakehehrlich Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D52328 llvm-svn: 342702
* [PDB] Fix failing test.Zachary Turner2018-09-201-3/+3
| | | | | | | This test was missed on the last run since I only ran a subset of them before commiting. llvm-svn: 342659
* [gcov] Fix wrong line hit counts when multiple blocks are on the same lineCalixte Denizet2018-09-2013-25/+25
| | | | | | | | | | | | | | | | | | | | | Summary: The goal of this patch is to have the same behaviour than gcc-gcov. Currently the hit counts for a line is the sum of the counts for each block on that line. The idea is to detect the cycles in the graph of blocks in using the algorithm by Hawick & James. The count for a cycle is the min of the counts for each edge in the cycle. Once we've the count for each cycle, we can sum them and add the transition counts of those cycles. Fix both https://bugs.llvm.org/show_bug.cgi?id=38065 and https://bugs.llvm.org/show_bug.cgi?id=38066 Reviewers: marco-c, davidxl Reviewed By: marco-c Subscribers: vsk, lebedev.ri, sylvestre.ledru, dblaikie, llvm-commits Differential Revision: https://reviews.llvm.org/D49659 llvm-svn: 342657
* [llvm-mca][BtVer2] Modify ANDN tests in zero-idioms-avx-256.s. NFCAndrea Di Biagio2018-09-201-42/+42
| | | | | | | Two test cases should have tested 256-bit variants of VANDN zero-idioms instead of the 128-bit variants. llvm-svn: 342655
* [TableGen][SubtargetEmitter] Add the ability for processor models to ↵Andrea Di Biagio2018-09-191-0/+322
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | describe dependency breaking instructions. This patch adds the ability for processor models to describe dependency breaking instructions. Different processors may specify a different set of dependency-breaking instructions. That means, we cannot assume that all processors of the same target would use the same rules to classify dependency breaking instructions. The main goal of this patch is to provide the means to describe dependency breaking instructions directly via tablegen, and have the following TargetSubtargetInfo hooks redefined in overrides by tabegen'd XXXGenSubtargetInfo classes (here, XXX is a Target name). ``` virtual bool isZeroIdiom(const MachineInstr *MI, APInt &Mask) const { return false; } virtual bool isDependencyBreaking(const MachineInstr *MI, APInt &Mask) const { return isZeroIdiom(MI); } ``` An instruction MI is a dependency-breaking instruction if a call to method isDependencyBreaking(MI) on the STI (TargetSubtargetInfo object) evaluates to true. Similarly, an instruction MI is a special case of zero-idiom dependency breaking instruction if a call to STI.isZeroIdiom(MI) returns true. The extra APInt is used for those targets that may want to select which machine operands have their dependency broken (see comments in code). Note that by default, subtargets don't know about the existence of dependency-breaking. In the absence of external information, those method calls would always return false. A new tablegen class named STIPredicate has been added by this patch to let processor models classify instructions that have properties in common. The idea is that, a MCInstrPredicate definition can be used to "generate" an instruction equivalence class, with the idea that instructions of a same class all have a property in common. STIPredicate definitions are essentially a collection of instruction equivalence classes. Also, different processor models can specify a different variant of the same STIPredicate with different rules (i.e. predicates) to classify instructions. Tablegen backends (in this particular case, the SubtargetEmitter) will be able to process STIPredicate definitions, and automatically generate functions in XXXGenSubtargetInfo. This patch introduces two special kind of STIPredicate classes named IsZeroIdiomFunction and IsDepBreakingFunction in tablegen. It also adds a definition for those in the BtVer2 scheduling model only. This patch supersedes the one committed at r338372 (phabricator review: D49310). The main advantages are: - We can describe subtarget predicates via tablegen using STIPredicates. - We can describe zero-idioms / dep-breaking instructions directly via tablegen in the scheduling models. In future, the STIPredicates framework can be used for solving other problems. Examples of future developments are: - Teach how to identify optimizable register-register moves - Teach how to identify slow LEA instructions (each subtarget defining its own concept of "slow" LEA). - Teach how to identify instructions that have undocumented false dependencies on the output registers on some processors only. It is also (in my opinion) an elegant way to expose knowledge to both external tools like llvm-mca, and codegen passes. For example, machine schedulers in LLVM could reuse that information when internally constructing the data dependency graph for a code region. This new design feature is also an "opt-in" feature. Processor models don't have to use the new STIPredicates. It has all been designed to be as unintrusive as possible. Differential Revision: https://reviews.llvm.org/D52174 llvm-svn: 342555
* [llvm-objcopy] Add missing alias for --strip-all-gnuAlexander Shaposhnikov2018-09-171-0/+3
| | | | | | | | | | | | | This diff adds -S as an alias for --strip-all-gnu (for compatibility with binutils' objcopy). Patch by Dmitry Golovin! Test plan: make check-all Differential revision: https://reviews.llvm.org/D52163 llvm-svn: 342364
* [X86][BMI1] Fix BLSI/BLSMSK/BLSR BMI1 scheduling on btver2Simon Pilgrim2018-09-141-25/+25
| | | | | | These have the same behaviour as tzcnt on btver2 - confirmed with AMD 16h SOG, Agner and instlatx64. llvm-svn: 342235
* Add flag to llvm-profdata to allow symbols in profile data to be remapped, andRichard Smith2018-09-1317-0/+121
| | | | | | | | | | | | | | | | | add a tool to generate symbol remapping files. Summary: The new tool llvm-cxxmap builds a symbol mapping table from a file containing a description of partial equivalences to apply to mangled names and files containing old and new symbol tables. Reviewers: davidxl Subscribers: mgorny, llvm-commits Differential Revision: https://reviews.llvm.org/D51470 llvm-svn: 342168
* [llvm-cov] Delete custom JSON serialization code (NFC)Vedant Kumar2018-09-1211-263/+31
| | | | | | | Teach llvm-cov to use the new llvm JSON library, and remove some redundant/brittle JSON serialization tests. llvm-svn: 342088
* [objcopy] make objcopy follow program header standardsJulie Hockett2018-09-124-5/+21
| | | | | | | | | | | | | | | | | | Submitted on behalf of Armando Montanez (amontanez@google.com). Objects with unused program headers copied by objcopy would always have nonzero values for program header offset and program header entry size. While technically valid, this atypical behavior triggers warnings in some tools. This change sets the two fields to zero when the program header is unused, better fitting the general expectations for unused program header data. Section headers behaved somewhat similarly (though only with the entry size), and are fixed in this revision as well. Differential Revision: https://reviews.llvm.org/D51961 llvm-svn: 342065
* Make malformed-machos.test pass on my Mac.Nico Weber2018-09-111-1/+1
| | | | | | | For some reason, llvm-objdump defaults to -arch=i386 on this system while the test checks x86_64 output. Explicitly pass -arch=x86_64. llvm-svn: 341944
* [XRay] Add TSC to NewCPUId RecordsDean Michael Berris2018-09-112-3/+3
| | | | | | | | | | | | | | | Summary: This more correctly reflects the data written by the FDR mode runtime. This is a continuation of the work in D50441. Reviewers: mboerger, eizan Subscribers: hiraditya, llvm-commits Differential Revision: https://reviews.llvm.org/D51911 llvm-svn: 341905
* [XRay] Add the `llvm-xray fdr-dump` implementationDean Michael Berris2018-09-112-0/+41
| | | | | | | | | | | | | | | | | | | Summary: In this change, we implement a `BlockPrinter` which orders records in a Block that's been indexed by the `BlockIndexer`. This is used in the `llvm-xray fdr-dump` tool which ties together the various types and utilities we've been working on, to allow for inspection of XRay FDR mode traces both with and without verification. This change is the final step of the refactoring of D50441. Reviewers: mboerger, eizan Subscribers: mgorny, hiraditya, llvm-commits Differential Revision: https://reviews.llvm.org/D51846 llvm-svn: 341887
* [XRay] Fix buildbot failureDavid Carlier2018-09-101-1/+1
| | | | llvm-svn: 341774
* [Xray] tooling allow MachO format supportDavid Carlier2018-09-102-0/+9
| | | | | | | | | | | | Getting writable xray __DATA sections from MachO as well. Reviewers: dberris Reviewed By: dberris Differential Revision: https://reviews.llvm.org/D51758 llvm-svn: 341772
* [llvm-dwp] Clean up tests X86/*.testFangrui Song2018-09-076-15/+8
| | | | llvm-svn: 341688
* [llvm-objcopy] Dwarf .debug section compression support (zlib, zlib-gnu).Puyan Lotfi2018-09-076-0/+146
| | | | | | | | | | | | | | | | | | | | | | | Third Attempt: - Alignment issues resolved. - zlib::isAvailable() detected. - ArrayRef misuse fixed. Usage: llvm-objcopy --compress-debug-sections=zlib foo.o llvm-objcopy --compress-debug-sections=zlib-gnu foo.o In both cases the debug section contents is compressed with zlib. In the GNU style case the header is the "ZLIB" magic string followed by the uint64 big- endian decompressed size. In the non-GNU mode the header is the Elf(32|64)_Chdr. Decompression support is coming soon. Differential Revision: https://reviews.llvm.org/D49678 llvm-svn: 341635
* [llvm-strip] -p test fix for windows buildbotsJordan Rupprecht2018-09-071-4/+4
| | | | | | Windows ls prints dates as "1997-05-05" instead of "May 05 1997", so only check for a leading space. llvm-svn: 341614
* Revert: [llvm-objcopy] Dwarf .debug section compression (Second Attempt).Puyan Lotfi2018-09-076-146/+0
| | | | | | Various bots still fail for unknown reason. llvm-svn: 341613
* [llvm-objcopy] Dwarf .debug section compression support (zlib, zlib-gnu).Puyan Lotfi2018-09-066-0/+146
| | | | | | | | | | | | | | | | | | | | Second Attempt. Alignment issues resolved. zlib::isAvailable() detected. Usage: llvm-objcopy --compress-debug-sections=zlib foo.o llvm-objcopy --compress-debug-sections=zlib-gnu foo.o In both cases the debug section contents is compressed with zlib. In the GNU style case the header is the "ZLIB" magic string followed by the uint64 big- endian decompressed size. In the non-GNU mode the header is the Elf(32|64)_Chdr. Decompression support is coming soon. Differential Revision: https://reviews.llvm.org/D49678 llvm-svn: 341607
* [llvm-strip] Fix -p test to check for explicit spaces around dates, to avoid ↵Jordan Rupprecht2018-09-061-4/+4
| | | | | | when the filename happens to contain 1995/1997. llvm-svn: 341595
* Reland rL341509: "[llvm-dwp] Use buffer_stream if output file is not ↵Fangrui Song2018-09-061-4/+2
| | | | | | | | | | seekable (e.g. "-")" It caused ambiguity between llvm::cl::Optional and llvm::Optional, which has been fixed by dropping `using namespace cl;` in favor of explicit cl:: qualified names. llvm-svn: 341586
* [llvm-ar] Support * as comment char in MRI scriptsMartin Storsjo2018-09-061-3/+9
| | | | | | | | | | | | MRI scripts have two comment chars, * and ;, but only the latter was supported before. Also allow leading spaces before comment chars (and before any command string), and allow comments after a command. Differential Revision: https://reviews.llvm.org/D51338 llvm-svn: 341571
* Revert rL341509 to fix massive failures on buildbotsMax Kazantsev2018-09-061-2/+4
| | | | llvm-svn: 341515
OpenPOWER on IntegriCloud