diff options
author | Quentin Colombet <qcolombet@apple.com> | 2012-11-01 23:55:47 +0000 |
---|---|---|
committer | Quentin Colombet <qcolombet@apple.com> | 2012-11-01 23:55:47 +0000 |
commit | 4e172067b2237dbe053c95a89945e03f70b75dd6 (patch) | |
tree | ca78ca54c139d74cefc74115a90a86f7afd9b0c1 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | 3d5af279b1790620c9554cf216903968643055cb (diff) | |
download | bcm5719-llvm-4e172067b2237dbe053c95a89945e03f70b75dd6.tar.gz bcm5719-llvm-4e172067b2237dbe053c95a89945e03f70b75dd6.zip |
Update the front end to use minsize attribute
llvm-svn: 167266
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index 9617de8eb7a..11991124ee0 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -583,6 +583,9 @@ void CodeGenModule::SetLLVMFunctionAttributesForDefinition(const Decl *D, if (D->hasAttr<ColdAttr>()) F->addFnAttr(llvm::Attributes::OptimizeForSize); + if (D->hasAttr<MinSizeAttr>()) + F->addFnAttr(llvm::Attributes::MinSize); + if (isa<CXXConstructorDecl>(D) || isa<CXXDestructorDecl>(D)) F->setUnnamedAddr(true); |