[llvm-commits] [llvm] r142799 - /llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp
Chandler Carruth
chandlerc at gmail.com
Mon Oct 24 09:51:55 PDT 2011
Author: chandlerc
Date: Mon Oct 24 11:51:55 2011
New Revision: 142799
URL: http://llvm.org/viewvc/llvm-project?rev=142799&view=rev
Log:
Sink an otherwise unused variable's initializer into the asserts that
used it. Fixes an unused variable warning from GCC on release builds.
Modified:
llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp
Modified: llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp?rev=142799&r1=142798&r2=142799&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp (original)
+++ llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp Mon Oct 24 11:51:55 2011
@@ -395,9 +395,8 @@
void MachineBlockPlacement::placeChainsTopologically(MachineFunction &F) {
MachineBasicBlock *EntryB = &F.front();
- BlockChain *EntryChain = BlockToChain[EntryB];
- assert(EntryChain && "Missing chain for entry block");
- assert(*EntryChain->begin() == EntryB &&
+ assert(BlockToChain[EntryB] && "Missing chain for entry block");
+ assert(*BlockToChain[EntryB]->begin() == EntryB &&
"Entry block is not the head of the entry block chain");
// Walk the blocks in RPO, and insert each block for a chain in order the
More information about the llvm-commits
mailing list