.po 1i
.TH GETPID 2 Bell
.V 08/15/84 17:13:33
.\" @[$]getpid.2	1.7 08/15/84 17:13:33 - Zilog Inc.
.SH NAME
getpid, - get process \s-1ID\s+1s
.br
getpgrp \- get group process  \s-1ID\s+1s
.br
getppid \- get parent process \s-1ID\s+1s
.SH SYNOPSIS
.B int getpid( )
.br
.B int getpgrp( )
.br
.B int getppid( )
.SH DESCRIPTION
.B Getpid
returns the process ID of the calling process.
.PP
.B Getpgrp
returns the process group
.SM ID
of the calling process.
.PP
.B Getppid
returns the parent process
.SM ID
of the calling process.
.SH SEE ALSO
exec(2), fork(2), intro(2), setpgrp(2), signal(2), mktemp(3).
.SH ASSEMBLER
.nf
.na
	CONSTANT GETPID := 20

	...		
	sc	#GETPID
	...	!* pid returned in r4, carry flag set if error *!
		!* parent pid in r5 *!

	CONSTANT SEGPGRP := 39

	...
	sc	#SEGPGRP
	...	!* process group id in r4 *!
.fi
.ad
