This is the mail archive of the cygwin-developers@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

pthread_key_create and friends


I have a working implementation of pthread_key_create,
pthread_key_delete, pthread_getspecific and pthread_setspecific.

I'm using Tls index entries (as they are a precise match for the
functionality needed).. the problem is there are only 64 available for
each process under win32 (until windows 2000).

I note that 3/4 index entries are used by existing code in cygwin...

my question is, how many is a reasonable number to allocate for
pthreads? (The spec requires a #define to be set, which we won't want to
change very often.) My code will return error codes if all the slots are
used, but it would be better to avoid using all the slots..

For my test code I've set the max amount of indexs avaliable to
pthread_key functions at 32 - is 28 remaining index entries to few for
future expansion? We should allow as many as possible for the
pthread_key functions...


Rob


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]