Thread specific storage across platform Unix/NT/OS2/Linux ...
Original Publication Date: 2001-Jul-18
Included in the Prior Art Database: 2003-Jun-11
Certain thread specific data applies to all platforms. Each thread has its own pointer to a data structure which is referred by specdata pointer. Because an application can be running in multi-threaded mode, each thread must know how to store and retrieve its pointer. The proposed herein implementation uses a large global array of pointers as storage for all threads. Each thread uses its thread ID to index to this array to set and get the specdata pointer. 1) Overload system new, delete, malloc ... The malloc, strdup, and free commands are redefined to dtw_mem_malloc, dtw_mem_strdup, dtw_mem_free.These symbols are exported from dtwmem.dll