Add debugging helper
[oota-llvm.git] / lib / Transforms / LevelRaise.cpp
index 84f57852cdcdee426f8341aeb4b881788526ffb0..952082320635046f6a4bb87acccaecea81f43082 100644 (file)
@@ -209,7 +209,7 @@ static bool PeepholeOptimize(BasicBlock *BB, BasicBlock::iterator &BI) {
       if (!Src->hasName() && CI->hasName()) {
         std::string Name = CI->getName();
         CI->setName("");
-        Src->setName(Name, BB->getParent()->getSymbolTable());
+        Src->setName(Name, &BB->getParent()->getSymbolTable());
       }
 
       // DCE the instruction now, to avoid having the iterative version of DCE