From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id B9F116F873; Fri, 28 Jan 2022 18:11:36 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B9F116F873 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1643382696; bh=a0If5l67s1pZZrWIIQL0/v5io4HrOisWYdA+7QeLxNs=; h=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=oU/z5oGGw1c7bScMj6frGGzJbEaLLDBn+1ExwTcgode/WuSVQjl5SpaWB4jYIQ2ZB OQskMLutFh4VZIcxdzQAexVLqGiPM4FWYBqePId+ktfuomFoLcaK3xyNyl+XJgcWAU QKR4hP5NRGOCUz8CksGBGwALcNpqpXWqb1BqqreQ= Received: from smtp54.i.mail.ru (smtp54.i.mail.ru [217.69.128.34]) (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 CCE2E6F873 for ; Fri, 28 Jan 2022 18:11:35 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org CCE2E6F873 Received: by smtp54.i.mail.ru with esmtpa (envelope-from ) id 1nDSuU-000870-Va; Fri, 28 Jan 2022 18:11:35 +0300 Date: Fri, 28 Jan 2022 18:09:35 +0300 To: sergos Message-ID: References: <20211229122731.31617-1-skaplun@tarantool.org> <671DCAEC-D19C-409F-89D4-0065C8292D34@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <671DCAEC-D19C-409F-89D4-0065C8292D34@tarantool.org> X-4EC0790: 10 X-7564579A: EEAE043A70213CC8 X-77F55803: 4F1203BC0FB41BD99F281FB7F96F126D5C01C79F7F2485624D256791FCB2EE0000894C459B0CD1B94A209387AD4161CBF5A78AB7A045FBD3120A037C88EB6996FC9ECFF4D26F401E X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE75C3A43A35AA60CB6EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637A0569EA9A35E44F48638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D84D1372F3F86467495BD501459A9F2AD4117882F4460429724CE54428C33FAD305F5C1EE8F4F765FC2EE5AD8F952D28FBA471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F446042972877693876707352033AC447995A7AD182CC0D3CB04F14752D2E47CDBA5A96583BA9C0B312567BB231DD303D21008E29813377AFFFEAFD269A417C69337E82CC2E827F84554CEF50127C277FBC8AE2E8BA83251EDC214901ED5E8D9A59859A8B6A45692FFBBD75A6A089D37D7C0E48F6C5571747095F342E88FB05168BE4CE3AF X-8FC586DF: 6EFBBC1D9D64D975 X-C1DE0DAB: 0D63561A33F958A5F85938A8159B6B9826184EC7BF9741BFAD538149DE486BA3D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA75F04B387B5D7535DE410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D3488E5CD2E691F5566F4D6B9759D7E70E67A8D32CFE8FB02889B7B9E1DD07AB4ECD2510B12A0ECAEF51D7E09C32AA3244CF574D4F01B85B9CE19EC930EC4B2FA76E3D93501275E802FFACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojqLK0kLh8sGeDXmkDmqZmDQ== X-Mailru-Sender: 3B9A0136629DC91206CBC582EFEF4CB4A73BB315FD6E64BB378ACB91701CF4E4C27EF3C42871D26EF2400F607609286E924004A7DEC283833C7120B22964430C52B393F8C72A41A84198E0F3ECE9B5443453F38A29522196 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH luajit] Actually implement maxirconst trace limit. X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Sergey Kaplun via Tarantool-patches Reply-To: Sergey Kaplun Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Hi, Sergos! Thanks for the review! On 28.01.22, sergos wrote: > Hi! > > I reviewed the one at https://github.com/tarantool/luajit/commit/2cdd5ac0367629d2f37489dd842d9a6b068cf12c > > Overall is LGTM, I would like to update the 2nd test message to something like > ’trace should not appear due to maxirconst limit’ Fixed, see the iterative patch below. Branch is force-pushed. =================================================================== diff --git a/test/tarantool-tests/lj-430-maxirconst.test.lua b/test/tarantool-tests/lj-430-maxirconst.test.lua index 79553ecb..10de2520 100644 --- a/test/tarantool-tests/lj-430-maxirconst.test.lua +++ b/test/tarantool-tests/lj-430-maxirconst.test.lua @@ -38,6 +38,6 @@ irconst4() irconst4() jit.off() test:ok(ntrace_old == misc.getmetrics().jit_trace_num, - 'trace number is the same') + 'trace should not appear due to maxirconst limit') os.exit(test:check() and 0 or 1) =================================================================== > > Sergos > > > On 28 Jan 2022, at 15:35, Sergey Kaplun wrote: > > > > Igor, > > > > On 28.01.22, Igor Munkin wrote: > >> Sergey, > >> > >> On 28.01.22, Sergey Kaplun wrote: > >>> Igor, > >>> > >>> Thanks for the review! > >>> > >> > >> > >> > >>>>> > >>>>> Issue: https://github.com/LuaJIT/LuaJIT/issues/430 > >>>>> Branch: https://github.com/tarantool/luajit/tree/skaplun/lj-430-maxirconst-actually-implement-full-ci > >>>>> Tarantool branch: https://github.com/tarantool/tarantool/tree/skaplun/lj-430-maxirconst-actually-implement-full-ci > >>>>> > >>>>> src/lj_record.c | 5 ++- > >>>>> .../lj-430-maxirconst.test.lua | 43 +++++++++++++++++++ > >>>>> 2 files changed, 46 insertions(+), 2 deletions(-) > >>>>> create mode 100644 test/tarantool-tests/lj-430-maxirconst.test.lua > >>>>> > >>>> > >>>> > >>>> > >>>>> diff --git a/test/tarantool-tests/lj-430-maxirconst.test.lua b/test/tarantool-tests/lj-430-maxirconst.test.lua > >>>>> new file mode 100644 > >>>>> index 00000000..1829b37d > >>>>> --- /dev/null > >>>>> +++ b/test/tarantool-tests/lj-430-maxirconst.test.lua > >>>>> @@ -0,0 +1,43 @@ > >>>>> +-- XXX: avoid any other traces compilation due to hotcount > >>>>> +-- collisions for predictible results. > >> > >> > >> > >>>>> +jit.off() > >>>>> +jit.flush() > >>>> > >>>> Minor: I'd rather move this part closer to 'jit.opt.start' to save the > >>>> test structure closer to the other test chunks. Feel free to ignore. > >>> > >>> I really want to exclude __any__ JIT work here to avoid false-positive > >>> hotcount (was precendents during writing this test :)). Ignoring. > >> > >> OK, got it. > >> > >>> > >> > >> > >> > >>>>> +test:ok(ntrace_old + 1 == misc.getmetrics().jit_trace_num, > >>>>> + 'trace number increases') > >>>> > >>>> Typo: I doubt we use tabs in Lua sources, but I might be wrong... > >>> > >>> I suggest to use quarter tabs indent style as we use for C code and Mike > >>> use in src/jit/*.lua (see bcsave.lua for example). > >>> > >>> There was no precedent before, IINM :). > >> > >> See test/tarantool-tests/lj-695-ffi-vararg-call.test.lua[1]. > > > > Fixed, repushed. > > > >> > >>> > >>>> > >>>>> + > >>>>> +ntrace_old = misc.getmetrics().jit_trace_num > >>>>> +jit.on() > >>>>> +irconst4() > >>>>> +irconst4() > >>>>> +jit.off() > >>>>> +test:ok(ntrace_old == misc.getmetrics().jit_trace_num, > >>>>> + 'trace number is the same') > >>>> > >>>> Ditto. > >>>> > >>>>> + > >>>>> +os.exit(test:check() and 0 or 1) > >>>>> -- > >>>>> 2.34.1 > >>>>> > >>>> > >>>> -- > >>>> Best regards, > >>>> IM > >>> > >>> -- > >>> Best regards, > >>> Sergey Kaplun > >> > >> [1]: https://github.com/tarantool/luajit/blob/tarantool/test/tarantool-tests/lj-695-ffi-vararg-call.test.lua > >> > >> -- > >> Best regards, > >> IM > > > > -- > > Best regards, > > Sergey Kaplun > -- Best regards, Sergey Kaplun