Tarantool development patches archive
 help / color / mirror / Atom feed
From: Kirill Yukhin <kyukhin@tarantool.org>
To: Igor Munkin <imun@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org,
	Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
Subject: Re: [Tarantool-patches] [PATCH] lua/utils: improve luaT_newthread performance
Date: Wed, 29 Jul 2020 16:41:25 +0300	[thread overview]
Message-ID: <20200729134125.hsh4r5rqqatls3ei@tarantool.org> (raw)
In-Reply-To: <ec0eb12f402d5ea2a37b50212caa66b5808375a6.1595238969.git.imun@tarantool.org>

Hello,

On 20 июл 14:28, Igor Munkin wrote:
> <luaT_newthread> created a new GCfunc object for the helper invoked in a
> protected <lua_cpcall> frame (i.e. <luaT_newthread_wrapper>) on each
> call. The change introduces a static reference to a GCfunc object for
> <luaT_newthread_wrapper> to be initialized on Tarantool startup to
> reduce Lua GC memory usage.
> 
> Furthermore, since <lua_cpcall> yields nothing on guest stack, the newly
> created Lua coroutine need to be pushed back to prevent its sweep. So
> to reduce guest stack manipulations <lua_cpcall> is replaced with
> <lua_pcall> and the resulting Lua thread is obtained via guest stack.
> 
> Signed-off-by: Igor Munkin <imun@tarantool.org>

I've checked your patch into 1.10, 2.4, 2.5 and master.

--
Regards, Kirill Yukhin

      parent reply	other threads:[~2020-07-29 13:41 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-20 11:28 Igor Munkin
2020-07-20 12:10 ` Timur Safin
2020-07-22 11:30 ` Sergey Ostanevich
2020-07-22 15:12   ` Igor Munkin
2020-07-24 16:15     ` Sergey Ostanevich
2020-07-24 19:18       ` Igor Munkin
2020-07-23 21:23 ` Vladislav Shpilevoy
2020-07-24 14:14   ` Igor Munkin
2020-07-24 21:47     ` Vladislav Shpilevoy
2020-07-24 21:41       ` Igor Munkin
2020-07-24 21:45 ` Igor Munkin
2020-07-29 13:41 ` Kirill Yukhin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200729134125.hsh4r5rqqatls3ei@tarantool.org \
    --to=kyukhin@tarantool.org \
    --cc=imun@tarantool.org \
    --cc=tarantool-patches@dev.tarantool.org \
    --cc=v.shpilevoy@tarantool.org \
    --subject='Re: [Tarantool-patches] [PATCH] lua/utils: improve luaT_newthread performance' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox