Skip to content
  1. Dec 19, 2012
  2. Dec 18, 2012
  3. Dec 17, 2012
    • Chandler Carruth's avatar
      Fix another SROA crasher, PR14601. · e3f4119b
      Chandler Carruth authored
      This was a silly oversight, we weren't pruning allocas which were used
      by variable-length memory intrinsics from the set that could be widened
      and promoted as integers. Fix that.
      
      llvm-svn: 170353
      e3f4119b
    • Evgeniy Stepanov's avatar
      [msan] Fix lint warning. · 88b8dced
      Evgeniy Stepanov authored
      llvm-svn: 170347
      88b8dced
    • Chandler Carruth's avatar
      Teach the rewriting of memcpy calls to support subvector copies. · 21eb4e96
      Chandler Carruth authored
      This also cleans up a bit of the memcpy call rewriting by sinking some
      irrelevant code further down and making the call-emitting code a bit
      more concrete.
      
      Previously, memcpy of a subvector would actually miscompile (!!!) the
      copy into a single vector element copy. I have no idea how this ever
      worked. =/ This is the memcpy half of PR14478 which we probably weren't
      noticing previously because it didn't actually assert.
      
      The rewrite relies on the newly refactored insert- and extractVector
      functions to do the heavy lifting, and those are the same as used for
      loads and stores which makes the test coverage a bit more meaningful
      here.
      
      llvm-svn: 170338
      21eb4e96
    • Evgeniy Stepanov's avatar
      Optimize tree walking in markAliveBlocks. · 95a80abe
      Evgeniy Stepanov authored
      Check whether a BB is known as reachable before adding it to the worklist.
      This way BB's with multiple predecessors are added to the list no more than
      once.
      
      llvm-svn: 170335
      95a80abe
    • Chandler Carruth's avatar
      Fix a secondary bug I introduced while fixing the first part of PR14478. · cacda256
      Chandler Carruth authored
      The first half of fixing this bug was actually in r170328, but was
      entirely coincidental. It did however get me to realize the nature of
      the bug, and adapt the test case to test more interesting behavior. In
      turn, that uncovered the rest of the bug which I've fixed here.
      
      This should fix two new asserts that showed up in the vectorize nightly
      tester.
      
      llvm-svn: 170333
      cacda256
    • Chandler Carruth's avatar
      Hoist a convertValue call to the two paths where it is needed. · 95e1fb8a
      Chandler Carruth authored
      I noticed this while looking at r170328. We only ever do a vector
      rewrite when the alloca *is* the vector type, so it's good to not paper
      over bugs here by doing a convertValue that isn't needed.
      
      llvm-svn: 170331
      95e1fb8a
    • Chandler Carruth's avatar
      Hoist the insertVector helper to be a static helper. · ce4562bd
      Chandler Carruth authored
      This will allow its use inside of memcpy rewriting as well. This routine
      is more complex than extractVector, and some of its uses are not 100%
      where I want them to be so there is still some work to do here.
      
      While this can technically change the output in some cases, it shouldn't
      be a change that matters -- IE, it can leave some dead code lying around
      that prior versions did not, etc.
      
      Yet another step in the refactorings leading up to the solution to the
      last component of PR14478.
      
      llvm-svn: 170328
      ce4562bd
    • Chandler Carruth's avatar
      Lift the extractVector helper all the way out to a static helper function. · b6bc8749
      Chandler Carruth authored
      The method helpers all implicitly act upon the alloca, and what we
      really want is a fully generic helper. Doing memcpy rewrites is more
      special than all other rewrites because we are at times rewriting
      instructions which touch pointers *other* than the alloca. As
      a consequence all of the helpers needed by memcpy rewriting of
      sub-vector copies will need to be generalized fully.
      
      Note that all of these helpers ({insert,extract}{Integer,Vector}) are
      woefully uncommented. I'm going to go back through and document them
      once I get the factoring correct.
      
      No functionality changed.
      
      llvm-svn: 170325
      b6bc8749
    • Chandler Carruth's avatar
      Factor the vector load rewriting into a more generic form. · 769445ef
      Chandler Carruth authored
      This makes it suitable for use in rewriting memcpy in the presence of
      subvector memcpy intrinsics.
      
      No functionality changed.
      
      llvm-svn: 170324
      769445ef
    • Chandler Carruth's avatar
      Fix the first part of PR14478: memset now works. · ccca504f
      Chandler Carruth authored
      PR14478 highlights a serious problem in SROA that simply wasn't being
      exercised due to a lack of vector input code mixed with C-library
      function calls. Part of SROA was written carefully to handle subvector
      accesses via memset and memcpy, but the rewriter never grew support for
      this. Fixing it required refactoring the subvector access code in other
      parts of SROA so it could be shared, and then fixing the splat formation
      logic and using subvector insertion (this patch).
      
      The PR isn't quite fixed yet, as memcpy is still broken in the same way.
      I'm starting on that series of patches now.
      
      Hopefully this will be enough to bring the bullet benchmark back to life
      with the bb-vectorizer enabled, but that may require fixing memcpy as
      well.
      
      llvm-svn: 170301
      ccca504f
    • Chandler Carruth's avatar
      Extract the logic for inserting a subvector into a vector alloca. · eae65a56
      Chandler Carruth authored
      No functionality changed. Another step of refactoring toward solving
      PR14487.
      
      llvm-svn: 170300
      eae65a56
    • Chandler Carruth's avatar
      Lift the integer splat computation into a helper function. · 514f34f9
      Chandler Carruth authored
      No functionality changed. Refactoring leading up to the fix for PR14478
      which requires some significant changes to the memset and memcpy
      rewriting.
      
      llvm-svn: 170299
      514f34f9
  4. Dec 15, 2012
  5. Dec 14, 2012
  6. Dec 13, 2012
  7. Dec 12, 2012
Loading