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 DEF0145614; Fri, 12 Jul 2024 17:47:58 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9303D42F4D; Fri, 12 Jul 2024 17:47:05 +0200 (CEST) Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) by mails.dpdk.org (Postfix) with ESMTP id 098E442ED4 for ; Fri, 12 Jul 2024 17:47:00 +0200 (CEST) Received: by mail-wr1-f50.google.com with SMTP id ffacd0b85a97d-36786081ac8so1187176f8f.0 for ; Fri, 12 Jul 2024 08:47:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance.com; s=google; t=1720799219; x=1721404019; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=0fXJ6t0d2zAO6sEyqI+7xcaVC7kKapC5S+fh1vOf4A0=; b=icHIfJH8yhbNbSN1m5jSV3UBoUFDkJr2W9tVxXk2LhZe3tlKFpQTuuwobxMNoKyk0F mHZX018KScVyT0+NaNpqVjUIgfvv6Bbn6Syw64KYmtxFHkA/bTFHaDHAjDONHxwHxM99 F/5ndLRh6cOf+pUoYoxhJYMQLK/itvoBckg9GJ5MZ6R0s1d4+pMXI7b+IM5it/b/8cd+ T1fYaNPGDTIf7kJ3Iefn2feoweq6dQoudQM2QywJLczsQuuYpU8ix2ZZp5NBT3TB9AxA TzltAmGCplfhEtX6j12i3ikZ+oyrdinx3FK5ClkZ51pFoaRouVMFOaYekVtnr5WXUxLt Q2sg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720799219; x=1721404019; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0fXJ6t0d2zAO6sEyqI+7xcaVC7kKapC5S+fh1vOf4A0=; b=NOiij7YJzE8nDMohIBf2n9GNNZ0XtKgyFYZ4CxGNaN9uZGenAg7DEosSTbwJ1pD1Qr 3eaprihIxjslnU56Ne1TgUgpnCXKfpOBDhgMNh0j03E/Kps4JLl4Z2BdUzQD4lVrLPPW qjk2DPc1/GIn4Hz6+tbeSQj1y9oA9RhgTXsTX96c1pqM+tiWTSqv1po1FEdQ3KrQTjxI DJDpzwbOiV2emj9YHe+Sx/3PKRU7JLN5Wb2jJBKiD1/iZI/QJBmNAMzRt0Cz6YUIY57p CXb53EbLwJjAOxu4PcZ9bKqRMZdtwFCN5T6GL+CFCObNMhtufMicPWBypBoxeRTEMt5+ 12BQ== X-Gm-Message-State: AOJu0Yxs/z/NT7XarN/eN+fyRUc4SE4lu3o7RYUXEuMHEsKDrdK0yrQA jjrCsTavw0ApfpnDT9gfCJUrCd3JtjlwFgD8gw856Hmi+8M7JuVXUoDIORwgasY= X-Google-Smtp-Source: AGHT+IGaJ9vehuQRXpfwwo0wl9tpg6LsVipmYt2e0ZRBstOWgMy4FvQwTITiR8IV7HT8GP6tKtQ2cw== X-Received: by 2002:a5d:5052:0:b0:367:9904:e6b9 with SMTP id ffacd0b85a97d-367ceacb545mr9023930f8f.44.1720799219758; Fri, 12 Jul 2024 08:46:59 -0700 (PDT) Received: from C02FF2N1MD6T.bytedance.net (ec2-3-9-240-80.eu-west-2.compute.amazonaws.com. [3.9.240.80]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-367cde7e023sm10468615f8f.13.2024.07.12.08.46.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Jul 2024 08:46:59 -0700 (PDT) From: Daniel Gregory To: Stanislaw Kardach , Yipeng Wang , Sameh Gobriel Cc: dev@dpdk.org, Punit Agrawal , Liang Ma , Pengcheng Wang , Chunsong Feng , Daniel Gregory Subject: [PATCH v2 9/9] member: use accelerated crc on riscv Date: Fri, 12 Jul 2024 16:46:45 +0100 Message-Id: <20240712154645.80622-10-daniel.gregory@bytedance.com> X-Mailer: git-send-email 2.39.3 (Apple Git-146) In-Reply-To: <20240712154645.80622-1-daniel.gregory@bytedance.com> References: <20240618174133.33457-1-daniel.gregory@bytedance.com> <20240712154645.80622-1-daniel.gregory@bytedance.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org When the RISC-V Zbc (carryless multiplication) extension is present, an implementation of CRC hashing using hardware instructions is available. Use it rather than jhash. Signed-off-by: Daniel Gregory --- lib/member/rte_member.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/member/rte_member.h b/lib/member/rte_member.h index aec192eba5..152659628a 100644 --- a/lib/member/rte_member.h +++ b/lib/member/rte_member.h @@ -92,7 +92,7 @@ typedef uint16_t member_set_t; #define RTE_MEMBER_SKETCH_COUNT_BYTE 0x02 /** @internal Hash function used by membership library. */ -#if defined(RTE_ARCH_X86) || defined(__ARM_FEATURE_CRC32) +#if defined(RTE_ARCH_X86) || defined(__ARM_FEATURE_CRC32) || defined(RTE_RISCV_FEATURE_ZBC) #include #define MEMBER_HASH_FUNC rte_hash_crc #else -- 2.39.2