summaryrefslogtreecommitdiffstats
path: root/lib/Target/ARM/ARMLoadStoreOptimizer.cpp
diff options
context:
space:
mode:
authorrdivacky <rdivacky@FreeBSD.org>2010-03-06 09:22:29 +0000
committerrdivacky <rdivacky@FreeBSD.org>2010-03-06 09:22:29 +0000
commit9bef28eb9e224d641ce31a423e215ccf82bf1d43 (patch)
tree542734eaa7870f95912cbaebccb87dbec0c20b4f /lib/Target/ARM/ARMLoadStoreOptimizer.cpp
parent8230c40430a1325b5cc5bc0221931487b4bd573c (diff)
downloadFreeBSD-src-9bef28eb9e224d641ce31a423e215ccf82bf1d43.zip
FreeBSD-src-9bef28eb9e224d641ce31a423e215ccf82bf1d43.tar.gz
Update LLVM to r97873.
Diffstat (limited to 'lib/Target/ARM/ARMLoadStoreOptimizer.cpp')
-rw-r--r--lib/Target/ARM/ARMLoadStoreOptimizer.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Target/ARM/ARMLoadStoreOptimizer.cpp b/lib/Target/ARM/ARMLoadStoreOptimizer.cpp
index 5b4f02d..19f1e3b 100644
--- a/lib/Target/ARM/ARMLoadStoreOptimizer.cpp
+++ b/lib/Target/ARM/ARMLoadStoreOptimizer.cpp
@@ -761,6 +761,11 @@ static bool isMemoryOp(const MachineInstr *MI) {
MI->getOperand(0).isUndef())
return false;
+ // Likewise don't mess with references to undefined addresses.
+ if (MI->getNumOperands() > 1 && MI->getOperand(1).isReg() &&
+ MI->getOperand(1).isUndef())
+ return false;
+
int Opcode = MI->getOpcode();
switch (Opcode) {
default: break;
OpenPOWER on IntegriCloud