diff options
| author | Chris Lattner <sabre@nondot.org> | 2007-01-07 06:58:05 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2007-01-07 06:58:05 +0000 |
| commit | fbc524fe874526aa52c722c4c123bac6cd875816 (patch) | |
| tree | 5218cb3a0168d57e4f4d29f264d8edaa065ffcab /llvm/lib/Transforms | |
| parent | cd65cf6095a04e7501f0e57841015e00a8c8514a (diff) | |
| download | bcm5719-llvm-fbc524fe874526aa52c722c4c123bac6cd875816.tar.gz bcm5719-llvm-fbc524fe874526aa52c722c4c123bac6cd875816.zip | |
relax some types
llvm-svn: 32980
Diffstat (limited to 'llvm/lib/Transforms')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/InstructionCombining.cpp | 5 | ||||
| -rw-r--r-- | llvm/lib/Transforms/Scalar/LowerGC.cpp | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp index 66fbe1482d9..ccc4a9cc864 100644 --- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp @@ -3552,8 +3552,7 @@ Instruction *InstCombiner::MatchBSwap(BinaryOperator &I) { FnName = "llvm.bswap.i64"; else assert(0 && "Unknown integer type!"); - Function *F = M->getOrInsertFunction(FnName, I.getType(), I.getType(), NULL); - + Constant *F = M->getOrInsertFunction(FnName, I.getType(), I.getType(), NULL); return new CallInst(F, V); } @@ -6953,7 +6952,7 @@ Instruction *InstCombiner::visitCallInst(CallInst &CI) { Name = "llvm.memcpy.i32"; else Name = "llvm.memcpy.i64"; - Function *MemCpy = M->getOrInsertFunction(Name, + Constant *MemCpy = M->getOrInsertFunction(Name, CI.getCalledFunction()->getFunctionType()); CI.setOperand(0, MemCpy); Changed = true; diff --git a/llvm/lib/Transforms/Scalar/LowerGC.cpp b/llvm/lib/Transforms/Scalar/LowerGC.cpp index e0d6933821f..fa06bd0dfcb 100644 --- a/llvm/lib/Transforms/Scalar/LowerGC.cpp +++ b/llvm/lib/Transforms/Scalar/LowerGC.cpp @@ -37,7 +37,7 @@ namespace { /// GCRead/GCWrite - These are the functions provided by the garbage /// collector for read/write barriers. - Function *GCRead, *GCWrite; + Constant *GCRead, *GCWrite; /// RootChain - This is the global linked-list that contains the chain of GC /// roots. |

