diff options
author | Nico Weber <nicolasweber@gmx.de> | 2015-11-07 02:47:31 +0000 |
---|---|---|
committer | Nico Weber <nicolasweber@gmx.de> | 2015-11-07 02:47:31 +0000 |
commit | 00406472e8763041fe1dc4d439776d75cccbed90 (patch) | |
tree | 812106512d568798412c5052e7bc279158c2b6da /llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp | |
parent | 76dd243f99ce814f1f5d2da9cb936db7dc6e90da (diff) | |
download | bcm5719-llvm-00406472e8763041fe1dc4d439776d75cccbed90.tar.gz bcm5719-llvm-00406472e8763041fe1dc4d439776d75cccbed90.zip |
Try to fix build more -- like r252392 but for WebAssembly.
llvm-svn: 252394
Diffstat (limited to 'llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp')
-rw-r--r-- | llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp b/llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp index 077273c17d7..58b16dc4cb6 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp +++ b/llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp @@ -154,7 +154,7 @@ static void SortBlocks(MachineFunction &MF, const MachineLoopInfo &MLI) { 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 &MF, const MachineLoopInfo &MLI) { // 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 &MF, const MachineLoopInfo &MLI) { 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 &MF, const MachineLoopInfo &MLI, 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. |