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

Side by Side Diff: src/ic/arm64/handler-compiler-arm64.cc

Issue 2686723004: [stubs] Port LoadFunctionPrototypeStub to CSA (Closed)
Patch Set: Created 3 years, 10 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
« no previous file with comments | « src/ic/arm/handler-compiler-arm.cc ('k') | src/ic/handler-compiler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 #if V8_TARGET_ARCH_ARM64 5 #if V8_TARGET_ARCH_ARM64
6 6
7 #include "src/ic/handler-compiler.h" 7 #include "src/ic/handler-compiler.h"
8 8
9 #include "src/api-arguments.h" 9 #include "src/api-arguments.h"
10 #include "src/field-type.h" 10 #include "src/field-type.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 // Check that the properties array is a dictionary. 76 // Check that the properties array is a dictionary.
77 __ Ldr(map, FieldMemOperand(properties, HeapObject::kMapOffset)); 77 __ Ldr(map, FieldMemOperand(properties, HeapObject::kMapOffset));
78 __ JumpIfNotRoot(map, Heap::kHashTableMapRootIndex, miss_label); 78 __ JumpIfNotRoot(map, Heap::kHashTableMapRootIndex, miss_label);
79 79
80 NameDictionaryLookupStub::GenerateNegativeLookup( 80 NameDictionaryLookupStub::GenerateNegativeLookup(
81 masm, miss_label, &done, receiver, properties, name, scratch1); 81 masm, miss_label, &done, receiver, properties, name, scratch1);
82 __ Bind(&done); 82 __ Bind(&done);
83 __ DecrementCounter(counters->negative_lookups_miss(), 1, scratch0, scratch1); 83 __ DecrementCounter(counters->negative_lookups_miss(), 1, scratch0, scratch1);
84 } 84 }
85 85
86 void NamedLoadHandlerCompiler::GenerateLoadFunctionPrototype(
87 MacroAssembler* masm, Register receiver, Register scratch1,
88 Register scratch2, Label* miss_label) {
89 __ TryGetFunctionPrototype(receiver, scratch1, scratch2, miss_label);
90 // TryGetFunctionPrototype can't put the result directly in x0 because the
91 // 3 inputs registers can't alias and we call this function from
92 // LoadIC::GenerateFunctionPrototype, where receiver is x0. So we explicitly
93 // move the result in x0.
94 __ Mov(x0, scratch1);
95 __ Ret();
96 }
97
98
99 // Generate code to check that a global property cell is empty. Create 86 // Generate code to check that a global property cell is empty. Create
100 // the property cell at compilation time if no cell exists for the 87 // the property cell at compilation time if no cell exists for the
101 // property. 88 // property.
102 void PropertyHandlerCompiler::GenerateCheckPropertyCell( 89 void PropertyHandlerCompiler::GenerateCheckPropertyCell(
103 MacroAssembler* masm, Handle<JSGlobalObject> global, Handle<Name> name, 90 MacroAssembler* masm, Handle<JSGlobalObject> global, Handle<Name> name,
104 Register scratch, Label* miss) { 91 Register scratch, Label* miss) {
105 Handle<PropertyCell> cell = JSGlobalObject::EnsureEmptyPropertyCell( 92 Handle<PropertyCell> cell = JSGlobalObject::EnsureEmptyPropertyCell(
106 global, name, PropertyCellType::kInvalidated); 93 global, name, PropertyCellType::kInvalidated);
107 Isolate* isolate = masm->isolate(); 94 Isolate* isolate = masm->isolate();
108 DCHECK(cell->value()->IsTheHole(isolate)); 95 DCHECK(cell->value()->IsTheHole(isolate));
(...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after
609 // Return the generated code. 596 // Return the generated code.
610 return GetCode(kind(), name); 597 return GetCode(kind(), name);
611 } 598 }
612 599
613 600
614 #undef __ 601 #undef __
615 } // namespace internal 602 } // namespace internal
616 } // namespace v8 603 } // namespace v8
617 604
618 #endif // V8_TARGET_ARCH_IA32 605 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ic/arm/handler-compiler-arm.cc ('k') | src/ic/handler-compiler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698