commit 75af0e3cad07c28852f28d05c5d91086e038d94c
parent c4856aabf031e8011eddc225256fe6f4bf743f18
Author: Devine Lu Linvega <aliceffekt@gmail.com>
Date: Wed, 8 Mar 2023 09:25:55 -0800
Removed redundant mask in SFT opcode
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/uxn-fast.c b/src/uxn-fast.c
@@ -119,8 +119,8 @@ uxn_eval(Uxn *u, Uint16 pc)
case 0x1d: /* ORA */ t=T;n=N; SET(2,-1) PUT(0, n | t) break;
case 0x3e: /* EOR2 */ t=T2;n=N2; SET(4,-2) PUT2(0, n ^ t) break;
case 0x1e: /* EOR */ t=T;n=N; SET(2,-1) PUT(0, n ^ t) break;
- case 0x3f: /* SFT2 */ t=T;n=H2; SET(3,-1) PUT2(0, n >> (t & 0x0f) << ((t & 0xf0) >> 4)) break;
- case 0x1f: /* SFT */ t=T;n=N; SET(2,-1) PUT(0, n >> (t & 0x0f) << ((t & 0xf0) >> 4)) break;
+ case 0x3f: /* SFT2 */ t=T;n=H2; SET(3,-1) PUT2(0, n >> (t & 0x0f) << (t >> 4)) break;
+ case 0x1f: /* SFT */ t=T;n=N; SET(2,-1) PUT(0, n >> (t & 0x0f) << (t >> 4)) break;
}
}
}