Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lAc6w-0004IP-JE for pgsql-hackers@arkaria.postgresql.org; Fri, 12 Feb 2021 17:20:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lAc6v-0006sJ-9i for pgsql-hackers@arkaria.postgresql.org; Fri, 12 Feb 2021 17:20:05 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lAc6v-0006sB-2z for pgsql-hackers@lists.postgresql.org; Fri, 12 Feb 2021 17:20:05 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lAc6m-0000LB-VD; Fri, 12 Feb 2021 17:20:04 +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 11CHJhfu1557042; Fri, 12 Feb 2021 12:19:43 -0500 From: Tom Lane To: Alexander Korotkov cc: Thomas Munro , Heikki Linnakangas , Alexander Korotkov , PostgreSQL Hackers Subject: Re: Detecting pointer misalignment (was Re: pgsql: Implementation of subscripting for jsonb) In-reply-to: References: <37bb56a0-391d-759d-771b-9c1d8c15a84b@iki.fi> <3293925.1612163110@sss.pgh.pa.us> <475514.1612745257@sss.pgh.pa.us> Comments: In-reply-to Alexander Korotkov message dated "Fri, 12 Feb 2021 17:29:48 +0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1557040.1613150383.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Fri, 12 Feb 2021 12:19:43 -0500 Message-ID: <1557041.1613150383@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk I've updated buildfarm member longfin to use "-fsanitize=3Dalignment -fsanitize-trap=3Dalignment", and it just got through a run successfully with that. It'd be good perhaps if some other buildfarm owners followed suit (mumble JIT coverage mumble). Looking around at other recent reports, it looks like we'll need to tweak the compiler version cutoffs a bit. I see for instance that spurfowl, with gcc (Ubuntu 5.4.0-6ubuntu1~16.04.11) 5.4.0 20160609, is whining: pg_crc32c_sse42.c:24:1: warning: \342\200\230no_sanitize\342\200\231 attri= bute directive ignored [-Wattributes] So maybe it'd better be __GNUC__ >=3D 6 not __GNUC__ >=3D 5. I think we can wait a little bit for more reports before messing with that, though. Once this does settle, should we consider back-patching so that it's possible to run alignment checks in the back branches too? regards, tom lane