]> mj.ucw.cz Git - libucw.git/commit
Use thread-local storage of GCC 4.x
authorMartin Mares <mj@ucw.cz>
Thu, 22 Jul 2010 13:32:49 +0000 (15:32 +0200)
committerMartin Mares <mj@ucw.cz>
Thu, 22 Jul 2010 13:32:49 +0000 (15:32 +0200)
commit30680da0fe1192be08f2ff02d912e3b8a0f1212f
treeb2a5a227ec7289c7a2e8d4d349164c392ad1ab35
parent404b915049ad455039f133bf9ad7cfd8708b1ebc
Use thread-local storage of GCC 4.x

ucw/threads.c can now work in three different modes:

   o  non-threaded
   o  threaded with context in pthread per-thread storage
   o  threaded with context stored as __thread

I had to make a backward-incompatible change: ucwlib_context->thread_id
is no longer accessible directly (because I do not know of any way how
to initialize it in the __thread mode) and a wrapper function should
be used.
ucw/default.cfg
ucw/perl/UCW/Configure/LibUCW.pm
ucw/threads.c
ucw/threads.h