Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qsDsZ-007CQW-Rp for pgsql-hackers@arkaria.postgresql.org; Mon, 16 Oct 2023 03:02:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1qsDsX-00EydM-4y for pgsql-hackers@arkaria.postgresql.org; Mon, 16 Oct 2023 03:02:49 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qsDsW-00EydE-Rh for pgsql-hackers@lists.postgresql.org; Mon, 16 Oct 2023 03:02:49 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qsDsU-000gYo-Vt for pgsql-hackers@lists.postgresql.org; Mon, 16 Oct 2023 03:02:48 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 39G32jXm2188265; Sun, 15 Oct 2023 23:02:45 -0400 From: Tom Lane To: Thomas Munro cc: Michael Paquier , Vik Fearing , cary huang , pgsql-hackers@lists.postgresql.org Subject: Re: Add support for AT LOCAL In-reply-to: References: <65b620bd-4f05-4381-97c3-5ec9ac39d5b9@postgresfriends.org> <2129576.1697407071@sss.pgh.pa.us> Comments: In-reply-to Thomas Munro message dated "Mon, 16 Oct 2023 15:53:56 +1300" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <2188263.1697425365.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Sun, 15 Oct 2023 23:02:45 -0400 Message-ID: <2188264.1697425365@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Thomas Munro writes: > On Mon, Oct 16, 2023 at 2:58=E2=80=AFPM Michael Paquier wrote: >> Another theory would be one of these weird compiler optimization issue >> from xlc? In recent history, there was 8d2a01ae12cd. > Yeah, there are more like that too. xlc 12.1 is dead (like the OS > version it shipped with). New versions are available on cfarm if we > care about this target. But I am conscious of the cosmic law that if > you blame the compiler too soon you can cause the bug to move into > your code... I'm having a hard time not believing that this is a compiler bug. Looking back at 8d2a01ae12cd and its speculation that xlc is overly liberal about reordering code around sequence points ... I wonder if it'd help to do this calculation in a local variable, and only assign the final value to result->time ? But we have to reproduce the problem first. regards, tom lane