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

Unified Diff: runtime/vm/assembler_arm64.h

Issue 2912863006: Inline instance object hash code into object header on 64 bit. (Closed)
Patch Set: Add assembler tests and other feedback from Ryan Created 3 years, 6 months 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
« no previous file with comments | « runtime/vm/assembler_arm.cc ('k') | runtime/vm/assembler_arm64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/assembler_arm64.h
diff --git a/runtime/vm/assembler_arm64.h b/runtime/vm/assembler_arm64.h
index cde10dac4e529ea577cac9b1a6445a1bed009b64..9f1ac2b178c25cff5cd915ee217b08311053a93b 100644
--- a/runtime/vm/assembler_arm64.h
+++ b/runtime/vm/assembler_arm64.h
@@ -742,16 +742,19 @@ class Assembler : public ValueObject {
EmitLoadStoreRegPair(STP, rt, rt2, a, sz);
}
- void ldxr(Register rt, Register rn) {
+ void ldxr(Register rt, Register rn, OperandSize size = kDoubleWord) {
// rt = value
// rn = address
- EmitLoadStoreExclusive(LDXR, R31, rn, rt, kDoubleWord);
+ EmitLoadStoreExclusive(LDXR, R31, rn, rt, size);
}
- void stxr(Register rs, Register rt, Register rn) {
+ void stxr(Register rs,
+ Register rt,
+ Register rn,
+ OperandSize size = kDoubleWord) {
// rs = status (1 = failure, 0 = success)
// rt = value
// rn = address
- EmitLoadStoreExclusive(STXR, rs, rn, rt, kDoubleWord);
+ EmitLoadStoreExclusive(STXR, rs, rn, rt, size);
}
void clrex() {
const int32_t encoding = static_cast<int32_t>(CLREX);
@@ -1689,8 +1692,8 @@ class Assembler : public ValueObject {
Register rn,
Register rt,
OperandSize sz = kDoubleWord) {
- ASSERT(sz == kDoubleWord);
- const int32_t size = B31 | B30;
+ ASSERT(sz == kDoubleWord || sz == kWord);
+ const int32_t size = B31 | (sz == kDoubleWord ? B30 : 0);
ASSERT((rs != kNoRegister) && (rs != ZR));
ASSERT((rn != kNoRegister) && (rn != ZR));
« no previous file with comments | « runtime/vm/assembler_arm.cc ('k') | runtime/vm/assembler_arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698