| 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_ARM64 | 7 #if V8_TARGET_ARCH_ARM64 |
| 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 316 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 327 Handle<Code> NamedLoadHandlerCompiler::CompileLoadGlobal( | 327 Handle<Code> NamedLoadHandlerCompiler::CompileLoadGlobal( |
| 328 Handle<PropertyCell> cell, Handle<Name> name, bool is_configurable) { | 328 Handle<PropertyCell> cell, Handle<Name> name, bool is_configurable) { |
| 329 Label miss; | 329 Label miss; |
| 330 if (IC::ICUseVector(kind())) { | 330 if (IC::ICUseVector(kind())) { |
| 331 PushVectorAndSlot(); | 331 PushVectorAndSlot(); |
| 332 } | 332 } |
| 333 FrontendHeader(receiver(), name, &miss); | 333 FrontendHeader(receiver(), name, &miss); |
| 334 | 334 |
| 335 // Get the value from the cell. | 335 // Get the value from the cell. |
| 336 Register result = StoreDescriptor::ValueRegister(); | 336 Register result = StoreDescriptor::ValueRegister(); |
| 337 __ Mov(result, Operand(cell)); | 337 Handle<WeakCell> weak_cell = factory()->NewWeakCell(cell); |
| 338 __ LoadWeakValue(result, weak_cell, &miss); |
| 338 __ Ldr(result, FieldMemOperand(result, Cell::kValueOffset)); | 339 __ Ldr(result, FieldMemOperand(result, Cell::kValueOffset)); |
| 339 | 340 |
| 340 // Check for deleted property if property can actually be deleted. | 341 // Check for deleted property if property can actually be deleted. |
| 341 if (is_configurable) { | 342 if (is_configurable) { |
| 342 __ JumpIfRoot(result, Heap::kTheHoleValueRootIndex, &miss); | 343 __ JumpIfRoot(result, Heap::kTheHoleValueRootIndex, &miss); |
| 343 } | 344 } |
| 344 | 345 |
| 345 Counters* counters = isolate()->counters(); | 346 Counters* counters = isolate()->counters(); |
| 346 __ IncrementCounter(counters->named_load_global_stub(), 1, x1, x3); | 347 __ IncrementCounter(counters->named_load_global_stub(), 1, x1, x3); |
| 347 if (IC::ICUseVector(kind())) { | 348 if (IC::ICUseVector(kind())) { |
| (...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 741 // Return the generated code. | 742 // Return the generated code. |
| 742 return GetCode(kind(), Code::FAST, name); | 743 return GetCode(kind(), Code::FAST, name); |
| 743 } | 744 } |
| 744 | 745 |
| 745 | 746 |
| 746 #undef __ | 747 #undef __ |
| 747 } | 748 } |
| 748 } // namespace v8::internal | 749 } // namespace v8::internal |
| 749 | 750 |
| 750 #endif // V8_TARGET_ARCH_IA32 | 751 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |