According to
https://bitsavers.org/pdf/dec/pdp11/1170/PDP-11_70_Handbook_1977-78.pdf page 64 (4-24): "N: set if high-order bit of low-order byte (bit 7) of result is set; cleared otherwise"
This commit is contained in:
parent
899e2a00ea
commit
b018d4bf06
1 changed files with 1 additions and 1 deletions
2
op000.py
2
op000.py
|
@ -83,7 +83,7 @@ def op_swab(cpu, inst):
|
|||
val, xb6 = cpu.operandx(inst & 0o77, rmw=True)
|
||||
|
||||
val = ((val >> 8) & cpu.MASK8) | ((val & cpu.MASK8) << 8)
|
||||
cpu.psw_n = val & cpu.SIGN16
|
||||
cpu.psw_n = val & cpu.SIGN8
|
||||
|
||||
# note this screwy definition, per the handbook
|
||||
cpu.psw_z = ((val & cpu.MASK8) == 0)
|
||||
|
|
Loading…
Add table
Reference in a new issue