1 /* Copyright (C) 1991, 1992, 1993, 1995 Free Software Foundation, Inc.
2 This file is part of the GNU C Library.
4 The GNU C Library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public License as
6 published by the Free Software Foundation; either version 2 of the
7 License, or (at your option) any later version.
9 The GNU C Library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Library General Public License for more details.
14 You should have received a copy of the GNU Library General Public
15 License along with the GNU C Library; see the file COPYING.LIB. If
16 not, write to the Free Software Foundation, Inc., 675 Mass Ave,
17 Cambridge, MA 02139, USA. */
21 /* <sysdeps/unix/bsd/sequent/i386/sysdep.h> defines this to put the first
22 two arguments into registers. Since the arguments to wait3 are
23 transferred magically through the same registers, we want to disable this.
24 This allows us to avoid rewriting this file for that system. */
27 #define ARGS_2 /* Special-case no-op. */
33 mov 8(%esp), %ecx /* Flags. */
34 mov 12(%esp), %edx /* rusage pointer. */
35 pushl $0xdf; popf /* Set all the condition codes. */
36 DO_CALL (wait, 2) /* Do the system call. */
37 je syscall_error /* Check for error. */
38 mov 4(%esp), scratch /* Status pointer. */
39 orl scratch, scratch /* Is it nil? */
40 je done /* Yup; return. */
41 mov r1, 0(scratch) /* Non-nil; store the status in it. */
44 weak_alias (__wait3, wait3)