Reintegrate an unnecessary call back to the rest of the code
This commit is contained in:
parent
e6c0ca0937
commit
8c37a1a871
107
gidubba.asm
107
gidubba.asm
|
@ -359,11 +359,54 @@ inline: cleq r0, r0, input
|
|||
xor r0, r0
|
||||
brneq r0, r1, cmdp
|
||||
|
||||
;Save the line
|
||||
cleq r0, r0, save
|
||||
;Restore the buffer start address
|
||||
;High byte
|
||||
load r0, bfstrt
|
||||
store chload + 1, r0
|
||||
;Low byte
|
||||
load r0, bfstrt + 1
|
||||
store chload + 2, r0
|
||||
|
||||
;Insert the next line
|
||||
breq r0, r0, nextln
|
||||
;Store the save address
|
||||
;High byte
|
||||
load r0, eoflod + 1
|
||||
store chsave + 1, r0
|
||||
;Low byte
|
||||
load r0, eoflod + 2
|
||||
store chsave + 2, r0
|
||||
|
||||
;Load and save a character from the buffer
|
||||
;Load
|
||||
chload: load r1, buffer
|
||||
;Save
|
||||
chsave: store buffer + 100, r1
|
||||
|
||||
;Check for line end
|
||||
load r2, #a
|
||||
breq r1, r2, nextln
|
||||
|
||||
;Increment the buffer address
|
||||
;Load the address
|
||||
load r0, chload + 1
|
||||
load r1, chload + 2
|
||||
;Increment
|
||||
cleq r0, r0, incdw
|
||||
;Store the address
|
||||
store chload + 1, r0
|
||||
store chload + 2, r1
|
||||
|
||||
;Increment the save address
|
||||
;Load the address
|
||||
load r0, chsave + 1
|
||||
load r1, chsave + 2
|
||||
;Increment
|
||||
cleq r0, r0, incdw
|
||||
;Store the address
|
||||
store chsave + 1, r0
|
||||
store chsave + 2, r1
|
||||
|
||||
;Load and save the next character
|
||||
breq r0, r0, chload
|
||||
|
||||
inesc: load r0, #20
|
||||
store ffff, r0
|
||||
|
@ -1640,62 +1683,6 @@ lmterr: load r0, #21
|
|||
|
||||
;***
|
||||
|
||||
;Save the line
|
||||
|
||||
;Restore the buffer start address
|
||||
;High byte
|
||||
save: load r0, bfstrt
|
||||
store chload + 1, r0
|
||||
;Low byte
|
||||
load r0, bfstrt + 1
|
||||
store chload + 2, r0
|
||||
|
||||
;Store the save address
|
||||
;High byte
|
||||
load r0, eoflod + 1
|
||||
store chsave + 1, r0
|
||||
;Low byte
|
||||
load r0, eoflod + 2
|
||||
store chsave + 2, r0
|
||||
|
||||
;Load and save a character from the buffer
|
||||
;Load
|
||||
chload: load r1, buffer
|
||||
;Save
|
||||
chsave: store buffer + 100, r1
|
||||
|
||||
;Check for line end
|
||||
load r2, #a
|
||||
breq r1, r2, savend
|
||||
|
||||
;Increment the buffer address
|
||||
;Load the address
|
||||
load r0, chload + 1
|
||||
load r1, chload + 2
|
||||
;Increment
|
||||
cleq r0, r0, incdw
|
||||
;Store the address
|
||||
store chload + 1, r0
|
||||
store chload + 2, r1
|
||||
|
||||
;Increment the save address
|
||||
;Load the address
|
||||
load r0, chsave + 1
|
||||
load r1, chsave + 2
|
||||
;Increment
|
||||
cleq r0, r0, incdw
|
||||
;Store the address
|
||||
store chsave + 1, r0
|
||||
store chsave + 2, r1
|
||||
|
||||
;Load and save the next character
|
||||
breq r0, r0, chload
|
||||
|
||||
;Return
|
||||
savend: ret
|
||||
|
||||
;***
|
||||
|
||||
;Find the argument line in the save and store its number
|
||||
|
||||
;Check for the argument
|
||||
|
|
Loading…
Reference in New Issue