From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Tue, 31 Jul 2018 23:43:42 +0300 From: Konstantin Osipov Subject: Re: [RFC PATCH 20/23] vinyl: use cbus for communication between scheduler and worker threads Message-ID: <20180731204342.GI15235@chai> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8bb3cb144751a6b7d051bc7d392223175b5f740f.1531065648.git.vdavydov.dev@gmail.com> To: Vladimir Davydov Cc: tarantool-patches@freelists.org List-ID: * Vladimir Davydov [18/07/08 22:53]: > We need cbus for forwarding deferred DELETE statements generated in a > worker thread during primary index compaction to the tx thread where > they can be inserted into secondary indexes. Since pthread mutex/cond > and cbus are incompatible by their nature, let's rework communication > channel between the tx and worker threads using cbus. OK to push. > + /** > + * Fiber that is currently executing this task in > + * a worker thread. > + */ > + struct fiber *fiber; You could consider using a fiber pool rather than starting a fiber for each task, but I guess it's minor. Have you benched the performance of this patch? I would expect it to have some positive impact on performance. -- Konstantin Osipov, Moscow, Russia, +7 903 626 22 32 http://tarantool.io - www.twitter.com/kostja_osipov