summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGBuiltin.cpp
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2015-02-04 22:37:07 +0000
committerReid Kleckner <reid@kleckner.net>2015-02-04 22:37:07 +0000
commitaca01db706122a2c465ab43224281a2857255b25 (patch)
treeb06da48786a839b6217aed3e2469c0ae64cd8ab0 /clang/lib/CodeGen/CGBuiltin.cpp
parentba77ad75d3570863a0ca270336cf6de46dbb21ef (diff)
downloadbcm5719-llvm-aca01db706122a2c465ab43224281a2857255b25.tar.gz
bcm5719-llvm-aca01db706122a2c465ab43224281a2857255b25.zip
Implement IRGen for SEH __finally and AbnormalTermination
Previously we would simply double-emit the body of the __finally block, but that doesn't work when it contains any kind of Decl, which we can't double emit. This fixes that by emitting the block once and branching into a shared code region and then branching back out. llvm-svn: 228222
Diffstat (limited to 'clang/lib/CodeGen/CGBuiltin.cpp')
-rw-r--r--clang/lib/CodeGen/CGBuiltin.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CGBuiltin.cpp b/clang/lib/CodeGen/CGBuiltin.cpp
index f192788c787..aa6d8d6587d 100644
--- a/clang/lib/CodeGen/CGBuiltin.cpp
+++ b/clang/lib/CodeGen/CGBuiltin.cpp
@@ -1663,6 +1663,9 @@ RValue CodeGenFunction::EmitBuiltinExpr(const FunctionDecl *FD,
case Builtin::BI__exception_info:
case Builtin::BI_exception_info:
return RValue::get(EmitSEHExceptionInfo());
+ case Builtin::BI__abnormal_termination:
+ case Builtin::BI_abnormal_termination:
+ return RValue::get(EmitSEHAbnormalTermination());
case Builtin::BI_setjmpex: {
if (getTarget().getTriple().isOSMSVCRT()) {
llvm::Type *ArgTypes[] = {Int8PtrTy, Int8PtrTy};
OpenPOWER on IntegriCloud