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 1rpaXM-007SXW-4v for pgsql-hackers@arkaria.postgresql.org; Wed, 27 Mar 2024 21:10:20 +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 1rpaXK-002afk-Pr for pgsql-hackers@arkaria.postgresql.org; Wed, 27 Mar 2024 21:10:18 +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 1rpaXK-002afc-GN for pgsql-hackers@lists.postgresql.org; Wed, 27 Mar 2024 21:10:18 +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 1rpaXG-006lTp-Tr for pgsql-hackers@postgresql.org; Wed, 27 Mar 2024 21:10:17 +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 42RLADF73442908; Wed, 27 Mar 2024 17:10:13 -0400 From: Tom Lane To: Nathan Bossart cc: John Naylor , Ants Aasma , pgsql-hackers@postgresql.org Subject: Re: add AVX2 support to simd.h In-reply-to: <20240327185716.GA4188857@nathanxps13> References: <20240321170944.GA1767527@nathanxps13> <20240325152121.GB2662364@nathanxps13> <20240325213754.GA3094030@nathanxps13> <20240326190904.GA3700674@nathanxps13> <3189995.1711495704@sss.pgh.pa.us> <20240326235554.GA3766883@nathanxps13> <20240327013616.GA3940109@nathanxps13> <3206056.1711504137@sss.pgh.pa.us> <20240327185716.GA4188857@nathanxps13> Comments: In-reply-to Nathan Bossart message dated "Wed, 27 Mar 2024 13:57:16 -0500" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3442906.1711573813.1@sss.pgh.pa.us> Date: Wed, 27 Mar 2024 17:10:13 -0400 Message-ID: <3442907.1711573813@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Nathan Bossart writes: > Here's what I had in mind. My usual benchmark seems to indicate that this > shouldn't impact performance. Shouldn't "i" be declared uint32, since nelem is? BTW, I wonder why these functions don't declare their array arguments like "const uint32 *base". LGTM otherwise, and I like the fact that the #if structure gets a lot less messy. regards, tom lane