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

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

Issue 2156923002: [builtins] Introduce a builtin for Abort(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase 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/ia32/builtins-ia32.cc ('k') | src/builtins/mips64/builtins-mips64.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_MIPS 5 #if V8_TARGET_ARCH_MIPS
6 6
7 #include "src/codegen.h" 7 #include "src/codegen.h"
8 #include "src/debug/debug.h" 8 #include "src/debug/debug.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 2776 matching lines...) Expand 10 before | Expand all | Expand 10 after
2787 // -- ra : return address 2787 // -- ra : return address
2788 // ----------------------------------- 2788 // -----------------------------------
2789 __ SmiTag(a0); 2789 __ SmiTag(a0);
2790 __ Move(a1, Smi::FromInt(AllocateTargetSpace::encode(OLD_SPACE))); 2790 __ Move(a1, Smi::FromInt(AllocateTargetSpace::encode(OLD_SPACE)));
2791 __ Push(a0, a1); 2791 __ Push(a0, a1);
2792 __ Move(cp, Smi::FromInt(0)); 2792 __ Move(cp, Smi::FromInt(0));
2793 __ TailCallRuntime(Runtime::kAllocateInTargetSpace); 2793 __ TailCallRuntime(Runtime::kAllocateInTargetSpace);
2794 } 2794 }
2795 2795
2796 // static 2796 // static
2797 void Builtins::Generate_Abort(MacroAssembler* masm) {
2798 // ----------- S t a t e -------------
2799 // -- a0 : message_id as Smi
2800 // -- ra : return address
2801 // -----------------------------------
2802 __ Push(a0);
2803 __ Move(cp, Smi::FromInt(0));
2804 __ TailCallRuntime(Runtime::kAbort);
2805 }
2806
2807 // static
2797 void Builtins::Generate_StringToNumber(MacroAssembler* masm) { 2808 void Builtins::Generate_StringToNumber(MacroAssembler* masm) {
2798 // The StringToNumber stub takes on argument in a0. 2809 // The StringToNumber stub takes on argument in a0.
2799 __ AssertString(a0); 2810 __ AssertString(a0);
2800 2811
2801 // Check if string has a cached array index. 2812 // Check if string has a cached array index.
2802 Label runtime; 2813 Label runtime;
2803 __ lw(a2, FieldMemOperand(a0, String::kHashFieldOffset)); 2814 __ lw(a2, FieldMemOperand(a0, String::kHashFieldOffset));
2804 __ And(at, a2, Operand(String::kContainsCachedArrayIndexMask)); 2815 __ And(at, a2, Operand(String::kContainsCachedArrayIndexMask));
2805 __ Branch(&runtime, ne, at, Operand(zero_reg)); 2816 __ Branch(&runtime, ne, at, Operand(zero_reg));
2806 __ IndexFromHash(a2, v0); 2817 __ IndexFromHash(a2, v0);
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
2969 __ break_(0xCC); 2980 __ break_(0xCC);
2970 } 2981 }
2971 } 2982 }
2972 2983
2973 #undef __ 2984 #undef __
2974 2985
2975 } // namespace internal 2986 } // namespace internal
2976 } // namespace v8 2987 } // namespace v8
2977 2988
2978 #endif // V8_TARGET_ARCH_MIPS 2989 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/builtins/ia32/builtins-ia32.cc ('k') | src/builtins/mips64/builtins-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698