summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/X86/X86Subtarget.h
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2015-06-03 05:32:44 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2015-06-03 05:32:44 +0000
commitcf8beece97c5b8695fa1e8a5f5727ad730424595 (patch)
treee66e2cd3be4fa4de338662514ebddbd233f822a3 /llvm/lib/Target/X86/X86Subtarget.h
parent75d5b5495f1514e239c1b18254ddcf7a297e80ee (diff)
downloadbcm5719-llvm-cf8beece97c5b8695fa1e8a5f5727ad730424595.tar.gz
bcm5719-llvm-cf8beece97c5b8695fa1e8a5f5727ad730424595.zip
Revert "make reciprocal estimate code generation more flexible by adding command-line options (2nd try)"
This reverts commit r238842. It broke -DBUILD_SHARED_LIBS=ON build. llvm-svn: 238900
Diffstat (limited to 'llvm/lib/Target/X86/X86Subtarget.h')
-rw-r--r--llvm/lib/Target/X86/X86Subtarget.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/llvm/lib/Target/X86/X86Subtarget.h b/llvm/lib/Target/X86/X86Subtarget.h
index 27429d050bd..455dd7744d7 100644
--- a/llvm/lib/Target/X86/X86Subtarget.h
+++ b/llvm/lib/Target/X86/X86Subtarget.h
@@ -190,6 +190,16 @@ protected:
/// True if INC and DEC instructions are slow when writing to flags
bool SlowIncDec;
+ /// Use the RSQRT* instructions to optimize square root calculations.
+ /// For this to be profitable, the cost of FSQRT and FDIV must be
+ /// substantially higher than normal FP ops like FADD and FMUL.
+ bool UseSqrtEst;
+
+ /// Use the RCP* instructions to optimize FP division calculations.
+ /// For this to be profitable, the cost of FDIV must be
+ /// substantially higher than normal FP ops like FADD and FMUL.
+ bool UseReciprocalEst;
+
/// Processor has AVX-512 PreFetch Instructions
bool HasPFI;
@@ -367,6 +377,8 @@ public:
bool LEAusesAG() const { return LEAUsesAG; }
bool slowLEA() const { return SlowLEA; }
bool slowIncDec() const { return SlowIncDec; }
+ bool useSqrtEst() const { return UseSqrtEst; }
+ bool useReciprocalEst() const { return UseReciprocalEst; }
bool hasCDI() const { return HasCDI; }
bool hasPFI() const { return HasPFI; }
bool hasERI() const { return HasERI; }
OpenPOWER on IntegriCloud