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 1sWSYk-00FHE6-CX for pgsql-hackers@arkaria.postgresql.org; Wed, 24 Jul 2024 03:20:58 +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 1sWSYi-000aGi-2n for pgsql-hackers@arkaria.postgresql.org; Wed, 24 Jul 2024 03:20:56 +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 1sWSYh-000aGZ-PD for pgsql-hackers@lists.postgresql.org; Wed, 24 Jul 2024 03:20:56 +0000 Received: from mail-io1-xd32.google.com ([2607:f8b0:4864:20::d32]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sWSYf-0018Lc-K8 for pgsql-hackers@lists.postgresql.org; Wed, 24 Jul 2024 03:20:54 +0000 Received: by mail-io1-xd32.google.com with SMTP id ca18e2360f4ac-8076cee8088so221667539f.0 for ; Tue, 23 Jul 2024 20:20:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721791252; x=1722396052; darn=lists.postgresql.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=5O7s3hF2F4k6qB4bK0tPY1zgT7jUyMD8kGAnwvL1Hv0=; b=Xr79HT9Ov2d2CdrBvVlfmgApDQdr7TaCdPvg7IBetMGgUnCU9n1i6G/vbd4GWTrEyN 3tC6Ht08D1Epp6+GFr6TlZJbhyfkwEElEwGwtU29UDTCulCd0iJ8heAgEWS0ALXt216F 8hXGQrKcCodsckhLHo8OgXtKOcGzFKrSe9km2v72WUiP7pp0cYU/VYutXmpcKQQDaLRB tGdZLJGXBf2nen7yicslGBriQyVkMTbRgFYETkAfj9i0gl/+jMAGxOn8LZC8rk4qq0l0 zf0w0MOF1/sJGLTcCGqOMQutVVy028TyuB/7fu6TgoJgwv+OAfyC0Avkf+xOOqwTwbGR g6ag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721791252; x=1722396052; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=5O7s3hF2F4k6qB4bK0tPY1zgT7jUyMD8kGAnwvL1Hv0=; b=FBXDsIS8IVs1FzBRNdrSnuFa5fT3SSn1ZwBYebgY5nOx/zuYAu3UbLRclOe1n8Owc0 5zAs9SE+kWSIzdo/q1amntg+CJE14mEXhtIn+QnH6Ii32M6xs57imlwbn8x8nXAYoN7e AOxXj3AFHNahx2EhN5QjZzLJf1LiaPQfync5IGiQU4xaA/CI83L3apPEWySSnb5adDgw AjV1HUV+Yf/JwMryspOi1qzJwfeiHfmD/rk46TwTSiDXwA7DoqPeIeYYk4PJoRTEd6F1 PqR83XkONfqyRgvxmvnscQlRh1DzKZoqyE/tazEwLbX39+4rCGYfXpHEXTlwQAV/APXY sxIA== X-Forwarded-Encrypted: i=1; AJvYcCXizvQtJNXmam5ehbYM2eMysXVjccivLzhP1wnBMbnxd0xlui6+gRBC7zMzcs+NO/EduE+t+yZmsA4zyqK1hgv+2PxEsIsORhY/qouFYGRpqmzA X-Gm-Message-State: AOJu0YxmNcx6NE8rDSlhljwRg8PFyqVKJAdZ0VCFYHMF1ZgDsy4Nrjn/ mannAPxp7JHMJ4SGy6grIXVZMowD63LNTHBGRikaz2geKExrMCSxxJKITw== X-Google-Smtp-Source: AGHT+IGd0vAmYRH4xXgPcm4UvnxRdqS2xYTiBqsw8z+71dyFNNqZo4DfYm1V8opDyuFi0FDiWuvjJw== X-Received: by 2002:a05:6602:2c11:b0:806:6b24:ee2c with SMTP id ca18e2360f4ac-81f71d9ea27mr146876539f.16.1721791252340; Tue, 23 Jul 2024 20:20:52 -0700 (PDT) Received: from nathan (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id 8926c6da1cb9f-4c28c9332ffsm210720173.96.2024.07.23.20.20.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Jul 2024 20:20:52 -0700 (PDT) Date: Tue, 23 Jul 2024 22:20:50 -0500 From: Nathan Bossart To: Joseph Koshakow Cc: jian he , Alexander Lakhin , Tom Lane , PostgreSQL Hackers , Andres Freund Subject: Re: Remove dependence on integer wrapping Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, Jul 23, 2024 at 05:41:18PM -0400, Joseph Koshakow wrote: > On Tue, Jul 23, 2024 at 2:14 AM jian he wrote: >> On Tue, Jul 23, 2024 at 6:56 AM Joseph Koshakow wrote: >>> The specific bug that this patch fixes is preventing the following >>> statement: >>> >>> # INSERT INTO arroverflowtest(i[-2147483648:2147483647]) VALUES > ('{1}'); >>> >>> So we may want to add that test back in. >>> >> I agree with you. > > I've updated the patch to add this test back in. I've committed/back-patched the fix for array_set_slice(). I ended up fiddling with the test cases a bit more because they generate errors that include a platform-dependent value (MaxArraySize). To handle that, I moved the new tests to the section added in commit 18b5851 where VERBOSITY is set to "sqlstate". -- nathan