summaryrefslogtreecommitdiff
path: root/include
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 /include
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 'include')
-rw-r--r--include/llvm-c/Core.h5
-rw-r--r--include/llvm/Bitcode/LLVMBitCodes.h3
-rw-r--r--include/llvm/IR/Attributes.h1
3 files changed, 6 insertions, 3 deletions
diff --git a/include/llvm-c/Core.h b/include/llvm-c/Core.h
index a7d17b7b83..57834c5292 100644
--- a/include/llvm-c/Core.h
+++ b/include/llvm-c/Core.h
@@ -165,8 +165,9 @@ typedef enum {
a temporary measure until the API/ABI impact to the C API is understood
and the path forward agreed upon.
LLVMAddressSafety = 1ULL << 32,
- LLVMStackProtectStrongAttribute = 1ULL<<33
- LLVMCold = 1ULL << 34
+ LLVMStackProtectStrongAttribute = 1ULL<<33,
+ LLVMCold = 1ULL << 34,
+ LLVMOptimizeNone = 1ULL << 35
*/
} LLVMAttribute;
diff --git a/include/llvm/Bitcode/LLVMBitCodes.h b/include/llvm/Bitcode/LLVMBitCodes.h
index 463e3b919d..90e9063d90 100644
--- a/include/llvm/Bitcode/LLVMBitCodes.h
+++ b/include/llvm/Bitcode/LLVMBitCodes.h
@@ -368,7 +368,8 @@ namespace bitc {
ATTR_KIND_UW_TABLE = 33,
ATTR_KIND_Z_EXT = 34,
ATTR_KIND_BUILTIN = 35,
- ATTR_KIND_COLD = 36
+ ATTR_KIND_COLD = 36,
+ ATTR_KIND_OPTIMIZE_NONE = 37
};
} // End bitc namespace
diff --git a/include/llvm/IR/Attributes.h b/include/llvm/IR/Attributes.h
index 2183758fbc..ebee637004 100644
--- a/include/llvm/IR/Attributes.h
+++ b/include/llvm/IR/Attributes.h
@@ -88,6 +88,7 @@ public:
NoReturn, ///< Mark the function as not returning
NoUnwind, ///< Function doesn't unwind stack
OptimizeForSize, ///< opt_size
+ OptimizeNone, ///< Function must not be optimized.
ReadNone, ///< Function does not access memory
ReadOnly, ///< Function only reads from memory
Returned, ///< Return value is always equal to this argument