[llvm] r184568 - Modify the -join-globalcopies option (off by default).

Andrew Trick atrick at apple.com
Fri Jun 21 11:33:09 PDT 2013


Author: atrick
Date: Fri Jun 21 13:33:09 2013
New Revision: 184568

URL: http://llvm.org/viewvc/llvm-project?rev=184568&view=rev
Log:
Modify the -join-globalcopies option (off by default).

Always coalesce in forward order to propagate rematerialization.
I'm fixing this option so I can enable it by default soon.

Modified:
    llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp

Modified: llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp?rev=184568&r1=184567&r2=184568&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp (original)
+++ llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp Fri Jun 21 13:33:09 2013
@@ -2117,8 +2117,8 @@ RegisterCoalescer::copyCoalesceInMBB(Mac
     // are not inherently easier to resolve, but slightly preferable until we
     // have local live range splitting. In particular this is required by
     // cmp+jmp macro fusion.
-    for (MachineBasicBlock::reverse_iterator
-           MII = MBB->rbegin(), E = MBB->rend(); MII != E; ++MII) {
+    for (MachineBasicBlock::iterator MII = MBB->begin(), E = MBB->end();
+         MII != E; ++MII) {
       if (!MII->isCopyLike())
         continue;
       if (isLocalCopy(&(*MII), LIS))





More information about the llvm-commits mailing list