Re: gcc 13 warnings
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
Cc: Andres Freund <andres@anarazel.de>,
Pavel Stehule <pavel.stehule@gmail.com>,
Melanie Plageman <melanieplageman@gmail.com>,
PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2023-03-17T14:26:20Z
Lists: pgsql-hackers
Peter Eisentraut <peter.eisentraut@enterprisedb.com> writes: > On 16.03.23 19:11, Andres Freund wrote: >> So I just elected to leave it at the default for meson. > AFAICT, the default for meson is buildtype=debug, which is -O0. The -O3 > comes from meson.build setting buildtype=release. > I think a good compromise would be buildtype=debugoptimized, which is > -O2 with debug symbols, which also sort of matches the default in the > autoconf world. That sounds promising. > At least during the transition phase I would prefer having the same > default optimization level in both build systems, mainly because of how > this affects warnings. I'd prefer sticking to -O2 mainly because of the risk of new bugs. The meson conversion is a big enough job without adding "harden Postgres against -O3" to the list of tasks that must be accomplished. We can take that on in due time, but let's keep it separate. regards, tom lane
Commits
-
Use pg_assume() to avoid compiler warning below exec_set_found()
- 48a23f6eae71 19 (unreleased) landed
-
Add pg_assume(expr) macro
- d65eb5b1b84e 19 (unreleased) landed
-
meson: Change default buildtype to debugoptimized
- 5aae36dc9c68 16.0 landed