diff options
author | Evan Cheng <evan.cheng@apple.com> | 2006-05-23 06:39:12 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2006-05-23 06:39:12 +0000 |
commit | ea1450742ee0d6701d72052e8f29cca32dfd6378 (patch) | |
tree | e99c279a72ae3cf13c467bad09e7c55f4b257a2c /llvm/lib/Target/TargetMachine.cpp | |
parent | 27f8bdc7e5dd77a8a41860983feba1a79002e14d (diff) | |
download | bcm5719-llvm-ea1450742ee0d6701d72052e8f29cca32dfd6378.tar.gz bcm5719-llvm-ea1450742ee0d6701d72052e8f29cca32dfd6378.zip |
Added option -enable-finite-only-fp-math. When on, the codegen can assume that
FP arithmetic arguments and results are never NaNs or +=Infs. This includes
ignoring parity flag (PF) when checking for FP equality.
llvm-svn: 28432
Diffstat (limited to 'llvm/lib/Target/TargetMachine.cpp')
-rw-r--r-- | llvm/lib/Target/TargetMachine.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/Target/TargetMachine.cpp b/llvm/lib/Target/TargetMachine.cpp index 24e1e5a547a..28f3ae88a72 100644 --- a/llvm/lib/Target/TargetMachine.cpp +++ b/llvm/lib/Target/TargetMachine.cpp @@ -26,6 +26,7 @@ namespace llvm { bool NoFramePointerElim; bool NoExcessFPPrecision; bool UnsafeFPMath; + bool FiniteOnlyFPMath; Reloc::Model RelocationModel; }; namespace { @@ -48,6 +49,11 @@ namespace { cl::desc("Enable optimizations that may decrease FP precision"), cl::location(UnsafeFPMath), cl::init(false)); + cl::opt<bool, true> + EnableFiniteOnltFPMath("enable-finite-only-fp-math", + cl::desc("Enable optimizations that assumes non- NaNs / +-Infs"), + cl::location(FiniteOnlyFPMath), + cl::init(false)); cl::opt<llvm::Reloc::Model, true> DefRelocationModel( "relocation-model", |