summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGCall.cpp
diff options
context:
space:
mode:
authorPiotr Padlewski <prazek@google.com>2015-08-18 03:52:00 +0000
committerPiotr Padlewski <prazek@google.com>2015-08-18 03:52:00 +0000
commitbc7497abbb2f2b8757dbe992411c3301011f9a1d (patch)
tree523c0cf1cb27f9c6c1fecd5ad7c95775c5eb7955 /clang/lib/CodeGen/CGCall.cpp
parentd457df8008db1247a5584e93169fe5f8d30306a5 (diff)
downloadbcm5719-llvm-bc7497abbb2f2b8757dbe992411c3301011f9a1d.tar.gz
bcm5719-llvm-bc7497abbb2f2b8757dbe992411c3301011f9a1d.zip
Generating assumption loads of vptr after ctor call (fixed)
Generating call assume(icmp %vtable, %global_vtable) after constructor call for devirtualization purposes. For more info go to: http://lists.llvm.org/pipermail/cfe-dev/2015-July/044227.html Edit: Fixed version because of PR24479. http://reviews.llvm.org/D11859 llvm-svn: 245264
Diffstat (limited to 'clang/lib/CodeGen/CGCall.cpp')
-rw-r--r--clang/lib/CodeGen/CGCall.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGCall.cpp b/clang/lib/CodeGen/CGCall.cpp
index f7107b61060..2511e26e770 100644
--- a/clang/lib/CodeGen/CGCall.cpp
+++ b/clang/lib/CodeGen/CGCall.cpp
@@ -1412,7 +1412,8 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
if (const FunctionDecl *Fn = dyn_cast<FunctionDecl>(TargetDecl)) {
const FunctionProtoType *FPT = Fn->getType()->getAs<FunctionProtoType>();
- if (FPT && FPT->isNothrow(getContext()))
+ if (FPT && !isUnresolvedExceptionSpec(FPT->getExceptionSpecType()) &&
+ FPT->isNothrow(getContext()))
FuncAttrs.addAttribute(llvm::Attribute::NoUnwind);
// Don't use [[noreturn]] or _Noreturn for a call to a virtual function.
// These attributes are not inherited by overloads.
OpenPOWER on IntegriCloud