| 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/code-stubs.h" | 7 #include "src/code-stubs.h" |
| 8 #include "src/api-arguments.h" | 8 #include "src/api-arguments.h" |
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
| 10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
| (...skipping 1673 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1684 ExternalReference pending_exception(Isolate::kPendingExceptionAddress, | 1684 ExternalReference pending_exception(Isolate::kPendingExceptionAddress, |
| 1685 isolate()); | 1685 isolate()); |
| 1686 __ mov(Operand::StaticVariable(pending_exception), eax); | 1686 __ mov(Operand::StaticVariable(pending_exception), eax); |
| 1687 __ mov(eax, Immediate(isolate()->factory()->exception())); | 1687 __ mov(eax, Immediate(isolate()->factory()->exception())); |
| 1688 __ jmp(&exit); | 1688 __ jmp(&exit); |
| 1689 | 1689 |
| 1690 // Invoke: Link this frame into the handler chain. | 1690 // Invoke: Link this frame into the handler chain. |
| 1691 __ bind(&invoke); | 1691 __ bind(&invoke); |
| 1692 __ PushStackHandler(); | 1692 __ PushStackHandler(); |
| 1693 | 1693 |
| 1694 // Clear any pending exceptions. | |
| 1695 __ mov(edx, Immediate(isolate()->factory()->the_hole_value())); | |
| 1696 __ mov(Operand::StaticVariable(pending_exception), edx); | |
| 1697 | |
| 1698 // Fake a receiver (NULL). | 1694 // Fake a receiver (NULL). |
| 1699 __ push(Immediate(0)); // receiver | 1695 __ push(Immediate(0)); // receiver |
| 1700 | 1696 |
| 1701 // Invoke the function by calling through JS entry trampoline builtin and | 1697 // Invoke the function by calling through JS entry trampoline builtin and |
| 1702 // pop the faked function when we return. Notice that we cannot store a | 1698 // pop the faked function when we return. Notice that we cannot store a |
| 1703 // reference to the trampoline code directly in this stub, because the | 1699 // reference to the trampoline code directly in this stub, because the |
| 1704 // builtin stubs may not have been generated yet. | 1700 // builtin stubs may not have been generated yet. |
| 1705 if (type() == StackFrame::ENTRY_CONSTRUCT) { | 1701 if (type() == StackFrame::ENTRY_CONSTRUCT) { |
| 1706 ExternalReference construct_entry(Builtins::kJSConstructEntryTrampoline, | 1702 ExternalReference construct_entry(Builtins::kJSConstructEntryTrampoline, |
| 1707 isolate()); | 1703 isolate()); |
| (...skipping 3573 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5281 kStackUnwindSpace, nullptr, return_value_operand, | 5277 kStackUnwindSpace, nullptr, return_value_operand, |
| 5282 NULL); | 5278 NULL); |
| 5283 } | 5279 } |
| 5284 | 5280 |
| 5285 #undef __ | 5281 #undef __ |
| 5286 | 5282 |
| 5287 } // namespace internal | 5283 } // namespace internal |
| 5288 } // namespace v8 | 5284 } // namespace v8 |
| 5289 | 5285 |
| 5290 #endif // V8_TARGET_ARCH_X87 | 5286 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |