Fixed simulation bug: JGE/JL reversed.
This commit is contained in:
parent
626b0085a0
commit
b897d780c1
4
sim.c
4
sim.c
|
@ -388,12 +388,12 @@ static int step_jump(struct sim_device *dev, uint16_t ins)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case MSP430_OP_JGE:
|
case MSP430_OP_JGE:
|
||||||
sr = ((sr & MSP430_SR_N) ? 1 : 0) !=
|
sr = ((sr & MSP430_SR_N) ? 1 : 0) ==
|
||||||
((sr & MSP430_SR_V) ? 1 : 0);
|
((sr & MSP430_SR_V) ? 1 : 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case MSP430_OP_JL:
|
case MSP430_OP_JL:
|
||||||
sr = ((sr & MSP430_SR_N) ? 1 : 0) ==
|
sr = ((sr & MSP430_SR_N) ? 1 : 0) !=
|
||||||
((sr & MSP430_SR_V) ? 1 : 0);
|
((sr & MSP430_SR_V) ? 1 : 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue