This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Decrease number of threads used by goroutines.go test (take 2)
Jakub Jelinek <jakub@redhat.com> writes:
>> Why should this be Linux-specific? I think the same logic applies
>> everywhere.
>
> Because ulimit -u is Linux specific? At least, google doesn't show any
> hints about any other OSes having such limit, neither RLIMIT_NPROC nor
> ulimit -u.
At best, it's shell-specific: Solaris 11 /bin/sh (which is ksh93) does
have it, although admittedly previous Solaris/IRIX/Tru64 UNIX shells
don't. On the other hand, bash has it on all of those systems.
Why not simply test if ulimit -u doesn't error and then use it? I'd
very much prefer this to a solution that is unnecessarily OS-specific.
Thanks.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University