Re: [PATCH] Precompute string lengths in PerformRadiusTransaction - Mailing list pgsql-hackers

From John Naylor
Subject Re: [PATCH] Precompute string lengths in PerformRadiusTransaction
Date
Msg-id CANWCAZahqjM9_XVRXpV=M9Y7fDiywUFrXUYpBebvxQxdYj+NSA@mail.gmail.com
Whole thread
In response to [PATCH] Precompute string lengths in PerformRadiusTransaction  ("zengman" <zengman@halodbtech.com>)
Responses Re: [PATCH] Precompute string lengths in PerformRadiusTransaction
List pgsql-hackers
On Mon, Jan 5, 2026 at 9:36 PM zengman <zengman@halodbtech.com> wrote:
> I noticed that the `PerformRadiusTransaction` function is invoked in a loop,
> and the function itself contains internal loops that repeatedly call strlen() on the 'passwd' and 'secret' strings.
> While the optimization gain may be minimal, I still think it’s worth making the change —
> we can precompute the lengths of these two strings at the start of the function to eliminate redundant strlen()
calls.

Shortly after you posted this, it was decided that we're going to
remove this method entirely:

https://wiki.postgresql.org/wiki/RADIUS

--
John Naylor
Amazon Web Services



pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: SQL Property Graph Queries (SQL/PGQ)
Next
From: Jim Jones
Date:
Subject: Re: VACUUM FULL, CLUSTER, and REPACK block on other sessions' temp tables