Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(349)

Side by Side Diff: src/builtins/ia32/builtins-ia32.cc

Issue 2163603003: Revert of [builtins] Introduce a builtin for Abort(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/builtins/builtins.h ('k') | src/builtins/mips/builtins-mips.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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-factory.h" 7 #include "src/code-factory.h"
8 #include "src/codegen.h" 8 #include "src/codegen.h"
9 #include "src/deoptimizer.h" 9 #include "src/deoptimizer.h"
10 #include "src/full-codegen/full-codegen.h" 10 #include "src/full-codegen/full-codegen.h"
(...skipping 2681 matching lines...) Expand 10 before | Expand all | Expand 10 after
2692 __ SmiTag(edx); 2692 __ SmiTag(edx);
2693 __ PopReturnAddressTo(ecx); 2693 __ PopReturnAddressTo(ecx);
2694 __ Push(edx); 2694 __ Push(edx);
2695 __ Push(Smi::FromInt(AllocateTargetSpace::encode(OLD_SPACE))); 2695 __ Push(Smi::FromInt(AllocateTargetSpace::encode(OLD_SPACE)));
2696 __ PushReturnAddressFrom(ecx); 2696 __ PushReturnAddressFrom(ecx);
2697 __ Move(esi, Smi::FromInt(0)); 2697 __ Move(esi, Smi::FromInt(0));
2698 __ TailCallRuntime(Runtime::kAllocateInTargetSpace); 2698 __ TailCallRuntime(Runtime::kAllocateInTargetSpace);
2699 } 2699 }
2700 2700
2701 // static 2701 // static
2702 void Builtins::Generate_Abort(MacroAssembler* masm) {
2703 // ----------- S t a t e -------------
2704 // -- edx : message_id as Smi
2705 // -- esp[0] : return address
2706 // -----------------------------------
2707 __ PopReturnAddressTo(ecx);
2708 __ Push(edx);
2709 __ PushReturnAddressFrom(ecx);
2710 __ Move(esi, Smi::FromInt(0));
2711 __ TailCallRuntime(Runtime::kAbort);
2712 }
2713
2714 // static
2715 void Builtins::Generate_StringToNumber(MacroAssembler* masm) { 2702 void Builtins::Generate_StringToNumber(MacroAssembler* masm) {
2716 // The StringToNumber stub takes one argument in eax. 2703 // The StringToNumber stub takes one argument in eax.
2717 __ AssertString(eax); 2704 __ AssertString(eax);
2718 2705
2719 // Check if string has a cached array index. 2706 // Check if string has a cached array index.
2720 Label runtime; 2707 Label runtime;
2721 __ test(FieldOperand(eax, String::kHashFieldOffset), 2708 __ test(FieldOperand(eax, String::kHashFieldOffset),
2722 Immediate(String::kContainsCachedArrayIndexMask)); 2709 Immediate(String::kContainsCachedArrayIndexMask));
2723 __ j(not_zero, &runtime, Label::kNear); 2710 __ j(not_zero, &runtime, Label::kNear);
2724 __ mov(eax, FieldOperand(eax, String::kHashFieldOffset)); 2711 __ mov(eax, FieldOperand(eax, String::kHashFieldOffset));
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
3003 2990
3004 // And "return" to the OSR entry point of the function. 2991 // And "return" to the OSR entry point of the function.
3005 __ ret(0); 2992 __ ret(0);
3006 } 2993 }
3007 2994
3008 #undef __ 2995 #undef __
3009 } // namespace internal 2996 } // namespace internal
3010 } // namespace v8 2997 } // namespace v8
3011 2998
3012 #endif // V8_TARGET_ARCH_IA32 2999 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/builtins/builtins.h ('k') | src/builtins/mips/builtins-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698