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 1rqENb-00BIFn-6Q for pgsql-hackers@arkaria.postgresql.org; Fri, 29 Mar 2024 15:42:55 +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 1rqENZ-002Rzu-5t for pgsql-hackers@arkaria.postgresql.org; Fri, 29 Mar 2024 15:42:53 +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 1rqENY-002Rzm-So for pgsql-hackers@lists.postgresql.org; Fri, 29 Mar 2024 15:42:52 +0000 Received: from mail-io1-xd34.google.com ([2607:f8b0:4864:20::d34]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rqENR-007JTV-DH for pgsql-hackers@lists.postgresql.org; Fri, 29 Mar 2024 15:42:52 +0000 Received: by mail-io1-xd34.google.com with SMTP id ca18e2360f4ac-7c8ad87b2acso61623839f.3 for ; Fri, 29 Mar 2024 08:42:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1711726963; x=1712331763; darn=lists.postgresql.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=/KaanFxPf0hF0Ukc+LviRTnJEqy3XtfA2ivBJZ75XuQ=; b=bvMOSJgu88DMeDwJYA02219EIXLG5J2uJpIao4ssPj4/nY+w49RfpplRV2nBhAN0Zn i2eMXkYrWTkZAYgr6eiUvNpyiTiPL6HBgkZ5alZ69+AQUBQS0DqUFmNxclRqltUWLow8 j/riTxXI3t6cthz6XgBGG89jVwisJXIDP2WUP/VUK+mhozDU9/glyHCRmH4Ec5dht+pw 4JnqC8BDQQRaixD2fjn1qTYNM52ABNaUlqciAHEptaOiT1l/g0J44XYiilxI9D6XvXcJ ++a5JMt65rcXcpKaM/nlg44gGmmsUtwUFF08x3AJb2YtuYc/rtViZ9wOgv2a77w4fZPE zX/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711726963; x=1712331763; h=in-reply-to: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=/KaanFxPf0hF0Ukc+LviRTnJEqy3XtfA2ivBJZ75XuQ=; b=Ypil2eVdfoJ10xGOKYF/6uQyQpki9c6lB/rjfjPalrD6xbBIes3yBJxlTX/pqOkvdh ++wvE4QNQL58r1JsltpF7Cq9SYNpYDwOXkHAg9H+2rhq314Xw9PgmXs2xXZueU2S/Wdk mQ5V3Ym0YZTItsRAXWip6QuaspKItrgwWtVb7+7GB8D+KuYDml4j8DLIv/2F3BdjNW+F 1EwzRm52E+eUdGwCNlP75jAY1OrTjUMIsAwaO1luI+sYaVIo1SbUZW5+fuI+t2EDpsod UBHodID5V7bkNMigHcGPtf32ZN3dnRZf/ck//54N7p8QGqmTV7iNzqNumZa2u2fcgzEs gdPQ== X-Forwarded-Encrypted: i=1; AJvYcCU3ilyRBjhfMfCyBAdstDvU04eKrVbRTz/en6hJlcCGwK8l2H+93BrJIql/mf5BAOyq1lwTTi2UNqJheQl4CLLc+xPjGzx3w1aIXRfnW+B059O4 X-Gm-Message-State: AOJu0Ywef+DPo4l69IPCyzSZm+j+RlDKPJ4XSByU2A2Iih0liYlqCd8e Lh+XWMX3vvsZRVtmHnnT3c9XpmX/laiPVDpBcr+ylt4PJZSeB/Hk X-Google-Smtp-Source: AGHT+IGMHlNURuuyQ9mr4o9V8pvoHFI/YZnsnNH27qTpr6W9yJFBgah5pwNybKvyl3zKrYUtfG2KPw== X-Received: by 2002:a05:6602:1c87:b0:7d0:3e4e:242d with SMTP id hf7-20020a0566021c8700b007d03e4e242dmr2686924iob.5.1711726963394; Fri, 29 Mar 2024 08:42:43 -0700 (PDT) Received: from nathanxps13 (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id o6-20020a5eda46000000b007d04cc47189sm1069213iop.2.2024.03.29.08.42.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Mar 2024 08:42:42 -0700 (PDT) Date: Fri, 29 Mar 2024 10:42:41 -0500 From: Nathan Bossart To: Alvaro Herrera Cc: "Amonson, Paul D" , Tom Lane , David Rowley , Andres Freund , "Shankaran, Akash" , Noah Misch , Matthias van de Meent , "pgsql-hackers@lists.postgresql.org" Subject: Re: Popcount optimization using AVX512 Message-ID: <20240329154241.GB1046039@nathanxps13> References: <202403282210.7k22uxc5db3f@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <202403282210.7k22uxc5db3f@alvherre.pgsql> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Mar 28, 2024 at 11:10:33PM +0100, Alvaro Herrera wrote: > We don't do MSVC via autoconf/Make. We used to have a special build > framework for MSVC which parsed Makefiles to produce "solution" files, > but it was removed as soon as Meson was mature enough to build. See > commit 1301c80b2167. If it builds with Meson, you're good. The latest cfbot build for this seems to indicate that at least newer MSVC knows AVX512 intrinsics without any special compiler flags [0], so maybe what I had in v14 is good enough. A previous version of the patch set [1] had the following lines: + if host_system == 'windows' + test_flags = ['/arch:AVX512'] + endif I'm not sure if this is needed for older MSVC or something else. IIRC I couldn't find any other examples of this sort of thing in the meson scripts, either. Paul, do you recall why you added this? [0] https://cirrus-ci.com/task/5787206636273664?logs=configure#L159 [1] https://postgr.es/m/attachment/158206/v12-0002-Feature-Added-AVX-512-acceleration-to-the-pg_popcoun.patch -- Nathan Bossart Amazon Web Services: https://aws.amazon.com