summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/X86/X86InstrInfo.h
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
commit120f729ecafcaaacbea610655cd80fdd92d78bd7 (patch)
treeafaf22a812f33e147647a34a6039697db1b29dbc /llvm/lib/Target/X86/X86InstrInfo.h
parent7fdcbaf29103c1ccfc881e3de308fa2c17888e62 (diff)
downloadbcm5719-llvm-120f729ecafcaaacbea610655cd80fdd92d78bd7.tar.gz
bcm5719-llvm-120f729ecafcaaacbea610655cd80fdd92d78bd7.zip
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. llvm-svn: 89865
Diffstat (limited to 'llvm/lib/Target/X86/X86InstrInfo.h')
-rw-r--r--llvm/lib/Target/X86/X86InstrInfo.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Target/X86/X86InstrInfo.h b/llvm/lib/Target/X86/X86InstrInfo.h
index c6daa251430..3d4c2f695d0 100644
--- a/llvm/lib/Target/X86/X86InstrInfo.h
+++ b/llvm/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,
OpenPOWER on IntegriCloud