| OLD | NEW |
| 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 #if V8_TARGET_ARCH_ARM | 5 #if V8_TARGET_ARCH_ARM |
| 6 | 6 |
| 7 #include "src/ast/scopes.h" | 7 #include "src/ast/scopes.h" |
| 8 #include "src/code-factory.h" | 8 #include "src/code-factory.h" |
| 9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
| 10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
| (...skipping 1249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1260 __ jmp(done); | 1260 __ jmp(done); |
| 1261 } | 1261 } |
| 1262 } | 1262 } |
| 1263 } | 1263 } |
| 1264 | 1264 |
| 1265 | 1265 |
| 1266 void FullCodeGenerator::EmitGlobalVariableLoad(VariableProxy* proxy, | 1266 void FullCodeGenerator::EmitGlobalVariableLoad(VariableProxy* proxy, |
| 1267 TypeofMode typeof_mode) { | 1267 TypeofMode typeof_mode) { |
| 1268 #ifdef DEBUG | 1268 #ifdef DEBUG |
| 1269 Variable* var = proxy->var(); | 1269 Variable* var = proxy->var(); |
| 1270 DCHECK(var->IsUnallocatedOrGlobalSlot() || | 1270 DCHECK(var->IsUnallocated() || |
| 1271 (var->IsLookupSlot() && var->mode() == DYNAMIC_GLOBAL)); | 1271 (var->IsLookupSlot() && var->mode() == DYNAMIC_GLOBAL)); |
| 1272 #endif | 1272 #endif |
| 1273 __ mov(LoadGlobalDescriptor::SlotRegister(), | 1273 __ mov(LoadGlobalDescriptor::SlotRegister(), |
| 1274 Operand(SmiFromSlot(proxy->VariableFeedbackSlot()))); | 1274 Operand(SmiFromSlot(proxy->VariableFeedbackSlot()))); |
| 1275 CallLoadGlobalIC(typeof_mode); | 1275 CallLoadGlobalIC(typeof_mode); |
| 1276 } | 1276 } |
| 1277 | 1277 |
| 1278 | 1278 |
| 1279 void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy, | 1279 void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy, |
| 1280 TypeofMode typeof_mode) { | 1280 TypeofMode typeof_mode) { |
| (...skipping 1754 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3035 CallRuntimeWithOperands(is_strict(language_mode()) | 3035 CallRuntimeWithOperands(is_strict(language_mode()) |
| 3036 ? Runtime::kDeleteProperty_Strict | 3036 ? Runtime::kDeleteProperty_Strict |
| 3037 : Runtime::kDeleteProperty_Sloppy); | 3037 : Runtime::kDeleteProperty_Sloppy); |
| 3038 context()->Plug(r0); | 3038 context()->Plug(r0); |
| 3039 } else if (proxy != NULL) { | 3039 } else if (proxy != NULL) { |
| 3040 Variable* var = proxy->var(); | 3040 Variable* var = proxy->var(); |
| 3041 // Delete of an unqualified identifier is disallowed in strict mode but | 3041 // Delete of an unqualified identifier is disallowed in strict mode but |
| 3042 // "delete this" is allowed. | 3042 // "delete this" is allowed. |
| 3043 bool is_this = var->is_this(); | 3043 bool is_this = var->is_this(); |
| 3044 DCHECK(is_sloppy(language_mode()) || is_this); | 3044 DCHECK(is_sloppy(language_mode()) || is_this); |
| 3045 if (var->IsUnallocatedOrGlobalSlot()) { | 3045 if (var->IsUnallocated()) { |
| 3046 __ LoadGlobalObject(r2); | 3046 __ LoadGlobalObject(r2); |
| 3047 __ mov(r1, Operand(var->name())); | 3047 __ mov(r1, Operand(var->name())); |
| 3048 __ Push(r2, r1); | 3048 __ Push(r2, r1); |
| 3049 __ CallRuntime(Runtime::kDeleteProperty_Sloppy); | 3049 __ CallRuntime(Runtime::kDeleteProperty_Sloppy); |
| 3050 context()->Plug(r0); | 3050 context()->Plug(r0); |
| 3051 } else if (var->IsStackAllocated() || var->IsContextSlot()) { | 3051 } else if (var->IsStackAllocated() || var->IsContextSlot()) { |
| 3052 // Result of deleting non-global, non-dynamic variables is false. | 3052 // Result of deleting non-global, non-dynamic variables is false. |
| 3053 // The subexpression does not have side effects. | 3053 // The subexpression does not have side effects. |
| 3054 context()->Plug(is_this); | 3054 context()->Plug(is_this); |
| 3055 } else { | 3055 } else { |
| (...skipping 760 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3816 DCHECK(interrupt_address == | 3816 DCHECK(interrupt_address == |
| 3817 isolate->builtins()->OnStackReplacement()->entry()); | 3817 isolate->builtins()->OnStackReplacement()->entry()); |
| 3818 return ON_STACK_REPLACEMENT; | 3818 return ON_STACK_REPLACEMENT; |
| 3819 } | 3819 } |
| 3820 | 3820 |
| 3821 | 3821 |
| 3822 } // namespace internal | 3822 } // namespace internal |
| 3823 } // namespace v8 | 3823 } // namespace v8 |
| 3824 | 3824 |
| 3825 #endif // V8_TARGET_ARCH_ARM | 3825 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |