From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtpng3.m.smailru.net (smtpng3.m.smailru.net [94.100.177.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 33C534696C3 for ; Fri, 3 Apr 2020 02:41:16 +0300 (MSK) References: <50fe58f83ebb4e4971528641e74f99fe2f9fd8f2.1585304087.git.imun@tarantool.org> From: Vladislav Shpilevoy Message-ID: Date: Fri, 3 Apr 2020 01:41:14 +0200 MIME-Version: 1.0 In-Reply-To: <50fe58f83ebb4e4971528641e74f99fe2f9fd8f2.1585304087.git.imun@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Tarantool-patches] [PATCH luajit 1/2] jit: abort trace recording and execution for C API List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Igor Munkin , Sergey Ostanevich , Kirill Yukhin Cc: tarantool-patches@dev.tarantool.org Hi! Thanks for the patch! > diff --git a/src/lj_api.c b/src/lj_api.c > index a5e2465..c1f53e0 100644 > --- a/src/lj_api.c > +++ b/src/lj_api.c > @@ -300,7 +311,7 @@ LUA_API int lua_equal(lua_State *L, int idx1, int idx2) > return (int)(uintptr_t)base; > } else { > L->top = base+2; > - lj_vm_call(L, base, 1+1); > + call(L, base, 1+1); These changes look dangerous to perf. So if I had operators == and < overloaded for an FFI struct, they are not jitted anymore, right? Why? Does someone really yield in them? Could you measure how does it affect perf of these calls? From what I see, these changes basically kill FFI making it not better than Lua C. It no longer helps JITting anything, does it? The same for concat, and other things. Looks like an overkill. We would need sandwich protection only for a few places. Is it possible to avoid such drastic changes?