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 2923A608E9C; Thu, 31 Aug 2023 18:37:53 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 2923A608E9C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1693496273; bh=CcOU+88q4DX7kIZ3V1NdWAvDtTuS0Pjt6hvR/fsAeoc=; 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=y+vQopUt2pXGEPoU0o2bQCAWRXaonLRmV0ecMS2FirARPoHx2XQ2cKB1Pi5yln1I4 LhKgoetX8xAiwlrGmKJLzvdfcYEKu6vjdIyizSdF00P8JNJYsz1YJ0SHJ4HMWQkfIy rHVWwWTd2okI/sYSZsyeyXAvQoB7rcwM/cgljS48= Received: from smtp50.i.mail.ru (smtp50.i.mail.ru [95.163.41.92]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 5EBD0608E98 for ; Thu, 31 Aug 2023 18:36:57 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 5EBD0608E98 Received: by smtp50.i.mail.ru with esmtpa (envelope-from ) id 1qbjj4-00GwJn-00; Thu, 31 Aug 2023 18:36:54 +0300 Date: Thu, 31 Aug 2023 15:19:30 +0000 To: Sergey Kaplun Message-ID: References: <20230817144641.20088-1-skaplun@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20230817144641.20088-1-skaplun@tarantool.org> X-Clacks-Overhead: GNU Terry Pratchett X-Mailru-Src: smtp X-4EC0790: 10 X-7564579A: EEAE043A70213CC8 X-77F55803: 4F1203BC0FB41BD96201AD55A1C8F7DB4B94316895B7D143959E6F65F85AE25C182A05F5380850404C228DA9ACA6FE276A3B5B610F32D6738B5368DB35774B9EBD65894310403612C754C0B16C23FA54 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE73B44982FA5E78411EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637174E2957C4CE0F938638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D88BFFE15708FE43C40D720C8F0FDE6EA6117882F4460429724CE54428C33FAD305F5C1EE8F4F765FC2BE06DBDC430765AA471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F446042972877693876707352033AC447995A7AD18618001F51B5FD3F9D2E47CDBA5A96583BA9C0B312567BB2376E601842F6C81A19E625A9149C048EE0AC5B80A05675ACD4782AAF36435267CD8FC6C240DEA76429C9F4D5AE37F343AA9539A8B242431040A6AB1C7CE11FEE3F8BD4E506CFA3D8803F1AB874ED89028C4224003CC836476E2F48590F00D11D6E2021AF6380DFAD1A18204E546F3947CB11811A4A51E3B096D1867E19FE1407959CC434672EE6371089D37D7C0E48F6C8AA50765F790063757B1FBEA53BC6EDBEFF80C71ABB335746BA297DBC24807EABDAD6C7F3747799A X-C1DE0DAB: 0D63561A33F958A5FBCBF4E76F0DDAE5CBB3D1309E2E95E30B432602D7606328F87CCE6106E1FC07E67D4AC08A07B9B01DAA61796BF5227BCB5012B2E24CD356 X-C8649E89: 1C3962B70DF3F0ADBF74143AD284FC7177DD89D51EBB7742424CF958EAFF5D571004E42C50DC4CA955A7F0CF078B5EC49A30900B95165D342B1F2AD168155B06350B7BE03041A90B78462F51D12D8B6A3D3FE9A4C8267D08150C6C311E8A73161D7E09C32AA3244C34438AF0485297BC29289B6F50712F11B038C9161EF167A1BAD658CF5C8AB4025DA084F8E80FEBD376A4ED3E9341DC2FCD72808BE417F3B9E0E7457915DAA85F X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2bioj6jqRMsEo8wfMFSKfEjNgyQ== X-Mailru-Sender: 2FEBA92C8E508479FE7B9A1DF348D5312B19E8B232634F0DD9E8C6AFE34F5C43BF42EF22A1F855AA2326FE6F2A341ACE0FB9F97486540B4CD9E8847AB8CFED4D9ABF8A61C016C2CFB0DAF586E7D11B3E67EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH luajit] Fix TDUP load forwarding after table rehash. 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: Igor Munkin via Tarantool-patches Reply-To: Igor Munkin Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Sergey, I've checked the patchset into all long-term branches in tarantool/luajit and bumped a new version in master, release/2.11 and release/2.10. On 17.08.23, Sergey Kaplun via Tarantool-patches wrote: > From: Mike Pall > > Reported by Sergey Kaplun. > > (cherry-picked from commit c7db8255e1eb59f933fac7bc9322f0e4f8ddc6e6) > > After table rehashing number keys loaded via ALOAD may be placed in the > hash part of the table. So, load forwarding analysis missed the > corresponding stores like they are never existed. In such case, either > we faced an assertion failure in `fwd_ahload()` due to values types > mismatch, either we faced an assertion failure in `rec_check_slots()` > since forwarded value by the JIT compiler isn't the same as it is in the > interpreter. > > This patch adds a check that there is no any `IR_NEWREF` after table > creation, so it can't be rehashed. > > Sergey Kaplun: > * added the description and the test for the problem > > Part of tarantool/tarantool#8825 > --- > > Branch: https://github.com/tarantool/luajit/tree/skaplun/lj-980-load-fwd-after-table-rehash > PR: https://github.com/tarantool/tarantool/pull/8998 > Related issues: > * https://github.com/LuaJIT/LuaJIT/issues/980 > * https://github.com/tarantool/tarantool/issues/8825 > > src/lj_opt_mem.c | 6 + > ...j-980-load-fwd-after-table-rehash.test.lua | 166 ++++++++++++++++++ > 2 files changed, 172 insertions(+) > create mode 100644 test/tarantool-tests/lj-980-load-fwd-after-table-rehash.test.lua > > -- > 2.41.0 > -- Best regards, IM