llvm.org GIT mirror llvm / 5c2a1d9
Remove LessPreciseFPMADOption from TargetOptions along with all of the associated command line options and functions - it's currently unused in all of llvm and clang other than being set and reset. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@298023 91177308-0d34-0410-b5e6-96231b3b80d8 Eric Christopher 3 years ago
4 changed file(s) with 3 addition(s) and 27 deletion(s). Raw diff Collapse all Expand all
118118 "Emit nothing, for performance testing")));
119119
120120 cl::opt
121 EnableFPMAD("enable-fp-mad",
122 cl::desc("Enable less precise MAD instructions to be generated"),
123 cl::init(false));
124
125 cl::opt
126121 DisableFPElim("disable-fp-elim",
127122 cl::desc("Disable frame pointer elimination optimization"),
128123 cl::init(false));
282277 // a TargetOptions object with CodeGen flags and returns it.
283278 static inline TargetOptions InitTargetOptionsFromCodeGenFlags() {
284279 TargetOptions Options;
285 Options.LessPreciseFPMADOption = EnableFPMAD;
286280 Options.AllowFPOpFusion = FuseFPOps;
287281 Options.UnsafeFPMath = EnableUnsafeFPMath;
288282 Options.NoInfsFPMath = EnableNoInfsFPMath;
9898 class TargetOptions {
9999 public:
100100 TargetOptions()
101 : PrintMachineCode(false), LessPreciseFPMADOption(false),
102 UnsafeFPMath(false), NoInfsFPMath(false), NoNaNsFPMath(false),
103 NoTrappingFPMath(false), NoSignedZerosFPMath(false),
101 : PrintMachineCode(false), UnsafeFPMath(false), NoInfsFPMath(false),
102 NoNaNsFPMath(false), NoTrappingFPMath(false),
103 NoSignedZerosFPMath(false),
104104 HonorSignDependentRoundingFPMathOption(false), NoZerosInBSS(false),
105105 GuaranteedTailCallOpt(false), StackSymbolOrdering(true),
106106 EnableFastISel(false), UseInitArray(false),
118118 /// optimization should be disabled for the given machine function.
119119 bool DisableFramePointerElim(const MachineFunction &MF) const;
120120
121 /// LessPreciseFPMAD - This flag is enabled when the
122 /// -enable-fp-mad is specified on the command line. When this flag is off
123 /// (the default), the code generator is not allowed to generate mad
124 /// (multiply add) if the result is "less precise" than doing those
125 /// operations individually.
126 unsigned LessPreciseFPMADOption : 1;
127 bool LessPreciseFPMAD() const;
128
129121 /// UnsafeFPMath - This flag is enabled when the
130122 /// -enable-unsafe-fp-math flag is specified on the command line. When
131123 /// this flag is off (the default), the code generator is not allowed to
132124 /// produce results that are "less precise" than IEEE allows. This includes
133125 /// use of X86 instructions like FSIN and FCOS instead of libcalls.
134 /// UnsafeFPMath implies LessPreciseFPMAD.
135126 unsigned UnsafeFPMath : 1;
136127
137128 /// NoInfsFPMath - This flag is enabled when the
3333 return false;
3434 }
3535
36 /// LessPreciseFPMAD - This flag return true when -enable-fp-mad option
37 /// is specified on the command line. When this flag is off(default), the
38 /// code generator is not allowed to generate mad (multiply add) if the
39 /// result is "less precise" than doing those operations individually.
40 bool TargetOptions::LessPreciseFPMAD() const {
41 return UnsafeFPMath || LessPreciseFPMADOption;
42 }
43
4436 /// HonorSignDependentRoundingFPMath - Return true if the codegen must assume
4537 /// that the rounding mode of the FPU can change from its default.
4638 bool TargetOptions::HonorSignDependentRoundingFPMath() const {
7373 Options.X = DefaultOptions.X; \
7474 } while (0)
7575
76 RESET_OPTION(LessPreciseFPMADOption, "less-precise-fpmad");
7776 RESET_OPTION(UnsafeFPMath, "unsafe-fp-math");
7877 RESET_OPTION(NoInfsFPMath, "no-infs-fp-math");
7978 RESET_OPTION(NoNaNsFPMath, "no-nans-fp-math");