| 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/code-factory.h" | 9 #include "src/code-factory.h" |
| 10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
| (...skipping 587 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 598 // stack. | 598 // stack. |
| 599 __ mov(edx, eax); | 599 __ mov(edx, eax); |
| 600 int smi_tag = eax_is_tagged == kEaxIsSmiTagged ? kSmiTagSize : 0; | 600 int smi_tag = eax_is_tagged == kEaxIsSmiTagged ? kSmiTagSize : 0; |
| 601 __ shl(edx, kPointerSizeLog2 - smi_tag); | 601 __ shl(edx, kPointerSizeLog2 - smi_tag); |
| 602 // Check if the arguments will overflow the stack. | 602 // Check if the arguments will overflow the stack. |
| 603 __ cmp(ecx, edx); | 603 __ cmp(ecx, edx); |
| 604 __ j(greater, &okay); // Signed comparison. | 604 __ j(greater, &okay); // Signed comparison. |
| 605 | 605 |
| 606 // Out of stack space. | 606 // Out of stack space. |
| 607 __ push(Operand(ebp, calleeOffset)); // push this | 607 __ push(Operand(ebp, calleeOffset)); // push this |
| 608 if (eax_is_tagged == kEaxIsUntaggedInt) { |
| 609 __ SmiTag(eax); |
| 610 } |
| 608 __ push(eax); | 611 __ push(eax); |
| 609 __ InvokeBuiltin(Builtins::STACK_OVERFLOW, CALL_FUNCTION); | 612 __ InvokeBuiltin(Builtins::STACK_OVERFLOW, CALL_FUNCTION); |
| 610 | 613 |
| 611 __ bind(&okay); | 614 __ bind(&okay); |
| 612 } | 615 } |
| 613 | 616 |
| 614 | 617 |
| 615 static void Generate_JSEntryTrampolineHelper(MacroAssembler* masm, | 618 static void Generate_JSEntryTrampolineHelper(MacroAssembler* masm, |
| 616 bool is_construct) { | 619 bool is_construct) { |
| 617 ProfileEntryHookStub::MaybeCallEntryHook(masm); | 620 ProfileEntryHookStub::MaybeCallEntryHook(masm); |
| (...skipping 1069 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1687 | 1690 |
| 1688 __ bind(&ok); | 1691 __ bind(&ok); |
| 1689 __ ret(0); | 1692 __ ret(0); |
| 1690 } | 1693 } |
| 1691 | 1694 |
| 1692 #undef __ | 1695 #undef __ |
| 1693 } | 1696 } |
| 1694 } // namespace v8::internal | 1697 } // namespace v8::internal |
| 1695 | 1698 |
| 1696 #endif // V8_TARGET_ARCH_IA32 | 1699 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |