summaryrefslogtreecommitdiff
path: root/test/Feature
diff options
context:
space:
mode:
authorAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2013-08-23 11:53:55 +0000
committerAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2013-08-23 11:53:55 +0000
commit5768bb8d77892926dff0d078b1fb08c14ea791f3 (patch)
tree3a2f35fef53650a9e8988416a19f8787d0186f3d /test/Feature
parenta550b51bac50493db75a7b5788a3f2c3b62fd913 (diff)
downloadllvm-5768bb8d77892926dff0d078b1fb08c14ea791f3.tar.gz
llvm-5768bb8d77892926dff0d078b1fb08c14ea791f3.tar.bz2
llvm-5768bb8d77892926dff0d078b1fb08c14ea791f3.tar.xz
Add function attribute 'optnone'.
This function attribute indicates that the function is not optimized by any optimization or code generator passes with the exception of interprocedural optimization passes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@189101 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Feature')
-rw-r--r--test/Feature/optnone.ll12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/Feature/optnone.ll b/test/Feature/optnone.ll
new file mode 100644
index 0000000000..ec1d7232b3
--- /dev/null
+++ b/test/Feature/optnone.ll
@@ -0,0 +1,12 @@
+; RUN: llvm-as < %s | llvm-dis | FileCheck %s
+
+; Check for the presence of attribute noopt in the disassembly.
+
+; CHECK: @foo() #0
+define void @foo() #0 {
+ ret void
+}
+
+; CHECK: attributes #0 = { optnone }
+attributes #0 = { optnone }
+