{"id":228469,"date":"2014-07-28T10:15:03","date_gmt":"2014-07-28T06:15:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=228469"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=228469","title":{"rendered":"<span class=\"post_title\">\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0413\u0440\u0430\u0444\u044b, \u0421\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0417\u0430\u043c\u043a\u0438 \u0438 \u0410\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u0417\u0430\u0434\u0430\u0447 \u0432 Intel\u00ae Threading Building Blocks (\u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u0435)<\/span>"},"content":{"rendered":"<div class=\"content html_format\">       \u0414\u0430\u043d\u043d\u044b\u0439 \u043f\u043e\u0441\u0442 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f <a href=\"http:\/\/habrahabr.ru\/company\/intel\/blog\/228433\/\">\u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u0435\u043c \u0430\u0432\u0442\u043e\u0440\u0441\u043a\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0430 \u0441\u0442\u0430\u0442\u044c\u0438<\/a> \u00abFlow Graphs, Speculative Locks, and Task Arenas in Intel\u00ae Threading Building Blocks\u00bb \u0438\u0437 Parallel Universe Magazine, \u0432\u044b\u043f\u0443\u0441\u043a 18, 2014. \u0412 \u044d\u0442\u043e\u0439 \u043f\u043e\u043b\u043e\u0432\u0438\u043d\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0437\u0430\u043c\u043a\u0438 (speculative locks), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 Intel\u00ae Transactional Synchronization Extensions \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0430\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447 (user-managed task arenas), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u044e\u0442 \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0443\u0440\u043e\u0432\u043d\u0435\u043c \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430 \u0438 \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u0437\u0430\u0434\u0430\u0447. \u0415\u0441\u043b\u0438 \u0412\u0430\u0441 \u0437\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u043b\u043e \u2014 \u0434\u043e\u0431\u0440\u043e \u043f\u043e\u0436\u0430\u043b\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0434 \u043a\u0430\u0442.<br \/>  <a name=\"habracut\"><\/a>  <\/p>\n<h4>\u0421\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0417\u0430\u043c\u043a\u0438 (Speculative Locks)<\/h4>\n<p>  Intel TBB 4.2 \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0437\u0430\u043c\u043a\u0438: \u041d\u043e\u0432\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0430\u0437\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u043d\u0430 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 Intel\u00ae Transactional Synchronization Extensions (Intel\u00ae TSX). <br \/>  \u0421\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0437\u0430\u043c\u043a\u0438 \u043c\u043e\u0433\u0443\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u0441\u0435\u043a\u0446\u0438\u044f\u043c, \u0437\u0430\u0449\u0438\u0449\u0435\u043d\u043d\u044b\u043c \u044d\u0442\u0438\u043c \u0437\u0430\u043c\u043a\u043e\u043c, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e, \u0441\u0434\u0435\u043b\u0430\u0432 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0447\u0442\u043e \u0434\u043e\u0441\u0442\u0443\u043f \u0438 \u043c\u043e\u0434\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0435 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u0443\u0435\u0442 \u0434\u0440\u0443\u0433 \u0441 \u0434\u0440\u0443\u0433\u043e\u043c. \u041d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435, \u0435\u0441\u043b\u0438 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442 \u043f\u043e \u0434\u0430\u043d\u043d\u044b\u043c, \u043e\u0434\u043d\u043e \u0438\u043b\u0438 \u0431\u043e\u043b\u0435\u0435 \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u043e\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0430\u043d\u043d\u0443\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u043e, \u043d\u0435 \u0442\u0440\u043e\u043d\u0443\u0432 \u0437\u0430\u0449\u0438\u0449\u0451\u043d\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0438, \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u043d\u0435 \u0437\u0430\u0442\u0440\u0430\u0433\u0438\u0432\u0430\u044f \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u043e\u0442\u043e\u043a\u0438. \u0417\u0430\u0442\u0435\u043c \u043f\u043e\u0442\u043e\u043a\u0438, \u0432\u043e\u0432\u043b\u0435\u0447\u0435\u043d\u043d\u044b\u0435 \u0432 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442 \u043f\u043e \u0434\u0430\u043d\u043d\u044b\u043c, \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u044e\u0442 \u0438\u0445 \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0441\u0435\u043a\u0446\u0438\u0438 \u0438 \u043c\u043e\u0433\u0443\u0442 \u0432\u0437\u044f\u0442\u044c \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0439 \u0437\u0430\u043c\u043e\u043a \u0434\u043b\u044f \u0437\u0430\u0449\u0438\u0442\u044b \u0434\u0430\u043d\u043d\u044b\u0445 (\u0422\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044f Intel TSX \u043d\u0435 \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u0443\u0435\u0442, \u0447\u0442\u043e \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u043e\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u044c\u0441\u044f \u0443\u0441\u043f\u0435\u0448\u043d\u043e, \u0432 \u043a\u043e\u043d\u0446\u0435 \u043a\u043e\u043d\u0446\u043e\u0432).<br \/>  \u0412 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0445 \u0437\u0430\u043c\u043a\u043e\u0432 \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 Intel TBB [6, 7] \u0432\u0441\u0435 \u044d\u0442\u0438 \u0448\u0430\u0433\u0438 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u044f\u0442 \u043d\u0435\u0437\u0430\u043c\u0435\u0442\u043d\u043e \u0434\u043b\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0441\u0442 \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u043e\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c API \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043c\u044c\u044e\u0442\u0435\u043a\u0441\u0430. \u0411\u043e\u043b\u0435\u0435 \u0442\u043e\u0433\u043e, \u043d\u0430 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440\u0435, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044e Intel TSX, \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u0441\u0440\u0430\u0437\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u044b\u0439 \u0437\u0430\u043c\u043e\u043a. \u0422.\u0435. \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u043c\u043e\u0433\u0443\u0442 \u043f\u0438\u0441\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043c\u044b\u0435 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0433\u0443\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438.<br \/>  \u0421\u0435\u0439\u0447\u0430\u0441 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 Intel TBB \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 2 \u043a\u043b\u0430\u0441\u0441\u0430 \u043c\u044c\u044e\u0442\u0435\u043a\u0441\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044e Intel TSX: <i>speculative_spin_mutex<\/i> \u0438 <i>speculative_spin_rw_mutex<\/i>; \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u0431\u044b\u043b \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d, \u043a\u0430\u043a \u00abpreview feature\u00bb \u0432 Intel TBB 4.2 Update 2.<br \/>  \u041a\u043b\u0430\u0441\u0441 <i>speculative_spin_mutex<\/i> \u043e\u0447\u0435\u043d\u044c \u043f\u043e\u0445\u043e\u0436 \u043d\u0430 \u043a\u043b\u0430\u0441\u0441 <i>spin_mutex<\/i>; \u0438 \u043e\u0431\u0430 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u044b \u0432 \u043e\u0434\u043d\u043e\u043c \u0438 \u0442\u043e\u043c \u0436\u0435 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 tbb\/spin_mutex.h. \u041e\u0441\u043d\u043e\u0432\u043d\u043e\u0435 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 <i>speculative_spin_mutex<\/i>, \u043a\u043e\u043d\u0435\u0447\u043d\u043e, \u043a\u0440\u043e\u043c\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 Intel TSX, \u044d\u0442\u043e \u0435\u0433\u043e \u0440\u0430\u0437\u043c\u0435\u0440. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043a\u044d\u0448\u0430 \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u043c\u0438, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0441 \u0432\u044b\u0441\u043e\u043a\u043e\u0439 \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e\u0441\u0442\u044c\u044e \u043f\u0440\u0438\u0432\u0435\u043b\u043e \u043a \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u0443 \u0438 \u043f\u043e\u0442\u0435\u0440\u0435 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <i>speculative_spin_mutex<\/i> \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 2 \u043a\u044d\u0448 \u043b\u0438\u043d\u0438\u0438.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u0437\u0430\u043c\u043a\u0430:  <\/p>\n<pre><code class=\"cpp\">#include &lt;tbb\/spin_mutex.h&gt; #include &lt;set&gt; tbb::speculative_spin_mutex tsx_mtx; std::set&lt;int&gt; g_Set; void thread_safe_add_to_set( int value ) {     tbb::speculative_spin_mutex::scoped_lock lock(tsx_mtx);     g_Set.insert(value); } <\/code><\/pre>\n<p>  \u041a\u043b\u0430\u0441\u0441 <i>speculative_spin_rw_mutex<\/i>, \u043a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0434\u043e\u0433\u0430\u0434\u0430\u0442\u044c\u0441\u044f \u0438\u0437 \u0435\u0433\u043e \u0438\u043c\u0435\u043d\u0438, \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u0435\u0442 RW spinlock \u0441\u043e \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u043c \u0438\u0441\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435\u043c. \u041a\u0442\u043e-\u0442\u043e \u043c\u043e\u0433 \u0437\u0430\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u043b\u044e\u0431\u043e\u0439 \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0439 \u0437\u0430\u043c\u043e\u043a \u043d\u0435 \u044d\u043a\u0441\u043a\u043b\u044e\u0437\u0438\u0432\u0435\u043d \u043f\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044e, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044f \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u0447\u0438\u0442\u0430\u0442\u044c, \u043d\u043e \u0438 \u043f\u0438\u0441\u0430\u0442\u044c, \u0435\u0441\u043b\u0438 \u043d\u0435\u0442 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u043e\u0432. \u0422\u043e \u0435\u0441\u0442\u044c \u00ab\u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0439 RW-lock\u00bb \u043c\u043e\u0436\u0435\u0442 \u0437\u0432\u0443\u0447\u0430\u0442\u044c \u043a\u0430\u043a \u0442\u0430\u0432\u0442\u043e\u043b\u043e\u0433\u0438\u044f. \u041e\u0434\u043d\u0430\u043a\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u043f\u043e\u043c\u043d\u0438\u0442\u044c, \u0447\u0442\u043e \u043f\u043e\u0442\u043e\u043a \u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u0445\u0432\u0430\u0442\u0438\u0442\u044c \u0437\u0430\u043c\u043e\u043a \u00ab\u043f\u043e-\u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u043c\u0443\u00bb. \u0412 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, <i>speculative_spin_mutex <\/i>\u0434\u043e\u043b\u0436\u0435\u043d \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0442\u044c \u044d\u043a\u0441\u043a\u043b\u044e\u0437\u0438\u0432\u043d\u044b\u0439 \u0434\u043e\u0441\u0442\u0443\u043f \u043f\u043e\u0442\u043e\u043a\u0443, \u043d\u0435\u0432\u0430\u0436\u043d\u043e, \u0447\u0442\u043e \u044d\u0442\u043e\u0442 \u043f\u043e\u0442\u043e\u043a \u0434\u0435\u043b\u0430\u0435\u0442 \u2013 \u0447\u0438\u0442\u0430\u0435\u0442 \u0438\u043b\u0438 \u043c\u043e\u0434\u0438\u0444\u0438\u0446\u0438\u0440\u0443\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435; \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u044d\u0442\u043e \u043d\u0435 \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0438\u0439 RW-lock. \u0421 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u0442\u043e\u0440\u043e\u043d\u044b, <i>speculative_spin_mutex <\/i>\u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u043c\u043d\u043e\u0433\u0438\u043c \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u044f\u043c \u0434\u0430\u043d\u043d\u044b\u0445. \u0411\u043e\u043b\u0435\u0435 \u0442\u043e\u0433\u043e, \u00ab\u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0438\u0435\u00bb \u0438 \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u0438 \u043c\u043e\u0433\u0443\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e. \u041d\u043e \u0441 \u044d\u0442\u0438\u043c \u0441\u043e\u043f\u0440\u044f\u0436\u0435\u043d\u044b \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043d\u0430\u043a\u043b\u0430\u0434\u043d\u044b\u0435 \u0440\u0430\u0441\u0445\u043e\u0434\u044b: \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u0435 \u043f\u043e\u043b\u044f \u0434\u0430\u043d\u043d\u044b\u0445 \u043a\u043b\u0430\u0441\u0441\u0430 \u0434\u043e\u043b\u0436\u043d\u044b \u0445\u0440\u0430\u043d\u0438\u0442\u044c\u0441\u044f \u043d\u0430 \u0440\u0430\u0437\u043d\u044b\u0445 \u043a\u044d\u0448-\u043b\u0438\u043d\u0438\u044f\u0445, \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0433\u043e \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u043a \u043a\u044d\u0448-\u043b\u0438\u043d\u0438\u0438 \u043e\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u044f\u0434\u0435\u0440 (false sharing). \u0418\u0437-\u0437\u0430 \u044d\u0442\u043e\u0433\u043e \u043a\u0430\u0436\u0434\u044b\u0439 \u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440 \u043a\u043b\u0430\u0441\u0441\u0430 <i>speculative_spin_rw_mutex <\/i>\u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 \u0442\u0440\u0438 \u043a\u044d\u0448-\u043b\u0438\u043d\u0438\u0438.<br \/>  \u0425\u043e\u0442\u044f <i>speculative_spin_rw_mutex <\/i>\u0432 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 tbb\/spin_rw_mutex.h, \u0438 \u0434\u0430\u0436\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 <i>spin_rw_mutex<\/i>, \u043a\u0430\u043a \u0447\u0430\u0441\u0442\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438, \u044d\u0442\u0438 \u0434\u0432\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0435 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b. \u0412 \u043a\u043b\u0430\u0441\u0441\u0435 <i>speculative_spin_rw_mutex <\/i>\u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0442 \u043c\u0435\u0442\u043e\u0434\u044b <i>lock()<\/i> \u0438 <i>unlock()<\/i>. \u041e\u043d \u0437\u0430\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0448\u0430\u0431\u043b\u043e\u043d \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u0432\u0438\u0434\u0438\u043c\u043e\u0441\u0442\u0438, \u0442.\u0435.\u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0447\u0435\u0440\u0435\u0437 \u043a\u043b\u0430\u0441\u0441 <i>speculative_spin_rw_mutex::scoped_lock<\/i>. \u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u044d\u0442\u043e \u043a\u043b\u0430\u0441\u0441 \u0434\u043b\u044f \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f (preview feature), \u043c\u0430\u043a\u0440\u043e\u0441 TBB_PREVIEW_SPECULATIVE_SPIN_RW_MUTEX \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d \u0432 \u043d\u0435\u043d\u0443\u043b\u0435\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c, \u043a\u0430\u043a \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u044d\u0442\u043e\u0442 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b.<br \/>  \u041a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e, \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0438 \u043f\u043e\u043b\u044c\u0437\u0430 \u043e\u0442 \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0445 \u0437\u0430\u043c\u043a\u043e\u0432 \u043e\u0447\u0435\u043d\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u0437\u0430\u0434\u0430\u0447\u0438. \u041d\u0435 \u043d\u0430\u0434\u043e \u0434\u0443\u043c\u0430\u0442\u044c, \u0447\u0442\u043e \u044d\u0442\u0438 \u043d\u043e\u0432\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b \u2014 \u00ab\u0443\u043b\u0443\u0447\u0448\u0435\u043d\u043d\u044b\u0435 \u0437\u0430\u043c\u043a\u0438\u00bb. \u041d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0440\u0435\u0448\u0438\u0442\u044c \u0432 \u043a\u0430\u0436\u0434\u043e\u043c \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u0447\u0442\u043e \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0437\u0430\u043c\u043a\u0438 \u2013 \u044d\u0442\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442.<\/p>\n<h4>\u0423\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0410\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u0417\u0430\u0434\u0430\u0447 (User-Managed Task Arenas)<\/h4>\n<p>  \u0414\u0440\u0443\u0433\u0430\u044f \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u0447\u0430\u0441\u0442\u044c \u043d\u043e\u0432\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438, \u043d\u0435\u0434\u0430\u0432\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u043d\u043e\u0439 \u0432 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 \u2013 \u044d\u0442\u043e \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u0430\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447. \u0412 \u043d\u0430\u0448\u0435\u0439 \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u043b\u043e\u0433\u0438\u0438 \u0430\u0440\u0435\u043d\u0430 \u2013 \u044d\u0442\u043e \u043c\u0435\u0441\u0442\u043e \u0434\u043b\u044f \u043f\u043e\u0442\u043e\u043a\u043e\u0432, \u0433\u0434\u0435 \u043e\u043d\u0438 \u0434\u0435\u043b\u044f\u0442\u0441\u044f \u0437\u0430\u0434\u0430\u0447\u0430\u043c\u0438 \u0438 \u0437\u0430\u0431\u0438\u0440\u0430\u044e\u0442 \u0437\u0430\u0434\u0430\u0447\u0438 \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f. \u0418\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u043b\u0430 \u043e\u0434\u043d\u0443 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u0443\u044e \u0430\u0440\u0435\u043d\u0443 \u0434\u043b\u044f \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f. \u0417\u0430\u0442\u0435\u043c \u043c\u044b \u0435\u0451 \u043f\u043e\u043c\u0435\u043d\u044f\u043b\u0438, \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0432 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u0430\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043f\u043e\u0442\u043e\u043a\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0438\u0441\u0445\u043e\u0434\u044f \u0438\u0437 \u043e\u0442\u0437\u044b\u0432\u043e\u0432 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u043e \u0442\u043e\u043c, \u0447\u0442\u043e \u0440\u0430\u0431\u043e\u0442\u0430, \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u0430\u044f \u043d\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438, \u0434\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c \u0438\u0437\u043e\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u0430 \u0434\u0440\u0443\u0433 \u043e\u0442 \u0434\u0440\u0443\u0433\u0430. \u0417\u0430\u0442\u0435\u043c \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u044b, \u0447\u0442\u043e\u0431\u044b \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u0443\u0440\u043e\u0432\u043d\u044f \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430 \u0438 \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u043d\u0435 \u0431\u044b\u043b\u0438 \u0441\u0432\u044f\u0437\u0430\u043d\u044b \u0441 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f. \u0414\u043b\u044f \u0443\u0434\u043e\u0432\u043b\u0435\u0442\u0432\u043e\u0440\u0435\u043d\u0438\u044f \u044d\u0442\u0438\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0432\u044b \u0432\u0432\u0435\u043b\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0430\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447. \u041d\u0430 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u044d\u0442\u043e \u0432\u0441\u0451 \u0435\u0449\u0435 \u043a\u043b\u0430\u0441\u0441 \u0434\u043b\u044f \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u043b\u0435\u043d\u0438\u044f (preview feature) \u0438 \u0434\u043b\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043e\u043d \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043c\u0430\u043a\u0440\u043e\u0441\u0430 TBB_PREVIEW_TASK_ARENA \u0432 \u043d\u0435\u043d\u0443\u043b\u0435\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435. \u041d\u043e \u043c\u044b \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u043c \u043d\u0430\u0434 \u0442\u0435\u043c, \u0447\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0435\u0433\u043e \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u043c\u044b\u043c \u043f\u043e\u0437\u0434\u043d\u0435\u0435 \u0432 \u044d\u0442\u043e\u043c (2014) \u0433\u043e\u0434\u0443.<br \/>  API \u0434\u043b\u044f \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0445 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0430\u0440\u0435\u043d \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d \u0447\u0435\u0440\u0435\u0437 \u043a\u043b\u0430\u0441\u0441 <i>task_arena<\/i>. \u041f\u0440\u0438 \u0437\u0430\u0434\u0430\u043d\u0438\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 <i>task_arena<\/i>, \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043c\u043e\u0436\u0435\u0442 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0436\u0435\u043b\u0430\u0435\u043c\u044b\u0439 \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c \u0438 \u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0437\u0430\u0440\u0435\u0437\u0435\u0440\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043e \u0437\u0430 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f.   <\/p>\n<pre><code class=\"cpp\">#define TBB_PREVIEW_TASK_ARENA 1 #include &lt;tbb\/task_arena.h&gt; tbb::task_arena my_arena(4, 1); <\/code><\/pre>\n<p>  \u0412 \u044d\u0442\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0430\u0440\u0435\u043d\u0430 \u0441\u043e\u0437\u0434\u0430\u0435\u0442\u0441\u044f \u0434\u043b\u044f 4 \u043f\u043e\u0442\u043e\u043a\u043e\u0432 \u0438 \u043e\u0434\u043d\u043e \u043c\u0435\u0441\u0442\u043e \u0440\u0435\u0437\u0435\u0440\u0432\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0437\u0430 \u043f\u043e\u0442\u043e\u043a\u043e\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u0434\u043e 3 \u0440\u0430\u0431\u043e\u0447\u0438\u0445 \u043f\u043e\u0442\u043e\u043a\u043e\u0432, \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u043e\u0439 Intel TBB, \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0438\u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0442\u044c\u0441\u044f \u043a \u044d\u0442\u043e\u0439 \u0430\u0440\u0435\u043d\u0435 \u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0430\u0434 \u0437\u0430\u0434\u0430\u0447\u0430\u043c\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0432 \u044d\u0442\u043e\u0439 \u0430\u0440\u0435\u043d\u0435. \u0417\u0434\u0435\u0441\u044c \u043d\u0435\u0442 \u043b\u0438\u043c\u0438\u0442\u0430 \u043d\u0430 \u0442\u043e, \u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0442\u043e\u043a\u043e\u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043c\u043e\u0433\u0443\u0442 \u0441\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u0432 \u044d\u0442\u0443 \u0430\u0440\u0435\u043d\u0443, \u043d\u043e \u043e\u0431\u0449\u0438\u0439 \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c \u0431\u0443\u0434\u0435\u0442 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d 4; \u0432\u0441\u0435 \u00ab\u043b\u0438\u0448\u043d\u0438\u0435\u00bb \u043f\u043e\u0442\u043e\u043a\u0438 \u043d\u0435 \u0441\u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0438\u0441\u043e\u0435\u0434\u0438\u043d\u0438\u0442\u0441\u044f \u043a \u0430\u0440\u0435\u043d\u0435 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0442\u0430\u043c \u0437\u0430\u0434\u0430\u0447\u0438.<br \/>  \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 \u0432 \u0430\u0440\u0435\u043d\u0443, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u043e\u0434\u044b <i>execute()<\/i> \u0438\u043b\u0438 <i>enqueue()<\/i>:  <\/p>\n<pre><code class=\"cpp\">my_arena.enqueue( a_job_functor ); my_arena.execute( a_job_functor2 ); <\/code><\/pre>\n<p>  \u0420\u0430\u0431\u043e\u0442\u0430 \u0434\u043b\u044f \u043b\u044e\u0431\u044b\u0445 \u0438\u0437 \u044d\u0442\u0438\u0445 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430 \u043b\u044f\u043c\u0431\u0434\u0430 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u044f\u043c\u0438 \u0438\u0437 \u0421++11 \u0438\u043b\u0438 \u0444\u0443\u043d\u043a\u0442\u043e\u0440\u043e\u043c. \u042d\u0442\u0438 \u0434\u0432\u0430 \u043c\u0435\u0442\u043e\u0434\u0430 \u0440\u0430\u0437\u043b\u0438\u0447\u0430\u044e\u0442\u0441\u044f \u043c\u0435\u0442\u043e\u0434\u043e\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0432 \u0430\u0440\u0435\u043d\u0443. <i>task_arena::enqueue()<\/i> \u2013 \u044d\u0442\u043e \u0430\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u044b\u0439 \u0432\u044b\u0437\u043e\u0432 \u0434\u043b\u044f \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0442\u0438\u043f\u0430 \u00abfire-and-forget\u00bb (\u043e\u0442\u043f\u0440\u0430\u0432\u0438\u043b-\u0438-\u0437\u0430\u0431\u044b\u043b); \u043f\u043e\u0442\u043e\u043a, \u0432\u044b\u0437\u0432\u0430\u0432\u0448\u0438\u0439 <i>task_arena::enqueue() <\/i>\u043d\u0435 \u043f\u0440\u0438\u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0435\u0442\u0441\u044f \u043a \u0430\u0440\u0435\u043d\u0435 \u0438 \u0441\u0440\u0430\u0437\u0443 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044f \u0438\u0437 \u044d\u0442\u043e\u0433\u043e \u0432\u044b\u0437\u043e\u0432\u0430. <i>task_arena::execute()<\/i>, \u043d\u0430\u043f\u0440\u043e\u0442\u0438\u0432, \u043d\u0435 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044f, \u043f\u043e\u043a\u0430 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u043d\u0430\u044f \u0440\u0430\u0431\u043e\u0442\u0430 \u043d\u0435 \u0437\u0430\u043a\u043e\u043d\u0447\u0435\u043d\u0430; \u0435\u0441\u043b\u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u043f\u043e\u0442\u043e\u043a, \u0432\u044b\u0437\u0432\u0430\u0432\u0448\u0438\u0439 <i>task_arena::execute()<\/i>, \u043f\u0440\u0438\u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0435\u0442\u0441\u044f \u043a \u0430\u0440\u0435\u043d\u0435 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u0435\u0451 \u0437\u0430\u0434\u0430\u0447\u0438. \u0415\u0441\u043b\u0438 \u043d\u0435\u0442, \u0442\u043e \u043f\u043e\u0442\u043e\u043a \u0431\u043b\u043e\u043a\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043d\u0430 \u0432\u0440\u0435\u043c\u044f, \u043f\u043e\u043a\u0430 \u0437\u0430\u0434\u0430\u0447\u0430 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0430.<br \/>  \u041c\u043e\u0436\u043d\u043e \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447 \u0432 <i>task_arena<\/i>, \u043d\u043e \u044d\u0442\u043e \u043d\u0435 \u0442\u043e, \u0434\u043b\u044f \u0447\u0435\u0433\u043e \u043e\u043d\u0430 \u0437\u0430\u0434\u0443\u043c\u0430\u043d\u0430. \u041e\u0431\u044b\u0447\u043d\u043e \u0432 <i>task_arena <\/i> \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0440\u0430\u0431\u043e\u0442\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0432\u044b\u0437\u043e\u0432 <i>parallel_for<\/i>:  <\/p>\n<pre><code class=\"cpp\">my_arena.execute( [&]{     tbb::parallel_for(0,N,iteration_functor()); }); <\/code><\/pre>\n<p>  \u0438\u043b\u0438 flow graph:  <\/p>\n<pre><code class=\"cpp\">tbb::flow::graph g; ... \/\/ create the graph here my_arena.enqueue( [&]{     ... \/\/ start graph computations }); ... \/\/ do something else my_arena.execute( [&]{     g.wait_for_all(); }); \/\/ does not return until the flow graph finishes <\/code><\/pre>\n<p>  \u0411\u043e\u043b\u044c\u0448\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e\u0431 \u0430\u0440\u0435\u043d\u0430\u0445 \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432 \u0441\u043f\u0440\u0430\u0432\u043e\u0447\u043d\u043e\u043c \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0435 Intel TBB.<\/p>\n<h4>\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h4>\n<p>  \u0428\u0430\u0431\u043b\u043e\u043d\u043d\u0430\u044f \u0421++ \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 The Intel\u00ae Threading Building Blocks \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u0442 \u0431\u043e\u0433\u0430\u0442\u044b\u0439 \u043d\u0430\u0431\u043e\u0440 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 \u0434\u043b\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u0432\u044b\u0441\u043e\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u043e\u0433\u043e, \u043e\u0441\u043d\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 \u0437\u0430\u0434\u0430\u0447\u0430\u0445 \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430 \u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043c\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432 \u0431\u0443\u0434\u0443\u0449\u0435\u043c \u043c\u043e\u0433\u0443\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u044e \u043c\u043e\u0449\u044c \u043c\u043d\u043e\u0433\u043e\u044f\u0434\u0435\u0440\u043d\u044b\u0445 \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440. \u0411\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 \u0444\u043e\u043a\u0443\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438 \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0444\u043e\u043a\u0443\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0445 \u0434\u0435\u0442\u0430\u043b\u044f\u0445 \u043f\u043e \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044e \u044d\u0442\u0438\u043c \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u043e\u043c. \u0412 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043a \u0432\u044b\u0441\u043e\u043a\u043e\u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u044b\u043c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f\u043c \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0445 \u0432\u044b\u0441\u043e\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0445 \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u044c\u043d\u044b\u0445 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u0432 \u0438 \u043f\u043e\u0442\u043e\u043a\u043e\u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u044b\u0445 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0442\u0430\u043a\u0438\u0435 \u043d\u0438\u0437\u043a\u043e\u0443\u0440\u043e\u0432\u043d\u0435\u0432\u044b\u0435 \u0441\u0442\u0440\u043e\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0431\u043b\u043e\u043a\u0438, \u043a\u0430\u043a \u043f\u043e\u0442\u043e\u043a\u043e\u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u044b\u0439 \u043c\u0430\u0441\u0448\u0442\u0430\u0431\u0438\u0440\u0443\u0435\u043c\u044b\u0439 \u0434\u0438\u0441\u043f\u0435\u0442\u0447\u0435\u0440 \u043f\u0430\u043c\u044f\u0442\u0438, \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0438 \u0438 \u0430\u0442\u043e\u043c\u0430\u0440\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438.<br \/>  \u041d\u0435\u0441\u043c\u043e\u0442\u0440\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 Intel TBB \u0443\u0436\u0435 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u043e\u043b\u043d\u0430\u044f \u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043d\u043d\u0430\u044f \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u043e\u043c, \u043c\u044b \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0435\u043c \u0443\u043b\u0443\u0447\u0448\u0430\u0442\u044c \u0435\u0451 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0438 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0442\u044c \u0435\u0451 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c. \u0412 \u0432\u0435\u0440\u0441\u0438\u0438 Intel TBB 4.0 \u043c\u044b \u0432\u044b\u043f\u0443\u0441\u0442\u0438\u043b\u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0443 \u0432\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0433\u0440\u0430\u0444\u0430 \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0434\u0430\u0442\u044c \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c \u0431\u043e\u043b\u0435\u0435 \u043b\u0435\u0433\u043a\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0430\u0437\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u043d\u0430 \u0433\u0440\u0430\u0444\u0430\u0445 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u043f\u043e \u0434\u0430\u043d\u043d\u044b\u043c \u0438\u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044e. \u0412 \u0432\u0435\u0440\u0441\u0438\u0438 Intel TBB 4.2 \u043c\u044b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0430\u043b\u0438 \u043d\u043e\u0432\u044b\u043c\u0438 \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438 \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 Intel\u00ae Transactional Synchronization Extensions \u0438 \u043e\u0442\u043a\u043b\u0438\u043a\u043d\u0443\u043b\u0438\u0441\u044c \u043d\u0430 \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u043e \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u043d\u043e\u043c \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0435 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u0443\u0440\u043e\u0432\u043d\u0435\u043c \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430 \u0438 \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u0437\u0430\u0434\u0430\u0447 \u0432\u0432\u0435\u0434\u0435\u043d\u0438\u0435\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0445 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0430\u0440\u0435\u043d \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447. <br \/>  \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0439\u0442\u0438 \u0441\u0432\u0435\u0436\u0438\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 Intel TBB \u0438 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0443\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043d\u0430 \u043d\u0430\u0448\u0438\u0445 \u0441\u0430\u0439\u0442\u0430\u0445:   <\/p>\n<ul>\n<li>\u041e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0439 \u0441\u0430\u0439\u0442 <a href=\"http:\/\/software.intel.com\/en-us\/intel-tbb\">software.intel.com\/en-us\/intel-tbb<\/a><\/li>\n<li>\u0412\u0435\u0440\u0441\u0438\u044f \u0441 \u043e\u0442\u043a\u0440\u044b\u0442\u044b\u043c \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u043c \u043a\u043e\u0434\u043e\u043c <a href=\"http:\/\/threadingbuildingblocks.org\">threadingbuildingblocks.org<\/a> <\/li>\n<li>\u0414\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f <a href=\"http:\/\/software.intel.com\/en-us\/tbb_4.2_ug\">software.intel.com\/en-us\/tbb_4.2_ug<\/a><\/li>\n<li>\u0424\u043e\u0440\u0443\u043c <a href=\"http:\/\/software.intel.com\/en-us\/forums\/intel-threading-building-blocks\">software.intel.com\/en-us\/forums\/intel-threading-building-blocks<\/a> <\/li>\n<\/ul>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0411\u0438\u0431\u043b\u0438\u043e\u0433\u0440\u0430\u0444\u0438\u044f<\/b><\/p>\n<div class=\"spoiler_text\">[1] Michael McCool, Arch Robison, James Reinders \u201cStructured Parallel Programming\u201d <a href=\"http:\/\/parallelbook.com\/\">parallelbook.com\/<\/a> <br \/>   [2] Vladimir Polin, \u201cAndroid* Tutorial: Writing a Multithreaded Application using Intel\u00ae Threading Building Blocks\u201d. <a href=\"http:\/\/software.intel.com\/en-us\/android\/articles\/android-tutorial-writing-a-multithreaded-application-using-intel-threading-building-blocks\">software.intel.com\/en-us\/android\/articles\/android-tutorial-writing-a-multithreaded-application-using-intel-threading-building-blocks<\/a><br \/>  [3] Vladimir Polin, \u201cWindows* 8 Tutorial: Writing a Multithreaded Application for the Windows Store* using Intel\u00ae Threading Building Blocks\u201d. <a href=\"http:\/\/software.intel.com\/en-us\/blogs\/2013\/01\/14\/windows-8-tutorial-writing-a-multithreaded-application-for-the-windows-store-using\">software.intel.com\/en-us\/blogs\/2013\/01\/14\/windows-8-tutorial-writing-a-multithreaded-application-for-the-windows-store-using<\/a> <br \/>  [4] Michael J. Voss, \u201cThe Intel Threading Building Blocks Flow Graph\u201d, <br \/>  Dr. Dobb\u2019s, October 2011, <a href=\"http:\/\/www.drdobbs.com\/tools\/the-intel-threading-building-blocks-flow\/231900177\">www.drdobbs.com\/tools\/the-intel-threading-building-blocks-flow\/231900177<\/a>.<br \/>   [5] Aparna Chandramowlishwaran, Kathleen Knobe, and Richard Vuduc, \u201cPerformance <br \/>  Evaluation of Concurrent Collections on High-Performance Multicore Computing Systems\u201d, <br \/>  2010 Symposium on Parallel &#038; Distributed Processing (IPDPS), April 2010.<br \/>  [6] Christopher Huson, \u201cTransactional memory support: the speculative_spin_mutex\u201d. <a href=\"http:\/\/software.intel.com\/en-us\/blogs\/2013\/10\/07\/transactional-memory-support-the-speculative-spin-mutex\">software.intel.com\/en-us\/blogs\/2013\/10\/07\/transactional-memory-support-the-speculative-spin-mutex<\/a><br \/>  [7] Christopher Huson, \u201cTransactional Memory Support: the speculative_spin_rw_mutex\u201d. <a href=\"http:\/\/software.intel.com\/en-us\/blogs\/2014\/03\/07\/transactional-memory-support-the-speculative-spin-rw-mutex-community-preview\">software.intel.com\/en-us\/blogs\/2014\/03\/07\/transactional-memory-support-the-speculative-spin-rw-mutex-community-preview<\/a>  <\/div>\n<\/div>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/company\/intel\/blog\/228469\/\"> http:\/\/habrahabr.ru\/company\/intel\/blog\/228469\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">       \u0414\u0430\u043d\u043d\u044b\u0439 \u043f\u043e\u0441\u0442 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f <a href=\"http:\/\/habrahabr.ru\/company\/intel\/blog\/228433\/\">\u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u0435\u043c \u0430\u0432\u0442\u043e\u0440\u0441\u043a\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0430 \u0441\u0442\u0430\u0442\u044c\u0438<\/a> \u00abFlow Graphs, Speculative Locks, and Task Arenas in Intel\u00ae Threading Building Blocks\u00bb \u0438\u0437 Parallel Universe Magazine, \u0432\u044b\u043f\u0443\u0441\u043a 18, 2014. \u0412 \u044d\u0442\u043e\u0439 \u043f\u043e\u043b\u043e\u0432\u0438\u043d\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u043f\u0435\u043a\u0443\u043b\u044f\u0442\u0438\u0432\u043d\u044b\u0435 \u0437\u0430\u043c\u043a\u0438 (speculative locks), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 Intel\u00ae Transactional Synchronization Extensions \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0430\u0440\u0435\u043d\u044b \u0434\u043b\u044f \u0437\u0430\u0434\u0430\u0447 (user-managed task arenas), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u044e\u0442 \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0443\u0440\u043e\u0432\u043d\u0435\u043c \u043f\u0430\u0440\u0430\u043b\u043b\u0435\u043b\u0438\u0437\u043c\u0430 \u0438 \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u0437\u0430\u0434\u0430\u0447. \u0415\u0441\u043b\u0438 \u0412\u0430\u0441 \u0437\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u043b\u043e \u2014 \u0434\u043e\u0431\u0440\u043e \u043f\u043e\u0436\u0430\u043b\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0434 \u043a\u0430\u0442.  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-228469","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/228469","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=228469"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/228469\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=228469"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=228469"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=228469"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}