| 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 <limits.h> // For LONG_MIN, LONG_MAX. | 5 #include <limits.h> // For LONG_MIN, LONG_MAX. |
| 6 | 6 |
| 7 #include "src/v8.h" | 7 #include "src/v8.h" |
| 8 | 8 |
| 9 #if V8_TARGET_ARCH_MIPS64 | 9 #if V8_TARGET_ARCH_MIPS64 |
| 10 | 10 |
| (...skipping 3866 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3877 | 3877 |
| 3878 // Ensure that the object is a heap number | 3878 // Ensure that the object is a heap number |
| 3879 CheckMap(value_reg, | 3879 CheckMap(value_reg, |
| 3880 scratch1, | 3880 scratch1, |
| 3881 Heap::kHeapNumberMapRootIndex, | 3881 Heap::kHeapNumberMapRootIndex, |
| 3882 fail, | 3882 fail, |
| 3883 DONT_DO_SMI_CHECK); | 3883 DONT_DO_SMI_CHECK); |
| 3884 | 3884 |
| 3885 // Check for nan: all NaN values have a value greater (signed) than 0x7ff00000 | 3885 // Check for nan: all NaN values have a value greater (signed) than 0x7ff00000 |
| 3886 // in the exponent. | 3886 // in the exponent. |
| 3887 li(scratch1, Operand(kNaNOrInfinityLowerBoundUpper32)); | 3887 li(scratch1, Operand(kHoleNanUpper32 & HeapNumber::kExponentMask)); |
| 3888 lw(exponent_reg, FieldMemOperand(value_reg, HeapNumber::kExponentOffset)); | 3888 lw(exponent_reg, FieldMemOperand(value_reg, HeapNumber::kExponentOffset)); |
| 3889 Branch(&maybe_nan, ge, exponent_reg, Operand(scratch1)); | 3889 Branch(&maybe_nan, ge, exponent_reg, Operand(scratch1)); |
| 3890 | 3890 |
| 3891 lwu(mantissa_reg, FieldMemOperand(value_reg, HeapNumber::kMantissaOffset)); | 3891 lwu(mantissa_reg, FieldMemOperand(value_reg, HeapNumber::kMantissaOffset)); |
| 3892 | 3892 |
| 3893 bind(&have_double_value); | 3893 bind(&have_double_value); |
| 3894 // dsll(scratch1, key_reg, kDoubleSizeLog2 - kSmiTagSize); | 3894 // dsll(scratch1, key_reg, kDoubleSizeLog2 - kSmiTagSize); |
| 3895 dsra(scratch1, key_reg, 32 - kDoubleSizeLog2); | 3895 dsra(scratch1, key_reg, 32 - kDoubleSizeLog2); |
| 3896 Daddu(scratch1, scratch1, elements_reg); | 3896 Daddu(scratch1, scratch1, elements_reg); |
| 3897 sw(mantissa_reg, FieldMemOperand( | 3897 sw(mantissa_reg, FieldMemOperand( |
| (...skipping 2290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6188 } | 6188 } |
| 6189 if (mag.shift > 0) sra(result, result, mag.shift); | 6189 if (mag.shift > 0) sra(result, result, mag.shift); |
| 6190 srl(at, dividend, 31); | 6190 srl(at, dividend, 31); |
| 6191 Addu(result, result, Operand(at)); | 6191 Addu(result, result, Operand(at)); |
| 6192 } | 6192 } |
| 6193 | 6193 |
| 6194 | 6194 |
| 6195 } } // namespace v8::internal | 6195 } } // namespace v8::internal |
| 6196 | 6196 |
| 6197 #endif // V8_TARGET_ARCH_MIPS64 | 6197 #endif // V8_TARGET_ARCH_MIPS64 |
| OLD | NEW |