Initial data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 72d218235f
commit f23f22d71c
199087 changed files with 3378941 additions and 0 deletions

View file

@ -0,0 +1,3 @@
EmptyString:
DC.B 0
EVEN

View file

@ -0,0 +1,14 @@
LEA EmptyString,A0 ;assign the empty string to address register A0
getStringLength:
MOVE.L A0,-(SP) ;push A0 onto the stack. This will be used to check if the string is empty.
loop_getStringLength:
MOVE.B (A0)+,D0
BEQ Terminated
JMP loop_getStringLength
SUBQ.L #1,A0 ;after the terminator is read, A0 is incremented to point to the byte after it. This fixes that.
CMP.L A0,(SP) ;compare the current A0 with the original value.
BEQ StringIsEmpty ;if they are equal, then nothing was read besides the terminator. Therefore the string is empty.
;if the above branch wasn't taken, the string is not empty and execution arrives here.