aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target
diff options
context:
space:
mode:
authorBob Wilson <bob.wilson@apple.com>2009-11-25 17:27:53 +0000
committerBob Wilson <bob.wilson@apple.com>2009-11-25 17:27:53 +0000
commit4a66e5bfc2a18a11b64c45b82862fb0f10109a98 (patch)
tree4d4862eb9675bea27f56ca16f467008381ba3f3d /lib/Target
parentd71cebf57591e2dc27930d3002848dddc76c3f92 (diff)
downloadexternal_llvm-4a66e5bfc2a18a11b64c45b82862fb0f10109a98.zip
external_llvm-4a66e5bfc2a18a11b64c45b82862fb0f10109a98.tar.gz
external_llvm-4a66e5bfc2a18a11b64c45b82862fb0f10109a98.tar.bz2
Based on the testcase for pr3120, running on my MacPro with Xeon processors,
it is definitely profitable to tail duplicate indirect branches for x86. This is likely to be true to various degrees for all modern x86 processors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@89865 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target')
-rw-r--r--lib/Target/X86/X86InstrInfo.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Target/X86/X86InstrInfo.h b/lib/Target/X86/X86InstrInfo.h
index c6daa25..3d4c2f6 100644
--- a/lib/Target/X86/X86InstrInfo.h
+++ b/lib/Target/X86/X86InstrInfo.h
@@ -632,6 +632,8 @@ public:
///
unsigned getGlobalBaseReg(MachineFunction *MF) const;
+ virtual bool isProfitableToDuplicateIndirectBranch() const { return true; }
+
private:
MachineInstr* foldMemoryOperandImpl(MachineFunction &MF,
MachineInstr* MI,