Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/138174/?format=api
http://patches.dpdk.org/api/patches/138174/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20240311232112.736613-3-yoan.picchi@arm.com/", "project": { "id": 1, "url": "http://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<20240311232112.736613-3-yoan.picchi@arm.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20240311232112.736613-3-yoan.picchi@arm.com", "date": "2024-03-11T23:21:10", "name": "[v6,2/4] hash: optimize compare signature for NEON", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "bf56cf77254e0eeac2ae13927c16cc704ba16ac5", "submitter": { "id": 3196, "url": "http://patches.dpdk.org/api/people/3196/?format=api", "name": "Yoan Picchi", "email": "yoan.picchi@arm.com" }, "delegate": { "id": 1, "url": "http://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/20240311232112.736613-3-yoan.picchi@arm.com/mbox/", "series": [ { "id": 31467, "url": "http://patches.dpdk.org/api/series/31467/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=31467", "date": "2024-03-11T23:21:08", "name": "hash: add SVE support for bulk key lookup", "version": 6, "mbox": "http://patches.dpdk.org/series/31467/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/138174/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/138174/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@inbox.dpdk.org", "Delivered-To": "patchwork@inbox.dpdk.org", "Received": [ "from mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 5C16C43C5A;\n\tTue, 12 Mar 2024 00:21:34 +0100 (CET)", "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 954BA40ED8;\n\tTue, 12 Mar 2024 00:21:27 +0100 (CET)", "from foss.arm.com (foss.arm.com [217.140.110.172])\n by mails.dpdk.org (Postfix) with ESMTP id 30A7D40289\n for <dev@dpdk.org>; Tue, 12 Mar 2024 00:21:23 +0100 (CET)", "from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14])\n by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id A386A153B;\n Mon, 11 Mar 2024 16:21:59 -0700 (PDT)", "from octeon10-1.usa.Arm.com (unknown [10.118.91.161])\n by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 67F503F64C;\n Mon, 11 Mar 2024 16:21:22 -0700 (PDT)" ], "From": "Yoan Picchi <yoan.picchi@arm.com>", "To": "Yipeng Wang <yipeng1.wang@intel.com>,\n Sameh Gobriel <sameh.gobriel@intel.com>,\n Bruce Richardson <bruce.richardson@intel.com>,\n Vladimir Medvedkin <vladimir.medvedkin@intel.com>", "Cc": "dev@dpdk.org, nd@arm.com, Yoan Picchi <yoan.picchi@arm.com>,\n Ruifeng Wang <ruifeng.wang@arm.com>, Nathan Brown <nathan.brown@arm.com>", "Subject": "[PATCH v6 2/4] hash: optimize compare signature for NEON", "Date": "Mon, 11 Mar 2024 23:21:10 +0000", "Message-Id": "<20240311232112.736613-3-yoan.picchi@arm.com>", "X-Mailer": "git-send-email 2.25.1", "In-Reply-To": "<20240311232112.736613-1-yoan.picchi@arm.com>", "References": "<20231020165159.1649282-1-yoan.picchi@arm.com>\n <20240311232112.736613-1-yoan.picchi@arm.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 <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org" }, "content": "Upon a successful comparison, NEON sets all the bits in the lane to 1\nWe can skip shifting by simply masking with specific masks.\n\nSigned-off-by: Yoan Picchi <yoan.picchi@arm.com>\nReviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>\nReviewed-by: Nathan Brown <nathan.brown@arm.com>\n---\n lib/hash/arch/arm/compare_signatures.h | 24 +++++++++++-------------\n 1 file changed, 11 insertions(+), 13 deletions(-)", "diff": "diff --git a/lib/hash/arch/arm/compare_signatures.h b/lib/hash/arch/arm/compare_signatures.h\nindex 1af6ba8190..b5a457f936 100644\n--- a/lib/hash/arch/arm/compare_signatures.h\n+++ b/lib/hash/arch/arm/compare_signatures.h\n@@ -30,23 +30,21 @@ compare_signatures_dense(uint16_t *hitmask_buffer,\n \tswitch (sig_cmp_fn) {\n #if RTE_HASH_BUCKET_ENTRIES <= 8\n \tcase RTE_HASH_COMPARE_NEON: {\n-\t\tuint16x8_t vmat, vsig, x;\n-\t\tint16x8_t shift = {0, 1, 2, 3, 4, 5, 6, 7};\n-\t\tuint16_t low, high;\n+\t\tuint16x8_t vmat, hit1, hit2;\n+\t\tconst uint16x8_t mask = {0x1, 0x2, 0x4, 0x8, 0x10, 0x20, 0x40, 0x80};\n+\t\tconst uint16x8_t vsig = vld1q_dup_u16((uint16_t const *)&sig);\n \n-\t\tvsig = vld1q_dup_u16((uint16_t const *)&sig);\n \t\t/* Compare all signatures in the primary bucket */\n-\t\tvmat = vceqq_u16(vsig,\n-\t\t\tvld1q_u16((uint16_t const *)prim_bucket_sigs));\n-\t\tx = vshlq_u16(vandq_u16(vmat, vdupq_n_u16(0x0001)), shift);\n-\t\tlow = (uint16_t)(vaddvq_u16(x));\n+\t\tvmat = vceqq_u16(vsig, vld1q_u16(prim_bucket_sigs));\n+\t\thit1 = vandq_u16(vmat, mask);\n+\n \t\t/* Compare all signatures in the secondary bucket */\n-\t\tvmat = vceqq_u16(vsig,\n-\t\t\tvld1q_u16((uint16_t const *)sec_bucket_sigs));\n-\t\tx = vshlq_u16(vandq_u16(vmat, vdupq_n_u16(0x0001)), shift);\n-\t\thigh = (uint16_t)(vaddvq_u16(x));\n-\t\t*hitmask_buffer = low | high << RTE_HASH_BUCKET_ENTRIES;\n+\t\tvmat = vceqq_u16(vsig, vld1q_u16(sec_bucket_sigs));\n+\t\thit2 = vandq_u16(vmat, mask);\n \n+\t\thit2 = vshlq_n_u16(hit2, RTE_HASH_BUCKET_ENTRIES);\n+\t\thit2 = vorrq_u16(hit1, hit2);\n+\t\t*hitmask_buffer = vaddvq_u16(hit2);\n \t\t}\n \t\tbreak;\n #endif\n", "prefixes": [ "v6", "2/4" ] }{ "id": 138174, "url": "