Re: Fwd: Big Performance drop of Exceptions in UDFs between V11.2 and 13.4 - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Fwd: Big Performance drop of Exceptions in UDFs between V11.2 and 13.4
Date
Msg-id 845520.1630085407@sss.pgh.pa.us
Whole thread Raw
In response to Fwd: Big Performance drop of Exceptions in UDFs between V11.2 and 13.4  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> First, this apparently only affects build done with NLS. And in fact
> even on release 11 the performance is much better when run on a non-NLS
> build. So there's lots of work to do here.

Wow ... it would not have occurred to me to check that.

Testing that angle using HEAD on Linux (RHEL8), here are times
I see for the OP's slow query:

Non-NLS build, C locale:
Time: 12452.062 ms (00:12.452)

NLS build, en_US.utf8 locale:
Time: 13596.114 ms (00:13.596)

NLS build, after SET lc_messages TO 'es_ES.utf8':
Time: 15190.689 ms (00:15.191)

So there is a cost for translating the error messages on Linux too,
but it's not nearly as awful as on Windows.  I wonder if this
boils down to a performance bug in the particular gettext version
you're using?

            regards, tom lane



pgsql-hackers by date:

Previous
From: David Christensen
Date:
Subject: Re: [PATCH] pgbench: add multiconnect option
Next
From: Peter Geoghegan
Date:
Subject: Re: log_autovacuum in Postgres 14 -- ordering issue