aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGException.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-12-16 07:05:41 +0000
committerAnders Carlsson <andersca@mac.com>2009-12-16 07:05:41 +0000
commite8e4a1c0bf2e3dd26dd0721a102307bbb589e96a (patch)
treee44725289737088310983e2b5b1b0e2f8f1e8674 /lib/CodeGen/CGException.cpp
parent30311fa6b0735b9cb73b01e25bf9652a4b9b0c53 (diff)
Use GetAddrOfRTTI everywhere and remove GenerateRTTI and GenerateRTTIRef. With this change, we can now compile and link TableGen.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91520 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGException.cpp')
-rw-r--r--lib/CodeGen/CGException.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/CodeGen/CGException.cpp b/lib/CodeGen/CGException.cpp
index b15b2e9b3b..c66bb46bd8 100644
--- a/lib/CodeGen/CGException.cpp
+++ b/lib/CodeGen/CGException.cpp
@@ -264,7 +264,7 @@ void CodeGenFunction::EmitCXXThrowExpr(const CXXThrowExpr *E) {
// Now throw the exception.
const llvm::Type *Int8PtrTy = llvm::Type::getInt8PtrTy(getLLVMContext());
- llvm::Constant *TypeInfo = CGM.GenerateRTTI(ThrowType);
+ llvm::Constant *TypeInfo = CGM.GetAddrOfRTTI(ThrowType);
llvm::Constant *Dtor = llvm::Constant::getNullValue(Int8PtrTy);
if (getInvokeDest()) {
@@ -347,8 +347,7 @@ void CodeGenFunction::EmitStartEHSpec(const Decl *D) {
for (unsigned i = 0; i < Proto->getNumExceptions(); ++i) {
QualType Ty = Proto->getExceptionType(i);
- llvm::Value *EHType
- = CGM.GenerateRTTI(Ty.getNonReferenceType());
+ llvm::Value *EHType = CGM.GetAddrOfRTTI(Ty.getNonReferenceType());
SelectorArgs.push_back(EHType);
}
if (Proto->getNumExceptions())
@@ -487,8 +486,8 @@ void CodeGenFunction::EmitCXXTryStmt(const CXXTryStmt &S) {
const CXXCatchStmt *C = S.getHandler(i);
VarDecl *CatchParam = C->getExceptionDecl();
if (CatchParam) {
- llvm::Value *EHType
- = CGM.GenerateRTTI(C->getCaughtType().getNonReferenceType());
+ llvm::Value *EHType
+ = CGM.GetAddrOfRTTI(C->getCaughtType().getNonReferenceType());
SelectorArgs.push_back(EHType);
} else {
// null indicates catch all