Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!cmcl2!adm!xadmx!rbj@dsys.ncsl.nist.gov From: rbj@dsys.ncsl.nist.gov (Root Boy Jim) Newsgroups: comp.unix.wizards Subject: What kinds of things would you want in the GNU OS? Message-ID: <19849@adm.BRL.MIL> Date: 2 Jun 89 21:53:26 GMT Sender: news@adm.BRL.MIL Lines: 29 ? From: Peter da Silva ? In article <19835@adm.BRL.MIL>, rbj@dsys.ncsl.nist.gov (Root Boy Jim) writes: ? > BTW, I agree with you that threads need not duplicate the stack. ? > It doesn't seem to make much sense what happens when a thread ? > returns/exits. However, I would rather see the kernel/library ? > push the address of thread_exit on the stack. Eliminates one argument. ? What if you want to do more stuff in your cleanup routine? This routine ? would also be called if the thread called exit(). Then have your thread do it explicitly, just like main does. Or if you insist, have thread_exit honor exit callbacks, similar to how on_exit does. Better yet, push the address of thread_die_horribly() on the stack and require that the thread exits explicitly. Require that main() exit explicitly by hacking startup to dump core on return from main. ? Actually, I'd like to be able to pass more stuff to thread(), such as maybe ? a mask of resources to be shared...? Share everything that fork does. Close/release what you don't want. ? Peter da Silva, Xenix Support, Ferranti International Controls Corporation. ? Business: uunet.uu.net!ficc!peter, peter@ficc.uu.net, +1 713 274 5180. ? Personal: ...!texbell!sugar!peter, peter@sugar.hackercorp.com. Root Boy Jim is what I am Are you what you are or what?