Compare commits

...
10 changed files with 25 additions and 17 deletions
+4 -3
View File
@@ -1370,9 +1370,10 @@ declare 385 {
declare 386 {
void Tcl_SetNotifier(Tcl_NotifierProcs *notifierProcPtr)
}
declare 387 {
Tcl_Mutex *Tcl_GetAllocMutex(void)
}
### Removed from stub table: see [Bug 547989]
#declare 387 {
# Tcl_Mutex *Tcl_GetAllocMutex(void)
#}
declare 388 {
int Tcl_GetChannelNames(Tcl_Interp *interp)
}
+1 -1
View File
@@ -172,7 +172,7 @@ TclInitAlloc(void)
if (!allocInit) {
allocInit = 1;
#ifdef TCL_THREADS
allocMutexPtr = Tcl_GetAllocMutex();
allocMutexPtr = TclpGetAllocMutex();
#endif
}
}
+1 -1
View File
@@ -155,7 +155,7 @@ TclInitDbCkalloc(void)
{
if (!ckallocInit) {
ckallocInit = 1;
ckallocMutexPtr = Tcl_GetAllocMutex();
ckallocMutexPtr = TclpGetAllocMutex();
#ifndef TCL_THREADS
/* Silence compiler warning */
(void)ckallocMutexPtr;
+3 -5
View File
@@ -1116,8 +1116,7 @@ EXTERN int Tcl_RegExpMatchObj(Tcl_Interp *interp,
Tcl_Obj *textObj, Tcl_Obj *patternObj);
/* 386 */
EXTERN void Tcl_SetNotifier(Tcl_NotifierProcs *notifierProcPtr);
/* 387 */
EXTERN Tcl_Mutex * Tcl_GetAllocMutex(void);
/* Slot 387 is reserved */
/* 388 */
EXTERN int Tcl_GetChannelNames(Tcl_Interp *interp);
/* 389 */
@@ -2233,7 +2232,7 @@ typedef struct TclStubs {
void (*tcl_AppendUnicodeToObj) (Tcl_Obj *objPtr, const Tcl_UniChar *unicode, int length); /* 384 */
int (*tcl_RegExpMatchObj) (Tcl_Interp *interp, Tcl_Obj *textObj, Tcl_Obj *patternObj); /* 385 */
void (*tcl_SetNotifier) (Tcl_NotifierProcs *notifierProcPtr); /* 386 */
Tcl_Mutex * (*tcl_GetAllocMutex) (void); /* 387 */
void (*reserved387)(void);
int (*tcl_GetChannelNames) (Tcl_Interp *interp); /* 388 */
int (*tcl_GetChannelNamesEx) (Tcl_Interp *interp, const char *pattern); /* 389 */
int (*tcl_ProcObjCmd) (ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); /* 390 */
@@ -3283,8 +3282,7 @@ extern const TclStubs *tclStubsPtr;
(tclStubsPtr->tcl_RegExpMatchObj) /* 385 */
#define Tcl_SetNotifier \
(tclStubsPtr->tcl_SetNotifier) /* 386 */
#define Tcl_GetAllocMutex \
(tclStubsPtr->tcl_GetAllocMutex) /* 387 */
/* Slot 387 is reserved */
#define Tcl_GetChannelNames \
(tclStubsPtr->tcl_GetChannelNames) /* 388 */
#define Tcl_GetChannelNamesEx \
+3
View File
@@ -1006,6 +1006,9 @@ declare 249 {
declare 250 {
void TclSetSlaveCancelFlags(Tcl_Interp *interp, int flags, int force)
}
declare 251 {
Tcl_Mutex *TclpGetAllocMutex(void)
}
##############################################################################
+5
View File
@@ -610,6 +610,8 @@ EXTERN char * TclDoubleDigits(double dv, int ndigits, int flags,
/* 250 */
EXTERN void TclSetSlaveCancelFlags(Tcl_Interp *interp, int flags,
int force);
/* 251 */
EXTERN Tcl_Mutex * TclpGetAllocMutex(void);
typedef struct TclIntStubs {
int magic;
@@ -866,6 +868,7 @@ typedef struct TclIntStubs {
int (*tclCopyChannel) (Tcl_Interp *interp, Tcl_Channel inChan, Tcl_Channel outChan, Tcl_WideInt toRead, Tcl_Obj *cmdPtr); /* 248 */
char * (*tclDoubleDigits) (double dv, int ndigits, int flags, int *decpt, int *signum, char **endPtr); /* 249 */
void (*tclSetSlaveCancelFlags) (Tcl_Interp *interp, int flags, int force); /* 250 */
Tcl_Mutex * (*tclpGetAllocMutex) (void); /* 251 */
} TclIntStubs;
#ifdef __cplusplus
@@ -1297,6 +1300,8 @@ extern const TclIntStubs *tclIntStubsPtr;
(tclIntStubsPtr->tclDoubleDigits) /* 249 */
#define TclSetSlaveCancelFlags \
(tclIntStubsPtr->tclSetSlaveCancelFlags) /* 250 */
#define TclpGetAllocMutex \
(tclIntStubsPtr->tclpGetAllocMutex) /* 251 */
#endif /* defined(USE_TCL_STUBS) */
+2 -1
View File
@@ -553,6 +553,7 @@ static const TclIntStubs tclIntStubs = {
TclCopyChannel, /* 248 */
TclDoubleDigits, /* 249 */
TclSetSlaveCancelFlags, /* 250 */
TclpGetAllocMutex, /* 251 */
};
static const TclIntPlatStubs tclIntPlatStubs = {
@@ -1161,7 +1162,7 @@ const TclStubs tclStubs = {
Tcl_AppendUnicodeToObj, /* 384 */
Tcl_RegExpMatchObj, /* 385 */
Tcl_SetNotifier, /* 386 */
Tcl_GetAllocMutex, /* 387 */
0, /* 387 */
Tcl_GetChannelNames, /* 388 */
Tcl_GetChannelNamesEx, /* 389 */
Tcl_ProcObjCmd, /* 390 */
+1 -1
View File
@@ -195,7 +195,7 @@ GetCache(void)
Tcl_Mutex *initLockPtr;
unsigned int i;
initLockPtr = Tcl_GetAllocMutex();
initLockPtr = TclpGetAllocMutex();
Tcl_MutexLock(initLockPtr);
if (listLockPtr == NULL) {
listLockPtr = TclpNewAllocMutex();
+3 -3
View File
@@ -360,12 +360,11 @@ TclpMasterUnlock(void)
pthread_mutex_unlock(&masterLock);
#endif
}
/*
*----------------------------------------------------------------------
*
* Tcl_GetAllocMutex
* TclpGetAllocMutex
*
* This procedure returns a pointer to a statically initialized mutex for
* use by the memory allocator. The alloctor must use this lock, because
@@ -382,10 +381,11 @@ TclpMasterUnlock(void)
*/
Tcl_Mutex *
Tcl_GetAllocMutex(void)
TclpGetAllocMutex(void)
{
#ifdef TCL_THREADS
pthread_mutex_t **allocLockPtrPtr = &allocLockPtr;
return (Tcl_Mutex *) allocLockPtrPtr;
#else
return NULL;
+2 -2
View File
@@ -464,7 +464,7 @@ TclpMasterUnlock(void)
/*
*----------------------------------------------------------------------
*
* Tcl_GetAllocMutex
* TclpGetAllocMutex
*
* This procedure returns a pointer to a statically initialized mutex for
* use by the memory allocator. The alloctor must use this lock, because
@@ -481,7 +481,7 @@ TclpMasterUnlock(void)
*/
Tcl_Mutex *
Tcl_GetAllocMutex(void)
TclpGetAllocMutex(void)
{
#ifdef TCL_THREADS
if (!allocOnce) {