[llvm-commits] CVS: reopt/lib/Inst/lib/Phase1/Phase1.cpp PrimInfo.cpp
Brian Gaeke
gaeke at cs.uiuc.edu
Tue Jul 20 15:23:09 PDT 2004
Changes in directory reopt/lib/Inst/lib/Phase1:
Phase1.cpp updated: 1.31 -> 1.32
PrimInfo.cpp updated: 1.19 -> 1.20
---
Log message:
Add hacks to get this stuff compiling again - I actually have no
idea if it still works :-(
---
Diffs of the changes: (+5 -11)
Index: reopt/lib/Inst/lib/Phase1/Phase1.cpp
diff -u reopt/lib/Inst/lib/Phase1/Phase1.cpp:1.31 reopt/lib/Inst/lib/Phase1/Phase1.cpp:1.32
--- reopt/lib/Inst/lib/Phase1/Phase1.cpp:1.31 Tue Feb 24 14:42:03 2004
+++ reopt/lib/Inst/lib/Phase1/Phase1.cpp Tue Jul 20 17:22:59 2004
@@ -137,14 +137,9 @@
if(ConstantExpr* ce = dyn_cast<ConstantExpr>(rpairParam)) {
assert(ce->getNumOperands() == 1 &&
"ConstantExpr encountered with unexpected #opds");
- if(ConstantPointerRef* cpr =
- dyn_cast<ConstantPointerRef>(ce->getOperand(0))) {
- if(Function* func = dyn_cast<Function>(cpr->getValue())) {
- return func;
- }
- }
+ if (Function* func = dyn_cast<Function> (ce->getOperand (0)))
+ return func;
}
-
return 0;
}
@@ -304,9 +299,8 @@
for(Value::use_iterator u = startFunc->use_begin(),
ue = startFunc->use_end(); u != ue; ++u) {
- if(isa<ConstantPointerRef>(*u)) {
- continue; // skips forward declarations of sigfun
- }
+ if (isa<GlobalValue> (*u))
+ continue; // skips forward declarations of sigfun
CallInst* startCall = dyn_cast<CallInst>(*u);
assert(startCall && "Use of a registered pp sigfun not in a call");
Index: reopt/lib/Inst/lib/Phase1/PrimInfo.cpp
diff -u reopt/lib/Inst/lib/Phase1/PrimInfo.cpp:1.19 reopt/lib/Inst/lib/Phase1/PrimInfo.cpp:1.20
--- reopt/lib/Inst/lib/Phase1/PrimInfo.cpp:1.19 Tue Feb 24 14:42:03 2004
+++ reopt/lib/Inst/lib/Phase1/PrimInfo.cpp Tue Jul 20 17:22:59 2004
@@ -86,7 +86,7 @@
std::vector<Constant*> init;
init.push_back(ConstantUInt::get(Type::UIntTy, siteID)); // siteID
init.push_back(ConstantUInt::get(Type::UIntTy, gbtType)); // gbtType
- init.push_back(ConstantPointerRef::get(loadVar)); // loadVar
+ init.push_back(loadVar); // loadVar
return ConstantStruct::get(st, init);
}
More information about the llvm-commits
mailing list