summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/dietlibc/i386/strcat.S
blob: e7d74ef13a4c15d4f30959d7a35930dde15e3439 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
.text
.align 0 
.global strcat
.type	 strcat,@function
strcat:
	pushl %edi
	pushl %esi

	movl 12(%esp), %edi
	movl 16(%esp), %esi

	pushl %edi

	xorl %eax, %eax
	xorl %ecx, %ecx
	decl %ecx
	repne scasb
	decl %edi
	
.Lloop:
	lodsb
	stosb
	testb %al, %al
	jnz .Lloop
	
	popl %eax
	popl %esi
	popl %edi
	ret