| 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 #if V8_TARGET_ARCH_MIPS | 7 #if V8_TARGET_ARCH_MIPS |
| 8 | 8 |
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
| 10 #include "src/base/division-by-constant.h" | 10 #include "src/base/division-by-constant.h" |
| 11 #include "src/bootstrapper.h" | 11 #include "src/bootstrapper.h" |
| 12 #include "src/codegen.h" | 12 #include "src/codegen.h" |
| 13 #include "src/debug/debug.h" | 13 #include "src/debug/debug.h" |
| 14 #include "src/mips/macro-assembler-mips.h" | 14 #include "src/mips/macro-assembler-mips.h" |
| 15 #include "src/register-configuration.h" | 15 #include "src/register-configuration.h" |
| 16 #include "src/runtime/runtime.h" | 16 #include "src/runtime/runtime.h" |
| 17 | 17 |
| 18 namespace v8 { | 18 namespace v8 { |
| 19 namespace internal { | 19 namespace internal { |
| 20 | 20 |
| 21 // Floating point constants. | 21 // Floating point constants. |
| 22 const uint32_t kDoubleSignMask = HeapNumber::kSignMask; | 22 const uint32_t kDoubleSignMask = HeapNumber::kSignMask; |
| 23 const uint32_t kDoubleExponentShift = HeapNumber::kExponentShift; | 23 const uint32_t kDoubleExponentShift = HeapNumber::kExponentShift; |
| 24 const uint32_t kDoubleNaNShift = kDoubleExponentShift - 1; | 24 const uint32_t kDoubleNaNShift = kDoubleExponentShift - 1; |
| 25 const uint32_t kDoubleNaNMask = | 25 const uint32_t kDoubleNaNMask = |
| 26 kDoubleSignMask | HeapNumber::kExponentMask | (1 << kDoubleNaNShift); | 26 HeapNumber::kExponentMask | (1 << kDoubleNaNShift); |
| 27 | 27 |
| 28 const uint32_t kSingleSignMask = kBinary32SignMask; | 28 const uint32_t kSingleSignMask = kBinary32SignMask; |
| 29 const uint32_t kSingleExponentMask = kBinary32ExponentMask; | 29 const uint32_t kSingleExponentMask = kBinary32ExponentMask; |
| 30 const uint32_t kSingleExponentShift = kBinary32ExponentShift; | 30 const uint32_t kSingleExponentShift = kBinary32ExponentShift; |
| 31 const uint32_t kSingleNaNShift = kSingleExponentShift - 1; | 31 const uint32_t kSingleNaNShift = kSingleExponentShift - 1; |
| 32 const uint32_t kSingleNaNMask = | 32 const uint32_t kSingleNaNMask = kSingleExponentMask | (1 << kSingleNaNShift); |
| 33 kSingleSignMask | kSingleExponentMask | (1 << kSingleNaNShift); | |
| 34 | 33 |
| 35 MacroAssembler::MacroAssembler(Isolate* arg_isolate, void* buffer, int size, | 34 MacroAssembler::MacroAssembler(Isolate* arg_isolate, void* buffer, int size, |
| 36 CodeObjectRequired create_code_object) | 35 CodeObjectRequired create_code_object) |
| 37 : Assembler(arg_isolate, buffer, size), | 36 : Assembler(arg_isolate, buffer, size), |
| 38 generating_stub_(false), | 37 generating_stub_(false), |
| 39 has_frame_(false), | 38 has_frame_(false), |
| 40 has_double_zero_reg_set_(false) { | 39 has_double_zero_reg_set_(false) { |
| 41 if (create_code_object == CodeObjectRequired::kYes) { | 40 if (create_code_object == CodeObjectRequired::kYes) { |
| 42 code_object_ = | 41 code_object_ = |
| 43 Handle<Object>::New(isolate()->heap()->undefined_value(), isolate()); | 42 Handle<Object>::New(isolate()->heap()->undefined_value(), isolate()); |
| (...skipping 6830 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6874 if (mag.shift > 0) sra(result, result, mag.shift); | 6873 if (mag.shift > 0) sra(result, result, mag.shift); |
| 6875 srl(at, dividend, 31); | 6874 srl(at, dividend, 31); |
| 6876 Addu(result, result, Operand(at)); | 6875 Addu(result, result, Operand(at)); |
| 6877 } | 6876 } |
| 6878 | 6877 |
| 6879 | 6878 |
| 6880 } // namespace internal | 6879 } // namespace internal |
| 6881 } // namespace v8 | 6880 } // namespace v8 |
| 6882 | 6881 |
| 6883 #endif // V8_TARGET_ARCH_MIPS | 6882 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |