OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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_S390 | 5 #if V8_TARGET_ARCH_S390 |
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 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 // parameter to a number first using the ToNumber builtin if necessary. | 152 // parameter to a number first using the ToNumber builtin if necessary. |
153 Label convert, convert_smi, convert_number, done_convert; | 153 Label convert, convert_smi, convert_number, done_convert; |
154 __ bind(&convert); | 154 __ bind(&convert); |
155 __ JumpIfSmi(r4, &convert_smi); | 155 __ JumpIfSmi(r4, &convert_smi); |
156 __ LoadP(r5, FieldMemOperand(r4, HeapObject::kMapOffset)); | 156 __ LoadP(r5, FieldMemOperand(r4, HeapObject::kMapOffset)); |
157 __ JumpIfRoot(r5, Heap::kHeapNumberMapRootIndex, &convert_number); | 157 __ JumpIfRoot(r5, Heap::kHeapNumberMapRootIndex, &convert_number); |
158 { | 158 { |
159 // Parameter is not a Number, use the ToNumber builtin to convert it. | 159 // Parameter is not a Number, use the ToNumber builtin to convert it. |
160 DCHECK(!FLAG_enable_embedded_constant_pool); | 160 DCHECK(!FLAG_enable_embedded_constant_pool); |
161 FrameScope scope(masm, StackFrame::MANUAL); | 161 FrameScope scope(masm, StackFrame::MANUAL); |
162 __ Push(r14, fp, cp, r3); | 162 __ PushStandardFrame(r3); |
163 __ la(fp, MemOperand(sp, 2 * kPointerSize)); | |
164 __ SmiTag(r2); | 163 __ SmiTag(r2); |
165 __ SmiTag(r6); | 164 __ SmiTag(r6); |
166 __ Push(r2, r6, r7); | 165 __ Push(r2, r6, r7); |
167 __ LoadRR(r2, r4); | 166 __ LoadRR(r2, r4); |
168 __ Call(masm->isolate()->builtins()->ToNumber(), RelocInfo::CODE_TARGET); | 167 __ Call(masm->isolate()->builtins()->ToNumber(), RelocInfo::CODE_TARGET); |
169 __ LoadRR(r4, r2); | 168 __ LoadRR(r4, r2); |
170 __ Pop(r2, r6, r7); | 169 __ Pop(r2, r6, r7); |
171 { | 170 { |
172 // Restore the double accumulator value (d1). | 171 // Restore the double accumulator value (d1). |
173 Label done_restore; | 172 Label done_restore; |
(...skipping 2744 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2918 __ bkpt(0); | 2917 __ bkpt(0); |
2919 } | 2918 } |
2920 } | 2919 } |
2921 | 2920 |
2922 #undef __ | 2921 #undef __ |
2923 | 2922 |
2924 } // namespace internal | 2923 } // namespace internal |
2925 } // namespace v8 | 2924 } // namespace v8 |
2926 | 2925 |
2927 #endif // V8_TARGET_ARCH_S390 | 2926 #endif // V8_TARGET_ARCH_S390 |
OLD | NEW |