diff options
author | Bill Wendling <isanbard@gmail.com> | 2011-07-12 01:16:47 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2011-07-12 01:16:47 +0000 |
commit | 7475113d746deebd4a7baefe1b9c716efd3c6170 (patch) | |
tree | d15f16d8b15a4cbadd617f3bb3fee1dc75aff99f /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | a78cd228c2a0f97feae7484473c5e8aad0cb51eb (diff) | |
download | bcm5719-llvm-7475113d746deebd4a7baefe1b9c716efd3c6170.tar.gz bcm5719-llvm-7475113d746deebd4a7baefe1b9c716efd3c6170.zip |
Revert r134888 (and related patches in other trees). It was causing
an assert on Darwin llvm-gcc builds.
Assertion failed: (castIsValid(op, S, Ty) && "Invalid cast!"), function Create, file /Users/buildslave/zorg/buildbot/smooshlab/slave-0.8/build.llvm-gcc-i386-darwin9-RA/llvm.src/lib/VMCore/Instructions.cpp, line 2067.
etc.
http://smooshlab.apple.com:8013/builders/llvm-gcc-i386-darwin9-RA/builds/2354
--- Reverse-merging r134888 into '.':
U lib/CodeGen/CodeGenModule.cpp
llvm-svn: 134950
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index e40d146bc06..95d7be5392e 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -1614,8 +1614,10 @@ llvm::Value *CodeGenModule::getBuiltinLibFunction(const FunctionDecl *FD, llvm::Function *CodeGenModule::getIntrinsic(unsigned IID, llvm::Type **Tys, unsigned NumTys) { - return llvm::Intrinsic::getDeclaration(&getModule(), (llvm::Intrinsic::ID)IID, - Tys, NumTys); + return llvm::Intrinsic::getDeclaration(&getModule(), + (llvm::Intrinsic::ID)IID, + const_cast<const llvm::Type **>(Tys), + NumTys); } static llvm::StringMapEntry<llvm::Constant*> & @@ -2293,7 +2295,7 @@ llvm::Constant *CodeGenModule::getBlockObjectDispose() { } // Otherwise construct the function by hand. - llvm::Type *args[] = { Int8PtrTy, Int32Ty }; + const llvm::Type *args[] = { Int8PtrTy, Int32Ty }; const llvm::FunctionType *fty = llvm::FunctionType::get(VoidTy, args, false); return BlockObjectDispose = @@ -2312,7 +2314,7 @@ llvm::Constant *CodeGenModule::getBlockObjectAssign() { } // Otherwise construct the function by hand. - llvm::Type *args[] = { Int8PtrTy, Int8PtrTy, Int32Ty }; + const llvm::Type *args[] = { Int8PtrTy, Int8PtrTy, Int32Ty }; const llvm::FunctionType *fty = llvm::FunctionType::get(VoidTy, args, false); return BlockObjectAssign = |