[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250915184228.49fe90ec@kernel.org>
Date: Mon, 15 Sep 2025 18:42:28 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Asbjørn Sloth Tønnesen
<ast@...erby.net>
Cc: "Jason A. Donenfeld" <Jason@...c4.com>, "David S. Miller"
<davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Paolo Abeni
<pabeni@...hat.com>, Donald Hunter <donald.hunter@...il.com>, Simon Horman
<horms@...nel.org>, Jacob Keller <jacob.e.keller@...el.com>, Sabrina
Dubroca <sd@...asysnail.net>, wireguard@...ts.zx2c4.com,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next v5 05/11] tools: ynl-gen: avoid repetitive
variables definitions
On Mon, 15 Sep 2025 14:42:50 +0000 Asbjørn Sloth Tønnesen wrote:
> In the generated attribute parsing code, avoid repetitively
> defining the same variables over and over again, local to
> the conditional block for each attribute.
>
> This patch consolidates the definitions of local variables
> for attribute parsing, so that they are defined at the
> function level, and re-used across attributes, thus making
> the generated code read more natural.
>
> If attributes defines identical local_vars, then they will
> be deduplicated, attributes are assumed to only use their
> local variables transiently.
Reviewed-by: Jakub Kicinski <kuba@...nel.org>
Powered by blists - more mailing lists