kolibrios-fun/kernel/branches/gfx_kernel/boot/drawtext.inc
Mihail Semenyako (mike.dld) e3172037f7 Added gfx_kernel branch
git-svn-id: svn://kolibrios.org@129 a494cfbc-eb01-0410-851d-a64ba20cac60
2006-08-14 21:38:03 +00:00

45 lines
538 B
PHP

substr:
push si di cx
movzx cx,byte[ds:si-1]
@@: mov al,[ds:si]
cmp al,[es:di]
jne @f
inc si
inc di
dec cx
jnz @b
; cld
; repe cmps byte[ds:si],[es:di]
@@: pop cx di si
ret
int2str:
dec bl
jz @f
xor edx,edx
div ecx
push edx
call int2str
pop eax
@@: cmp al,10
sbb al,$69
das
mov [ds:di],al
inc di
ret
int2strnz:
cmp eax,ecx
jb @f
xor edx,edx
div ecx
push edx
call int2strnz
pop eax
@@: cmp al,10
sbb al,$69
das
mov [ds:di],al
inc di
ret