pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Move -ffast-math defense to float.c and remove the configure che
Date: Sun, 15 Mar 2026 23:34:57 +0000
Message-ID: <E1w1uz2-000Lio-1h@gemulon.postgresql.org> (raw)

Move -ffast-math defense to float.c and remove the configure check.

We had defenses against -ffast-math in timestamp-related files,
which is a pretty obsolete place for them since we've not supported
floating-point timestamps in a long time.  Remove those and instead
put one in float.c, which is still broken by using this switch.
Add some commentary to put more color on why it's a bad idea.

Also remove the check from configure.  That was just there to fail
faster, but it doesn't really seem necessary anymore, and besides
we have no corresponding check in meson.build.

Author: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Suggested-by: Andres Freund <andres@anarazel.de>
Suggested-by: Peter Eisentraut <peter@eisentraut.org>
Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://postgr.es/m/abFXfKC8zR0Oclon%40ip-10-97-1-34.eu-west-3.compute.internal

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/82ff54377e557914d975d22c4847d98d0efa1dac

Modified Files
--------------
configure                                  | 23 -----------------------
configure.ac                               |  7 -------
src/backend/utils/adt/date.c               |  8 --------
src/backend/utils/adt/float.c              | 17 +++++++++++++++++
src/backend/utils/adt/timestamp.c          |  7 -------
src/interfaces/ecpg/pgtypeslib/interval.c  |  4 ----
src/interfaces/ecpg/pgtypeslib/timestamp.c |  4 ----
7 files changed, 17 insertions(+), 53 deletions(-)



Message-ID: <E1w1uz2-000Lio-1h@gemulon.postgresql.org>
Permalink:  ../E1w1uz2-000Lio-1h@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1w1uz2-000Lio-1h@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Move -ffast-math defense to float.c and remove the configure che
  In-Reply-To: <E1w1uz2-000Lio-1h@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox