[llvm] r252394 - Try to fix build more -- like r252392 but for WebAssembly.

Nico Weber via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 6 18:47:31 PST 2015


Author: nico
Date: Fri Nov  6 20:47:31 2015
New Revision: 252394

URL: http://llvm.org/viewvc/llvm-project?rev=252394&view=rev
Log:
Try to fix build more -- like r252392 but for WebAssembly.

Modified:
    llvm/trunk/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp

Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp?rev=252394&r1=252393&r2=252394&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp Fri Nov  6 20:47:31 2015
@@ -154,7 +154,7 @@ static void SortBlocks(MachineFunction &
   SmallPtrSet<MachineBasicBlock *, 16> Visited;
   SmallVector<POStackEntry, 16> Stack;
 
-  MachineBasicBlock *Entry = MF.begin();
+  MachineBasicBlock *Entry = &*MF.begin();
   Visited.insert(Entry);
   Stack.push_back(POStackEntry(Entry, MF, MLI));
 
@@ -170,7 +170,7 @@ static void SortBlocks(MachineFunction &
 
     // Put the block in its position in the MachineFunction.
     MachineBasicBlock &MBB = *Entry.MBB;
-    MBB.moveBefore(MF.begin());
+    MBB.moveBefore(&*MF.begin());
 
     // Branch instructions may utilize a fallthrough, so update them if a
     // fallthrough has been added or removed.
@@ -196,7 +196,7 @@ static void SortBlocks(MachineFunction &
       assert(Loop->getHeader() == Loop->getTopBlock());
       assert((Loop->getHeader() == &MBB ||
               Loop->contains(
-                  MLI.getLoopFor(prev(MachineFunction::iterator(&MBB))))) &&
+                  MLI.getLoopFor(&*prev(MachineFunction::iterator(&MBB))))) &&
              "Loop isn't contiguous");
     } else {
       // Assert that non-loops have no backedge predecessors.
@@ -257,7 +257,7 @@ static void PlaceMarkers(MachineFunction
           Iter = next(MachineFunction::iterator(Bottom));
         }
         BuildMI(MBB, MBB.begin(), DebugLoc(), TII.get(WebAssembly::LOOP))
-            .addMBB(Iter);
+            .addMBB(&*Iter);
       }
 
     // Check for forward branches and switches that need BLOCKS placed.




More information about the llvm-commits mailing list