Шаблон thread-local storage





The cleanup functions are called in an unspecified order. If a cleanup routine sets the value of associated with an instance of boost::thread_specific_ptr that has already been cleaned up, that value is added to the cleanup list. However, in order to use an alias template, two %template directives must be used: %template(SomeTypeBool) SomeType; %template() TypedefName; Firstly, the actual template is instantiated with a name to be used by the target language, as per any template being wrapped. When the address-of operator is applied to a thread-local variable, it is evaluated at run-time and returns the address of the current thread’s instance of that variable. An address so obtained may be used by any thread.


Скачать: pres_Manycore-FASTMath14.pdf

Похожие записи: