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

Side by Side Diff: src/crankshaft/mips64/lithium-codegen-mips64.cc

Issue 1631583002: [for-in] Further refactorings and unification around for-in. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/crankshaft/mips64/lithium-codegen-mips64.h" 5 #include "src/crankshaft/mips64/lithium-codegen-mips64.h"
6 6
7 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/crankshaft/hydrogen-osr.h" 9 #include "src/crankshaft/hydrogen-osr.h"
10 #include "src/crankshaft/mips64/lithium-gap-resolver-mips64.h" 10 #include "src/crankshaft/mips64/lithium-gap-resolver-mips64.h"
(...skipping 5665 matching lines...) Expand 10 before | Expand all | Expand 10 after
5676 Label use_cache, call_runtime; 5676 Label use_cache, call_runtime;
5677 DCHECK(object.is(a0)); 5677 DCHECK(object.is(a0));
5678 __ CheckEnumCache(&call_runtime); 5678 __ CheckEnumCache(&call_runtime);
5679 5679
5680 __ ld(result, FieldMemOperand(object, HeapObject::kMapOffset)); 5680 __ ld(result, FieldMemOperand(object, HeapObject::kMapOffset));
5681 __ Branch(&use_cache); 5681 __ Branch(&use_cache);
5682 5682
5683 // Get the set of properties to enumerate. 5683 // Get the set of properties to enumerate.
5684 __ bind(&call_runtime); 5684 __ bind(&call_runtime);
5685 __ push(object); 5685 __ push(object);
5686 CallRuntime(Runtime::kGetPropertyNamesFast, instr); 5686 CallRuntime(Runtime::kForInEnumerate, instr);
5687 __ bind(&use_cache); 5687 __ bind(&use_cache);
5688 } 5688 }
5689 5689
5690 5690
5691 void LCodeGen::DoForInCacheArray(LForInCacheArray* instr) { 5691 void LCodeGen::DoForInCacheArray(LForInCacheArray* instr) {
5692 Register map = ToRegister(instr->map()); 5692 Register map = ToRegister(instr->map());
5693 Register result = ToRegister(instr->result()); 5693 Register result = ToRegister(instr->result());
5694 Label load_cache, done; 5694 Label load_cache, done;
5695 __ EnumLength(result, map); 5695 __ EnumLength(result, map);
5696 __ Branch(&load_cache, ne, result, Operand(Smi::FromInt(0))); 5696 __ Branch(&load_cache, ne, result, Operand(Smi::FromInt(0)));
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
5802 __ Push(at, ToRegister(instr->function())); 5802 __ Push(at, ToRegister(instr->function()));
5803 CallRuntime(Runtime::kPushBlockContext, instr); 5803 CallRuntime(Runtime::kPushBlockContext, instr);
5804 RecordSafepoint(Safepoint::kNoLazyDeopt); 5804 RecordSafepoint(Safepoint::kNoLazyDeopt);
5805 } 5805 }
5806 5806
5807 5807
5808 #undef __ 5808 #undef __
5809 5809
5810 } // namespace internal 5810 } // namespace internal
5811 } // namespace v8 5811 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698