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_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 Loading... |
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 Loading... |
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 |
OLD | NEW |