| 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_X87 | 5 #if V8_TARGET_ARCH_X87 |
| 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 2928 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2939 VisitForStackValue(property->obj()); | 2939 VisitForStackValue(property->obj()); |
| 2940 VisitForStackValue(property->key()); | 2940 VisitForStackValue(property->key()); |
| 2941 CallRuntimeWithOperands(is_strict(language_mode()) | 2941 CallRuntimeWithOperands(is_strict(language_mode()) |
| 2942 ? Runtime::kDeleteProperty_Strict | 2942 ? Runtime::kDeleteProperty_Strict |
| 2943 : Runtime::kDeleteProperty_Sloppy); | 2943 : Runtime::kDeleteProperty_Sloppy); |
| 2944 context()->Plug(eax); | 2944 context()->Plug(eax); |
| 2945 } else if (proxy != NULL) { | 2945 } else if (proxy != NULL) { |
| 2946 Variable* var = proxy->var(); | 2946 Variable* var = proxy->var(); |
| 2947 // Delete of an unqualified identifier is disallowed in strict mode but | 2947 // Delete of an unqualified identifier is disallowed in strict mode but |
| 2948 // "delete this" is allowed. | 2948 // "delete this" is allowed. |
| 2949 bool is_this = var->HasThisName(isolate()); | 2949 bool is_this = var->is_this(); |
| 2950 DCHECK(is_sloppy(language_mode()) || is_this); | 2950 DCHECK(is_sloppy(language_mode()) || is_this); |
| 2951 if (var->IsUnallocatedOrGlobalSlot()) { | 2951 if (var->IsUnallocatedOrGlobalSlot()) { |
| 2952 __ mov(eax, NativeContextOperand()); | 2952 __ mov(eax, NativeContextOperand()); |
| 2953 __ push(ContextOperand(eax, Context::EXTENSION_INDEX)); | 2953 __ push(ContextOperand(eax, Context::EXTENSION_INDEX)); |
| 2954 __ push(Immediate(var->name())); | 2954 __ push(Immediate(var->name())); |
| 2955 __ CallRuntime(Runtime::kDeleteProperty_Sloppy); | 2955 __ CallRuntime(Runtime::kDeleteProperty_Sloppy); |
| 2956 context()->Plug(eax); | 2956 context()->Plug(eax); |
| 2957 } else if (var->IsStackAllocated() || var->IsContextSlot()) { | 2957 } else if (var->IsStackAllocated() || var->IsContextSlot()) { |
| 2958 // Result of deleting non-global variables is false. 'this' is | 2958 // Result of deleting non-global variables is false. 'this' is |
| 2959 // not really a variable, though we implement it as one. The | 2959 // not really a variable, though we implement it as one. The |
| (...skipping 703 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3663 isolate->builtins()->OnStackReplacement()->entry(), | 3663 isolate->builtins()->OnStackReplacement()->entry(), |
| 3664 Assembler::target_address_at(call_target_address, unoptimized_code)); | 3664 Assembler::target_address_at(call_target_address, unoptimized_code)); |
| 3665 return ON_STACK_REPLACEMENT; | 3665 return ON_STACK_REPLACEMENT; |
| 3666 } | 3666 } |
| 3667 | 3667 |
| 3668 | 3668 |
| 3669 } // namespace internal | 3669 } // namespace internal |
| 3670 } // namespace v8 | 3670 } // namespace v8 |
| 3671 | 3671 |
| 3672 #endif // V8_TARGET_ARCH_X87 | 3672 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |