Skip to content
  1. Oct 05, 2003
    • Chris Lattner's avatar
      Speed up the mem2reg transform for allocas which are only read/written in a single · 80471529
      Chris Lattner authored
      basic block.  This is amazingly common in code generated by the C/C++ front-ends.
      This change makes it not have to insert ANY phi nodes, whereas before it would insert
      a ton of dead ones which DCE would have to clean up.
      
      Thus, this fix improves compile-time performance of these trivial allocas in two ways:
        1. It doesn't have to do the walking and book-keeping for renaming
        2. It does not insert dead phi nodes for them which would have to
           subsequently be cleaned up.
      
      On my favorite testcase from 252.eon, this special case handles 305 out of
      356 promoted allocas in the function.  It speeds up the mem2reg pass from 7.5256s
      to 1.2505s.  It inserts 677 fewer dead PHI nodes, which speeds up a subsequent
      -dce pass from 18.7524s to 2.4806s.
      
      There are still 120 trivially dead PHI nodes being inserted for variables used
      in multiple basic blocks, but they are not handled by this patch.
      
      llvm-svn: 8881
      80471529
    • Chris Lattner's avatar
      The first PHI node may be null, scan for the first non-null one · a5721d3d
      Chris Lattner authored
      llvm-svn: 8865
      a5721d3d
    • Chris Lattner's avatar
      The VersionNumbers vector is only used during PHI placement. Turn it into an... · 203bc011
      Chris Lattner authored
      The VersionNumbers vector is only used during PHI placement.  Turn it into an argument, allowing us to get rid of the vector.
      
      llvm-svn: 8864
      203bc011
    • Chris Lattner's avatar
      * Update file header comment · 7d9692df
      Chris Lattner authored
      *** Revamp the code which handled unreachable code in the function.  Now the
          code is much more efficient for high-degree basic blocks, such as those
          that occur in the 252.eon SPEC benchmark.
      
      For the interested, the time to promote a SINGLE alloca in _ZN7mrScene4ReadERSi
      function used to be > 3.5s.  Now it is < .075s.  The function has a LOT of
      allocas in it, so it appeared to be infinite looping, this should make it much
      nicer.  :)
      
      llvm-svn: 8863
      7d9692df
    • Chris Lattner's avatar
      Simplify the loop a bit · db1f81bc
      Chris Lattner authored
      llvm-svn: 8862
      db1f81bc
    • Chris Lattner's avatar
      There is no need for separate WriteSets and PhiNodeBlocks lists. It is just a · 2093012a
      Chris Lattner authored
      work-list of value definitions.  This allows elimination of the explicit
      'iterative' step of the algorithm, and also reuses temporary memory better.
      
      llvm-svn: 8861
      2093012a
    • Chris Lattner's avatar
      The PhiNodes 2D vector is only used during PHI node placement. It doesn't · 9408b1e8
      Chris Lattner authored
      need to be an instance variable!
      
      llvm-svn: 8860
      9408b1e8
    • Chris Lattner's avatar
      * Document instance vars better · 417bc173
      Chris Lattner authored
      * Fuse two parallel loops
      * Use a more specific type for AllocaLookup
      
      llvm-svn: 8859
      417bc173
    • Chris Lattner's avatar
      Two small cleanups/speedups: · c360f135
      Chris Lattner authored
       * Do not insert a new entry into NewPhiNodes during the rename pass if there are no PHIs in a block.
       * Do not compute WriteSets in parallel
      
      llvm-svn: 8858
      c360f135
    • Chris Lattner's avatar
      * Minor cleanups · c3d57b59
      Chris Lattner authored
      * Eliminate the KillList instance variable, instead, just delete loads and
        stores as they are "renamed", and delete allocas when they are done
      * Make the 'visited' set an instance variable to avoid passing it on the stack.
      
      llvm-svn: 8857
      c3d57b59
  2. Sep 23, 2003
  3. Sep 22, 2003
  4. Sep 20, 2003
  5. Sep 15, 2003
  6. Sep 10, 2003
  7. Sep 08, 2003
  8. Aug 28, 2003
  9. Aug 26, 2003
  10. Aug 24, 2003
  11. Aug 23, 2003
  12. Aug 22, 2003
  13. Aug 18, 2003
  14. Aug 17, 2003
  15. Aug 05, 2003
  16. May 31, 2003
  17. May 30, 2003
Loading