Skip to content
  1. Oct 29, 2009
  2. Oct 28, 2009
    • Bob Wilson's avatar
      Reimplement BranchFolding change to avoid tail merging for a 1 instruction · 3ab552ec
      Bob Wilson authored
      common tail, except when the OptimizeForSize function attribute is present.
      Radar 7338114.
      
      llvm-svn: 85441
      3ab552ec
    • Bob Wilson's avatar
      Revert r85346 change to control tail merging by CodeGenOpt::Level. · 97b93126
      Bob Wilson authored
      I'm going to redo this using the OptimizeForSize function attribute.
      
      llvm-svn: 85426
      97b93126
    • Bob Wilson's avatar
      Record CodeGen optimization level in the BranchFolding pass so that we can · 9693f9d4
      Bob Wilson authored
      use it to control tail merging when there is a tradeoff between performance
      and code size.  When there is only 1 instruction in the common tail, we have
      been merging.  That can be good for code size but is a definite loss for
      performance.  Now we will avoid tail merging in that case when the
      optimization level is "Aggressive", i.e., "-O3".  Radar 7338114.
      
      Since the IfConversion pass invokes BranchFolding, it too needs to know
      the optimization level.  Note that I removed the RegisterPass instantiation
      for IfConversion because it required a default constructor.  If someone
      wants to keep that for some reason, we can add a default constructor with
      a hard-wired optimization level.
      
      llvm-svn: 85346
      9693f9d4
  3. Oct 22, 2009
    • Dan Gohman's avatar
      Revert the main portion of r31856. It was causing BranchFolding · ff97acd8
      Dan Gohman authored
      to break up CFG diamonds by banishing one of the blocks to the end of
      the function, which is bad for code density and branch size.
      
      This does pessimize MultiSource/Benchmarks/Ptrdist/yacr2, the
      benchmark cited as the reason for the change, however I've examined
      the code and it looks more like a case of gaming a particular
      branch than of being generally applicable.
      
      llvm-svn: 84803
      ff97acd8
  4. Sep 04, 2009
  5. Aug 22, 2009
  6. Aug 18, 2009
    • Dan Gohman's avatar
      Make tail merging handle blocks with repeated predecessors correctly, and · a41fa359
      Dan Gohman authored
      remove RemoveDuplicateSuccessor, as it is no longer necessary, and because
      it breaks assumptions made in
      MachineBasicBlock::isOnlyReachableByFallthrough.
      
      Convert test/CodeGen/X86/omit-label.ll to FileCheck and add a testcase
      for PR4732.
      
      test/CodeGen/Thumb2/thumb2-ifcvt2.ll sees a diff with this commit due to
      it being bugpoint-reduced to the point where it doesn't matter what the
      condition for the branch is.
      
      Add some more interesting code to
      test/CodeGen/X86/2009-08-06-branchfolder-crash.ll, which is the testcase
      that originally motivated the RemoveDuplicateSuccessor code, to help
      verify that the original problem isn't being re-broken.
      
      llvm-svn: 79338
      a41fa359
  7. Aug 07, 2009
  8. Jul 14, 2009
  9. Jul 11, 2009
    • Torok Edwin's avatar
      assert(0) -> LLVM_UNREACHABLE. · 56d06597
      Torok Edwin authored
      Make llvm_unreachable take an optional string, thus moving the cerr<< out of
      line.
      LLVM_UNREACHABLE is now a simple wrapper that makes the message go away for
      NDEBUG builds.
      
      llvm-svn: 75379
      56d06597
  10. May 11, 2009
  11. Feb 09, 2009
  12. Jan 28, 2009
  13. Jan 08, 2009
  14. Dec 11, 2008
  15. Dec 03, 2008
  16. Oct 27, 2008
  17. Oct 03, 2008
  18. Sep 22, 2008
  19. Sep 13, 2008
    • Dan Gohman's avatar
      Remove isImm(), isReg(), and friends, in favor of · 38453eeb
      Dan Gohman authored
      isImmediate(), isRegister(), and friends, to avoid confusion
      about having two different names with the same meaning. I'm
      not attached to the longer names, and would be ok with
      changing to the shorter names if others prefer it.
      
      llvm-svn: 56189
      38453eeb
  20. Sep 04, 2008
  21. Aug 22, 2008
  22. Aug 15, 2008
  23. Jul 29, 2008
  24. Jul 08, 2008
    • Dan Gohman's avatar
      Pool-allocation for MachineInstrs, MachineBasicBlocks, and · 3b460303
      Dan Gohman authored
      MachineMemOperands. The pools are owned by MachineFunctions.
      
      This drastically reduces the number of calls to malloc/free made
      during the "Emit" phase of scheduling, as well as later phases
      in CodeGen. Combined with other changes, this speeds up the
      "instruction selection" phase of CodeGen by 10% in some cases.
      
      llvm-svn: 53212
      3b460303
  25. Jul 01, 2008
    • Dale Johannesen's avatar
      Fix longstanding thinko: don't exclude · ad6b3a6e
      Dale Johannesen authored
      predessors of exit blocks from tail merging
      consideration.
      
      llvm-svn: 52985
      ad6b3a6e
    • Dan Gohman's avatar
      Split ISD::LABEL into ISD::DBG_LABEL and ISD::EH_LABEL, eliminating · fb19f940
      Dan Gohman authored
      the need for a flavor operand, and add a new SDNode subclass,
      LabelSDNode, for use with them to eliminate the need for a label id
      operand.
      
      Change instruction selection to let these label nodes through
      unmodified instead of creating copies of them. Teach the MachineInstr
      emitter how to emit a MachineInstr directly from an ISD label node.
      
      This avoids the need for allocating SDNodes for the label id and
      flavor value, as well as SDNodes for each of the post-isel label,
      label id, and label flavor.
      
      llvm-svn: 52943
      fb19f940
  26. Jun 19, 2008
  27. May 23, 2008
  28. May 13, 2008
  29. May 12, 2008
  30. May 10, 2008
  31. May 09, 2008
  32. May 06, 2008
  33. Apr 10, 2008
    • Evan Cheng's avatar
      Teach branch folding pass about implicit_def instructions. Unfortunately we... · 9d339849
      Evan Cheng authored
      Teach branch folding pass about implicit_def instructions. Unfortunately we can't just eliminate them since register scavenger expects every register use to be defined. However, we can delete them when there are no intra-block uses.  Carefully removing some implicit def's which enable more blocks to be optimized away.
      
      llvm-svn: 49461
      9d339849
  34. Feb 28, 2008
Loading