diff options
author | Alexey Volkov <avolkov.intel@gmail.com> | 2014-11-21 11:19:34 +0000 |
---|---|---|
committer | Alexey Volkov <avolkov.intel@gmail.com> | 2014-11-21 11:19:34 +0000 |
commit | fd1731d8765002abafcc97c358e6fcefa047285d (patch) | |
tree | 6aae61c0d4df3a4c667ff381e28d3655f1b82039 /llvm/lib/Target/X86/X86Subtarget.h | |
parent | 30a990744b777c4d8414df452e5800cd1d67f352 (diff) | |
download | bcm5719-llvm-fd1731d8765002abafcc97c358e6fcefa047285d.tar.gz bcm5719-llvm-fd1731d8765002abafcc97c358e6fcefa047285d.zip |
[X86] For Silvermont CPU use 16-bit division instead of 64-bit for small positive numbers
Differential Revision: http://reviews.llvm.org/D5938
llvm-svn: 222521
Diffstat (limited to 'llvm/lib/Target/X86/X86Subtarget.h')
-rw-r--r-- | llvm/lib/Target/X86/X86Subtarget.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/llvm/lib/Target/X86/X86Subtarget.h b/llvm/lib/Target/X86/X86Subtarget.h index 091b6c4fbbd..cf76ac70e0b 100644 --- a/llvm/lib/Target/X86/X86Subtarget.h +++ b/llvm/lib/Target/X86/X86Subtarget.h @@ -171,9 +171,13 @@ protected: /// the stack pointer. This is an optimization for Intel Atom processors. bool UseLeaForSP; - /// HasSlowDivide - True if smaller divides are significantly faster than - /// full divides and should be used when possible. - bool HasSlowDivide; + /// HasSlowDivide32 - True if 8-bit divisions are significantly faster than + /// 32-bit divisions and should be used when possible. + bool HasSlowDivide32; + + /// HasSlowDivide64 - True if 16-bit divides are significantly faster than + /// 64-bit divisions and should be used when possible. + bool HasSlowDivide64; /// PadShortFunctions - True if the short functions should be padded to prevent /// a stall when returning too early. @@ -373,7 +377,8 @@ public: bool hasVectorUAMem() const { return HasVectorUAMem; } bool hasCmpxchg16b() const { return HasCmpxchg16b; } bool useLeaForSP() const { return UseLeaForSP; } - bool hasSlowDivide() const { return HasSlowDivide; } + bool hasSlowDivide32() const { return HasSlowDivide32; } + bool hasSlowDivide64() const { return HasSlowDivide64; } bool padShortFunctions() const { return PadShortFunctions; } bool callRegIndirect() const { return CallRegIndirect; } bool LEAusesAG() const { return LEAUsesAG; } |