Skip to content
  1. Jan 04, 2011
  2. Jan 03, 2011
  3. Jan 02, 2011
  4. Dec 22, 2010
  5. Dec 21, 2010
  6. Dec 19, 2010
  7. Dec 16, 2010
  8. Dec 15, 2010
  9. Nov 30, 2010
  10. Nov 19, 2010
  11. Nov 18, 2010
    • Owen Anderson's avatar
      Completely rework the datastructure GVN uses to represent the value number to... · c21c100f
      Owen Anderson authored
      Completely rework the datastructure GVN uses to represent the value number to leader mapping.  Previously,
      this was a tree of hashtables, and a query recursed into the table for the immediate dominator ad infinitum
      if the initial lookup failed.  This led to really bad performance on tall, narrow CFGs.
      
      We can instead replace it with what is conceptually a multimap of value numbers to leaders (actually
      represented by a hashtable with a list of Value*'s as the value type), and then
      determine which leader from that set to use very cheaply thanks to the DFS numberings maintained by
      DominatorTree.  Because there are typically few duplicates of a given value, this scan tends to be
      quite fast.  Additionally, we use a custom linked list and BumpPtr allocation to avoid any unnecessary
      allocation in representing the value-side of the multimap.
      
      This change brings with it a 15% (!) improvement in the total running time of GVN on 403.gcc, which I
      think is pretty good considering that includes all the "real work" being done by MemDep as well.
      
      The one downside to this approach is that we can no longer use GVN to perform simple conditional progation,
      but that seems like an acceptable loss since we now have LVI and CorrelatedValuePropagation to pick up
      the slack.  If you see conditional propagation that's not happening, please file bugs against LVI or CVP.
      
      llvm-svn: 119714
      c21c100f
  12. Nov 17, 2010
    • Duncan Sands's avatar
      Remove dead code in GVN: now that SimplifyInstruction is called · 72313843
      Duncan Sands authored
      systematically, CollapsePhi will always return null here.  Note
      that CollapsePhi did an extra check, isSafeReplacement, which
      the SimplifyInstruction logic does not do.  I think that check
      was bogus - I guess we will soon find out!  (It was originally
      added in commit 41998 without a testcase).
      
      llvm-svn: 119456
      72313843
  13. Nov 14, 2010
  14. Nov 12, 2010
    • Duncan Sands's avatar
      Have GVN simplify instructions as it goes. For example, consider · 246b71c5
      Duncan Sands authored
      "%z = %x and %y".  If GVN can prove that %y equals %x, then it turns
      this into "%z = %x and %x".  With the new code, %z will be replaced
      with %x everywhere (and then deleted).  Previously %z would be value
      numbered too, which is a waste of time.  Also, while a clever value
      numbering algorithm would give %z the same value number as %x, our
      current one doesn't do so (at least I don't think it does).  The new
      logic has an essentially equivalent effect to what you would get if
      %z was given the same value number as %x, i.e. it should make value
      numbering smarter.  While there, get hold of target data once at the
      start rather than a gazillion times all over the place.
      
      llvm-svn: 118923
      246b71c5
  15. Nov 11, 2010
  16. Nov 10, 2010
  17. Oct 19, 2010
    • Owen Anderson's avatar
      Get rid of static constructors for pass registration. Instead, every pass... · 6c18d1aa
      Owen Anderson authored
      Get rid of static constructors for pass registration.  Instead, every pass exposes an initializeMyPassFunction(), which
      must be called in the pass's constructor.  This function uses static dependency declarations to recursively initialize
      the pass's dependencies.
      
      Clients that only create passes through the createFooPass() APIs will require no changes.  Clients that want to use the
      CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h
      before parsing commandline arguments.
      
      I have tested this with all standard configurations of clang and llvm-gcc on Darwin.  It is possible that there are problems
      with the static dependencies that will only be visible with non-standard options.  If you encounter any crash in pass
      registration/creation, please send the testcase to me directly.
      
      llvm-svn: 116820
      6c18d1aa
  18. Oct 12, 2010
  19. Oct 08, 2010
  20. Oct 01, 2010
  21. Sep 30, 2010
  22. Sep 25, 2010
    • Owen Anderson's avatar
      LoadPRE was not properly checking that the load it was PRE'ing post-dominated... · b590a927
      Owen Anderson authored
      LoadPRE was not properly checking that the load it was PRE'ing post-dominated the block it was being hoisted to.
      Splitting critical edges at the merge point only addressed part of the issue; it is also possible for non-post-domination
      to occur when the path from the load to the merge has branches in it.  Unfortunately, full anticipation analysis is
      time-consuming, so for now approximate it.  This is strictly more conservative than real anticipation, so we will miss
      some cases that real PRE would allow, but we also no longer insert loads into paths where they didn't exist before. :-)
      
      This is a very slight net positive on SPEC for me (0.5% on average).  Most of the benchmarks are largely unaffected, but
      when it pays off it pays off decently: 181.mcf improves by 4.5% on my machine.
      
      llvm-svn: 114785
      b590a927
  23. Sep 04, 2010
  24. Sep 02, 2010
    • Duncan Sands's avatar
      Reapply commit 112699, speculatively reverted by echristo, since · 6778149f
      Duncan Sands authored
      I'm sure it is harmless.  Original commit message:
      If PrototypeValue is erased in the middle of using the SSAUpdator
      then the SSAUpdator may access freed memory.  Instead, simply pass
      in the type and name explicitly, which is all that was used anyway.
      
      llvm-svn: 112810
      6778149f
  25. Sep 01, 2010
  26. Aug 29, 2010
  27. Aug 07, 2010
  28. Aug 06, 2010
  29. Jul 22, 2010
  30. Jul 09, 2010
Loading