|
|
@ -11,3 +11,13 @@ memcpy:: |
|
|
|
dec d |
|
|
|
jr nz, memcpy |
|
|
|
ret |
|
|
|
|
|
|
|
; Fills a memory region with a value |
|
|
|
; @param hl Pointer to the destination region |
|
|
|
; @param a Byte to fill with |
|
|
|
; @param c Number of bytes to fill. Must be >0 |
|
|
|
memset:: |
|
|
|
ld [hli], a |
|
|
|
dec c |
|
|
|
jr nz, memset |
|
|
|
ret |