get/set/swapcontext + linuxthreads/glibc + MTasker
Ulrich Drepper
drepper@redhat.com
Fri Jan 17 11:33:00 GMT 2003
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
bert hubert wrote:
> Is there a fundamental reason why get/set/swapcontext and linuxthreads bite
> eachother?
In some configurations the stack pointer is used to identify the thread
pointer. Therefore it is impossible to reliably use the *context
functions together with LinuxThreads.
> Would this be a problem for NPTL?
Have you tried it? Me neither, but I don't see a problem.
> Any way to resolve this? Would using 'sigaltstack' help resolve this? Would
> using NPTL solve this?
Don't use sigaltstack in multi-threaded programs. Just think a second
about the desasters which would happen if two signals arrive at the same
time and are handled by different threads.
- --
- --------------. ,-. 444 Castro Street
Ulrich Drepper \ ,-----------------' \ Mountain View, CA 94041 USA
Red Hat `--' drepper at redhat.com `---------------------------
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)
iD8DBQE+J+fw2ijCOnn/RHQRAt/wAJ9NOTSCJBjjuZc2Vfv5gzILzL6FowCfWggb
dKx4GVvcqGLPEQpR4A+/aK0=
=ZvWG
-----END PGP SIGNATURE-----
More information about the Libc-alpha
mailing list