mirror of
https://github.com/Comp211-SP24/lab-04-Rushilwiz.git
synced 2025-04-09 14:50:16 -04:00
forgot NOR
This commit is contained in:
parent
f1740fd228
commit
c803957d8f
3
lab04.c
3
lab04.c
|
@ -95,6 +95,9 @@ void execute_r_instruction(r_instruction* instruct) {
|
||||||
registers[instruct->rd] =
|
registers[instruct->rd] =
|
||||||
registers[instruct->rs] | registers[instruct->rt];
|
registers[instruct->rs] | registers[instruct->rt];
|
||||||
break;
|
break;
|
||||||
|
case NOR_FUNC:
|
||||||
|
registers[instruct->rd] =
|
||||||
|
~(registers[instruct->rs] | registers[instruct->rt]);
|
||||||
default:
|
default:
|
||||||
fprintf(stderr, "Invalid function code!\n");
|
fprintf(stderr, "Invalid function code!\n");
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user