aboutsummaryrefslogtreecommitdiff
path: root/include/llvm/Support/CodeGen.h
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2011-11-16 08:38:26 +0000
committerEvan Cheng <evan.cheng@apple.com>2011-11-16 08:38:26 +0000
commitb95fc31aa2e5a0a0b9ee1909d1cb949577c5aa16 (patch)
treea891fa0a8cb7d5f75446fc0f0346eb55b18a715c /include/llvm/Support/CodeGen.h
parentf1b41dd38d2b2713e3870f384525b020bbac05f6 (diff)
Sink codegen optimization level into MCCodeGenInfo along side relocation model
and code model. This eliminates the need to pass OptLevel flag all over the place and makes it possible for any codegen pass to use this information. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144788 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/CodeGen.h')
-rw-r--r--include/llvm/Support/CodeGen.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/llvm/Support/CodeGen.h b/include/llvm/Support/CodeGen.h
index 41351dc73f..3a76cc7167 100644
--- a/include/llvm/Support/CodeGen.h
+++ b/include/llvm/Support/CodeGen.h
@@ -27,6 +27,16 @@ namespace llvm {
enum Model { Default, JITDefault, Small, Kernel, Medium, Large };
}
+ // Code generation optimization level.
+ namespace CodeGenOpt {
+ enum Level {
+ None, // -O0
+ Less, // -O1
+ Default, // -O2, -Os
+ Aggressive // -O3
+ };
+ }
+
} // end llvm namespace
#endif