OLD | NEW |
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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_PPC | 7 #if V8_TARGET_ARCH_PPC |
8 | 8 |
9 #include "src/ic/call-optimization.h" | 9 #include "src/ic/call-optimization.h" |
10 #include "src/ic/handler-compiler.h" | 10 #include "src/ic/handler-compiler.h" |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 __ Ret(); | 188 __ Ret(); |
189 } | 189 } |
190 | 190 |
191 | 191 |
192 // Generate code to check that a global property cell is empty. Create | 192 // Generate code to check that a global property cell is empty. Create |
193 // the property cell at compilation time if no cell exists for the | 193 // the property cell at compilation time if no cell exists for the |
194 // property. | 194 // property. |
195 void PropertyHandlerCompiler::GenerateCheckPropertyCell( | 195 void PropertyHandlerCompiler::GenerateCheckPropertyCell( |
196 MacroAssembler* masm, Handle<JSGlobalObject> global, Handle<Name> name, | 196 MacroAssembler* masm, Handle<JSGlobalObject> global, Handle<Name> name, |
197 Register scratch, Label* miss) { | 197 Register scratch, Label* miss) { |
198 Handle<Cell> cell = JSGlobalObject::EnsurePropertyCell(global, name); | 198 Handle<PropertyCell> cell = JSGlobalObject::EnsurePropertyCell(global, name); |
199 DCHECK(cell->value()->IsTheHole()); | 199 DCHECK(cell->value()->IsTheHole()); |
200 Handle<WeakCell> weak_cell = masm->isolate()->factory()->NewWeakCell(cell); | 200 Handle<WeakCell> weak_cell = masm->isolate()->factory()->NewWeakCell(cell); |
201 __ LoadWeakValue(scratch, weak_cell, miss); | 201 __ LoadWeakValue(scratch, weak_cell, miss); |
202 __ LoadP(scratch, FieldMemOperand(scratch, Cell::kValueOffset)); | 202 __ LoadP(scratch, FieldMemOperand(scratch, PropertyCell::kValueOffset)); |
203 __ LoadRoot(ip, Heap::kTheHoleValueRootIndex); | 203 __ LoadRoot(ip, Heap::kTheHoleValueRootIndex); |
204 __ cmp(scratch, ip); | 204 __ cmp(scratch, ip); |
205 __ bne(miss); | 205 __ bne(miss); |
206 } | 206 } |
207 | 207 |
208 | 208 |
209 static void PushInterceptorArguments(MacroAssembler* masm, Register receiver, | 209 static void PushInterceptorArguments(MacroAssembler* masm, Register receiver, |
210 Register holder, Register name, | 210 Register holder, Register name, |
211 Handle<JSObject> holder_obj) { | 211 Handle<JSObject> holder_obj) { |
212 STATIC_ASSERT(NamedLoadHandlerCompiler::kInterceptorArgsNameIndex == 0); | 212 STATIC_ASSERT(NamedLoadHandlerCompiler::kInterceptorArgsNameIndex == 0); |
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
743 // Return the generated code. | 743 // Return the generated code. |
744 return GetCode(kind(), Code::NORMAL, name); | 744 return GetCode(kind(), Code::NORMAL, name); |
745 } | 745 } |
746 | 746 |
747 | 747 |
748 #undef __ | 748 #undef __ |
749 } | 749 } |
750 } // namespace v8::internal | 750 } // namespace v8::internal |
751 | 751 |
752 #endif // V8_TARGET_ARCH_ARM | 752 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |