aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJF Bastien <jfb@chromium.org>2013-07-11 09:33:08 -0700
committerJF Bastien <jfb@chromium.org>2013-07-11 09:33:08 -0700
commit8d4dd5f4314a8d6ec4fd6b8397e677763e8b7624 (patch)
treeb9f38423f4a1d96fae9fc4cd2ed188512deabdb4
parenteff7428a4cd1ffcbf4800bd0c502262da361c872 (diff)
Sandbox ARM load/store exclusive dual
PNaCl's LLVM sandboxing wasn't correct for ARM load/store exclusive dual. I encountered this while running our testsuite with my atomic changes: the tests which use volatile 64-bit values started failing validation. R=dschuff@chromium.org BUG= validation failure TEST= ./pnacl/test.sh test-arm Review URL: https://codereview.chromium.org/18978015
-rw-r--r--lib/Target/ARM/ARMNaClRewritePass.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Target/ARM/ARMNaClRewritePass.cpp b/lib/Target/ARM/ARMNaClRewritePass.cpp
index 497baebec8..505521cdc6 100644
--- a/lib/Target/ARM/ARMNaClRewritePass.cpp
+++ b/lib/Target/ARM/ARMNaClRewritePass.cpp
@@ -461,6 +461,7 @@ static bool IsDangerousLoad(const MachineInstr &MI, int *AddrIdx) {
case ARM::LDREX:
case ARM::LDREXB:
case ARM::LDREXH:
+ case ARM::LDREXD:
*AddrIdx = 1;
break;
@@ -1040,6 +1041,7 @@ static bool IsDangerousStore(const MachineInstr &MI, int *AddrIdx) {
case ARM::STREX:
case ARM::STREXB:
case ARM::STREXH:
+ case ARM::STREXD:
*AddrIdx = 2;
break;
}