summaryrefslogtreecommitdiffstats
path: root/llvm
Commit message (Collapse)AuthorAgeFilesLines
...
* [Hexagon] Minimize number of repeated constant extendersKrzysztof Parzyszek2017-10-135-1/+1939
| | | | | | | | | | | | | | Each constant extender requires an extra instruction, which adds to the code size and also reduces the number of available slots in an instruction packet. In most cases, the value of a repeated constant extender could be loaded into a register, and the instructions using the extender could be replaced with their counterparts that use that register instead. This patch adds a pass that tries to reduce the number of constant extenders, including extenders which differ only in an immediate offset known at compile time, e.g. @global and @global+12. llvm-svn: 315735
* Revert r315148 [TableGen] Avoid unnecessary std::string creationsDaniel Sanders2017-10-132-13/+13
| | | | | | | | I'm about to commit a patch that makes them necessary for getPredCode() and it would be strange for getPredCode() and getImmCode() to require different usage. llvm-svn: 315733
* [InstCombine] use local var to reduce code duplication; NFCISanjay Patel2017-10-131-16/+15
| | | | llvm-svn: 315728
* [LLVMCore] fix description for OverflowingBinaryOperator; NFCSanjay Patel2017-10-131-3/+3
| | | | llvm-svn: 315726
* [X86] Add initial skeleton support for knm cpuCraig Topper2017-10-133-5/+23
| | | | | | | | This adds Intel's Knights Mill CPU to valid CPU names for the backend. For now its an alias of "knl", but ultimately we need to support AVX5124FMAPS and AVX5124VNNIW instruction sets for it. Differential Revision: https://reviews.llvm.org/D38811 llvm-svn: 315722
* [IPSCCP] Move common functions to ValueLatticeUtils (NFC)Matthew Simpson2017-10-134-62/+113
| | | | | | | | | | | This patch moves some common utility functions out of IPSCCP and makes them available globally. The functions determine if interprocedural data-flow analyses can propagate information through function returns, arguments, and global variables. Differential Revision: https://reviews.llvm.org/D37638 llvm-svn: 315719
* [InstCombine] add hasOneUse check to add-zext-add fold to prevent increasing ↵Sanjay Patel2017-10-132-7/+4
| | | | | | instructions llvm-svn: 315718
* [InstCombine] add tests for add (zext (add nuw X, C2)), C --> zext (add nuw ↵Sanjay Patel2017-10-131-0/+32
| | | | | | X, C2 + C); NFC llvm-svn: 315717
* [llvm-demangle-fuzzer] Add a fuzz target for ItaniumDemangler.Matt Morehouse2017-10-134-0/+58
| | | | | | | | | | | | | | Patch By: hctim Reviewers: morehouse, bogner Reviewed By: bogner Subscribers: bogner, kcc, llvm-commits, mgorny Differential Revision: https://reviews.llvm.org/D38855 llvm-svn: 315716
* [llvm-cov] Reland sources-specified.test with addition of "-path-equivalence".Max Moroz2017-10-132-0/+34
| | | | | | | | | | | | Summary: This version of tests should be working properly. Reviewers: vsk Reviewed By: vsk Differential Revision: https://reviews.llvm.org/D38889 llvm-svn: 315714
* [SCEV] Maintain and use a loop->loop invalidation dependencySanjoy Das2017-10-133-118/+140
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This change uses the loop use list added in the previous change to remember the loops that appear in the trip count expressions of other loops; and uses it in forgetLoop. This lets us not scan every loop in the function on a forgetLoop call. With this change we no longer invalidate clear out backedge taken counts on forgetValue. I think this is fine -- the contract is that SCEV users must call forgetLoop(L) if their change to the IR could have changed the trip count of L; solely calling forgetValue on a value feeding into the backedge condition of L is not enough. Moreover, I don't think we can strengthen forgetValue to be sufficient for invalidating trip counts without significantly re-architecting SCEV. For instance, if we have the loop: I = *Ptr; E = I + 10; do { // ... } while (++I != E); then the backedge taken count of the loop is 9, and it has no reference to either I or E, i.e. there is no way in SCEV today to re-discover the dependency of the loop's trip count on E or I. So a SCEV client cannot change E to (say) "I + 20", call forgetValue(E) and expect the loop's trip count to be updated. Reviewers: atrick, sunfish, mkazantsev Subscribers: mcrosier, llvm-commits Differential Revision: https://reviews.llvm.org/D38435 llvm-svn: 315713
* [X86] Test scalar integer absolutes on 32-bit targets with/without CMOVSimon Pilgrim2017-10-131-18/+35
| | | | llvm-svn: 315711
* Not all buildbots seem to dump the nuw flag in SDAGReid Kleckner2017-10-131-1/+1
| | | | llvm-svn: 315710
* [InstCombine] use AddOne helper to reduce code; NFCSanjay Patel2017-10-131-6/+3
| | | | llvm-svn: 315709
* [X86] Updated scalar integer absolute tests to cover i8/i16/i32/i64Simon Pilgrim2017-10-131-11/+95
| | | | llvm-svn: 315706
* [InstCombine] rearrange code to remove repeated constant check; NFCISanjay Patel2017-10-132-7/+7
| | | | llvm-svn: 315703
* [InstCombine] allow zext(bool) + C --> select bool, C+1, C for vector typesSanjay Patel2017-10-132-14/+17
| | | | | | | The backend should be prepared for this transform after: https://reviews.llvm.org/rL311731 llvm-svn: 315701
* [TableGen] : Simplify RegisterInfoEmitterJaved Absar2017-10-131-6/+4
| | | | llvm-svn: 315700
* Update test to expect nuw flag in SDAG dump, fixes test after r315690Reid Kleckner2017-10-131-2/+2
| | | | llvm-svn: 315698
* lit.py: Add new %{shared_output(LABEL)} substitutionJordan Rose2017-10-139-11/+53
| | | | | | | | | | | | This refers to a temporary path that can be shared across all tests, identified by a particular label. This can be used for things like caches. At the moment, the character set for the LABEL is limited to C identifier characters, plus '-', '+', '=', and '.'. This is the same set of characters currently allowed in REQUIRES clause identifiers. llvm-svn: 315697
* [X86] Fix some inconsistent formatting in the processor feature lists.Craig Topper2017-10-131-4/+4
| | | | llvm-svn: 315696
* [X86] Add ProcIntelBDW to BroadwellProc class not BDWFeatures class.Craig Topper2017-10-131-4/+5
| | | | | | This isn't a property we want inherited. llvm-svn: 315695
* [RS4GC] Look through vector bitcasts when looking for base pointerDaniel Neilson2017-10-132-0/+31
| | | | | | | | | | | | | | | | | | Summary: In RS4GC it is possible that a base pointer is contained in a vector that has undergone a bitcast from one element-pointertype to another. We teach RS4GC how to look through bitcasts of vector types when looking for a base pointer. Reviewers: anna Reviewed By: anna Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D38849 llvm-svn: 315694
* [llvm-cov] Temporary delete sources-specified.test, it is failing on some bots.Max Moroz2017-10-131-27/+0
| | | | | | | | | | | | | | Summary: http://lab.llvm.org:8011/builders/clang-with-thin-lto-ubuntu/builds/5950/steps/test-stage1-compiler/logs/stdio Reviewers: vsk, Dor1s Reviewed By: Dor1s Subscribers: mehdi_amini Differential Revision: https://reviews.llvm.org/D38888 llvm-svn: 315693
* [Hexagon] Add patterns for cmpb/cmph with immediate argumentsKrzysztof Parzyszek2017-10-133-0/+122
| | | | | | Patch by Sumanth Gundapaneni. llvm-svn: 315692
* [llvm-cov] Fix sources-specified.test so it ignores the order of files printed.Max Moroz2017-10-131-7/+6
| | | | | | | | | | | | Summary: https://reviews.llvm.org/D38884#896964 Reviewers: vsk, Dor1s Reviewed By: Dor1s Differential Revision: https://reviews.llvm.org/D38887 llvm-svn: 315691
* DAG: Add flags to dumpsMatt Arsenault2017-10-131-0/+30
| | | | llvm-svn: 315690
* [llvm-cov] An attempt to fix sources_specified.test failing on some buildbots.Max Moroz2017-10-131-4/+4
| | | | | | | | | | | | Summary: https://reviews.llvm.org/rL315685#115380 Reviewers: vsk, Dor1s Reviewed By: Dor1s Differential Revision: https://reviews.llvm.org/D38884 llvm-svn: 315687
* [X86] Stop creating CMOV nodes with a second MVT::Glue resultCraig Topper2017-10-131-24/+9
| | | | | | | | | | | | | | Summary: We seem to inconsistently create CMOV nodes some with a Glue result and some without. But I can't find any cases that use the Glue result. So I've tried to remove all the place that did this. Reviewers: RKSimon, spatel, zvi Reviewed By: RKSimon Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D38664 llvm-svn: 315686
* [llvm-cov] Generate "report" for given source paths if sources are specified.Max Moroz2017-10-1310-2/+61
| | | | | | | | | | | | | | | | Summary: Documentation says that user can specify sources for both "show" and "report" commands. "Show" command respects specified sources, but "report" does not. It is useful to have both "show" and "report" generated for specified sources. Also added tests to for both commands with sources specified. Reviewers: vsk, kcc Reviewed By: vsk Differential Revision: https://reviews.llvm.org/D38860 llvm-svn: 315685
* Re-land "[dsymutil] Timestmap verification for __swift_ast"Jonas Devlieghere2017-10-135-23/+48
| | | | | | | | | | This patch adds timestamp verification for swiftmodule files. A new flag is provided to allows us to disable this check in order to allow testing of this feature. Differential revision: https://reviews.llvm.org/D38686 llvm-svn: 315684
* [SCEV] Teach SCEV to find maxBECount when loop endbound is variantAnna Thomas2017-10-134-36/+207
| | | | | | | | | | | | | | | | | | | | | | | Summary: This patch teaches SCEV to calculate the maxBECount when the end bound of the loop can vary. Note that we cannot calculate the exactBECount. This will only be done when both conditions are satisfied: 1. the loop termination condition is strictly LT. 2. the IV is proven to not overflow. This provides more information to users of SCEV and can be used to improve identification of finite loops. Reviewers: sanjoy, mkazantsev, silviu.baranga, atrick Reviewed by: mkazantsev Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D38825 llvm-svn: 315683
* [InstCombine] add tests for boolean extend + add; NFCSanjay Patel2017-10-131-0/+32
| | | | llvm-svn: 315681
* Revert r314923: "Recommit : Use the basic cost if a GEP is not used as ↵Daniel Jasper2017-10-1310-139/+10
| | | | | | | | | | | | | addressing mode" Significantly reduces performancei (~30%) of gipfeli (https://github.com/google/gipfeli) I have not yet managed to reproduce this regression with the open-source version of the benchmark on github, but will work with others to get a reproducer to you later today. llvm-svn: 315680
* [FileCheck] regexp doc update/fixSjoerd Meijer2017-10-131-5/+6
| | | | | | | | | | Minor doc update that the FileCheck matcher supports POSIX ERE. It also fixes a minor issue in the regexp describing a variable name: underscores are allowed too. Differential Revision: https://reviews.llvm.org/D38787 llvm-svn: 315679
* Disable gcov instrumentation of functions using funclet-based exception handlingMarco Castelluccio2017-10-131-0/+13
| | | | | | | | | | | | | | Summary: This patch fixes the crash from https://bugs.llvm.org/show_bug.cgi?id=34659 and https://bugs.llvm.org/show_bug.cgi?id=34833. Reviewers: rnk, majnemer Reviewed By: rnk, majnemer Subscribers: majnemer, llvm-commits Differential Revision: https://reviews.llvm.org/D38223 llvm-svn: 315677
* docs: Improve wording on building for fuzzingJustin Bogner2017-10-131-3/+3
| | | | | | | | The original sentence didn't really make sense. Patch by Vedant Kumar. Thanks! llvm-svn: 315676
* [X86] Remove patterns that select unmasked vbroadcastf2x32/vbroadcasti2x32. ↵Craig Topper2017-10-134-23/+29
| | | | | | | | Prefer vbroadcastsd/vpbroadcastq instead. There's no advantage to using these instructions when they aren't masked. This enables some additional execution domain switching without needing to update the table. llvm-svn: 315674
* [SCEV] Maintain loop use lists, and use them in forgetLoopSanjoy Das2017-10-133-0/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Currently we do not correctly invalidate memoized results for add recurrences that were created directly (i.e. they were not created from a `Value`). This change fixes this by keeping loop use lists and using the loop use lists to determine which SCEV expressions to invalidate. Here are some statistics on the number of uses of in the use lists of all loops on a clang bootstrap (config: release, no asserts): Count: 731310 Min: 1 Mean: 8.555150 50th %time: 4 95th %tile: 25 99th %tile: 53 Max: 433 Reviewers: atrick, sunfish, mkazantsev Subscribers: mcrosier, llvm-commits Differential Revision: https://reviews.llvm.org/D38434 llvm-svn: 315672
* [SelectionDAG] Cleanup the SIGN_EXTEND_INREG handling in computeKnownBits. NFCICraig Topper2017-10-131-26/+14
| | | | | | Use less temporary APInts. Use bit counting more. Don't call getScalarSizeInBits so many places, just capture it once. llvm-svn: 315671
* [SelectionDAG] Fix typo in comment. NFCCraig Topper2017-10-131-1/+1
| | | | llvm-svn: 315670
* docs: Improve the docs about llvm-isel-fuzzer on OSS FuzzJustin Bogner2017-10-131-4/+9
| | | | llvm-svn: 315651
* [X86] Add the test case for r315613 that I forgot to 'git add'.Craig Topper2017-10-131-0/+13
| | | | llvm-svn: 315649
* [SelectionDAG] Correct the early out in SelectionDAG::getZeroExtendInReg to ↵Craig Topper2017-10-131-1/+1
| | | | | | | | work properly for vector types. I don't know if we ever hit this case or not. Turning it into an assert only fired on expanding some atomic operation in a SystemZ lit test. llvm-svn: 315648
* [llvm-isel-fuzzer] Use "--" as separator rather than '='.Matt Morehouse2017-10-135-17/+17
| | | | | | | | | | | | | | Summary: OSS-Fuzz doesn't support '=' in filenames. Reviewers: bogner, kcc Reviewed By: kcc Subscribers: javed.absar, hiraditya, llvm-commits Differential Revision: https://reviews.llvm.org/D38866 llvm-svn: 315647
* llvm-isel-fuzzer: Use the right REQUIRES line for r315599Justin Bogner2017-10-133-5/+2
| | | | | | | I'd mixed up ENABLE_SHARED and BUILD_SHARED_LIBS before, so these tests were being disabled in too many places. llvm-svn: 315646
* Removing default case statement from covered switch.Keith Wyss2017-10-131-8/+0
| | | | | | | | | | | Previous patch did not count on the llvm command line parser to restrict the inputs, but it is safe to do so. Fix forward for patch with details: -- https://reviews.llvm.org/D38650 and -- https://llvm.org/svn/llvm-project/llvm/trunk@315635 91177308-0d34-0410-b5e6-96231b3b80d8 llvm-svn: 315644
* Add DK_Remark to SMDiagnosticAdam Nemet2017-10-124-1/+20
| | | | | | | | | | | Swift uses SMDiagnostic for diagnostic messages. For https://github.com/apple/swift/pull/12294, we need remark support. I picked the color that clang uses to display them. Differential Revision: https://reviews.llvm.org/D38865 llvm-svn: 315642
* [SelectionDAG] Const-correct the DemandedMask argument to one of the ↵Craig Topper2017-10-122-2/+2
| | | | | | overloads of SimplifyDemandedBits. NFC llvm-svn: 315641
* [Transforms] Fix some Clang-tidy modernize and Include What You Use ↵Eugene Zelenko2017-10-122-177/+253
| | | | | | warnings; other minor fixes (NFC). llvm-svn: 315640
OpenPOWER on IntegriCloud