From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 935554238D for ; Mon, 9 Jan 2023 18:47:24 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 70E7640689; Mon, 9 Jan 2023 18:47:24 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id C345640150 for ; Mon, 9 Jan 2023 18:47:23 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1673286443; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=T3s+wwk9MA9vLIrP/xGGeVc1OVVNuZi8OepuvLnJ8nM=; b=dwHcHYEO4BoCbCiGpguS8sPtb070sVyduXzqbJbCW4ZOml8/51YQzT5wVoh/Q0UmEED7Gs 6U8kY4w5x/u5vPPKeD/0SEnFmWlPJOOaPOkPbSbwA2Ng53Y0mxBrTJFzx8j/CTUL0sBLmD B72vlBJasl/kyl/EXdqk/fcOjn1MGug= Received: from mail-pj1-f70.google.com (mail-pj1-f70.google.com [209.85.216.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-639-sRiRdbjhOI-G3k4gv1iH1Q-1; Mon, 09 Jan 2023 12:47:21 -0500 X-MC-Unique: sRiRdbjhOI-G3k4gv1iH1Q-1 Received: by mail-pj1-f70.google.com with SMTP id r5-20020a17090a1bc500b00227067dde1eso1628234pjr.0 for ; Mon, 09 Jan 2023 09:47:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=T3s+wwk9MA9vLIrP/xGGeVc1OVVNuZi8OepuvLnJ8nM=; b=Igm+Ad+m8OIRVuSE6a9hRjDolhcnmrnmqpgEvkZX/o2+KjWHDCmElahgSDpzlQzbCx ypcRC1xjM/g6NAlHRmNCDAVlTqOKG02d/MCcXZXTk00L+X+IELH2E0KgIgak+2/E8LHw KWrjFPR3hfVN1NLhymCxROmS2FA5FdgLnPQgBLpr3uFK9Si+0M4Kagm9yuNlPjQ905ja 28Y/mSq2aiMEpygOfHQPrZd+u/Nd8K1gTPK5mCSZdCeFPrZQiKsLTGzLMnDzceumd6qQ vVrWRP2xu/CJsJB4KAMwSDN4Eunw2Ta3cKIpx7/3Fjnlx1fpjxJeTkdvDklMYxXZGFgx 94LQ== X-Gm-Message-State: AFqh2korJd0nfnj5WqkJH/2HIJUFp1/HO2rCZXncAvvPOU9j+r3sgDBT a/FOu+QWr4m5o6Hv9IVNo8/Z6YQzq5VvJLIa44/y9EzXEMSwfqRSVD2HyC9aTrYhu2MLC4xAzC3 zVcxf01oOLRKpLkTcVr+Yyvw= X-Received: by 2002:a17:90b:264d:b0:226:1564:643c with SMTP id pa13-20020a17090b264d00b002261564643cmr3318822pjb.206.1673286440888; Mon, 09 Jan 2023 09:47:20 -0800 (PST) X-Google-Smtp-Source: AMrXdXvku1Jooy3zmE52b8tTtEd7U7o834tR5zXw8PxUCJn7ViLH4ZqXCbu9WZ0Z1f5UXoSdf3ehgh81TLsdCnZGHvM= X-Received: by 2002:a17:90b:264d:b0:226:1564:643c with SMTP id pa13-20020a17090b264d00b002261564643cmr3318816pjb.206.1673286440495; Mon, 09 Jan 2023 09:47:20 -0800 (PST) MIME-Version: 1.0 References: <20230109100337.714937-1-david.marchand@redhat.com> In-Reply-To: From: David Marchand Date: Mon, 9 Jan 2023 18:47:09 +0100 Message-ID: Subject: Re: [PATCH] hash: fix GFNI implementation build with GCC 12 To: David Marchand Cc: Bruce Richardson , dev@dpdk.org, Yipeng Wang , Sameh Gobriel , Vladimir Medvedkin , stable@dpdk.org X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org On Mon, Jan 9, 2023 at 11:24 AM Bruce Richardson wrote: > On Mon, Jan 09, 2023 at 11:03:37AM +0100, David Marchand wrote: > > On a system that has AVX512F and GFNI, compiling fails with: > > > > In file included from /usr/lib/gcc/x86_64-redhat-linux/12/include/immin= trin.h:71, > > from /usr/lib/gcc/x86_64-redhat-linux/12/include/x86in= trin.h:32, > > from ../../../git/pub/dpdk.org/main/lib/eal/x86/includ= e/rte_vect.h:31, > > from ../../../git/pub/dpdk.org/main/lib/eal/x86/includ= e/rte_memcpy.h:17, > > from ../../../git/pub/dpdk.org/main/lib/mempool/rte_me= mpool.h:48, > > from ../../../git/pub/dpdk.org/main/lib/mbuf/rte_mbuf.= h:38, > > from ../../../git/pub/dpdk.org/main/lib/net/rte_ip.h:3= 3, > > from ../../../git/pub/dpdk.org/main/lib/hash/rte_thash= .h:25, > > from ../../../git/pub/dpdk.org/main/lib/hash/rte_thash= .c:7: > > In function =E2=80=98_mm512_mask_permutexvar_epi8=E2=80=99, > > inlined from =E2=80=98__rte_thash_gfni=E2=80=99 at > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:142:= 17, > > inlined from =E2=80=98rte_thash_gfni=E2=80=99 at > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:182:= 20, > > inlined from =E2=80=98rte_thash_adjust_tuple=E2=80=99 at > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash.c:784:11: > > /usr/lib/gcc/x86_64-redhat-linux/12/include/avx512vbmiintrin.h:97:20: > > error: =E2=80=98tuple_bytes=E2=80=99 may be used uninitialized [-= Werror=3Dmaybe-uninitialized] > > 97 | return (__m512i) __builtin_ia32_permvarqi512_mask ((__v64qi) = __B, > > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~= ~~~~ > > 98 | (__v64qi) = __A, > > | ~~~~~~~~~~= ~~~~ > > 99 | (__v64qi) = __W, > > | ~~~~~~~~~~= ~~~~ > > 100 | (__mmask64= ) __M); > > | ~~~~~~~~~~= ~~~~~~ > > > > And: > > > > In file included from ../../../git/pub/dpdk.org/main/lib/hash/rte_thash= _gfni.h:17, > > from ../../../git/pub/dpdk.org/main/lib/hash/rte_thash= .h:27: > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h: > > In function =E2=80=98rte_thash_adjust_tuple=E2=80=99: > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:91:33: > > note: =E2=80=98tuple_bytes=E2=80=99 was declared here > > 91 | __m512i vals, matrixes, tuple_bytes, tuple_bytes_2; > > | ^~~~~~~~~~~ > > In function =E2=80=98_mm512_mask_permutexvar_epi8=E2=80=99, > > inlined from =E2=80=98__rte_thash_gfni=E2=80=99 at > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:142:= 17, > > inlined from =E2=80=98rte_thash_gfni=E2=80=99 at > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:182:= 20, > > inlined from =E2=80=98rte_thash_adjust_tuple=E2=80=99 at > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash.c:784:11: > > /usr/lib/gcc/x86_64-redhat-linux/12/include/avx512vbmiintrin.h:97:20: > > error: =E2=80=98permute_mask=E2=80=99 may be used uninitialized [= -Werror=3Dmaybe-uninitialized] > > 97 | return (__m512i) __builtin_ia32_permvarqi512_mask ((__v64qi) = __B, > > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~= ~~~~ > > 98 | (__v64qi) = __A, > > | ~~~~~~~~~~= ~~~~ > > 99 | (__v64qi) = __W, > > | ~~~~~~~~~~= ~~~~ > > 100 | (__mmask64= ) __M); > > | ~~~~~~~~~~= ~~~~~~ > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h: > > In function =E2=80=98rte_thash_adjust_tuple=E2=80=99: > > ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:92:30: > > note: =E2=80=98permute_mask=E2=80=99 was declared here > > 92 | __mmask64 load_mask, permute_mask, permute_mask_2; > > | ^~~~~~~~~~~~ > > cc1: all warnings being treated as errors > > > > Set those variables to 0. > > > > Fixes: 4fd8c4cb0de1 ("hash: add new Toeplitz hash implementation") > > Cc: stable@dpdk.org > > > > Signed-off-by: David Marchand > Acked-by: Bruce Richardson Applied, thanks. --=20 David Marchand