| 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 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_IA32 | 7 #if V8_TARGET_ARCH_IA32 |
| 8 | 8 |
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
| 10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 134 #ifdef DEBUG | 134 #ifdef DEBUG |
| 135 if (strlen(FLAG_stop_at) > 0 && | 135 if (strlen(FLAG_stop_at) > 0 && |
| 136 info_->function()->name()->IsUtf8EqualTo(CStrVector(FLAG_stop_at))) { | 136 info_->function()->name()->IsUtf8EqualTo(CStrVector(FLAG_stop_at))) { |
| 137 __ int3(); | 137 __ int3(); |
| 138 } | 138 } |
| 139 #endif | 139 #endif |
| 140 | 140 |
| 141 // Sloppy mode functions and builtins need to replace the receiver with the | 141 // Sloppy mode functions and builtins need to replace the receiver with the |
| 142 // global proxy when called as functions (without an explicit receiver | 142 // global proxy when called as functions (without an explicit receiver |
| 143 // object). | 143 // object). |
| 144 if (info_->this_has_uses() && is_sloppy(info_->language_mode()) && | 144 if (graph()->this_has_uses() && is_sloppy(info_->language_mode()) && |
| 145 !info_->is_native()) { | 145 !info_->is_native()) { |
| 146 Label ok; | 146 Label ok; |
| 147 // +1 for return address. | 147 // +1 for return address. |
| 148 int receiver_offset = (scope()->num_parameters() + 1) * kPointerSize; | 148 int receiver_offset = (scope()->num_parameters() + 1) * kPointerSize; |
| 149 __ mov(ecx, Operand(esp, receiver_offset)); | 149 __ mov(ecx, Operand(esp, receiver_offset)); |
| 150 | 150 |
| 151 __ cmp(ecx, isolate()->factory()->undefined_value()); | 151 __ cmp(ecx, isolate()->factory()->undefined_value()); |
| 152 __ j(not_equal, &ok, Label::kNear); | 152 __ j(not_equal, &ok, Label::kNear); |
| 153 | 153 |
| 154 __ mov(ecx, GlobalObjectOperand()); | 154 __ mov(ecx, GlobalObjectOperand()); |
| (...skipping 5614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5769 CallRuntime(Runtime::kPushBlockContext, 2, instr); | 5769 CallRuntime(Runtime::kPushBlockContext, 2, instr); |
| 5770 RecordSafepoint(Safepoint::kNoLazyDeopt); | 5770 RecordSafepoint(Safepoint::kNoLazyDeopt); |
| 5771 } | 5771 } |
| 5772 | 5772 |
| 5773 | 5773 |
| 5774 #undef __ | 5774 #undef __ |
| 5775 | 5775 |
| 5776 } } // namespace v8::internal | 5776 } } // namespace v8::internal |
| 5777 | 5777 |
| 5778 #endif // V8_TARGET_ARCH_IA32 | 5778 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |