summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2010-09-29 18:20:25 +0000
committerDaniel Dunbar <daniel@zuster.org>2010-09-29 18:20:25 +0000
commit8caf6415a878f6087abb2240b8d2d0e935197de1 (patch)
treeb8767db0512d2cf42f8f18d592d586c95d8e1092 /clang/lib/CodeGen
parentf3d3d1c7432d73ba12fb7fdb2bf90fcb37037dc6 (diff)
downloadbcm5719-llvm-8caf6415a878f6087abb2240b8d2d0e935197de1.tar.gz
bcm5719-llvm-8caf6415a878f6087abb2240b8d2d0e935197de1.zip
Add support for attribute((naked)), patch by Zoxc on cfe-commits!
- Minor style tweaks by me. llvm-svn: 115056
Diffstat (limited to 'clang/lib/CodeGen')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 805b33e3247..12c8f7919fa 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -457,6 +457,9 @@ void CodeGenModule::SetLLVMFunctionAttributesForDefinition(const Decl *D,
if (D->hasAttr<AlwaysInlineAttr>())
F->addFnAttr(llvm::Attribute::AlwaysInline);
+ if (D->hasAttr<NakedAttr>())
+ F->addFnAttr(llvm::Attribute::Naked);
+
if (D->hasAttr<NoInlineAttr>())
F->addFnAttr(llvm::Attribute::NoInline);
OpenPOWER on IntegriCloud