Skip to content
  1. Dec 06, 2010
    • Chris Lattner's avatar
      Use a stronger predicate here, pointed out by Duncan · 4dc53e37
      Chris Lattner authored
      llvm-svn: 121040
      4dc53e37
    • Chris Lattner's avatar
      add some DEBUG statements. · ca335e38
      Chris Lattner authored
      llvm-svn: 121038
      ca335e38
    • Chris Lattner's avatar
      Fix PR8735, a really terrible problem in the inliner's "alloca merging" · fb212de0
      Chris Lattner authored
      optimization.
      
      Consider:
      static void foo() {
        A = alloca
        ...
      }
      
      static void bar() {
        B = alloca
        ...
        call foo();
      }
      
      void main() {
        bar()
      }
      
      The inliner proceeds bottom up, but lets pretend it decides not to inline foo
      into bar.  When it gets to main, it inlines bar into main(), and says "hey, I
      just inlined an alloca "B" into main, lets remember that.  Then it keeps going
      and finds that it now contains a call to foo.  It decides to inline foo into
      main, and says "hey, foo has an alloca A, and I have an alloca B from another
      inlined call site, lets reuse it".  The problem with this of course, is that 
      the lifetime of A and B are nested, not disjoint.
      
      Unfortunately I can't create a reasonable testcase for this: the one in the
      PR is both huge and extremely sensitive, because you minor tweaks end up
      causing foo to get inlined into bar too early.  We already have tests for the
      basic alloca merging optimization and this does not break them.
      
      llvm-svn: 120995
      fb212de0
    • Chris Lattner's avatar
      improve comment · cd3af96a
      Chris Lattner authored
      llvm-svn: 120994
      cd3af96a
    • Chris Lattner's avatar
      improve -debug output and comments a little. · 5b6a865f
      Chris Lattner authored
      llvm-svn: 120993
      5b6a865f
    • Chris Lattner's avatar
      Fix PR8728, a miscompilation I recently introduced. When optimizing · 94fbdf38
      Chris Lattner authored
      memcpy's like:
        memcpy(A, B)
        memcpy(A, C)
      
      we cannot delete the first memcpy as dead if A and C might be aliases.
      If so, we actually get:
      
        memcpy(A, B)
        memcpy(A, A)
      
      which is not correct to transform into:
      
        memcpy(A, A)
      
      This patch was heavily influenced by Jakub Staszak's patch in PR8728, thanks
      Jakub!
      
      llvm-svn: 120974
      94fbdf38
  2. Dec 05, 2010
    • Frits van Bommel's avatar
      Refactor jump threading. · 76244867
      Frits van Bommel authored
      Should have no functional change other than the order of two transformations that are mutually-exclusive and the exact formatting of debug output.
      Internally, it now stores the ConstantInt*s as Constant*s, and actual undef values instead of nulls.
      
      llvm-svn: 120946
      76244867
    • Frits van Bommel's avatar
      Remove trailing whitespace. · 5e75ef4a
      Frits van Bommel authored
      llvm-svn: 120945
      5e75ef4a
    • Frits van Bommel's avatar
      Teach SimplifyCFG to turn · 8fb69ee8
      Frits van Bommel authored
        (indirectbr (select cond, blockaddress(@fn, BlockA),
                                  blockaddress(@fn, BlockB)))
      into
        (br cond, BlockA, BlockB).
      
      llvm-svn: 120943
      8fb69ee8
  3. Dec 01, 2010
  4. Nov 30, 2010
  5. Nov 29, 2010
  6. Nov 27, 2010
  7. Nov 24, 2010
  8. Nov 23, 2010
Loading