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 1652954EB90; Wed, 16 Aug 2023 12:03:14 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 1652954EB90 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1692176594; bh=zqNRA78YXt2a4vFLQhirasXnpELANDrqm+D9QHZrAnw=; 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=jtYirHSFkXstkmqfcSaPFlkzS2nw2hxun8bdHT0RVW81ngZwBbkFEsNPU1E5LZ/77 //CwKYHFJN7Tusm8hvy+Bi/wG9JDCF/RkRfPdYJML1qqWmysIUmUPXLgKSTCgP2csM 6GLp+5ZDrVlJjw4Vr9jcr4/yncJarDHmZHG9+Q8c= Received: from smtp45.i.mail.ru (smtp45.i.mail.ru [95.163.41.83]) (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 E852A54EB90 for ; Wed, 16 Aug 2023 12:03:12 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org E852A54EB90 Received: by smtp45.i.mail.ru with esmtpa (envelope-from ) id 1qWCQq-006a1m-1E; Wed, 16 Aug 2023 12:03:12 +0300 Date: Wed, 16 Aug 2023 12:03:12 +0300 To: Sergey Kaplun Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Mailru-Src: smtp X-7564579A: B8F34718100C35BD X-77F55803: 4F1203BC0FB41BD969E04B5EED670DC8BEB87106826C459512B2000DD660D84D182A05F538085040AA5592B1ECF5B78CEF7DB7BF0524D871444617E2C167ED8B705D7E91E7ABB0D2 X-C1DE0DAB: 0D63561A33F958A54671C82DD1E8EE2145051ED961C23FDE1A4508520D7C436EF87CCE6106E1FC07E67D4AC08A07B9B062B3BD3CC35DA588CB5012B2E24CD356 X-C8649E89: 1C3962B70DF3F0AD5177F0B940C8B66ECE892A7B2722663E91682638B966EB3F662256BEEFA9527F9C982AF23C3A21A8004418C78CED1962F17FB9184861B684C0E365F245C4AFE5C6DFB5F8D8F7CF6F37FD76D11AF80A0D030D4C74A1080AC9E8F3F94C4DF11195EA455F16B58544A21C197AAF4D2E4732965026E5D17F6739C77C69D99B9914278E50E1F0597A6FD5CD72808BE417F3B9E0E7457915DAA85F X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojHVl7ekwB6hhvr2c9Vv4qpg== X-Mailru-Sender: 11C2EC085EDE56FA38FD4C59F7EFE4079FF4C562C4300AABE411EC34DD372A9ACD8872D538E8F8CBD51284F0FE6F529ABC7555A253F5B200DF104D74F62EE79D27EC13EC74F6107F4198E0F3ECE9B5443453F38A29522196 X-Mras: OK Subject: Re: [Tarantool-patches] [PATCH luajit 18/19] DynASM/MIPS: Fix shadowed variable. 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: Maxim Kokryashkin via Tarantool-patches Reply-To: Maxim Kokryashkin Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Hi, Sergey! Thanks for the patch! LGTM, except for the single typo in the commit message. On Wed, Aug 09, 2023 at 06:36:07PM +0300, Sergey Kaplun via Tarantool-patches wrote: > From: Mike Pall > > Cleanup only, bug cannot trigger. > Thanks to Domingo Alvarez Duarte. > > (cherry-picked from commit 5c911998a3c85d024a8006feafc68d0b4c962fd8) > > This patch fixes local shadow variable `n` in `template__` function from Typo: s/local/the local/ > by renaming it to `m`. Since this cannot be > triggered, there is no test provided. > > Sergey Kaplun: > * added the description for the problem > --- > dynasm/dasm_mips.lua | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/dynasm/dasm_mips.lua b/dynasm/dasm_mips.lua > index 78a4e34a..bd2a2b43 100644 > --- a/dynasm/dasm_mips.lua > +++ b/dynasm/dasm_mips.lua > @@ -809,9 +809,9 @@ map_op[".template__"] = function(params, template, nparams) > elseif p == "X" then > op = op + parse_index(params[n]); n = n + 1 > elseif p == "B" or p == "J" then > - local mode, n, s = parse_label(params[n], false) > - if p == "B" then n = n + 2048 end > - waction("REL_"..mode, n, s, 1) > + local mode, m, s = parse_label(params[n], false) > + if p == "B" then m = m + 2048 end > + waction("REL_"..mode, m, s, 1) > n = n + 1 > elseif p == "A" then > op = op + parse_imm(params[n], 5, 6, 0, false); n = n + 1 > -- > 2.41.0 >