xref: /original-bsd/lib/libc/vax/sys/cache.lib/fork.c (revision 4092c5cc)
1 /*-
2  * Copyright (c) 1983, 1993
3  *	The Regents of the University of California.  All rights reserved.
4  *
5  * %sccs.include.redist.c%
6  */
7 
8 #if defined(LIBC_SCCS) && !defined(lint)
9 	.asciz "@(#)fork.c	8.1 (Berkeley) 06/04/93"
10 #endif /* LIBC_SCCS and not lint */
11 
12 #include "SYS.h"
13 
14 	.globl	mypid, myppid
15 
16 SYSCALL(fork)
17 	jlbc	r1,1f	# parent, since r1 == 0 in parent, 1 in child
18 	movl	r0,myppid
19 	clrl	mypid
20 	clrl	r0
21 1:
22 	ret		# pid = fork()
23