remove ORR instruction

This commit is contained in:
Arthur Lu
2022-08-20 00:33:07 -07:00
parent ca7bf9fc6e
commit 218445e20c
6 changed files with 5 additions and 10 deletions

View File

@@ -35,7 +35,7 @@ op_type = {
'CLB': 'G',
'ADD': 'A',
#'SUB': 'A',
'ORR': 'A',
#'ORR': 'A',
'AND': 'A',
'LSH': 'T',
'PTY': 'G',
@@ -58,7 +58,7 @@ op_codes = {
'CLB': 0b0_0011_1000,
'ADD': 0b0_0100_0000,
#'SUB': 0b0_0101_0000,
'ORR': 0b0_0110_0000,
#'ORR': 0b0_0110_0000,
'AND': 0b0_0111_0000,
'LSH': 0b0_1000_0000,
'PTY': 0b0_1000_1000,

View File

@@ -56,7 +56,7 @@ lfsr_routine: GET r7 // get previous state
PUT r1 // store feedback bit to r1 temporarily
GET r7 // get previous state again
LSH #d1 // left shift previous state by 1
ORR r1 // or with parity bit to get next state
XOR r1 // or with parity bit to get next state
PUT r7 // put next state to r7
GET r14 // load link register
JMP r0 // return to function call address

View File

@@ -98,7 +98,7 @@ lfsr_routine: GET r7 // get previous state
PUT r1 // store feedback bit to r1 temporarily
GET r7 // get previous state again
LSH #d1 // left shift previous state by 1
ORR r1 // or with parity bit to get next state
XOR r1 // or with parity bit to get next state
PUT r7 // put next state to r7
GET r14 // load link register
JMP r0 // return to function call address

View File

@@ -139,7 +139,7 @@ lfsr_routine: GET r7 // get previous state
PUT r1 // store feedback bit to r1 temporarily
GET r7 // get previous state again
LSH #d1 // left shift previous state by 1
ORR r1 // or with parity bit to get next state
XOR r1 // or with parity bit to get next state
PUT r7 // put next state to r7
GET r14 // load link register
JMP r0 // return to function call address