Small optimizations in memset and memcpy.
This commit is contained in:
parent
49ffb1065b
commit
0e519e1e58
14
string.asm
14
string.asm
|
@ -303,8 +303,8 @@ rtl equ 1 return address
|
||||||
short M move 1 byte now
|
short M move 1 byte now
|
||||||
lda [p2]
|
lda [p2]
|
||||||
sta [p1]
|
sta [p1]
|
||||||
long M
|
|
||||||
dec len
|
dec len
|
||||||
|
long M
|
||||||
inc4 p1
|
inc4 p1
|
||||||
inc4 p2
|
inc4 p2
|
||||||
lb1 anop endif
|
lb1 anop endif
|
||||||
|
@ -482,19 +482,19 @@ rtl equ 1 return address
|
||||||
|
|
||||||
ph4 <p save the pointer
|
ph4 <p save the pointer
|
||||||
|
|
||||||
short M
|
short I,M
|
||||||
lda val form a 2 byte value
|
ldx val form a 2 byte value
|
||||||
sta val+1
|
stx val+1
|
||||||
|
|
||||||
lda len if there are an odd # of bytes then
|
lda len if there are an odd # of bytes then
|
||||||
lsr A
|
lsr A
|
||||||
bcc lb1
|
bcc lb1
|
||||||
lda val set 1 byte now
|
txa set 1 byte now
|
||||||
sta [p]
|
sta [p]
|
||||||
long M
|
|
||||||
dec len
|
dec len
|
||||||
|
long I,M
|
||||||
inc4 p
|
inc4 p
|
||||||
lb1 long M endif
|
lb1 long I,M endif
|
||||||
|
|
||||||
lda val set len bytes
|
lda val set len bytes
|
||||||
ldx len+2 set full banks
|
ldx len+2 set full banks
|
||||||
|
|
Loading…
Reference in New Issue