forgot NOR

This commit is contained in:
Rushil Umaretiya 2024-03-22 17:22:44 -04:00
parent f1740fd228
commit c803957d8f
No known key found for this signature in database
GPG Key ID: 4E8FAF9C926AF959

View File

@ -95,6 +95,9 @@ void execute_r_instruction(r_instruction* instruct) {
registers[instruct->rd] =
registers[instruct->rs] | registers[instruct->rt];
break;
case NOR_FUNC:
registers[instruct->rd] =
~(registers[instruct->rs] | registers[instruct->rt]);
default:
fprintf(stderr, "Invalid function code!\n");
exit(EXIT_FAILURE);