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

Unified Diff: src/full-codegen/mips64/full-codegen-mips64.cc

Issue 1315903005: MIPS: Refine '[es6] Introduce a dedicated JSIteratorResult type.' (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 3 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/full-codegen/mips/full-codegen-mips.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/full-codegen/mips64/full-codegen-mips64.cc
diff --git a/src/full-codegen/mips64/full-codegen-mips64.cc b/src/full-codegen/mips64/full-codegen-mips64.cc
index bd1fea27d5839113b4bd443066e4eddc0b7e5e6d..154edcd18cc066ea08d5a4de26322726d502cc83 100644
--- a/src/full-codegen/mips64/full-codegen-mips64.cc
+++ b/src/full-codegen/mips64/full-codegen-mips64.cc
@@ -2278,11 +2278,12 @@ void FullCodeGenerator::EmitCreateIteratorResult(bool done) {
__ ld(a1, FieldMemOperand(a1, GlobalObject::kNativeContextOffset));
__ ld(a1, ContextOperand(a1, Context::ITERATOR_RESULT_MAP_INDEX));
__ pop(a2);
- __ li(a3, Operand(isolate()->factory()->ToBoolean(done)));
- __ li(t0, Operand(isolate()->factory()->empty_fixed_array()));
+ __ LoadRoot(a3,
+ done ? Heap::kTrueValueRootIndex : Heap::kFalseValueRootIndex);
+ __ LoadRoot(a4, Heap::kEmptyFixedArrayRootIndex);
__ sd(a1, FieldMemOperand(v0, HeapObject::kMapOffset));
- __ sd(t0, FieldMemOperand(v0, JSObject::kPropertiesOffset));
- __ sd(t0, FieldMemOperand(v0, JSObject::kElementsOffset));
+ __ sd(a4, FieldMemOperand(v0, JSObject::kPropertiesOffset));
+ __ sd(a4, FieldMemOperand(v0, JSObject::kElementsOffset));
__ sd(a2, FieldMemOperand(v0, JSIteratorResult::kValueOffset));
__ sd(a3, FieldMemOperand(v0, JSIteratorResult::kDoneOffset));
STATIC_ASSERT(JSIteratorResult::kSize == 5 * kPointerSize);
@@ -4502,12 +4503,11 @@ void FullCodeGenerator::EmitCreateIterResultObject(CallRuntime* expr) {
__ ld(a1, ContextOperand(cp, Context::GLOBAL_OBJECT_INDEX));
__ ld(a1, FieldMemOperand(a1, GlobalObject::kNativeContextOffset));
__ ld(a1, ContextOperand(a1, Context::ITERATOR_RESULT_MAP_INDEX));
- __ pop(a3);
- __ pop(a2);
- __ li(t0, Operand(isolate()->factory()->empty_fixed_array()));
+ __ Pop(a2, a3);
+ __ LoadRoot(a4, Heap::kEmptyFixedArrayRootIndex);
__ sd(a1, FieldMemOperand(v0, HeapObject::kMapOffset));
- __ sd(t0, FieldMemOperand(v0, JSObject::kPropertiesOffset));
- __ sd(t0, FieldMemOperand(v0, JSObject::kElementsOffset));
+ __ sd(a4, FieldMemOperand(v0, JSObject::kPropertiesOffset));
+ __ sd(a4, FieldMemOperand(v0, JSObject::kElementsOffset));
__ sd(a2, FieldMemOperand(v0, JSIteratorResult::kValueOffset));
__ sd(a3, FieldMemOperand(v0, JSIteratorResult::kDoneOffset));
STATIC_ASSERT(JSIteratorResult::kSize == 5 * kPointerSize);
« no previous file with comments | « src/full-codegen/mips/full-codegen-mips.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698