*** empty log message ***


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2777 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/LiveVar/BBLiveVar.cpp b/lib/Analysis/LiveVar/BBLiveVar.cpp
index 7d735b7..eb58671 100644
--- a/lib/Analysis/LiveVar/BBLiveVar.cpp
+++ b/lib/Analysis/LiveVar/BBLiveVar.cpp
@@ -18,23 +18,23 @@
 
 static AnnotationID AID(AnnotationManager::getID("Analysis::BBLiveVar"));
 
-BBLiveVar *BBLiveVar::CreateOnBB(const BasicBlock *BB, unsigned POID) {
+BBLiveVar *BBLiveVar::CreateOnBB(const BasicBlock &BB, unsigned POID) {
   BBLiveVar *Result = new BBLiveVar(BB, POID);
-  BB->addAnnotation(Result);
+  BB.addAnnotation(Result);
   return Result;
 }
 
-BBLiveVar *BBLiveVar::GetFromBB(const BasicBlock *BB) {
-  return (BBLiveVar*)BB->getAnnotation(AID);
+BBLiveVar *BBLiveVar::GetFromBB(const BasicBlock &BB) {
+  return (BBLiveVar*)BB.getAnnotation(AID);
 }
 
-void BBLiveVar::RemoveFromBB(const BasicBlock *BB) {
-  bool Deleted = BB->deleteAnnotation(AID);
+void BBLiveVar::RemoveFromBB(const BasicBlock &BB) {
+  bool Deleted = BB.deleteAnnotation(AID);
   assert(Deleted && "BBLiveVar annotation did not exist!");
 }
 
 
-BBLiveVar::BBLiveVar(const BasicBlock *bb, unsigned id)
+BBLiveVar::BBLiveVar(const BasicBlock &bb, unsigned id)
   : Annotation(AID), BB(bb), POID(id) {
   InSetChanged = OutSetChanged = false;
 
@@ -50,7 +50,7 @@
 
 void BBLiveVar::calcDefUseSets() {
   // get the iterator for machine instructions
-  const MachineCodeForBasicBlock &MIVec = BB->getMachineInstrVec();
+  const MachineCodeForBasicBlock &MIVec = BB.getMachineInstrVec();
 
   // iterate over all the machine instructions in BB
   for (MachineCodeForBasicBlock::const_reverse_iterator MII = MIVec.rbegin(),
@@ -129,7 +129,7 @@
 //-----------------------------------------------------------------------------
 // To add an operand which is a def
 //-----------------------------------------------------------------------------
-void  BBLiveVar::addDef(const Value *Op) {
+void BBLiveVar::addDef(const Value *Op) {
   DefSet.insert(Op);     // operand is a def - so add to def set
   InSet.erase(Op);       // this definition kills any later uses
   InSetChanged = true; 
@@ -211,9 +211,9 @@
   //
   bool needAnotherIt = false;  
 
-  for (pred_const_iterator PI = pred_begin(BB), PE = pred_end(BB);
+  for (pred_const_iterator PI = pred_begin(&BB), PE = pred_end(&BB);
        PI != PE ; ++PI) {
-    BBLiveVar *PredLVBB = BBLiveVar::GetFromBB(*PI);
+    BBLiveVar *PredLVBB = BBLiveVar::GetFromBB(**PI);
 
     // do set union
     if (setPropagate(&PredLVBB->OutSet, &InSet, *PI)) {