pthread_sigqueue{_np} ??
Mark Brown
bmark@us.ibm.com
Fri Feb 9 10:30:00 GMT 2001
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
More information about the Libc-alpha
mailing list