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 "v8.h" | 7 #include "v8.h" |
8 | 8 |
9 #if V8_TARGET_ARCH_MIPS | 9 #if V8_TARGET_ARCH_MIPS |
10 | 10 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 | 49 |
50 void MacroAssembler::Store(Register src, | 50 void MacroAssembler::Store(Register src, |
51 const MemOperand& dst, | 51 const MemOperand& dst, |
52 Representation r) { | 52 Representation r) { |
53 ASSERT(!r.IsDouble()); | 53 ASSERT(!r.IsDouble()); |
54 if (r.IsInteger8() || r.IsUInteger8()) { | 54 if (r.IsInteger8() || r.IsUInteger8()) { |
55 sb(src, dst); | 55 sb(src, dst); |
56 } else if (r.IsInteger16() || r.IsUInteger16()) { | 56 } else if (r.IsInteger16() || r.IsUInteger16()) { |
57 sh(src, dst); | 57 sh(src, dst); |
58 } else { | 58 } else { |
59 if (r.IsHeapObject()) { | |
60 AssertNotSmi(src); | |
61 } else if (r.IsSmi()) { | |
62 AssertSmi(src); | |
63 } | |
64 sw(src, dst); | 59 sw(src, dst); |
65 } | 60 } |
66 } | 61 } |
67 | 62 |
68 | 63 |
69 void MacroAssembler::LoadRoot(Register destination, | 64 void MacroAssembler::LoadRoot(Register destination, |
70 Heap::RootListIndex index) { | 65 Heap::RootListIndex index) { |
71 lw(destination, MemOperand(s6, index << kPointerSizeLog2)); | 66 lw(destination, MemOperand(s6, index << kPointerSizeLog2)); |
72 } | 67 } |
73 | 68 |
(...skipping 5677 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5751 } | 5746 } |
5752 if (ms.shift() > 0) sra(result, result, ms.shift()); | 5747 if (ms.shift() > 0) sra(result, result, ms.shift()); |
5753 srl(at, dividend, 31); | 5748 srl(at, dividend, 31); |
5754 Addu(result, result, Operand(at)); | 5749 Addu(result, result, Operand(at)); |
5755 } | 5750 } |
5756 | 5751 |
5757 | 5752 |
5758 } } // namespace v8::internal | 5753 } } // namespace v8::internal |
5759 | 5754 |
5760 #endif // V8_TARGET_ARCH_MIPS | 5755 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |