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 C08A441D52 for ; Thu, 23 Feb 2023 16:06:57 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BBD4843228; Thu, 23 Feb 2023 16:06:57 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id BBC2043228 for ; Thu, 23 Feb 2023 16:06:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1677164816; 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=6AbmsKQdmZln+0Phb21R+WIlzZjWK2qZs8TlYudPSg8=; b=MU4pTD83mk8JWiDXehNxoiwqBJWWbkdzaena6hCZj1ufqNWpmT+A8gk35jq8zLUDMq5nMq YOsUe7NHn5FfqbD0N9r+sM1lOg6lj930uYXNqnPKiaTDRuycpknyampbu9RCfcibgs5DP/ KJU0/d2Ywjwp2bBlJAYlbzyIXJDFK7E= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-230-oupRe8LyP8e-yalfTYOhrg-1; Thu, 23 Feb 2023 10:06:55 -0500 X-MC-Unique: oupRe8LyP8e-yalfTYOhrg-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id D90F0857A89; Thu, 23 Feb 2023 15:06:53 +0000 (UTC) Received: from rh.redhat.com (unknown [10.39.192.53]) by smtp.corp.redhat.com (Postfix) with ESMTP id 123F72166B29; Thu, 23 Feb 2023 15:06:52 +0000 (UTC) From: Kevin Traynor To: David Marchand Cc: Bruce Richardson , dpdk stable Subject: patch 'hash: fix GFNI implementation build with GCC 12' has been queued to stable release 21.11.4 Date: Thu, 23 Feb 2023 15:04:53 +0000 Message-Id: <20230223150631.723699-2-ktraynor@redhat.com> In-Reply-To: <20230223150631.723699-1-ktraynor@redhat.com> References: <20230223150631.723699-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Hi, FYI, your patch has been queued to stable release 21.11.4 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 02/28/23. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/kevintraynor/dpdk-stable This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable/commit/47951ef1dc21882215a531472d055c58a7618cb0 Thanks. Kevin --- >From 47951ef1dc21882215a531472d055c58a7618cb0 Mon Sep 17 00:00:00 2001 From: David Marchand Date: Mon, 9 Jan 2023 11:03:37 +0100 Subject: [PATCH] hash: fix GFNI implementation build with GCC 12 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [ upstream commit fe2c18a0a8b22703dec3add385a371ad819d7872 ] On a system that has AVX512F and GFNI, compiling fails with: In file included from /usr/lib/gcc/x86_64-redhat-linux/12/include/immintrin.h:71, from /usr/lib/gcc/x86_64-redhat-linux/12/include/x86intrin.h:32, from ../../../git/pub/dpdk.org/main/lib/eal/x86/include/rte_vect.h:31, from ../../../git/pub/dpdk.org/main/lib/eal/x86/include/rte_memcpy.h:17, from ../../../git/pub/dpdk.org/main/lib/mempool/rte_mempool.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:33, 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 ‘_mm512_mask_permutexvar_epi8’, inlined from ‘__rte_thash_gfni’ at ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:142:17, inlined from ‘rte_thash_gfni’ at ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:182:20, inlined from ‘rte_thash_adjust_tuple’ 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: ‘tuple_bytes’ may be used uninitialized [-Werror=maybe-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 ‘rte_thash_adjust_tuple’: ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:91:33: note: ‘tuple_bytes’ was declared here 91 | __m512i vals, matrixes, tuple_bytes, tuple_bytes_2; | ^~~~~~~~~~~ In function ‘_mm512_mask_permutexvar_epi8’, inlined from ‘__rte_thash_gfni’ at ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:142:17, inlined from ‘rte_thash_gfni’ at ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:182:20, inlined from ‘rte_thash_adjust_tuple’ 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: ‘permute_mask’ may be used uninitialized [-Werror=maybe-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 ‘rte_thash_adjust_tuple’: ../../../git/pub/dpdk.org/main/lib/hash/rte_thash_x86_gfni.h:92:30: note: ‘permute_mask’ 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") Signed-off-by: David Marchand Acked-by: Bruce Richardson --- lib/hash/rte_thash_x86_gfni.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/hash/rte_thash_x86_gfni.h b/lib/hash/rte_thash_x86_gfni.h index 657b1862c3..0583f64793 100644 --- a/lib/hash/rte_thash_x86_gfni.h +++ b/lib/hash/rte_thash_x86_gfni.h @@ -88,6 +88,8 @@ __rte_thash_gfni(const uint64_t *mtrx, const uint8_t *tuple, __m512i xor_acc = _mm512_setzero_si512(); __m512i perm_bytes = _mm512_setzero_si512(); - __m512i vals, matrixes, tuple_bytes, tuple_bytes_2; - __mmask64 load_mask, permute_mask, permute_mask_2; + __m512i vals, matrixes, tuple_bytes_2; + __m512i tuple_bytes = _mm512_setzero_si512(); + __mmask64 load_mask, permute_mask_2; + __mmask64 permute_mask = 0; int chunk_len = 0, i = 0; uint8_t mtrx_msk; -- 2.39.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-02-23 14:46:23.930075333 +0000 +++ 0002-hash-fix-GFNI-implementation-build-with-GCC-12.patch 2023-02-23 14:46:23.695235704 +0000 @@ -1 +1 @@ -From fe2c18a0a8b22703dec3add385a371ad819d7872 Mon Sep 17 00:00:00 2001 +From 47951ef1dc21882215a531472d055c58a7618cb0 Mon Sep 17 00:00:00 2001 @@ -8,0 +9,2 @@ +[ upstream commit fe2c18a0a8b22703dec3add385a371ad819d7872 ] + @@ -76 +77,0 @@ -Cc: stable@dpdk.org @@ -85 +86 @@ -index 880739b710..7bb76ac1bb 100644 +index 657b1862c3..0583f64793 100644 @@ -88 +89 @@ -@@ -89,6 +89,8 @@ __rte_thash_gfni(const uint64_t *mtrx, const uint8_t *tuple, +@@ -88,6 +88,8 @@ __rte_thash_gfni(const uint64_t *mtrx, const uint8_t *tuple,