summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorJames Molloy <james.molloy@arm.com>2011-10-26 08:53:19 +0000
committerJames Molloy <james.molloy@arm.com>2011-10-26 08:53:19 +0000
commitdd9137aa56bd15e6db00eb9a652b10e76eb8c4fa (patch)
tree582dcf996da1914d448521479d38dc23b10735e7 /llvm/lib
parent39fe265e9ca879bd4495848f67394f48b6a9978d (diff)
downloadbcm5719-llvm-dd9137aa56bd15e6db00eb9a652b10e76eb8c4fa.tar.gz
bcm5719-llvm-dd9137aa56bd15e6db00eb9a652b10e76eb8c4fa.zip
Revert r142530 at least temporarily while a discussion is had on llvm-commits regarding exactly how much optsize should optimize for size over performance.
llvm-svn: 143023
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/ARM/ARMISelLowering.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/llvm/lib/Target/ARM/ARMISelLowering.cpp b/llvm/lib/Target/ARM/ARMISelLowering.cpp
index d7aca309807..472bf4c42f3 100644
--- a/llvm/lib/Target/ARM/ARMISelLowering.cpp
+++ b/llvm/lib/Target/ARM/ARMISelLowering.cpp
@@ -2104,11 +2104,8 @@ SDValue ARMTargetLowering::LowerGlobalAddressELF(SDValue Op,
}
// If we have T2 ops, we can materialize the address directly via movt/movw
- // pair. This is always cheaper in terms of performance, but uses at least 2
- // extra bytes.
- MachineFunction &MF = DAG.getMachineFunction();
- if (Subtarget->useMovt() &&
- !MF.getFunction()->hasFnAttr(Attribute::OptimizeForSize)) {
+ // pair. This is always cheaper.
+ if (Subtarget->useMovt()) {
++NumMovwMovt;
// FIXME: Once remat is capable of dealing with instructions with register
// operands, expand this into two nodes.
OpenPOWER on IntegriCloud