上QQ阅读APP看书,第一时间看更新
Thread local storage
Thread local storage (TLS) with Windows threads is similar to Pthreads in that a central key (TLS index) has to be created first after which individual threads can use that global index to store and retrieve local values.
Like with Pthreads, this involves a similar amount of manual memory management, as the TLS value has to be allocated and deleted by hand.