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_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
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 1829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1840 ExternalReference pending_exception(Isolate::kPendingExceptionAddress, | 1840 ExternalReference pending_exception(Isolate::kPendingExceptionAddress, |
1841 isolate()); | 1841 isolate()); |
1842 __ mov(Operand::StaticVariable(pending_exception), eax); | 1842 __ mov(Operand::StaticVariable(pending_exception), eax); |
1843 __ mov(eax, Immediate(isolate()->factory()->exception())); | 1843 __ mov(eax, Immediate(isolate()->factory()->exception())); |
1844 __ jmp(&exit); | 1844 __ jmp(&exit); |
1845 | 1845 |
1846 // Invoke: Link this frame into the handler chain. | 1846 // Invoke: Link this frame into the handler chain. |
1847 __ bind(&invoke); | 1847 __ bind(&invoke); |
1848 __ PushStackHandler(); | 1848 __ PushStackHandler(); |
1849 | 1849 |
1850 // Clear any pending exceptions. | |
1851 __ mov(edx, Immediate(isolate()->factory()->the_hole_value())); | |
1852 __ mov(Operand::StaticVariable(pending_exception), edx); | |
1853 | |
1854 // Fake a receiver (NULL). | 1850 // Fake a receiver (NULL). |
1855 __ push(Immediate(0)); // receiver | 1851 __ push(Immediate(0)); // receiver |
1856 | 1852 |
1857 // Invoke the function by calling through JS entry trampoline builtin and | 1853 // Invoke the function by calling through JS entry trampoline builtin and |
1858 // pop the faked function when we return. Notice that we cannot store a | 1854 // pop the faked function when we return. Notice that we cannot store a |
1859 // reference to the trampoline code directly in this stub, because the | 1855 // reference to the trampoline code directly in this stub, because the |
1860 // builtin stubs may not have been generated yet. | 1856 // builtin stubs may not have been generated yet. |
1861 if (type() == StackFrame::ENTRY_CONSTRUCT) { | 1857 if (type() == StackFrame::ENTRY_CONSTRUCT) { |
1862 ExternalReference construct_entry(Builtins::kJSConstructEntryTrampoline, | 1858 ExternalReference construct_entry(Builtins::kJSConstructEntryTrampoline, |
1863 isolate()); | 1859 isolate()); |
(...skipping 3626 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5490 kStackUnwindSpace, nullptr, return_value_operand, | 5486 kStackUnwindSpace, nullptr, return_value_operand, |
5491 NULL); | 5487 NULL); |
5492 } | 5488 } |
5493 | 5489 |
5494 #undef __ | 5490 #undef __ |
5495 | 5491 |
5496 } // namespace internal | 5492 } // namespace internal |
5497 } // namespace v8 | 5493 } // namespace v8 |
5498 | 5494 |
5499 #endif // V8_TARGET_ARCH_IA32 | 5495 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |