mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-28 22:43:29 +00:00
Add optimize-for-size knob.
llvm-svn: 48793
This commit is contained in:
parent
8cb64d8e8b
commit
71f3156ea3
@ -78,6 +78,10 @@ namespace llvm {
|
||||
/// on the commandline. When the flag is on, the target will perform tail call
|
||||
/// optimization (pop the caller's stack) providing it supports it.
|
||||
extern bool PerformTailCallOpt;
|
||||
|
||||
/// OptimizeForSize - When this flags is set, code generator avoids optimization
|
||||
/// that increases size.
|
||||
extern bool OptimizeForSize;
|
||||
} // End llvm namespace
|
||||
|
||||
#endif
|
||||
|
@ -34,6 +34,7 @@ namespace llvm {
|
||||
Reloc::Model RelocationModel;
|
||||
CodeModel::Model CMModel;
|
||||
bool PerformTailCallOpt;
|
||||
bool OptimizeForSize;
|
||||
}
|
||||
namespace {
|
||||
cl::opt<bool, true> PrintCode("print-machineinstrs",
|
||||
@ -123,6 +124,11 @@ namespace {
|
||||
cl::desc("Turn on tail call optimization."),
|
||||
cl::location(PerformTailCallOpt),
|
||||
cl::init(false));
|
||||
cl::opt<bool, true>
|
||||
EnableOptimizeForSize("optimizeforsize",
|
||||
cl::desc("Optimize for size."),
|
||||
cl::location(OptimizeForSize),
|
||||
cl::init(false));
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user