Index: src/mips/constants-mips.h |
diff --git a/src/mips/constants-mips.h b/src/mips/constants-mips.h |
index 22c3e6c18bc548bca41d9587ab9d9116e90ac348..2943a492e7f31a39b376019ceb750262e542a442 100644 |
--- a/src/mips/constants-mips.h |
+++ b/src/mips/constants-mips.h |
@@ -369,187 +369,188 @@ enum Opcode { |
enum SecondaryField { |
// SPECIAL Encoding of Function Field. |
- SLL = ((0 << 3) + 0), |
- MOVCI = ((0 << 3) + 1), |
- SRL = ((0 << 3) + 2), |
- SRA = ((0 << 3) + 3), |
- SLLV = ((0 << 3) + 4), |
- SRLV = ((0 << 3) + 6), |
- SRAV = ((0 << 3) + 7), |
- |
- JR = ((1 << 3) + 0), |
- JALR = ((1 << 3) + 1), |
- MOVZ = ((1 << 3) + 2), |
- MOVN = ((1 << 3) + 3), |
- BREAK = ((1 << 3) + 5), |
- |
- MFHI = ((2 << 3) + 0), |
- CLZ_R6 = ((2 << 3) + 0), |
- CLO_R6 = ((2 << 3) + 1), |
- MFLO = ((2 << 3) + 2), |
- |
- MULT = ((3 << 3) + 0), |
- MULTU = ((3 << 3) + 1), |
- DIV = ((3 << 3) + 2), |
- DIVU = ((3 << 3) + 3), |
- |
- ADD = ((4 << 3) + 0), |
- ADDU = ((4 << 3) + 1), |
- SUB = ((4 << 3) + 2), |
- SUBU = ((4 << 3) + 3), |
- AND = ((4 << 3) + 4), |
- OR = ((4 << 3) + 5), |
- XOR = ((4 << 3) + 6), |
- NOR = ((4 << 3) + 7), |
- |
- SLT = ((5 << 3) + 2), |
- SLTU = ((5 << 3) + 3), |
- |
- TGE = ((6 << 3) + 0), |
- TGEU = ((6 << 3) + 1), |
- TLT = ((6 << 3) + 2), |
- TLTU = ((6 << 3) + 3), |
- TEQ = ((6 << 3) + 4), |
- SELEQZ_S = ((6 << 3) + 5), |
- TNE = ((6 << 3) + 6), |
- SELNEZ_S = ((6 << 3) + 7), |
+ SLL = ((0 << 3) + 0), |
+ MOVCI = ((0 << 3) + 1), |
+ SRL = ((0 << 3) + 2), |
+ SRA = ((0 << 3) + 3), |
+ SLLV = ((0 << 3) + 4), |
+ SRLV = ((0 << 3) + 6), |
+ SRAV = ((0 << 3) + 7), |
+ |
+ JR = ((1 << 3) + 0), |
+ JALR = ((1 << 3) + 1), |
+ MOVZ = ((1 << 3) + 2), |
+ MOVN = ((1 << 3) + 3), |
+ BREAK = ((1 << 3) + 5), |
+ |
+ MFHI = ((2 << 3) + 0), |
+ CLZ_R6 = ((2 << 3) + 0), |
+ CLO_R6 = ((2 << 3) + 1), |
+ MFLO = ((2 << 3) + 2), |
+ |
+ MULT = ((3 << 3) + 0), |
+ MULTU = ((3 << 3) + 1), |
+ DIV = ((3 << 3) + 2), |
+ DIVU = ((3 << 3) + 3), |
+ |
+ ADD = ((4 << 3) + 0), |
+ ADDU = ((4 << 3) + 1), |
+ SUB = ((4 << 3) + 2), |
+ SUBU = ((4 << 3) + 3), |
+ AND = ((4 << 3) + 4), |
+ OR = ((4 << 3) + 5), |
+ XOR = ((4 << 3) + 6), |
+ NOR = ((4 << 3) + 7), |
+ |
+ SLT = ((5 << 3) + 2), |
+ SLTU = ((5 << 3) + 3), |
+ |
+ TGE = ((6 << 3) + 0), |
+ TGEU = ((6 << 3) + 1), |
+ TLT = ((6 << 3) + 2), |
+ TLTU = ((6 << 3) + 3), |
+ TEQ = ((6 << 3) + 4), |
+ SELEQZ_S = ((6 << 3) + 5), |
+ TNE = ((6 << 3) + 6), |
+ SELNEZ_S = ((6 << 3) + 7), |
// Multiply integers in r6. |
- MUL_MUH = ((3 << 3) + 0), // MUL, MUH. |
- MUL_MUH_U = ((3 << 3) + 1), // MUL_U, MUH_U. |
+ MUL_MUH = ((3 << 3) + 0), // MUL, MUH. |
+ MUL_MUH_U = ((3 << 3) + 1), // MUL_U, MUH_U. |
+ RINT = ((3 << 3) + 2), |
- MUL_OP = ((0 << 3) + 2), |
- MUH_OP = ((0 << 3) + 3), |
- DIV_OP = ((0 << 3) + 2), |
- MOD_OP = ((0 << 3) + 3), |
+ MUL_OP = ((0 << 3) + 2), |
+ MUH_OP = ((0 << 3) + 3), |
+ DIV_OP = ((0 << 3) + 2), |
+ MOD_OP = ((0 << 3) + 3), |
- DIV_MOD = ((3 << 3) + 2), |
- DIV_MOD_U = ((3 << 3) + 3), |
+ DIV_MOD = ((3 << 3) + 2), |
+ DIV_MOD_U = ((3 << 3) + 3), |
// SPECIAL2 Encoding of Function Field. |
- MUL = ((0 << 3) + 2), |
- CLZ = ((4 << 3) + 0), |
- CLO = ((4 << 3) + 1), |
+ MUL = ((0 << 3) + 2), |
+ CLZ = ((4 << 3) + 0), |
+ CLO = ((4 << 3) + 1), |
// SPECIAL3 Encoding of Function Field. |
- EXT = ((0 << 3) + 0), |
- INS = ((0 << 3) + 4), |
+ EXT = ((0 << 3) + 0), |
+ INS = ((0 << 3) + 4), |
// REGIMM encoding of rt Field. |
- BLTZ = ((0 << 3) + 0) << 16, |
- BGEZ = ((0 << 3) + 1) << 16, |
- BLTZAL = ((2 << 3) + 0) << 16, |
- BGEZAL = ((2 << 3) + 1) << 16, |
- BGEZALL = ((2 << 3) + 3) << 16, |
+ BLTZ = ((0 << 3) + 0) << 16, |
+ BGEZ = ((0 << 3) + 1) << 16, |
+ BLTZAL = ((2 << 3) + 0) << 16, |
+ BGEZAL = ((2 << 3) + 1) << 16, |
+ BGEZALL = ((2 << 3) + 3) << 16, |
// COP1 Encoding of rs Field. |
- MFC1 = ((0 << 3) + 0) << 21, |
- CFC1 = ((0 << 3) + 2) << 21, |
- MFHC1 = ((0 << 3) + 3) << 21, |
- MTC1 = ((0 << 3) + 4) << 21, |
- CTC1 = ((0 << 3) + 6) << 21, |
- MTHC1 = ((0 << 3) + 7) << 21, |
- BC1 = ((1 << 3) + 0) << 21, |
- S = ((2 << 3) + 0) << 21, |
- D = ((2 << 3) + 1) << 21, |
- W = ((2 << 3) + 4) << 21, |
- L = ((2 << 3) + 5) << 21, |
- PS = ((2 << 3) + 6) << 21, |
+ MFC1 = ((0 << 3) + 0) << 21, |
+ CFC1 = ((0 << 3) + 2) << 21, |
+ MFHC1 = ((0 << 3) + 3) << 21, |
+ MTC1 = ((0 << 3) + 4) << 21, |
+ CTC1 = ((0 << 3) + 6) << 21, |
+ MTHC1 = ((0 << 3) + 7) << 21, |
+ BC1 = ((1 << 3) + 0) << 21, |
+ S = ((2 << 3) + 0) << 21, |
+ D = ((2 << 3) + 1) << 21, |
+ W = ((2 << 3) + 4) << 21, |
+ L = ((2 << 3) + 5) << 21, |
+ PS = ((2 << 3) + 6) << 21, |
// COP1 Encoding of Function Field When rs=S. |
- ROUND_L_S = ((1 << 3) + 0), |
- TRUNC_L_S = ((1 << 3) + 1), |
- CEIL_L_S = ((1 << 3) + 2), |
- FLOOR_L_S = ((1 << 3) + 3), |
- ROUND_W_S = ((1 << 3) + 4), |
- TRUNC_W_S = ((1 << 3) + 5), |
- CEIL_W_S = ((1 << 3) + 6), |
- FLOOR_W_S = ((1 << 3) + 7), |
- CVT_D_S = ((4 << 3) + 1), |
- CVT_W_S = ((4 << 3) + 4), |
- CVT_L_S = ((4 << 3) + 5), |
- CVT_PS_S = ((4 << 3) + 6), |
+ ROUND_L_S = ((1 << 3) + 0), |
+ TRUNC_L_S = ((1 << 3) + 1), |
+ CEIL_L_S = ((1 << 3) + 2), |
+ FLOOR_L_S = ((1 << 3) + 3), |
+ ROUND_W_S = ((1 << 3) + 4), |
+ TRUNC_W_S = ((1 << 3) + 5), |
+ CEIL_W_S = ((1 << 3) + 6), |
+ FLOOR_W_S = ((1 << 3) + 7), |
+ CVT_D_S = ((4 << 3) + 1), |
+ CVT_W_S = ((4 << 3) + 4), |
+ CVT_L_S = ((4 << 3) + 5), |
+ CVT_PS_S = ((4 << 3) + 6), |
// COP1 Encoding of Function Field When rs=D. |
- ADD_D = ((0 << 3) + 0), |
- SUB_D = ((0 << 3) + 1), |
- MUL_D = ((0 << 3) + 2), |
- DIV_D = ((0 << 3) + 3), |
- SQRT_D = ((0 << 3) + 4), |
- ABS_D = ((0 << 3) + 5), |
- MOV_D = ((0 << 3) + 6), |
- NEG_D = ((0 << 3) + 7), |
- ROUND_L_D = ((1 << 3) + 0), |
- TRUNC_L_D = ((1 << 3) + 1), |
- CEIL_L_D = ((1 << 3) + 2), |
- FLOOR_L_D = ((1 << 3) + 3), |
- ROUND_W_D = ((1 << 3) + 4), |
- TRUNC_W_D = ((1 << 3) + 5), |
- CEIL_W_D = ((1 << 3) + 6), |
- FLOOR_W_D = ((1 << 3) + 7), |
- MIN = ((3 << 3) + 4), |
- MINA = ((3 << 3) + 5), |
- MAX = ((3 << 3) + 6), |
- MAXA = ((3 << 3) + 7), |
- CVT_S_D = ((4 << 3) + 0), |
- CVT_W_D = ((4 << 3) + 4), |
- CVT_L_D = ((4 << 3) + 5), |
- C_F_D = ((6 << 3) + 0), |
- C_UN_D = ((6 << 3) + 1), |
- C_EQ_D = ((6 << 3) + 2), |
- C_UEQ_D = ((6 << 3) + 3), |
- C_OLT_D = ((6 << 3) + 4), |
- C_ULT_D = ((6 << 3) + 5), |
- C_OLE_D = ((6 << 3) + 6), |
- C_ULE_D = ((6 << 3) + 7), |
+ ADD_D = ((0 << 3) + 0), |
+ SUB_D = ((0 << 3) + 1), |
+ MUL_D = ((0 << 3) + 2), |
+ DIV_D = ((0 << 3) + 3), |
+ SQRT_D = ((0 << 3) + 4), |
+ ABS_D = ((0 << 3) + 5), |
+ MOV_D = ((0 << 3) + 6), |
+ NEG_D = ((0 << 3) + 7), |
+ ROUND_L_D = ((1 << 3) + 0), |
+ TRUNC_L_D = ((1 << 3) + 1), |
+ CEIL_L_D = ((1 << 3) + 2), |
+ FLOOR_L_D = ((1 << 3) + 3), |
+ ROUND_W_D = ((1 << 3) + 4), |
+ TRUNC_W_D = ((1 << 3) + 5), |
+ CEIL_W_D = ((1 << 3) + 6), |
+ FLOOR_W_D = ((1 << 3) + 7), |
+ MIN = ((3 << 3) + 4), |
+ MINA = ((3 << 3) + 5), |
+ MAX = ((3 << 3) + 6), |
+ MAXA = ((3 << 3) + 7), |
+ CVT_S_D = ((4 << 3) + 0), |
+ CVT_W_D = ((4 << 3) + 4), |
+ CVT_L_D = ((4 << 3) + 5), |
+ C_F_D = ((6 << 3) + 0), |
+ C_UN_D = ((6 << 3) + 1), |
+ C_EQ_D = ((6 << 3) + 2), |
+ C_UEQ_D = ((6 << 3) + 3), |
+ C_OLT_D = ((6 << 3) + 4), |
+ C_ULT_D = ((6 << 3) + 5), |
+ C_OLE_D = ((6 << 3) + 6), |
+ C_ULE_D = ((6 << 3) + 7), |
// COP1 Encoding of Function Field When rs=W or L. |
- CVT_S_W = ((4 << 3) + 0), |
- CVT_D_W = ((4 << 3) + 1), |
- CVT_S_L = ((4 << 3) + 0), |
- CVT_D_L = ((4 << 3) + 1), |
- BC1EQZ = ((2 << 2) + 1) << 21, |
- BC1NEZ = ((3 << 2) + 1) << 21, |
+ CVT_S_W = ((4 << 3) + 0), |
+ CVT_D_W = ((4 << 3) + 1), |
+ CVT_S_L = ((4 << 3) + 0), |
+ CVT_D_L = ((4 << 3) + 1), |
+ BC1EQZ = ((2 << 2) + 1) << 21, |
+ BC1NEZ = ((3 << 2) + 1) << 21, |
// COP1 CMP positive predicates Bit 5..4 = 00. |
- CMP_AF = ((0 << 3) + 0), |
- CMP_UN = ((0 << 3) + 1), |
- CMP_EQ = ((0 << 3) + 2), |
- CMP_UEQ = ((0 << 3) + 3), |
- CMP_LT = ((0 << 3) + 4), |
- CMP_ULT = ((0 << 3) + 5), |
- CMP_LE = ((0 << 3) + 6), |
- CMP_ULE = ((0 << 3) + 7), |
- CMP_SAF = ((1 << 3) + 0), |
- CMP_SUN = ((1 << 3) + 1), |
- CMP_SEQ = ((1 << 3) + 2), |
- CMP_SUEQ = ((1 << 3) + 3), |
- CMP_SSLT = ((1 << 3) + 4), |
- CMP_SSULT = ((1 << 3) + 5), |
- CMP_SLE = ((1 << 3) + 6), |
- CMP_SULE = ((1 << 3) + 7), |
+ CMP_AF = ((0 << 3) + 0), |
+ CMP_UN = ((0 << 3) + 1), |
+ CMP_EQ = ((0 << 3) + 2), |
+ CMP_UEQ = ((0 << 3) + 3), |
+ CMP_LT = ((0 << 3) + 4), |
+ CMP_ULT = ((0 << 3) + 5), |
+ CMP_LE = ((0 << 3) + 6), |
+ CMP_ULE = ((0 << 3) + 7), |
+ CMP_SAF = ((1 << 3) + 0), |
+ CMP_SUN = ((1 << 3) + 1), |
+ CMP_SEQ = ((1 << 3) + 2), |
+ CMP_SUEQ = ((1 << 3) + 3), |
+ CMP_SSLT = ((1 << 3) + 4), |
+ CMP_SSULT = ((1 << 3) + 5), |
+ CMP_SLE = ((1 << 3) + 6), |
+ CMP_SULE = ((1 << 3) + 7), |
// COP1 CMP negative predicates Bit 5..4 = 01. |
- CMP_AT = ((2 << 3) + 0), // Reserved, not implemented. |
- CMP_OR = ((2 << 3) + 1), |
- CMP_UNE = ((2 << 3) + 2), |
- CMP_NE = ((2 << 3) + 3), |
- CMP_UGE = ((2 << 3) + 4), // Reserved, not implemented. |
- CMP_OGE = ((2 << 3) + 5), // Reserved, not implemented. |
- CMP_UGT = ((2 << 3) + 6), // Reserved, not implemented. |
- CMP_OGT = ((2 << 3) + 7), // Reserved, not implemented. |
- CMP_SAT = ((3 << 3) + 0), // Reserved, not implemented. |
- CMP_SOR = ((3 << 3) + 1), |
- CMP_SUNE = ((3 << 3) + 2), |
- CMP_SNE = ((3 << 3) + 3), |
- CMP_SUGE = ((3 << 3) + 4), // Reserved, not implemented. |
- CMP_SOGE = ((3 << 3) + 5), // Reserved, not implemented. |
- CMP_SUGT = ((3 << 3) + 6), // Reserved, not implemented. |
- CMP_SOGT = ((3 << 3) + 7), // Reserved, not implemented. |
- |
- SEL = ((2 << 3) + 0), |
- SELEQZ_C = ((2 << 3) + 4), // COP1 on FPR registers. |
- SELNEZ_C = ((2 << 3) + 7), // COP1 on FPR registers. |
+ CMP_AT = ((2 << 3) + 0), // Reserved, not implemented. |
+ CMP_OR = ((2 << 3) + 1), |
+ CMP_UNE = ((2 << 3) + 2), |
+ CMP_NE = ((2 << 3) + 3), |
+ CMP_UGE = ((2 << 3) + 4), // Reserved, not implemented. |
+ CMP_OGE = ((2 << 3) + 5), // Reserved, not implemented. |
+ CMP_UGT = ((2 << 3) + 6), // Reserved, not implemented. |
+ CMP_OGT = ((2 << 3) + 7), // Reserved, not implemented. |
+ CMP_SAT = ((3 << 3) + 0), // Reserved, not implemented. |
+ CMP_SOR = ((3 << 3) + 1), |
+ CMP_SUNE = ((3 << 3) + 2), |
+ CMP_SNE = ((3 << 3) + 3), |
+ CMP_SUGE = ((3 << 3) + 4), // Reserved, not implemented. |
+ CMP_SOGE = ((3 << 3) + 5), // Reserved, not implemented. |
+ CMP_SUGT = ((3 << 3) + 6), // Reserved, not implemented. |
+ CMP_SOGT = ((3 << 3) + 7), // Reserved, not implemented. |
+ |
+ SEL = ((2 << 3) + 0), |
+ SELEQZ_C = ((2 << 3) + 4), // COP1 on FPR registers. |
+ SELNEZ_C = ((2 << 3) + 7), // COP1 on FPR registers. |
// COP1 Encoding of Function Field When rs=PS. |
// COP1X Encoding of Function Field. |
- MADD_D = ((4 << 3) + 1), |
+ MADD_D = ((4 << 3) + 1), |
- NULLSF = 0 |
+ NULLSF = 0 |
}; |