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 1s2ru3-006tOH-1N for pgsql-hackers@arkaria.postgresql.org; Fri, 03 May 2024 12:20:39 +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 1s2rty-008lwC-M1 for pgsql-hackers@arkaria.postgresql.org; Fri, 03 May 2024 12:20:35 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s2rtw-008lw3-OJ for pgsql-hackers@lists.postgresql.org; Fri, 03 May 2024 12:20:35 +0000 Received: from fhigh2-smtp.messagingengine.com ([103.168.172.153]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s2rtp-001L8y-5n for pgsql-hackers@lists.postgresql.org; Fri, 03 May 2024 12:20:33 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailfhigh.nyi.internal (Postfix) with ESMTP id 03AAC11401BE; Fri, 3 May 2024 08:20:24 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Fri, 03 May 2024 08:20:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eisentraut.org; h=cc:cc:content-transfer-encoding:content-type:content-type :date:date:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:subject:subject:to:to; s=fm2; t=1714738823; x=1714825223; bh=N9lw5mvJOqGWITYz4+PydyAvyranTkm0 ktgAn+ngjC4=; b=kIGjPFtG12Pd9Ln5xBKfZ2sezUnceY/KX+5JNCnJxDpJVqvt WIeP1nEO9s/Twyto7ONFqzhD7HPqQir6puCzy8JzqTGoGLy0TFBeHbJSVjQ+hBEL WkODVeJf1SOiycZIOYsqXHE0Nl6fiVbkopi0cVwloy810LHSgCe+FuSYy8qa71nK eePX72V22PggDS/Clbo2cp4rW93H84JpykUDQ3kFZuXw//LWGTbCwMx203DQX+PX ztyuu1j7P3pAaMf+ywk/2lJp51G4vwRNEd+MahcldXXTqXp4wqMv1Pib9WudNUJm Ktu71Y68VSo30Jm4xVkPuWviBgCbLKe9f8wGzA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1714738823; x= 1714825223; bh=N9lw5mvJOqGWITYz4+PydyAvyranTkm0ktgAn+ngjC4=; b=J KFtUcEG/m8lvAbTmeYlq8RnPzXRLjITAmUGzGx21t7wn5RIUfG+dog1l9hK1T76D 2/2A1KX3lFLqixRuhkfvPVEYhA+d+dXuXjPerqX3+bSJT2rDpF3DrYvHFH0EfDZ9 eEUkJzmi8oJL92b4zXCHOcW3DVTHgTqPwlaCBGlbCjv4FBE9p/IvcW5djcwN1Hf4 KoOPup17PGBFficWzCALko56cefmNVms6t58a+fRxtG13baT/LxZERwI26yEfGGJ 9RA8/NTKqC/+DIu8Xaqb8fifDNdZu8dD+RpnQ3To8s/NEPCOhavMV6XBp5gt7jwC zbH30JjcJA/kn5fRR8xWg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvddvtddghedtucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtjeertddtvdejnecuhfhrohhmpefrvght vghrucfgihhsvghnthhrrghuthcuoehpvghtvghrsegvihhsvghnthhrrghuthdrohhrgh eqnecuggftrfgrthhtvghrnhepgfejtdfhkeeftdeugfeileehteeljeeghfeuledthfeu tedvffdukeefjefhgeehnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrg hilhhfrhhomhepphgvthgvrhesvghishgvnhhtrhgruhhtrdhorhhg X-ME-Proxy: Feedback-ID: ie0a040ee:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 3 May 2024 08:20:22 -0400 (EDT) Message-ID: Date: Fri, 3 May 2024 14:20:21 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: pg_trgm comparison bug on cross-architecture replication due to different char implementation To: Tom Lane , Alexander Korotkov Cc: "Guo, Adam" , "pgsql-hackers@lists.postgresql.org" References: <3335675.1713884256@sss.pgh.pa.us> <1685377.1714496091@sss.pgh.pa.us> <1696557.1714498172@sss.pgh.pa.us> Content-Language: en-US From: Peter Eisentraut In-Reply-To: <1696557.1714498172@sss.pgh.pa.us> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 30.04.24 19:29, Tom Lane wrote: >> 1) Assume that char signedness is somehow a property of bits-on-disk >> even though it's weird. Then pg_trgm indexes are correct, but we need >> to store char signedness in pg_control. >> 2) Assume that char signedness is not a property of bits-on-disk. >> Then pg_trgm indexes are buggy and need to be fixed. >> What do you think? > Also, the bigger picture here is the seeming assumption that "if > we change pg_trgm then it will be safe to replicate from x86 to > arm". I don't believe that that's a good idea and I'm unwilling > to promise that it will work, regardless of what we do about > char signedness. That being the case, I don't want to invest a > lot of effort in the signedness issue. Option (1) is clearly > a small change with little if any risk of future breakage. But note that option 1 would prevent some replication that is currently working.