Skip to content
  1. Apr 23, 2016
  2. Apr 22, 2016
    • Rong Xu's avatar
      [PGO] change the interface for createPGOFuncNameMetadata() · f8f051cb
      Rong Xu authored
      This patch changes the interface for createPGOFuncNameMetadata() where we add
      another PGOFuncName argument.
      
      Differential Revision: http://reviews.llvm.org/D19433
      
      llvm-svn: 267216
      f8f051cb
    • Philip Reames's avatar
      [unordered] sink unordered stores at end of blocks · 5f0e3694
      Philip Reames authored
      The existing code turned out to be completely correct when auditted.  Thus, only minor code changes and adding a couple of tests.
      
      llvm-svn: 267215
      5f0e3694
    • Sanjoy Das's avatar
      Fold compares for distinct allocations · f97229d6
      Sanjoy Das authored
      Summary:
      We can fold compares to false when two distinct allocations within a
      function are compared for equality.
      
      Patch by Anna Thomas!
      
      Reviewers: majnemer, reames, sanjoy
      
      Subscribers: llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D19390
      
      llvm-svn: 267214
      f97229d6
    • Philip Reames's avatar
      [unordered] Extend load/store type canonicalization to handle unordered operations · eedef73b
      Philip Reames authored
      Extend the type canonicalization logic to work for unordered atomic loads and stores.  Note that while this change itself is fairly simple and low risk, there's a reasonable chance this will expose problems in the backends by suddenly generating IR they wouldn't have seen before.  Anything of this nature will be an existing bug in the backend (you could write an atomic float load), but this will definitely change the frequency with which such cases are encountered.  If you see problems, feel free to revert this change, but please make sure you collect a test case.  
      
      llvm-svn: 267210
      eedef73b
    • Justin Bogner's avatar
      PM: Port SinkingPass to the new pass manager · b9394908
      Justin Bogner authored
      llvm-svn: 267199
      b9394908
    • Justin Bogner's avatar
      PM: Reorder the functions used for SinkingPass. NFC · 82077c4a
      Justin Bogner authored
      This will make the port to the new PM easier to follow.
      
      llvm-svn: 267198
      82077c4a
    • Jun Bum Lim's avatar
      [DeadStoreElimination] Shorten beginning of memset overwritten by later stores · d29a24e4
      Jun Bum Lim authored
      Summary: This change will shorten memset if the beginning of memset is overwritten by later stores.
      
      Reviewers: hfinkel, eeckstein, dberlin, mcrosier
      
      Subscribers: mgrang, mcrosier, llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D18906
      
      llvm-svn: 267197
      d29a24e4
    • Justin Bogner's avatar
      PM: Port DCE to the new pass manager · 395c2127
      Justin Bogner authored
      Also add a very basic test, since apparently there aren't any tests
      for DCE whatsoever to add the new pass version to.
      
      llvm-svn: 267196
      395c2127
    • Adam Nemet's avatar
      [LoopUtils] Extend findStringMetadataForLoop to return the value for metadata · fe3def7c
      Adam Nemet authored
      E.g. for:
      
        !1 = {"llvm.distribute", i32 1}
      
      it now returns the MDOperand for 1.
      
      I will use this in LoopDistribution to check the value of the metadata.
      
      Note that the change is backward-compatible with its current use in
      LoopVersioningLICM.  An Optional implicitly converts to a bool depending
      whether it contains a value or not.
      
      llvm-svn: 267190
      fe3def7c
    • Chad Rosier's avatar
      1a4bc110
    • Geoff Berry's avatar
      [MemorySSA] Fix bug in CachingMemorySSAWalker::invalidateInfo · 9fe26e6d
      Geoff Berry authored
      Summary:
      CachingMemorySSAWalker::invalidateInfo was using IsCall to determine
      which cache map needed to be cleared of entries referring to the invalidated
      MemoryAccess, but there could also be entries referring to it in the
      other cache map (value entries, not key entries).  This change just
      clears both tables to be conservatively correct.
      
      Also add a verifyRemoved() function, called when expensive
      checks (i.e. XDEBUG) are enabled to verify that the invalidated
      MemoryAccess object is not referenced in any of the caches.
      
      Reviewers: dberlin, george.burgess.iv
      
      Subscribers: mcrosier, llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D19388
      
      llvm-svn: 267157
      9fe26e6d
    • David Majnemer's avatar
      [EarlyCSE] Don't add the overflow flags to the hash · bfd695d5
      David Majnemer authored
      We take the intersection of overflow flags while CSE'ing.
      This permits us to consider two instructions with different overflow
      behavior to be replaceable.
      
      llvm-svn: 267153
      bfd695d5
    • Silviu Baranga's avatar
      [InstCombine] Preserve fast math flags when combining PHIs · e985c76b
      Silviu Baranga authored
      Summary:
      When optimizing PHIs which have inputs floating point binary
      operators, we preserve all IR flags except the fast math
      flags.
      
      This change removes the logic which tracked some of the IR flags
      (no wrap, exact) and replaces it by doing an and on the IR flags of
      all inputs to the PHI - which will also handle the fast math
      flags.
      
      Reviewers: majnemer
      
      Subscribers: llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D19370
      
      llvm-svn: 267139
      e985c76b
    • Vedant Kumar's avatar
      Revert "Initial implementation of optimization bisect support." · 6013f45f
      Vedant Kumar authored
      This reverts commit r267022, due to an ASan failure:
      
        http://lab.llvm.org:8080/green/job/clang-stage2-cmake-RgSan_check/1549
      
      llvm-svn: 267115
      6013f45f
    • David Majnemer's avatar
      [GVN] Respect fast-math-flags on fcmps · d0ce8f14
      David Majnemer authored
      We assumed that flags were only present on binary operators.  This is
      not true, they may also be present on calls and fcmps.
      
      llvm-svn: 267113
      d0ce8f14
    • David Majnemer's avatar
      [EarlyCSE] Take the intersection of flags on instructions · 9554c133
      David Majnemer authored
      EarlyCSE had inconsistent behavior with regards to flag'd instructions:
      - In some cases, it would pessimize if the available instruction had
        different flags by not performing CSE.
      - In other cases, it would miscompile if it replaced an instruction
        which had no flags with an instruction which has flags.
      
      Fix this by being more consistent with our flag handling by utilizing
      andIRFlags.
      
      llvm-svn: 267111
      9554c133
    • Duncan P. N. Exon Smith's avatar
      ValueMapper/Enumerator: Clean up code in post-order traversals, NFC · 71480bd0
      Duncan P. N. Exon Smith authored
      Re-layer the functions in the new (i.e., newly correct) post-order
      traversals in ValueEnumerator (r266947) and ValueMapper (r266949).
      Instead of adding a node to the worklist in a helper function and
      returning a flag to say what happened, return the node itself.  This
      makes the code way cleaner: the worklist is local to the main function,
      there is no flag for an early loop exit (since we can cleanly bury the
      loop), and it's perfectly clear when pointers into the worklist might be
      invalidated.
      
      I'm fixing both algorithms in the same commit to avoid repeating the
      commit message; if you take the time to understand one the other should
      be easy.  The diff itself isn't entirely obvious since the traversals
      have some noise (i.e., things to do), but here's the high-level change:
      
          auto helper = [&WL](T *Op) {     auto helper = [](T **&I, T **E) {
                                       =>    while (I != E) {
            if (shouldVisit(Op)) {             T *Op = *I++;
              WL.push(Op, Op->begin());        if (shouldVisit(Op)) {
              return true;                       return Op;
            }                                }
            return false;                    return nullptr;
          };                               };
                                       =>
          WL.push(S, S->begin());          WL.push(S, S->begin());
          while (!empty()) {               while (!empty()) {
            auto *N = WL.top().N;            auto *N = WL.top().N;
            auto *&I = WL.top().I;           auto *&I = WL.top().I;
            bool DidChange = false;
            while (I != N->end())
              if (helper(*I++)) {      =>    if (T *Op = helper(I, N->end()) {
                DidChange = true;              WL.push(Op, Op->begin());
                break;                         continue;
              }                              }
            if (DidChange)
              continue;
      
            POT.push(WL.pop());        =>    POT.push(WL.pop());
          }                                }
      
      Thanks to Mehdi for helping me find a better way to layer this.
      
      llvm-svn: 267099
      71480bd0
    • Mike Aizatsky's avatar
      Fixed flag description · 243b71fd
      Mike Aizatsky authored
      Summary:
      asan-use-after-return control feature we call use-after-return or
      stack-use-after-return.
      
      Reviewers: kcc, aizatsky, eugenis
      
      Subscribers: llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D19284
      
      llvm-svn: 267064
      243b71fd
  3. Apr 21, 2016
  4. Apr 20, 2016
Loading