Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/42754/?format=api
http://patches.dpdk.org/api/patches/42754/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/1531242001-381104-7-git-send-email-yipeng1.wang@intel.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": "<1531242001-381104-7-git-send-email-yipeng1.wang@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1531242001-381104-7-git-send-email-yipeng1.wang@intel.com", "date": "2018-07-10T16:59:59", "name": "[v5,6/8] test: add tests in hash table perf test", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "7278f7d5c1372d0c7e753f649b0b9984330af1aa", "submitter": { "id": 754, "url": "http://patches.dpdk.org/api/people/754/?format=api", "name": "Wang, Yipeng1", "email": "yipeng1.wang@intel.com" }, "delegate": null, "mbox": "http://patches.dpdk.org/project/dpdk/patch/1531242001-381104-7-git-send-email-yipeng1.wang@intel.com/mbox/", "series": [ { "id": 506, "url": "http://patches.dpdk.org/api/series/506/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=506", "date": "2018-07-10T16:59:53", "name": "Add read-write concurrency to rte_hash library", "version": 5, "mbox": "http://patches.dpdk.org/series/506/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/42754/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/42754/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 93F661B43F;\n\tWed, 11 Jul 2018 02:07:27 +0200 (CEST)", "from mga14.intel.com (mga14.intel.com [192.55.52.115])\n\tby dpdk.org (Postfix) with ESMTP id 994671B1EC\n\tfor <dev@dpdk.org>; Wed, 11 Jul 2018 02:07:17 +0200 (CEST)", "from orsmga002.jf.intel.com ([10.7.209.21])\n\tby fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t10 Jul 2018 17:07:13 -0700", "from skx-yipeng.jf.intel.com ([10.54.81.175])\n\tby orsmga002.jf.intel.com with ESMTP; 10 Jul 2018 17:07:12 -0700" ], "X-Amp-Result": "SKIPPED(no attachment in message)", "X-Amp-File-Uploaded": "False", "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.51,336,1526367600\"; d=\"scan'208\";a=\"73792737\"", "From": "Yipeng Wang <yipeng1.wang@intel.com>", "To": "pablo.de.lara.guarch@intel.com", "Cc": "dev@dpdk.org, yipeng1.wang@intel.com, bruce.richardson@intel.com,\n\thonnappa.nagarahalli@arm.com, vguvva@caviumnetworks.com,\n\tbrijesh.s.singh@gmail.com", "Date": "Tue, 10 Jul 2018 09:59:59 -0700", "Message-Id": "<1531242001-381104-7-git-send-email-yipeng1.wang@intel.com>", "X-Mailer": "git-send-email 2.7.4", "In-Reply-To": "<1531242001-381104-1-git-send-email-yipeng1.wang@intel.com>", "References": "<1528455078-328182-1-git-send-email-yipeng1.wang@intel.com>\n\t<1531242001-381104-1-git-send-email-yipeng1.wang@intel.com>", "Subject": "[dpdk-dev] [PATCH v5 6/8] test: add tests in hash table perf test", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n\t<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\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "New code is added to support read-write concurrency for\nrte_hash. Due to the newly added code in critial path,\nthe perf test is modified to show any performance impact.\nIt is still a single-thread test.\n\nSigned-off-by: Yipeng Wang <yipeng1.wang@intel.com>\nAcked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>\n---\n test/test/test_hash_perf.c | 36 +++++++++++++++++++++++++-----------\n 1 file changed, 25 insertions(+), 11 deletions(-)", "diff": "diff --git a/test/test/test_hash_perf.c b/test/test/test_hash_perf.c\nindex a81d0c7..33dcb9f 100644\n--- a/test/test/test_hash_perf.c\n+++ b/test/test/test_hash_perf.c\n@@ -76,7 +76,8 @@ static struct rte_hash_parameters ut_params = {\n };\n \n static int\n-create_table(unsigned with_data, unsigned table_index)\n+create_table(unsigned int with_data, unsigned int table_index,\n+\t\tunsigned int with_locks)\n {\n \tchar name[RTE_HASH_NAMESIZE];\n \n@@ -86,6 +87,14 @@ create_table(unsigned with_data, unsigned table_index)\n \telse\n \t\tsprintf(name, \"test_hash%d\", hashtest_key_lens[table_index]);\n \n+\n+\tif (with_locks)\n+\t\tut_params.extra_flag =\n+\t\t\tRTE_HASH_EXTRA_FLAGS_TRANS_MEM_SUPPORT\n+\t\t\t\t| RTE_HASH_EXTRA_FLAGS_RW_CONCURRENCY;\n+\telse\n+\t\tut_params.extra_flag = 0;\n+\n \tut_params.name = name;\n \tut_params.key_len = hashtest_key_lens[table_index];\n \tut_params.socket_id = rte_socket_id();\n@@ -459,7 +468,7 @@ reset_table(unsigned table_index)\n }\n \n static int\n-run_all_tbl_perf_tests(unsigned with_pushes)\n+run_all_tbl_perf_tests(unsigned int with_pushes, unsigned int with_locks)\n {\n \tunsigned i, j, with_data, with_hash;\n \n@@ -468,7 +477,7 @@ run_all_tbl_perf_tests(unsigned with_pushes)\n \n \tfor (with_data = 0; with_data <= 1; with_data++) {\n \t\tfor (i = 0; i < NUM_KEYSIZES; i++) {\n-\t\t\tif (create_table(with_data, i) < 0)\n+\t\t\tif (create_table(with_data, i, with_locks) < 0)\n \t\t\t\treturn -1;\n \n \t\t\tif (get_input_keys(with_pushes, i) < 0)\n@@ -611,15 +620,20 @@ fbk_hash_perf_test(void)\n static int\n test_hash_perf(void)\n {\n-\tunsigned with_pushes;\n-\n-\tfor (with_pushes = 0; with_pushes <= 1; with_pushes++) {\n-\t\tif (with_pushes == 0)\n-\t\t\tprintf(\"\\nALL ELEMENTS IN PRIMARY LOCATION\\n\");\n+\tunsigned int with_pushes, with_locks;\n+\tfor (with_locks = 0; with_locks <= 1; with_locks++) {\n+\t\tif (with_locks)\n+\t\t\tprintf(\"\\nWith locks in the code\\n\");\n \t\telse\n-\t\t\tprintf(\"\\nELEMENTS IN PRIMARY OR SECONDARY LOCATION\\n\");\n-\t\tif (run_all_tbl_perf_tests(with_pushes) < 0)\n-\t\t\treturn -1;\n+\t\t\tprintf(\"\\nWithout locks in the code\\n\");\n+\t\tfor (with_pushes = 0; with_pushes <= 1; with_pushes++) {\n+\t\t\tif (with_pushes == 0)\n+\t\t\t\tprintf(\"\\nALL ELEMENTS IN PRIMARY LOCATION\\n\");\n+\t\t\telse\n+\t\t\t\tprintf(\"\\nELEMENTS IN PRIMARY OR SECONDARY LOCATION\\n\");\n+\t\t\tif (run_all_tbl_perf_tests(with_pushes, with_locks) < 0)\n+\t\t\t\treturn -1;\n+\t\t}\n \t}\n \tif (fbk_hash_perf_test() < 0)\n \t\treturn -1;\n", "prefixes": [ "v5", "6/8" ] }{ "id": 42754, "url": "