get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/49388/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 49388,
    "url": "https://patches.dpdk.org/api/patches/49388/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/1546483094-29712-2-git-send-email-gavin.hu@arm.com/",
    "project": {
        "id": 1,
        "url": "https://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": "<1546483094-29712-2-git-send-email-gavin.hu@arm.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1546483094-29712-2-git-send-email-gavin.hu@arm.com",
    "date": "2019-01-03T02:38:12",
    "name": "[v5,1/3] test/ring: ring perf test case enhancement",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "5c1cf656f1afa97a9b45c6d02763b16b60163e57",
    "submitter": {
        "id": 1018,
        "url": "https://patches.dpdk.org/api/people/1018/?format=api",
        "name": "Gavin Hu",
        "email": "gavin.hu@arm.com"
    },
    "delegate": {
        "id": 1,
        "url": "https://patches.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/1546483094-29712-2-git-send-email-gavin.hu@arm.com/mbox/",
    "series": [
        {
            "id": 2992,
            "url": "https://patches.dpdk.org/api/series/2992/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=2992",
            "date": "2019-01-03T02:38:11",
            "name": "ring test enhancement and new ring reset api and use it by hash",
            "version": 5,
            "mbox": "https://patches.dpdk.org/series/2992/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/49388/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/49388/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 824801B144;\n\tThu,  3 Jan 2019 03:38:32 +0100 (CET)",
            "from foss.arm.com (foss.arm.com [217.140.101.70])\n\tby dpdk.org (Postfix) with ESMTP id BCF3A1B130\n\tfor <dev@dpdk.org>; Thu,  3 Jan 2019 03:38:30 +0100 (CET)",
            "from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249])\n\tby usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0CC9A1596;\n\tWed,  2 Jan 2019 18:38:30 -0800 (PST)",
            "from net-arm-c2400.shanghai.arm.com (net-arm-c2400.shanghai.arm.com\n\t[10.169.40.108])\n\tby usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id\n\t4FFFC3F5AF; Wed,  2 Jan 2019 18:38:28 -0800 (PST)"
        ],
        "From": "gavin hu <gavin.hu@arm.com>",
        "To": "dev@dpdk.org",
        "Cc": "nd@arm.com, thomas@monjalon.net, jerinj@marvell.com,\n\themant.agrawal@nxp.com, Honnappa.Nagarahalli@arm.com, gavin.hu@arm.com,\n\tolivier.matz@6wind.com, bruce.richardson@intel.com,\n\tferruh.yigit@intel.com, Joyce Kong <joyce.kong@arm.com>",
        "Date": "Thu,  3 Jan 2019 10:38:12 +0800",
        "Message-Id": "<1546483094-29712-2-git-send-email-gavin.hu@arm.com>",
        "X-Mailer": "git-send-email 2.7.4",
        "In-Reply-To": "<1546483094-29712-1-git-send-email-gavin.hu@arm.com>",
        "References": "<1546390533-53868-1-git-send-email-gavin.hu@arm.com>\n\t<1546483094-29712-1-git-send-email-gavin.hu@arm.com>",
        "Subject": "[dpdk-dev] [PATCH v5 1/3] test/ring: ring perf test case enhancement",
        "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": "From: Joyce Kong <joyce.kong@arm.com>\n\nRun ring perf test on all available cores to really verify MPMC operations.\nThe old way of running on a pair of cores is not enough for MPMC rings.\n\nSuggested-by: gavin hu <gavin.hu@arm.com>\nSigned-off-by: joyce kong <joyce.kong@arm.com>\nReviewed-by: ruifeng wang <ruifeng.wang@arm.com>\nReviewed-by: honnappa nagarahalli <honnappa.nagarahalli@arm.com>\nReviewed-by: dharmik thakkar <dharmik.thakkar@arm.com>\nReviewed-by: ola liljedahl <ola.liljedahl@arm.com>\nReviewed-by: gavin hu <gavin.hu@arm.com>\n---\n test/test/test_ring_perf.c | 82 ++++++++++++++++++++++++++++++++++++++++++++--\n 1 file changed, 79 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/test/test/test_ring_perf.c b/test/test/test_ring_perf.c\nindex ebb3939..01c6937 100644\n--- a/test/test/test_ring_perf.c\n+++ b/test/test/test_ring_perf.c\n@@ -9,7 +9,7 @@\n #include <rte_cycles.h>\n #include <rte_launch.h>\n #include <rte_pause.h>\n-\n+#include <string.h>\n #include \"test.h\"\n \n /*\n@@ -20,6 +20,7 @@\n  *  * Empty ring dequeue\n  *  * Enqueue/dequeue of bursts in 1 threads\n  *  * Enqueue/dequeue of bursts in 2 threads\n+ *  * Enqueue/dequeue of bursts in all available threads\n  */\n \n #define RING_NAME \"RING_PERF\"\n@@ -248,9 +249,80 @@ run_on_core_pair(struct lcore_pair *cores, struct rte_ring *r,\n \t}\n }\n \n+static rte_atomic32_t synchro;\n+static uint64_t queue_count[RTE_MAX_LCORE];\n+\n+#define TIME_MS 100\n+\n+static int\n+load_loop_fn(void *p)\n+{\n+\tuint64_t time_diff = 0;\n+\tuint64_t begin = 0;\n+\tuint64_t hz = rte_get_timer_hz();\n+\tuint64_t lcount = 0;\n+\tconst unsigned int lcore = rte_lcore_id();\n+\tstruct thread_params *params = p;\n+\tvoid *burst[MAX_BURST] = {0};\n+\n+\t/* wait synchro for slaves */\n+\tif (lcore != rte_get_master_lcore())\n+\t\twhile (rte_atomic32_read(&synchro) == 0)\n+\t\t\trte_pause();\n+\n+\tbegin = rte_get_timer_cycles();\n+\twhile (time_diff < hz * TIME_MS / 1000) {\n+\t\trte_ring_mp_enqueue_bulk(params->r, burst, params->size, NULL);\n+\t\trte_ring_mc_dequeue_bulk(params->r, burst, params->size, NULL);\n+\t\tlcount++;\n+\t\ttime_diff = rte_get_timer_cycles() - begin;\n+\t}\n+\tqueue_count[lcore] = lcount;\n+\treturn 0;\n+}\n+\n+static int\n+run_on_all_cores(struct rte_ring *r)\n+{\n+\tuint64_t total = 0;\n+\tunsigned int i, c;\n+\tstruct thread_params param;\n+\n+\tmemset(&param, 0, sizeof(struct thread_params));\n+\tfor (i = 0; i < RTE_DIM(bulk_sizes); i++) {\n+\t\tprintf(\"\\nBulk enq/dequeue count on size %u\\n\", bulk_sizes[i]);\n+\t\tparam.size = bulk_sizes[i];\n+\t\tparam.r = r;\n+\n+\t\t/* clear synchro and start slaves */\n+\t\trte_atomic32_set(&synchro, 0);\n+\t\tif (rte_eal_mp_remote_launch(load_loop_fn,\n+\t\t\t\t&param, SKIP_MASTER) < 0)\n+\t\t\treturn -1;\n+\n+\t\t/* start synchro and launch test on master */\n+\t\trte_atomic32_set(&synchro, 1);\n+\t\tload_loop_fn(&param);\n+\n+\t\trte_eal_mp_wait_lcore();\n+\n+\t\tRTE_LCORE_FOREACH(c) {\n+\t\t\tprintf(\"Core [%u] count = %\"PRIu64\"\\n\",\n+\t\t\t\t\tc, queue_count[c]);\n+\t\t\ttotal += queue_count[c];\n+\t\t}\n+\n+\t\tprintf(\"Total count (size: %u): %\"PRIu64\"\\n\", bulk_sizes[i],\n+\t\t\t\t\t\ttotal);\n+\t}\n+\n+\treturn 0;\n+}\n+\n /*\n- * Test function that determines how long an enqueue + dequeue of a single item\n- * takes on a single lcore. Result is for comparison with the bulk enq+deq.\n+ * Test function that determines how long an enqueue + dequeue of a single\n+ * item takes on a single lcore. Result is for comparison with the bulk\n+ * enq+deq.\n  */\n static void\n test_single_enqueue_dequeue(struct rte_ring *r)\n@@ -394,6 +466,10 @@ test_ring_perf(void)\n \t\tprintf(\"\\n### Testing using two NUMA nodes ###\\n\");\n \t\trun_on_core_pair(&cores, r, enqueue_bulk, dequeue_bulk);\n \t}\n+\n+\tprintf(\"\\n### Testing using all slave nodes ###\\n\");\n+\trun_on_all_cores(r);\n+\n \trte_ring_free(r);\n \treturn 0;\n }\n",
    "prefixes": [
        "v5",
        "1/3"
    ]
}