Temporarily reordering instructions for compatibility

This commit is contained in:
Wolfgang Bumiller 2012-07-16 12:43:12 +02:00
parent 531d291216
commit 3943e27ebb

67
gmqcc.h
View file

@ -467,10 +467,6 @@ enum {
INSTR_MUL_V,
INSTR_MUL_VF,
INSTR_MUL_FV,
INSTR_MUL_Q,
INSTR_MUL_QF,
INSTR_MUL_M,
INSTR_MUL_MF,
INSTR_DIV_F,
INSTR_ADD_F,
INSTR_ADD_V,
@ -481,15 +477,11 @@ enum {
INSTR_EQ_S,
INSTR_EQ_E,
INSTR_EQ_FNC,
INSTR_EQ_Q,
INSTR_EQ_M,
INSTR_NE_F,
INSTR_NE_V,
INSTR_NE_S,
INSTR_NE_E,
INSTR_NE_FNC,
INSTR_NE_Q,
INSTR_NE_M,
INSTR_LE,
INSTR_GE,
INSTR_LT,
@ -500,8 +492,6 @@ enum {
INSTR_LOAD_ENT,
INSTR_LOAD_FLD,
INSTR_LOAD_FNC,
INSTR_LOAD_Q,
INSTR_LOAD_M,
INSTR_ADDRESS,
INSTR_STORE_F,
INSTR_STORE_V,
@ -509,24 +499,18 @@ enum {
INSTR_STORE_ENT,
INSTR_STORE_FLD,
INSTR_STORE_FNC,
INSTR_STORE_Q,
INSTR_STORE_M,
INSTR_STOREP_F,
INSTR_STOREP_V,
INSTR_STOREP_S,
INSTR_STOREP_ENT,
INSTR_STOREP_FLD,
INSTR_STOREP_FNC,
INSTR_STOREP_Q,
INSTR_STOREP_M,
INSTR_RETURN,
INSTR_NOT_F,
INSTR_NOT_V,
INSTR_NOT_S,
INSTR_NOT_ENT,
INSTR_NOT_FNC,
INSTR_INV_Q,
INSTR_INV_M,
INSTR_IF,
INSTR_IFNOT,
INSTR_CALL0,
@ -545,6 +529,23 @@ enum {
INSTR_BITAND,
INSTR_BITOR,
/* warning: will be reordered */
INSTR_MUL_Q,
INSTR_MUL_QF,
INSTR_MUL_M,
INSTR_MUL_MF,
INSTR_EQ_Q,
INSTR_EQ_M,
INSTR_NE_Q,
INSTR_NE_M,
INSTR_LOAD_Q,
INSTR_LOAD_M,
INSTR_STORE_Q,
INSTR_STORE_M,
INSTR_STOREP_Q,
INSTR_STOREP_M,
INSTR_INV_Q,
INSTR_INV_M,
/*
* Virtual instructions used by the assembler
* keep at the end but before virtual instructions
@ -602,10 +603,6 @@ static const struct {
{ "MUL_V" , 3, 5 },
{ "MUL_VF" , 3, 6 },
{ "MUL_FV" , 3, 6 },
{ "MUL_Q" , 3, 5 },
{ "MUL_QF" , 3, 6 },
{ "MUL_M" , 3, 5 },
{ "MUL_MF" , 3, 6 },
{ "DIV" , 0, 3 },
{ "ADD_F" , 3, 5 },
{ "ADD_V" , 3, 5 },
@ -616,15 +613,11 @@ static const struct {
{ "EQ_S" , 0, 4 },
{ "EQ_E" , 0, 4 },
{ "EQ_FNC" , 0, 6 },
{ "EQ_Q" , 0, 4 },
{ "EQ_M" , 0, 4 },
{ "NE_F" , 0, 4 },
{ "NE_V" , 0, 4 },
{ "NE_S" , 0, 4 },
{ "NE_E" , 0, 4 },
{ "NE_FNC" , 0, 6 },
{ "NE_Q" , 0, 4 },
{ "NE_M" , 0, 4 },
{ "LE" , 0, 2 },
{ "GE" , 0, 2 },
{ "LT" , 0, 2 },
@ -635,8 +628,6 @@ static const struct {
{ "FIELD_ENT" , 0, 9 },
{ "FIELD_FLD" , 0, 9 },
{ "FIELD_FNC" , 0, 9 },
{ "FIELD_Q" , 0, 7 },
{ "FIELD_M" , 0, 7 },
{ "ADDRESS" , 0, 7 },
{ "STORE_F" , 0, 7 },
{ "STORE_V" , 0, 7 },
@ -644,24 +635,18 @@ static const struct {
{ "STORE_ENT" , 0, 9 },
{ "STORE_FLD" , 0, 9 },
{ "STORE_FNC" , 0, 9 },
{ "STORE_Q" , 0, 7 },
{ "STORE_M" , 0, 7 },
{ "STOREP_F" , 0, 8 },
{ "STOREP_V" , 0, 8 },
{ "STOREP_S" , 0, 8 },
{ "STOREP_ENT", 0, 10},
{ "STOREP_FLD", 0, 10},
{ "STOREP_FNC", 0, 10},
{ "STOREP_Q" , 0, 8 },
{ "STOREP_M" , 0, 8 },
{ "RETURN" , 0, 6 },
{ "NOT_F" , 0, 5 },
{ "NOT_V" , 0, 5 },
{ "NOT_S" , 0, 5 },
{ "NOT_ENT" , 0, 7 },
{ "NOT_FNC" , 0, 7 },
{ "INV_Q" , 0, 5 },
{ "INV_M" , 0, 5 },
{ "IF" , 0, 2 },
{ "IFNOT" , 0, 5 },
{ "CALL0" , 1, 5 },
@ -679,6 +664,24 @@ static const struct {
{ "OR" , 0, 2 },
{ "BITAND" , 0, 6 },
{ "BITOR" , 0, 5 },
{ "MUL_Q" , 3, 5 },
{ "MUL_QF" , 3, 6 },
{ "MUL_M" , 3, 5 },
{ "MUL_MF" , 3, 6 },
{ "EQ_Q" , 0, 4 },
{ "EQ_M" , 0, 4 },
{ "NE_Q" , 0, 4 },
{ "NE_M" , 0, 4 },
{ "FIELD_Q" , 0, 7 },
{ "FIELD_M" , 0, 7 },
{ "STORE_Q" , 0, 7 },
{ "STORE_M" , 0, 7 },
{ "STOREP_Q" , 0, 8 },
{ "STOREP_M" , 0, 8 },
{ "INV_Q" , 0, 5 },
{ "INV_M" , 0, 5 },
{ "END" , 0, 3 } /* virtual assembler instruction */
};