summaryrefslogtreecommitdiff
path: root/sux.c
diff options
context:
space:
mode:
authormrb0nk500 <b0nk@b0nk.xyz>2020-10-05 08:47:08 -0400
committermrb0nk500 <b0nk@b0nk.xyz>2020-10-05 08:47:08 -0400
commit96ae48f8a79f33cff0a89fac211b6862866e1a44 (patch)
tree885ba3a75da7b3f711cabce8c7590e8430104075 /sux.c
parentca8e2f93acc794b00464c5513956bd84de258913 (diff)
- Added a routine for testing the SuB Suite's
implementation of free(), although it's commented out. - Removed the sbc() function from the emulator, since sbc can be done by just inverting the second operand of adc.
Diffstat (limited to 'sux.c')
-rw-r--r--sux.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sux.c b/sux.c
index daabdc2..acd834e 100644
--- a/sux.c
+++ b/sux.c
@@ -286,7 +286,7 @@ void *run(void *args) {
case SBC_IMM: /* SBC Immediate. */
case SBC_AB: /* SBC Absolute. */
case SBC_Z: /* SBC Zero Matrix. */
- cpu->a = sbc(cpu, cpu->a, value.u64, thread);
+ cpu->a = adc(cpu, cpu->a, ~value.u64, thread);
break;
case PLP_IMP: cpu->ps.u8[thread] = pull(cpu, 0, thread); break; /* PuLl Processor status from stack. */
case PLA_IMP: cpu->a = pull(cpu, size, thread); break; /* PuLl Accumulator from stack. */