summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/dietlibc/sparc/pipe.S
blob: b8ad1d25135c0079d31c184a719575feeeaac3bf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include "syscalls.h"

.text
.global pipe
pipe:
	mov	__NR_pipe, %g1
	ta 0x10
	bcc,a	.Lnoerror
	nop
	save	%sp, -96, %sp
	call	__errno_location
	nop
	st	%i0, [ %o0 ]
	ret
	restore	%g0, -1, %o0
.Lnoerror:
	st	%o0, [ %o2 ]
	st	%o1, [ %o2 + 4 ]
	retl
	mov	%g0, %o0