Fix bug introduced in last checkin due to CastInst not being visible

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3327 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2002-08-14 18:22:19 +00:00
parent 9c16dba29f
commit 9b2b80fd48
2 changed files with 5 additions and 3 deletions

View File

@ -253,7 +253,8 @@ void GCSE::CommonSubExpressionFound(Instruction *I, Instruction *Other) {
//
//===----------------------------------------------------------------------===//
bool GCSE::visitCastInst(CastInst &I) {
bool GCSE::visitCastInst(CastInst &CI) {
Instruction &I = (Instruction&)CI;
Value *Op = I.getOperand(0);
Function *F = I.getParent()->getParent();

View File

@ -88,8 +88,9 @@ namespace {
if (isLoopInvariant(I.getOperand(0)) && isLoopInvariant(I.getOperand(1)))
hoist(I);
}
void visitCastInst(CastInst &I) {
if (isLoopInvariant(I.getOperand(0))) hoist((Instruction&)I);
void visitCastInst(CastInst &CI) {
Instruction &I = (Instruction&)CI;
if (isLoopInvariant(I.getOperand(0))) hoist(I);
}
void visitShiftInst(ShiftInst &I) { visitBinaryOperator((Instruction&)I); }