From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) by sourceware.org (Postfix) with ESMTP id E5DBA3858D35 for ; Thu, 12 Jan 2023 06:51:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E5DBA3858D35 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gentoo.org Content-Type: multipart/signed; boundary="Apple-Mail=_23AEFCB4-FE88-4C48-B07C-9191721EFD49"; protocol="application/pgp-signature"; micalg=pgp-sha512 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.300.101.1.3\)) Subject: Re: avx512erintrin.h: uninitialized variable warning (optimized build) From: Sam James In-Reply-To: Date: Thu, 12 Jan 2023 06:51:32 +0000 Cc: gcc@gcc.gnu.org Message-Id: <7D444AFD-A62E-450E-A80F-CA0C2EB9ECD4@gentoo.org> References: To: James Addison X-Mailer: Apple Mail (2.3731.300.101.1.3) X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,KAM_SHORT,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --Apple-Mail=_23AEFCB4-FE88-4C48-B07C-9191721EFD49 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On 12 Jan 2023, at 00:26, James Addison via Gcc = wrote: >=20 > Hi, >=20 > During GCC 12.2.0 compilation of a file that includes[1] immintrin.h > with both code-optimization and uninitialized-variable-warnings > enabled, a warning is emitted: >=20 > /usr/lib/gcc/x86_64-linux-gnu/12/include/avx512erintrin.h:55:20: > warning: =E2=80=98__W=E2=80=99 is used uninitialized [-Wuninitialized] >=20 > The minimal repro compilation command appears to be: >=20 > gcc -O -Wuninitialized -mavx512er -mavx512pf > ./numpy/distutils/checks/cpu_avx512_knl.c >=20 > My question is: does the warning indicate a possible bug that should > be reported, or is there a reason that the relevant code[2] does not > initialize the variable (for example, for performance reasons)? See also https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105593, might be the same thing? --Apple-Mail=_23AEFCB4-FE88-4C48-B07C-9191721EFD49 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP -----BEGIN PGP SIGNATURE----- iNUEARYKAH0WIQQlpruI3Zt2TGtVQcJzhAn1IN+RkAUCY7+t9F8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0MjVB NkJCODhERDlCNzY0QzZCNTU0MUMyNzM4NDA5RjUyMERGOTE5MAAKCRBzhAn1IN+R kFwwAQCVujbfsoOfyNAggx5JnCZ0v7dk2ZAxLRx89uSlxRjNJgD9EDkczkXouE6D EeZkYN/7AgPVOoBvJc4T8YqEz+k3aQA= =VP4P -----END PGP SIGNATURE----- --Apple-Mail=_23AEFCB4-FE88-4C48-B07C-9191721EFD49--