get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 73547,
    "url": "https://patches.dpdk.org/api/patches/73547/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/f344fae24258fc2863ae77144dd5e887c926b6d8.1594238610.git.vladimir.medvedkin@intel.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": "<f344fae24258fc2863ae77144dd5e887c926b6d8.1594238610.git.vladimir.medvedkin@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/f344fae24258fc2863ae77144dd5e887c926b6d8.1594238610.git.vladimir.medvedkin@intel.com",
    "date": "2020-07-08T20:16:13",
    "name": "[v4,8/8] app/testfib: add support for different lookup functions",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "88b6fcf3040c503e4408c5bcfafa76a9df39c4cc",
    "submitter": {
        "id": 1216,
        "url": "https://patches.dpdk.org/api/people/1216/?format=api",
        "name": "Vladimir Medvedkin",
        "email": "vladimir.medvedkin@intel.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/f344fae24258fc2863ae77144dd5e887c926b6d8.1594238610.git.vladimir.medvedkin@intel.com/mbox/",
    "series": [
        {
            "id": 10896,
            "url": "https://patches.dpdk.org/api/series/10896/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=10896",
            "date": "2020-07-08T20:16:05",
            "name": "fib: implement AVX512 vector lookup",
            "version": 4,
            "mbox": "https://patches.dpdk.org/series/10896/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/73547/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/73547/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 dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 3EF99A0526;\n\tWed,  8 Jul 2020 22:18:07 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id F07971E496;\n\tWed,  8 Jul 2020 22:17:04 +0200 (CEST)",
            "from mga18.intel.com (mga18.intel.com [134.134.136.126])\n by dpdk.org (Postfix) with ESMTP id 81BEB1DCDD\n for <dev@dpdk.org>; Wed,  8 Jul 2020 22:16:59 +0200 (CEST)",
            "from fmsmga002.fm.intel.com ([10.253.24.26])\n by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 08 Jul 2020 13:16:59 -0700",
            "from silpixa00400322.ir.intel.com ([10.237.214.86])\n by fmsmga002.fm.intel.com with ESMTP; 08 Jul 2020 13:16:58 -0700"
        ],
        "IronPort-SDR": [
            "\n Qpa4QQNve0F4zWhKrBft5Kss0ta0Qe43at/ajPTV+7QrhrGuzs9Dez3+yIZhFetsP4Z8TdCzib\n DHhWHNo2PkXQ==",
            "\n moOPNMgfClKWhhixnRBNHHzp1kMzZnLfXl9rQ9Y1LPEBm9BWFH1AgBqfNur8RhXZwzO0LB+86B\n hIY0NI2W/dKw=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9676\"; a=\"135346095\"",
            "E=Sophos;i=\"5.75,329,1589266800\"; d=\"scan'208\";a=\"135346095\"",
            "E=Sophos;i=\"5.75,329,1589266800\"; d=\"scan'208\";a=\"315988631\""
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "From": "Vladimir Medvedkin <vladimir.medvedkin@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "konstantin.ananyev@intel.com,\n\tbruce.richardson@intel.com",
        "Date": "Wed,  8 Jul 2020 21:16:13 +0100",
        "Message-Id": "\n <f344fae24258fc2863ae77144dd5e887c926b6d8.1594238610.git.vladimir.medvedkin@intel.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "In-Reply-To": [
            "<cover.1594238609.git.vladimir.medvedkin@intel.com>",
            "<cover.1594238609.git.vladimir.medvedkin@intel.com>"
        ],
        "References": [
            "<cover.1594238609.git.vladimir.medvedkin@intel.com>",
            "<cover.1589890262.git.vladimir.medvedkin@intel.com>\n <cover.1594238609.git.vladimir.medvedkin@intel.com>"
        ],
        "Subject": "[dpdk-dev] [PATCH v4 8/8] app/testfib: add support for different\n\tlookup functions",
        "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 <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",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Added -v option to switch between different lookup implementations\nto measure their performance and correctness.\n\nSigned-off-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>\n---\n app/test-fib/main.c | 58 ++++++++++++++++++++++++++++++++++++++++++---\n 1 file changed, 55 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/app/test-fib/main.c b/app/test-fib/main.c\nindex 9cf01b16e..9c2d41387 100644\n--- a/app/test-fib/main.c\n+++ b/app/test-fib/main.c\n@@ -99,6 +99,7 @@ static struct {\n \tuint8_t\t\tent_sz;\n \tuint8_t\t\trnd_lookup_ips_ratio;\n \tuint8_t\t\tprint_fract;\n+\tuint8_t\t\tlookup_fn;\n } config = {\n \t.routes_file = NULL,\n \t.lookup_ips_file = NULL,\n@@ -110,7 +111,8 @@ static struct {\n \t.tbl8 = DEFAULT_LPM_TBL8,\n \t.ent_sz = 4,\n \t.rnd_lookup_ips_ratio = 0,\n-\t.print_fract = 10\n+\t.print_fract = 10,\n+\t.lookup_fn = 0\n };\n \n struct rt_rule_4 {\n@@ -638,7 +640,11 @@ print_usage(void)\n \t\t\"1/2/4/8 (default 4)>]\\n\"\n \t\t\"[-g <number of tbl8's for dir24_8 or trie FIBs>]\\n\"\n \t\t\"[-w <path to the file to dump routing table>]\\n\"\n-\t\t\"[-u <path to the file to dump ip's for lookup>]\\n\",\n+\t\t\"[-u <path to the file to dump ip's for lookup>]\\n\"\n+\t\t\"[-v <type of loookup function:\"\n+\t\t\"\\ts1, s2, s3 (3 types of scalar), v (vector) -\"\n+\t\t\" for DIR24_8 based FIB\\n\"\n+\t\t\"\\ts, v - for TRIE based ipv6 FIB>]\\n\",\n \t\tconfig.prgname);\n }\n \n@@ -681,7 +687,7 @@ parse_opts(int argc, char **argv)\n \tint opt;\n \tchar *endptr;\n \n-\twhile ((opt = getopt(argc, argv, \"f:t:n:d:l:r:c6ab:e:g:w:u:s\")) !=\n+\twhile ((opt = getopt(argc, argv, \"f:t:n:d:l:r:c6ab:e:g:w:u:sv:\")) !=\n \t\t\t-1) {\n \t\tswitch (opt) {\n \t\tcase 'f':\n@@ -769,6 +775,22 @@ parse_opts(int argc, char **argv)\n \t\t\t\trte_exit(-EINVAL, \"Invalid option -g\\n\");\n \t\t\t}\n \t\t\tbreak;\n+\t\tcase 'v':\n+\t\t\tif ((strcmp(optarg, \"s1\") == 0) ||\n+\t\t\t\t\t(strcmp(optarg, \"s\") == 0))\n+\t\t\t\tbreak;\n+\t\t\telse if (strcmp(optarg, \"v\") == 0) {\n+\t\t\t\tconfig.lookup_fn = 1;\n+\t\t\t\tbreak;\n+\t\t\t} else if (strcmp(optarg, \"s2\") == 0) {\n+\t\t\t\tconfig.lookup_fn = 2;\n+\t\t\t\tbreak;\n+\t\t\t} else if (strcmp(optarg, \"s3\") == 0) {\n+\t\t\t\tconfig.lookup_fn = 3;\n+\t\t\t\tbreak;\n+\t\t\t}\n+\t\t\tprint_usage();\n+\t\t\trte_exit(-EINVAL, \"Invalid option -v %s\\n\", optarg);\n \t\tdefault:\n \t\t\tprint_usage();\n \t\t\trte_exit(-EINVAL, \"Invalid options\\n\");\n@@ -846,6 +868,24 @@ run_v4(void)\n \t\treturn -rte_errno;\n \t}\n \n+\tif (config.lookup_fn != 0) {\n+\t\tif (config.lookup_fn == 1)\n+\t\t\tret = rte_fib_set_lookup_fn(fib,\n+\t\t\t\tRTE_FIB_DIR24_8_VECTOR_AVX512);\n+\t\telse if (config.lookup_fn == 2)\n+\t\t\tret = rte_fib_set_lookup_fn(fib,\n+\t\t\t\tRTE_FIB_DIR24_8_SCALAR_INLINE);\n+\t\telse if (config.lookup_fn == 3)\n+\t\t\tret = rte_fib_set_lookup_fn(fib,\n+\t\t\t\tRTE_FIB_DIR24_8_SCALAR_UNI);\n+\t\telse\n+\t\t\tret = -EINVAL;\n+\t\tif (ret != 0) {\n+\t\t\tprintf(\"Can not init lookup function\\n\");\n+\t\t\treturn ret;\n+\t\t}\n+\t}\n+\n \tfor (k = config.print_fract, i = 0; k > 0; k--) {\n \t\tstart = rte_rdtsc_precise();\n \t\tfor (j = 0; j < (config.nb_routes - i) / k; j++) {\n@@ -1025,6 +1065,18 @@ run_v6(void)\n \t\treturn -rte_errno;\n \t}\n \n+\tif (config.lookup_fn != 0) {\n+\t\tif (config.lookup_fn == 1)\n+\t\t\tret = rte_fib6_set_lookup_fn(fib,\n+\t\t\t\tRTE_FIB6_TRIE_VECTOR_AVX512);\n+\t\telse\n+\t\t\tret = -EINVAL;\n+\t\tif (ret != 0) {\n+\t\t\tprintf(\"Can not init lookup function\\n\");\n+\t\t\treturn ret;\n+\t\t}\n+\t}\n+\n \tfor (k = config.print_fract, i = 0; k > 0; k--) {\n \t\tstart = rte_rdtsc_precise();\n \t\tfor (j = 0; j < (config.nb_routes - i) / k; j++) {\n",
    "prefixes": [
        "v4",
        "8/8"
    ]
}