aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/CodeGenFunction.h
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2015-02-11 00:00:21 +0000
committerReid Kleckner <reid@kleckner.net>2015-02-11 00:00:21 +0000
commite7b3f7c70d31ec34534586d2259868639c8fe175 (patch)
tree04a1e1b29f8becd64cbe2d4f0d6d3461b30de174 /clang/lib/CodeGen/CodeGenFunction.h
parentbe6d1e49b0c58b5a28f0c8ca1e536c1157ca5666 (diff)
downloadllvm-e7b3f7c70d31ec34534586d2259868639c8fe175.zip
llvm-e7b3f7c70d31ec34534586d2259868639c8fe175.tar.gz
llvm-e7b3f7c70d31ec34534586d2259868639c8fe175.tar.bz2
Emit landing pads for SEH even if nounwind is present
Disabling exceptions applies nounwind to lots of functions. SEH catches asynch exceptions, so emit the landing pad anyway. llvm-svn: 228769
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.h')
-rw-r--r--clang/lib/CodeGen/CodeGenFunction.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenFunction.h b/clang/lib/CodeGen/CodeGenFunction.h
index f6e2bae..998e0676 100644
--- a/clang/lib/CodeGen/CodeGenFunction.h
+++ b/clang/lib/CodeGen/CodeGenFunction.h
@@ -1122,6 +1122,11 @@ public:
return getInvokeDestImpl();
}
+ bool currentFunctionUsesSEHTry() const {
+ const auto *FD = dyn_cast_or_null<FunctionDecl>(CurCodeDecl);
+ return FD && FD->usesSEHTry();
+ }
+
const TargetInfo &getTarget() const { return Target; }
llvm::LLVMContext &getLLVMContext() { return CGM.getLLVMContext(); }