Don't use PassInfo* as a type identifier for passes. Instead, use the address of...
[oota-llvm.git] / tools / bugpoint / bugpoint.cpp
index ba5234bdc89d52f7659eddef22ce4db3d696ed8c..b4bc455db122ac1c13df59ad1547d92bcef49b29 100644 (file)
@@ -90,7 +90,8 @@ namespace {
     AddToDriver(BugDriver &_D) : D(_D) {}
     
     virtual void add(Pass *P) {
-      const PassInfo *PI = P->getPassInfo();
+      const void *ID = P->getPassID();
+      const PassInfo *PI = PassRegistry::getPassRegistry()->getPassInfo(ID);
       D.addPasses(&PI, &PI + 1);
     }
   };