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

Unified Diff: src/x87/macro-assembler-x87.cc

Issue 2549773002: Internalize strings in-place (Closed)
Patch Set: rebased Created 3 years, 11 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 | « src/x87/codegen-x87.cc ('k') | test/cctest/test-code-stub-assembler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/x87/macro-assembler-x87.cc
diff --git a/src/x87/macro-assembler-x87.cc b/src/x87/macro-assembler-x87.cc
index e20fe315e6499bb8f8d11573ccb8c48584fcb45c..5bdf10147375d5e9cfebc470200664f37d30c6bc 100644
--- a/src/x87/macro-assembler-x87.cc
+++ b/src/x87/macro-assembler-x87.cc
@@ -2413,11 +2413,13 @@ void MacroAssembler::JumpIfNotBothSequentialOneByteStrings(Register object1,
const int kFlatOneByteStringTag =
kStringTag | kOneByteStringTag | kSeqStringTag;
// Interleave bits from both instance types and compare them in one check.
- DCHECK_EQ(0, kFlatOneByteStringMask & (kFlatOneByteStringMask << 3));
+ const int kShift = 8;
+ DCHECK_EQ(0, kFlatOneByteStringMask & (kFlatOneByteStringMask << kShift));
and_(scratch1, kFlatOneByteStringMask);
and_(scratch2, kFlatOneByteStringMask);
- lea(scratch1, Operand(scratch1, scratch2, times_8, 0));
- cmp(scratch1, kFlatOneByteStringTag | (kFlatOneByteStringTag << 3));
+ shl(scratch2, kShift);
+ or_(scratch1, scratch2);
+ cmp(scratch1, kFlatOneByteStringTag | (kFlatOneByteStringTag << kShift));
j(not_equal, failure);
}
« no previous file with comments | « src/x87/codegen-x87.cc ('k') | test/cctest/test-code-stub-assembler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698