This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: pthread_sigqueue{_np} ??
- To: Bharadwaj Yadavalli <bharadwaj dot yadavalli at compaq dot com>
- Subject: Re: pthread_sigqueue{_np} ??
- From: Mark Brown <bmark at us dot ibm dot com>
- Date: Fri, 09 Feb 2001 10:15:51 -0600
- CC: <libc-alpha at sourceware dot cygnus dot com>
Bharadwaj Yadavalli wrote on 08/02/01 3:52 PM:
> >Why do you want to do this?
>
> I need to stop the threads in a JVM (that I am porting to
> Linux) to do things like garbage collection. Basically I
> need to suspend and resume a given thread for this
> purpose. I'd like the suspend/resume signals to be queued
> rather than encountering a possible signal "merge" by using
> kill.
Some OSes (AIX and Solaris) implemented thread suspend/resume APIs for
just this purpose, even though they are not required by POSIX or the SUS.
It's better than shooting signals to threads (but use of these has its
own risks). I'm pretty sure LinuxThreads will let you send a SIGSTOP/
SIGCONT with pthread_kill (at your own risk).
--
Mark S. Brown bmark@us.ibm.com
Senior Technical Staff Member 512.838.3926 T/L678.3926
AIX and Linux Technologies Mark Brown/Austin/IBM
IBM Corporation, Austin, Texas