| 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 #ifndef V8_MIPS_CONSTANTS_H_ | 5 #ifndef V8_MIPS_CONSTANTS_H_ |
| 6 #define V8_MIPS_CONSTANTS_H_ | 6 #define V8_MIPS_CONSTANTS_H_ |
| 7 | 7 |
| 8 // UNIMPLEMENTED_ macro for MIPS. | 8 // UNIMPLEMENTED_ macro for MIPS. |
| 9 #ifdef DEBUG | 9 #ifdef DEBUG |
| 10 #define UNIMPLEMENTED_MIPS() \ | 10 #define UNIMPLEMENTED_MIPS() \ |
| (...skipping 941 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 952 inline int32_t Imm16Value() const { | 952 inline int32_t Imm16Value() const { |
| 953 DCHECK(InstructionType() == kImmediateType); | 953 DCHECK(InstructionType() == kImmediateType); |
| 954 return Bits(kImm16Shift + kImm16Bits - 1, kImm16Shift); | 954 return Bits(kImm16Shift + kImm16Bits - 1, kImm16Shift); |
| 955 } | 955 } |
| 956 | 956 |
| 957 inline int32_t Imm21Value() const { | 957 inline int32_t Imm21Value() const { |
| 958 DCHECK(InstructionType() == kImmediateType); | 958 DCHECK(InstructionType() == kImmediateType); |
| 959 return Bits(kImm21Shift + kImm21Bits - 1, kImm21Shift); | 959 return Bits(kImm21Shift + kImm21Bits - 1, kImm21Shift); |
| 960 } | 960 } |
| 961 | 961 |
| 962 inline int32_t Imm26Value() const { | 962 inline int64_t Imm26Value() const { |
| 963 DCHECK(InstructionType() == kJumpType); | 963 DCHECK(InstructionType() == kJumpType); |
| 964 return Bits(kImm26Shift + kImm26Bits - 1, kImm26Shift); | 964 return Bits(kImm26Shift + kImm26Bits - 1, kImm26Shift); |
| 965 } | 965 } |
| 966 | 966 |
| 967 // Say if the instruction should not be used in a branch delay slot. | 967 // Say if the instruction should not be used in a branch delay slot. |
| 968 bool IsForbiddenInBranchDelay() const; | 968 bool IsForbiddenInBranchDelay() const; |
| 969 // Say if the instruction 'links'. e.g. jal, bal. | 969 // Say if the instruction 'links'. e.g. jal, bal. |
| 970 bool IsLinkingInstruction() const; | 970 bool IsLinkingInstruction() const; |
| 971 // Say if the instruction is a break or a trap. | 971 // Say if the instruction is a break or a trap. |
| 972 bool IsTrap() const; | 972 bool IsTrap() const; |
| (...skipping 21 matching lines...) Expand all Loading... |
| 994 // TODO(plind): below should be based on kPointerSize | 994 // TODO(plind): below should be based on kPointerSize |
| 995 // TODO(plind): find all usages and remove the needless instructions for n64. | 995 // TODO(plind): find all usages and remove the needless instructions for n64. |
| 996 const int kCArgsSlotsSize = kCArgSlotCount * Instruction::kInstrSize * 2; | 996 const int kCArgsSlotsSize = kCArgSlotCount * Instruction::kInstrSize * 2; |
| 997 | 997 |
| 998 const int kInvalidStackOffset = -1; | 998 const int kInvalidStackOffset = -1; |
| 999 const int kBranchReturnOffset = 2 * Instruction::kInstrSize; | 999 const int kBranchReturnOffset = 2 * Instruction::kInstrSize; |
| 1000 | 1000 |
| 1001 } } // namespace v8::internal | 1001 } } // namespace v8::internal |
| 1002 | 1002 |
| 1003 #endif // #ifndef V8_MIPS_CONSTANTS_H_ | 1003 #endif // #ifndef V8_MIPS_CONSTANTS_H_ |
| OLD | NEW |