677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
|
}
#ifdef TCL_THREADS
/*
* Additions by AOL for specialized thread memory allocator.
*/
#ifdef USE_THREAD_ALLOC
static volatile int initialized = 0;
static pthread_key_t key;
typedef struct allocMutex {
Tcl_Mutex tlock;
pthread_mutex_t plock;
} allocMutex;
|
<
|
677
678
679
680
681
682
683
684
685
686
687
688
689
690
|
}
#ifdef TCL_THREADS
/*
* Additions by AOL for specialized thread memory allocator.
*/
static volatile int initialized = 0;
static pthread_key_t key;
typedef struct allocMutex {
Tcl_Mutex tlock;
pthread_mutex_t plock;
} allocMutex;
|
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
|
void
TclpSetAllocCache(
void *arg)
{
pthread_setspecific(key, arg);
}
#endif
#endif /* USE_THREAD_ALLOC */
void *
TclpThreadCreateKey(void)
{
pthread_key_t *ptkeyPtr;
ptkeyPtr = TclpSysAlloc(sizeof *ptkeyPtr, 0);
|
<
|
757
758
759
760
761
762
763
764
765
766
767
768
769
770
|
void
TclpSetAllocCache(
void *arg)
{
pthread_setspecific(key, arg);
}
#endif
void *
TclpThreadCreateKey(void)
{
pthread_key_t *ptkeyPtr;
ptkeyPtr = TclpSysAlloc(sizeof *ptkeyPtr, 0);
|