Skip to content
  1. May 23, 2004
  2. May 19, 2004
  3. May 14, 2004
    • Brian Gaeke's avatar
      Clean up this pass somewhat: · 27e49435
      Brian Gaeke authored
      Add better comments, including a better head-of-file comment.
      Prune #includes.
      Fix a FIXME that Chris put here by using doInitialization().
      Use DEBUG() to print out debug msgs.
      Give names to basic blocks inserted by this pass.
      Expand tabs.
      Use InsertProfilingInitCall() from ProfilingUtils to insert the initialize call.
      
      llvm-svn: 13581
      27e49435
  4. May 13, 2004
    • Chris Lattner's avatar
      This was not meant to be committed · 0026512b
      Chris Lattner authored
      llvm-svn: 13565
      0026512b
    • Chris Lattner's avatar
      Fix a nasty bug that caused us to unroll EXTREMELY large loops due to overflow · c12c945c
      Chris Lattner authored
      in the size calculation.
      
      This is not something you want to see:
      Loop Unroll: F[main] Loop %no_exit Loop Size = 2 Trip Count = 2147483648 - UNROLLING!
      
      The problem was that 2*2147483648 == 0.
      
      Now we get:
      Loop Unroll: F[main] Loop %no_exit Loop Size = 2 Trip Count = 2147483648 - TOO LARGE: 4294967296>100
      
      Thanks to some anonymous person playing with the demo page that repeatedly
      caused zion to go into swapping land.  That's one way to ensure you'll get
      a quick bugfix.  :)
      
      Testcase here: Transforms/LoopUnroll/2004-05-13-DontUnrollTooMuch.ll
      
      llvm-svn: 13564
      c12c945c
  5. May 12, 2004
    • Chris Lattner's avatar
      Do not pass in the same argument to the extracted function more than once, and · 66219aba
      Chris Lattner authored
      give the extracted function a more useful name than just foo_code.
      
      llvm-svn: 13493
      66219aba
    • Chris Lattner's avatar
      Implement support for code extracting basic blocks that have a return · 13d2ddfe
      Chris Lattner authored
      instruction in them.
      
      llvm-svn: 13490
      13d2ddfe
    • Chris Lattner's avatar
      Implement splitting of PHI nodes, allowing block extraction of BB's that have · 795c9933
      Chris Lattner authored
      PHI node entries from multiple outside-the-region blocks.  This also fixes
      extraction of the entry block in a function.  Yaay.
      
      This has successfully block extracted all (but one) block from the score_move
      function in obsequi (out of 33).  Hrm, I wonder which block the bug is in.  :)
      
      llvm-svn: 13489
      795c9933
    • Chris Lattner's avatar
      * Pull some code out into the definedInRegion/definedInCaller methods · 3b2917bf
      Chris Lattner authored
      * Add a stub for the severSplitPHINodes which will allow us to bbextract
        bb's with PHI nodes in them soon.
      * Remove unused arguments from findInputsOutputs
      * Dramatically simplify the code in findInputsOutputs.  In particular,
        nothing really cares whether or not a PHI node is using something.
      * Move moveCodeToFunction to after emitCallAndSwitchStatement as that's the
        order they get called.
      * Fix a bug where we would code extract a region that included a call to
        vastart.  Like 'alloca', calls to vastart must stay in the function that
        they are defined in.
      * Add some comments.
      
      llvm-svn: 13482
      3b2917bf
    • Chris Lattner's avatar
      Generate substantially better code when there are a limited number of exits · ffc49262
      Chris Lattner authored
      from the extracted region.  If the return has 0 or 1 exit blocks, the new
      function returns void.  If it has 2 exits, it returns bool, otherwise it
      returns a ushort as before.
      
      This allows us to use a conditional branch instruction when there are two
      exit blocks, as often happens during block extraction.
      
      llvm-svn: 13481
      ffc49262
    • Chris Lattner's avatar
      Two minor improvements: · 3d1ca67f
      Chris Lattner authored
        1. Get rid of the silly abort block.  When doing bb extraction, we get one
           abort block for every block extracted, which is kinda annoying.
        2. If the switch ends up having a single destination, turn it into an
           unconditional branch.
      
      I would like to add support for conditional branches, but to do this we will
      want to have the function return a bool instead of a ushort.
      
      llvm-svn: 13478
      3d1ca67f
  6. May 09, 2004
  7. May 08, 2004
    • Chris Lattner's avatar
      Implement folding of GEP's like: · 5f667a6f
      Chris Lattner authored
              %tmp.0 = getelementptr [50 x sbyte]* %ar, uint 0, int 5         ; <sbyte*> [#uses=2]
              %tmp.7 = getelementptr sbyte* %tmp.0, int 8             ; <sbyte*> [#uses=1]
      
      together.  This patch actually allows us to simplify and generalize the code.
      
      llvm-svn: 13415
      5f667a6f
  8. May 07, 2004
  9. May 04, 2004
  10. May 02, 2004
  11. Apr 30, 2004
    • Chris Lattner's avatar
      Fix a major pessimization in the instcombiner. If an allocation instruction · 652064e3
      Chris Lattner authored
      is only used by a cast, and the casted type is the same size as the original
      allocation, it would eliminate the cast by folding it into the allocation.
      
      Unfortunately, it was placing the new allocation instruction right before
      the cast, which could pull (for example) alloca instructions into the body
      of a function.  This turns statically allocatable allocas into expensive
      dynamically allocated allocas, which is bad bad bad.
      
      This fixes the problem by placing the new allocation instruction at the same
      place the old one was, duh. :)
      
      llvm-svn: 13289
      652064e3
  12. Apr 27, 2004
  13. Apr 26, 2004
  14. Apr 24, 2004
  15. Apr 23, 2004
  16. Apr 22, 2004
Loading