Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(700)

Unified Diff: runtime/vm/assembler_arm.cc

Issue 1434323003: ARM: Don't generate memory instructions with writeback where the data and address registers are the… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: runtime/vm/assembler_arm.cc
diff --git a/runtime/vm/assembler_arm.cc b/runtime/vm/assembler_arm.cc
index 6c016c9c21f64efcf27fc0305de4ca087c769d34..8abdfe72b7825e1db1e809da26966bdf20dcbdb6 100644
--- a/runtime/vm/assembler_arm.cc
+++ b/runtime/vm/assembler_arm.cc
@@ -105,6 +105,8 @@ void Assembler::EmitMemOp(Condition cond,
Address ad) {
ASSERT(rd != kNoRegister);
ASSERT(cond != kNoCondition);
+ ASSERT(!ad.has_writeback() || (ad.rn() != rd)); // Unpredictable.
+
int32_t encoding = (static_cast<int32_t>(cond) << kConditionShift) |
B26 | (ad.kind() == Address::Immediate ? 0 : B25) |
(load ? L : 0) |

Powered by Google App Engine
This is Rietveld 408576698