public inbox for [email protected]
help / color / mirror / Atom feedFrom: Nathan Bossart <[email protected]>
To: Matthew Kim <[email protected]>
Cc: Joseph Koshakow <[email protected]>
Cc: jian he <[email protected]>
Cc: Alexander Lakhin <[email protected]>
Cc: Tom Lane <[email protected]>
Cc: PostgreSQL Hackers <[email protected]>
Cc: Andres Freund <[email protected]>
Subject: Re: Remove dependence on integer wrapping
Date: Tue, 6 Aug 2024 16:43:12 -0500
Message-ID: <ZrKY8PJwGg23eZ3R@nathan> (raw)
In-Reply-To: <CAGzNdfGMe8vK1BRvUmW29T7rkqUhM67t=wbgsCSDBu=T+rqZrw@mail.gmail.com>
References: <CAAvxfHfdPgtqFqsb=Nxa1oc6GsQ_U+k3rfneo-EjYG4bne_ksw@mail.gmail.com>
<Zp54I4WMbWW6AQnP@nathan>
<CAAvxfHdWseDnK0gLYY51fdw-_pE=5Q2=K=pToVv5jo3YNVfHoQ@mail.gmail.com>
<Zp7Q4erYWVjtWzQr@nathan>
<Zp7cwd_6NXlHt6Ye@nathan>
<CAAvxfHeg0En5VV_9pjoHgd0kerK7REL84XEiS6=PUDOSKwx9rg@mail.gmail.com>
<CACJufxERqAgy4YBwc2hLZY=hw1kD2m6AVD3=kyAen8=HeLsfmw@mail.gmail.com>
<CAAvxfHeOdkaQXoca3W54=RZ6opCWLzqgmDM6s8GrUxKG1Tk+_g@mail.gmail.com>
<ZqBzEucmgeib_6Fe@nathan>
<CAGzNdfGMe8vK1BRvUmW29T7rkqUhM67t=wbgsCSDBu=T+rqZrw@mail.gmail.com>
On Wed, Jul 24, 2024 at 05:49:41PM -0400, Matthew Kim wrote:
> Hi, I´ve attached a patch that fixes the make_date overflow. I´ve upgraded
> the patches accordingly to reflect Joseph´s committed fix.
cfbot is unhappy with this one on Windows [0], and I think I see why.
While the patch uses pg_mul_s32_overflow(), it doesn't check its return
value, so we'll just proceed with a bogus value in the event of an
overflow. Windows apparently doesn't have HAVE__BUILTIN_OP_OVERFLOW
defined, so pg_mul_s32_overflow() sets the result to 0x5eed (24,301 in
decimal), which is where I'm guessing the year -24300 in the ERROR is from.
[0] https://api.cirrus-ci.com/v1/artifact/task/5872294914949120/testrun/build/testrun/regress/regress/re...
--
nathan
view thread (17+ messages) latest in thread
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: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
Subject: Re: Remove dependence on integer wrapping
In-Reply-To: <ZrKY8PJwGg23eZ3R@nathan>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox