{
int cf, pf, af, zf, sf, of;
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
cf = (DATA_TYPE)src1 < (DATA_TYPE)src2;
pf = parity_table[(uint8_t)CC_DST];
af = (CC_DST ^ src1 ^ src2) & 0x10;
static int glue(compute_c_sub, SUFFIX)(void)
{
int src1, src2, cf;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
cf = (DATA_TYPE)src1 < (DATA_TYPE)src2;
return cf;
}
{
int cf, pf, af, zf, sf, of;
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST - 1;
+ src1 = CC_DST + CC_SRC + 1;
+ src2 = CC_SRC;
cf = (DATA_TYPE)src1 <= (DATA_TYPE)src2;
pf = parity_table[(uint8_t)CC_DST];
af = (CC_DST ^ src1 ^ src2) & 0x10;
static int glue(compute_c_sbb, SUFFIX)(void)
{
int src1, src2, cf;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST - 1;
+ src1 = CC_DST + CC_SRC + 1;
+ src2 = CC_SRC;
cf = (DATA_TYPE)src1 <= (DATA_TYPE)src2;
return cf;
}
void OPPROTO glue(op_jb_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
if ((DATA_TYPE)src1 < (DATA_TYPE)src2)
JUMP_TB(PARAM1, 0, PARAM2);
void OPPROTO glue(op_jbe_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
if ((DATA_TYPE)src1 <= (DATA_TYPE)src2)
JUMP_TB(PARAM1, 0, PARAM2);
void OPPROTO glue(op_jl_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
if ((DATA_STYPE)src1 < (DATA_STYPE)src2)
JUMP_TB(PARAM1, 0, PARAM2);
void OPPROTO glue(op_jle_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
if ((DATA_STYPE)src1 <= (DATA_STYPE)src2)
JUMP_TB(PARAM1, 0, PARAM2);
void OPPROTO glue(op_setb_T0_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
T0 = ((DATA_TYPE)src1 < (DATA_TYPE)src2);
}
void OPPROTO glue(op_setbe_T0_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
T0 = ((DATA_TYPE)src1 <= (DATA_TYPE)src2);
}
void OPPROTO glue(op_setl_T0_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
T0 = ((DATA_STYPE)src1 < (DATA_STYPE)src2);
}
void OPPROTO glue(op_setle_T0_sub, SUFFIX)(void)
{
int src1, src2;
- src1 = CC_SRC;
- src2 = CC_SRC - CC_DST;
+ src1 = CC_DST + CC_SRC;
+ src2 = CC_SRC;
T0 = ((DATA_STYPE)src1 <= (DATA_STYPE)src2);
}
{
int cf;
cf = cc_table[CC_OP].compute_c();
- CC_SRC = T0;
T0 = T0 + T1 + cf;
- CC_DST = T0;
CC_OP = CC_OP_ADDB + SHIFT + cf * 3;
}
{
int cf;
cf = cc_table[CC_OP].compute_c();
- CC_SRC = T0;
T0 = T0 - T1 - cf;
- CC_DST = T0;
CC_OP = CC_OP_SUBB + SHIFT + cf * 3;
}
void OPPROTO glue(glue(op_cmpxchg, SUFFIX), _T0_T1_EAX_cc)(void)
{
- CC_SRC = EAX;
+ CC_SRC = T0;
CC_DST = EAX - T0;
if ((DATA_TYPE)CC_DST == 0) {
T0 = T1;