get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 128221,
    "url": "http://patches.dpdk.org/api/patches/128221/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20230606144746.708388-16-zhirun.yan@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": "<20230606144746.708388-16-zhirun.yan@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20230606144746.708388-16-zhirun.yan@intel.com",
    "date": "2023-06-06T14:47:44",
    "name": "[v8,15/17] examples/l3fwd-graph: introduce multicore dispatch worker model",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "3e1d65a38125663e0a70907679bba8124d7796e9",
    "submitter": {
        "id": 1154,
        "url": "http://patches.dpdk.org/api/people/1154/?format=api",
        "name": "Yan, Zhirun",
        "email": "zhirun.yan@intel.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/20230606144746.708388-16-zhirun.yan@intel.com/mbox/",
    "series": [
        {
            "id": 28374,
            "url": "http://patches.dpdk.org/api/series/28374/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=28374",
            "date": "2023-06-06T14:47:29",
            "name": "graph enhancement for multi-core dispatch",
            "version": 8,
            "mbox": "http://patches.dpdk.org/series/28374/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/128221/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/128221/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 D063842C40;\n\tTue,  6 Jun 2023 16:56:20 +0200 (CEST)",
            "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 58A6242D98;\n\tTue,  6 Jun 2023 16:55:39 +0200 (CEST)",
            "from mga14.intel.com (mga14.intel.com [192.55.52.115])\n by mails.dpdk.org (Postfix) with ESMTP id 2500842D82\n for <dev@dpdk.org>; Tue,  6 Jun 2023 16:55:36 +0200 (CEST)",
            "from fmsmga005.fm.intel.com ([10.253.24.32])\n by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 06 Jun 2023 07:55:27 -0700",
            "from dpdk-zhirun-lmm.sh.intel.com ([10.67.119.94])\n by fmsmga005.fm.intel.com with ESMTP; 06 Jun 2023 07:55:25 -0700"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple;\n d=intel.com; i=@intel.com; q=dns/txt; s=Intel;\n t=1686063337; x=1717599337;\n h=from:to:cc:subject:date:message-id:in-reply-to:\n references:mime-version:content-transfer-encoding;\n bh=JUa3REtKezppJy2yY4qVT5DBInLi5k/Hf4zZEP4w1Uc=;\n b=PcI/Xc1w0J7NoEkDDkYhkAIGdADbZq2aLC1fmb/h5QkLTTpxAAEQlalg\n gDl2J38LKh+f1S6P/XekEDKn1+l/rjk0kI9hwKBrfm7ivikerh/jzbQwE\n jjoopFvYWeEeZyEaG+seYOMHZxdeuGowNU6/BiwCbuNqPtcF9Dw4Yj7aW\n rKIJekRwb5NIQMtQD5dIKJ/Co7M+gG7Hevhc+JT54QyNzwajJYDSA4BbN\n FUoJtQMPi5itYaEVJnhM0LxkL7fS7taDSk+J7ZsnRHZssE37vECrpqgiX\n sfUETdPVEwWEzS2WJ22qLYCqcik/8cGoLMczKM/V3szGB/zccwtYVvajz A==;",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6600,9927,10733\"; a=\"356705672\"",
            "E=Sophos;i=\"6.00,221,1681196400\"; d=\"scan'208\";a=\"356705672\"",
            "E=McAfee;i=\"6600,9927,10733\"; a=\"1039222978\"",
            "E=Sophos;i=\"6.00,221,1681196400\"; d=\"scan'208\";a=\"1039222978\""
        ],
        "X-ExtLoop1": "1",
        "From": "Zhirun Yan <zhirun.yan@intel.com>",
        "To": "dev@dpdk.org, jerinj@marvell.com, kirankumark@marvell.com,\n ndabilpuram@marvell.com, stephen@networkplumber.org,\n pbhagavatula@marvell.com, jerinjacobk@gmail.com",
        "Cc": "cunming.liang@intel.com, haiyue.wang@intel.com,\n mattias.ronnblom@ericsson.com, Zhirun Yan <zhirun.yan@intel.com>",
        "Subject": "[PATCH v8 15/17] examples/l3fwd-graph: introduce multicore dispatch\n worker model",
        "Date": "Tue,  6 Jun 2023 22:47:44 +0800",
        "Message-Id": "<20230606144746.708388-16-zhirun.yan@intel.com>",
        "X-Mailer": "git-send-email 2.37.2",
        "In-Reply-To": "<20230606144746.708388-1-zhirun.yan@intel.com>",
        "References": "<20230605111923.3772260-1-zhirun.yan@intel.com>\n <20230606144746.708388-1-zhirun.yan@intel.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": "Add new parameter \"model\" to choose mcore dispatch or rtc model.\nAnd in dispatch model, the node will affinity to worker core successively.\n\nNote:\nRTE_GRAPH_MODEL_SELECT is set to GRAPH_MODEL_RTC by default. Must set\nmodel the same as RTE_GRAPH_MODEL_SELECT If set it as rtc or mcore\ndispatch explicitly. GRAPH_MODEL_MCORE_RUNTIME_SELECT means it could\nchoose by model in runtime.\nOnly support one RX node for mcore dispatch model in current\nimplementation.\n\n./dpdk-l3fwd-graph  -l 8,9,10,11 -n 4 -- -p 0x1 --config=\"(0,0,9)\" -P\n--model=\"dispatch\"\n\nSigned-off-by: Haiyue Wang <haiyue.wang@intel.com>\nSigned-off-by: Cunming Liang <cunming.liang@intel.com>\nSigned-off-by: Zhirun Yan <zhirun.yan@intel.com>\n---\n examples/l3fwd-graph/main.c | 231 ++++++++++++++++++++++++++++++------\n 1 file changed, 193 insertions(+), 38 deletions(-)",
    "diff": "diff --git a/examples/l3fwd-graph/main.c b/examples/l3fwd-graph/main.c\nindex 5feeab4f0f..77a5a98aec 100644\n--- a/examples/l3fwd-graph/main.c\n+++ b/examples/l3fwd-graph/main.c\n@@ -23,6 +23,12 @@\n #include <rte_cycles.h>\n #include <rte_eal.h>\n #include <rte_ethdev.h>\n+#define GRAPH_MODEL_RTC 0 /* Run-to-completion model, set by default. */\n+#define GRAPH_MODEL_MCORE_DISPATCH 1 /* Dispatch model. */\n+#define GRAPH_MODEL_MCORE_RUNTIME_SELECT 2 /* Support to select model by */\n+\t\t\t\t\t   /* parsing model in cmdline. */\n+#undef RTE_GRAPH_MODEL_SELECT\n+#define RTE_GRAPH_MODEL_SELECT GRAPH_MODEL_RTC\n #include <rte_graph_worker.h>\n #include <rte_launch.h>\n #include <rte_lcore.h>\n@@ -55,6 +61,9 @@\n \n #define NB_SOCKETS 8\n \n+/* Graph module */\n+#define WORKER_MODEL_RTC \"rtc\"\n+#define WORKER_MODEL_MCORE_DISPATCH \"dispatch\"\n /* Static global variables used within this file. */\n static uint16_t nb_rxd = RX_DESC_DEFAULT;\n static uint16_t nb_txd = TX_DESC_DEFAULT;\n@@ -88,6 +97,8 @@ struct lcore_rx_queue {\n \tchar node_name[RTE_NODE_NAMESIZE];\n };\n \n+static uint32_t model_conf = RTE_GRAPH_MODEL_DEFAULT;\n+\n /* Lcore conf */\n struct lcore_conf {\n \tuint16_t n_rx_queue;\n@@ -153,6 +164,19 @@ static struct ipv4_l3fwd_lpm_route ipv4_l3fwd_lpm_route_array[] = {\n \t{RTE_IPV4(198, 18, 6, 0), 24, 6}, {RTE_IPV4(198, 18, 7, 0), 24, 7},\n };\n \n+static int\n+check_worker_model_params(void)\n+{\n+\tif (model_conf == RTE_GRAPH_MODEL_MCORE_DISPATCH &&\n+\t    nb_lcore_params > 1) {\n+\t\tprintf(\"Exceeded max number of lcore params for remote model: %hu\\n\",\n+\t\t       nb_lcore_params);\n+\t\treturn -1;\n+\t}\n+\n+\treturn 0;\n+}\n+\n static int\n check_lcore_params(void)\n {\n@@ -276,6 +300,7 @@ print_usage(const char *prgname)\n \t\t\"  --eth-dest=X,MM:MM:MM:MM:MM:MM: Ethernet destination for \"\n \t\t\"port X\\n\"\n \t\t\"  --max-pkt-len PKTLEN: maximum packet length in decimal (64-9600)\\n\"\n+\t\t\"  --model NAME: walking model name, dispatch or rtc(by default)\\n\"\n \t\t\"  --no-numa: Disable numa awareness\\n\"\n \t\t\"  --per-port-pool: Use separate buffer pool per port\\n\"\n \t\t\"  --pcap-enable: Enables pcap capture\\n\"\n@@ -318,6 +343,19 @@ parse_max_pkt_len(const char *pktlen)\n \treturn len;\n }\n \n+static void\n+parse_worker_model(const char *model)\n+{\n+\tif (strcmp(model, WORKER_MODEL_MCORE_DISPATCH) == 0)\n+\t\tmodel_conf = RTE_GRAPH_MODEL_MCORE_DISPATCH;\n+\telse if (strcmp(model, WORKER_MODEL_RTC) == 0)\n+\t\tmodel_conf = RTE_GRAPH_MODEL_RTC;\n+\n+\tif (model_conf != RTE_GRAPH_MODEL_SELECT &&\n+\t    RTE_GRAPH_MODEL_SELECT <= RTE_GRAPH_MODEL_MCORE_DISPATCH)\n+\t\trte_exit(EXIT_FAILURE, \"Invalid worker model: %s\", model);\n+}\n+\n static int\n parse_portmask(const char *portmask)\n {\n@@ -434,6 +472,8 @@ static const char short_options[] = \"p:\" /* portmask */\n #define CMD_LINE_OPT_PCAP_ENABLE   \"pcap-enable\"\n #define CMD_LINE_OPT_NUM_PKT_CAP   \"pcap-num-cap\"\n #define CMD_LINE_OPT_PCAP_FILENAME \"pcap-file-name\"\n+#define CMD_LINE_OPT_WORKER_MODEL  \"model\"\n+\n enum {\n \t/* Long options mapped to a short option */\n \n@@ -449,6 +489,7 @@ enum {\n \tCMD_LINE_OPT_PARSE_PCAP_ENABLE,\n \tCMD_LINE_OPT_PARSE_NUM_PKT_CAP,\n \tCMD_LINE_OPT_PCAP_FILENAME_CAP,\n+\tCMD_LINE_OPT_WORKER_MODEL_TYPE,\n };\n \n static const struct option lgopts[] = {\n@@ -460,6 +501,7 @@ static const struct option lgopts[] = {\n \t{CMD_LINE_OPT_PCAP_ENABLE, 0, 0, CMD_LINE_OPT_PARSE_PCAP_ENABLE},\n \t{CMD_LINE_OPT_NUM_PKT_CAP, 1, 0, CMD_LINE_OPT_PARSE_NUM_PKT_CAP},\n \t{CMD_LINE_OPT_PCAP_FILENAME, 1, 0, CMD_LINE_OPT_PCAP_FILENAME_CAP},\n+\t{CMD_LINE_OPT_WORKER_MODEL, 1, 0, CMD_LINE_OPT_WORKER_MODEL_TYPE},\n \t{NULL, 0, 0, 0},\n };\n \n@@ -551,6 +593,11 @@ parse_args(int argc, char **argv)\n \t\t\tprintf(\"Pcap file name: %s\\n\", pcap_filename);\n \t\t\tbreak;\n \n+\t\tcase CMD_LINE_OPT_WORKER_MODEL_TYPE:\n+\t\t\tprintf(\"Use new worker model: %s\\n\", optarg);\n+\t\t\tparse_worker_model(optarg);\n+\t\t\tbreak;\n+\n \t\tdefault:\n \t\t\tprint_usage(prgname);\n \t\t\treturn -1;\n@@ -788,6 +835,142 @@ config_port_max_pkt_len(struct rte_eth_conf *conf,\n \treturn 0;\n }\n \n+static void\n+graph_config_mcore_dispatch(struct rte_graph_param graph_conf)\n+{\n+\tuint16_t nb_patterns = graph_conf.nb_node_patterns;\n+\tint worker_count = rte_lcore_count() - 1;\n+\tint main_lcore_id = rte_get_main_lcore();\n+\trte_graph_t main_graph_id = 0;\n+\tstruct rte_node *node_tmp;\n+\tstruct lcore_conf *qconf;\n+\tstruct rte_graph *graph;\n+\trte_graph_t graph_id;\n+\trte_graph_off_t off;\n+\tint n_rx_node = 0;\n+\tint worker_lcore;\n+\trte_node_t count;\n+\tint i, j;\n+\tint ret;\n+\n+\tfor (j = 0; j < nb_lcore_params; j++) {\n+\t\tqconf = &lcore_conf[lcore_params[j].lcore_id];\n+\t\t/* Add rx node patterns of all lcore */\n+\t\tfor (i = 0; i < qconf->n_rx_queue; i++) {\n+\t\t\tchar *node_name = qconf->rx_queue_list[i].node_name;\n+\t\t\tunsigned int lcore_id = lcore_params[j].lcore_id;\n+\n+\t\t\tgraph_conf.node_patterns[nb_patterns + n_rx_node + i] = node_name;\n+\t\t\tn_rx_node++;\n+\t\t\tret = rte_graph_model_mcore_dispatch_node_lcore_affinity_set(node_name,\n+\t\t\t\t\t\t\t\t\t\t     lcore_id);\n+\t\t\tif (ret == 0)\n+\t\t\t\tprintf(\"Set node %s affinity to lcore %u\\n\", node_name,\n+\t\t\t\t       lcore_params[j].lcore_id);\n+\t\t}\n+\t}\n+\n+\tgraph_conf.nb_node_patterns = nb_patterns + n_rx_node;\n+\tgraph_conf.socket_id = rte_lcore_to_socket_id(main_lcore_id);\n+\n+\tqconf = &lcore_conf[main_lcore_id];\n+\tsnprintf(qconf->name, sizeof(qconf->name), \"worker_%u\",\n+\t\t main_lcore_id);\n+\n+\t/* create main graph */\n+\tmain_graph_id = rte_graph_create(qconf->name, &graph_conf);\n+\tif (main_graph_id == RTE_GRAPH_ID_INVALID)\n+\t\trte_exit(EXIT_FAILURE,\n+\t\t\t \"rte_graph_create(): main_graph_id invalid for lcore %u\\n\",\n+\t\t\t main_lcore_id);\n+\n+\t/* set the graph model for the main graph */\n+\trte_graph_worker_model_set(RTE_GRAPH_MODEL_MCORE_DISPATCH);\n+\tqconf->graph_id = main_graph_id;\n+\tqconf->graph = rte_graph_lookup(qconf->name);\n+\tif (!qconf->graph)\n+\t\trte_exit(EXIT_FAILURE,\n+\t\t\t \"rte_graph_lookup(): graph %s not found\\n\",\n+\t\t\t qconf->name);\n+\n+\tgraph = qconf->graph;\n+\tworker_lcore = lcore_params[nb_lcore_params - 1].lcore_id;\n+\trte_graph_foreach_node(count, off, graph, node_tmp) {\n+\t\t/* Need to set the node Lcore affinity before clone graph for each lcore */\n+\t\tif (node_tmp->dispatch.lcore_id == RTE_MAX_LCORE) {\n+\t\t\tworker_lcore = rte_get_next_lcore(worker_lcore, true, 1);\n+\t\t\tret = rte_graph_model_mcore_dispatch_node_lcore_affinity_set(node_tmp->name,\n+\t\t\t\t\t\t\t\t\t\t     worker_lcore);\n+\t\t\tif (ret == 0)\n+\t\t\t\tprintf(\"Set node %s affinity to lcore %u\\n\",\n+\t\t\t\t       node_tmp->name, worker_lcore);\n+\t\t}\n+\t}\n+\n+\tworker_lcore = main_lcore_id;\n+\tfor (i = 0; i < worker_count; i++) {\n+\t\tworker_lcore = rte_get_next_lcore(worker_lcore, true, 1);\n+\n+\t\tqconf = &lcore_conf[worker_lcore];\n+\t\tsnprintf(qconf->name, sizeof(qconf->name), \"cloned-%u\", worker_lcore);\n+\t\tgraph_id = rte_graph_clone(main_graph_id, qconf->name, &graph_conf);\n+\t\tret = rte_graph_model_mcore_dispatch_core_bind(graph_id, worker_lcore);\n+\t\tif (ret == 0)\n+\t\t\tprintf(\"bind graph %d to lcore %u\\n\", graph_id, worker_lcore);\n+\n+\t\t/* full cloned graph name */\n+\t\tsnprintf(qconf->name, sizeof(qconf->name), \"%s\",\n+\t\t\t rte_graph_id_to_name(graph_id));\n+\t\tqconf->graph_id = graph_id;\n+\t\tqconf->graph = rte_graph_lookup(qconf->name);\n+\t\tif (!qconf->graph)\n+\t\t\trte_exit(EXIT_FAILURE,\n+\t\t\t\t \"Failed to lookup graph %s\\n\",\n+\t\t\t\t qconf->name);\n+\t\tcontinue;\n+\t}\n+}\n+\n+static void\n+graph_config_rtc(struct rte_graph_param graph_conf)\n+{\n+\tuint16_t nb_patterns = graph_conf.nb_node_patterns;\n+\tstruct lcore_conf *qconf;\n+\trte_graph_t graph_id;\n+\tuint32_t lcore_id;\n+\trte_edge_t i;\n+\n+\tfor (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id++) {\n+\t\tif (rte_lcore_is_enabled(lcore_id) == 0)\n+\t\t\tcontinue;\n+\n+\t\tqconf = &lcore_conf[lcore_id];\n+\t\t/* Skip graph creation if no source exists */\n+\t\tif (!qconf->n_rx_queue)\n+\t\t\tcontinue;\n+\t\t/* Add rx node patterns of this lcore */\n+\t\tfor (i = 0; i < qconf->n_rx_queue; i++) {\n+\t\t\tgraph_conf.node_patterns[nb_patterns + i] =\n+\t\t\t\tqconf->rx_queue_list[i].node_name;\n+\t\t}\n+\t\tgraph_conf.nb_node_patterns = nb_patterns + i;\n+\t\tgraph_conf.socket_id = rte_lcore_to_socket_id(lcore_id);\n+\t\tsnprintf(qconf->name, sizeof(qconf->name), \"worker_%u\",\n+\t\t\t lcore_id);\n+\t\tgraph_id = rte_graph_create(qconf->name, &graph_conf);\n+\t\tif (graph_id == RTE_GRAPH_ID_INVALID)\n+\t\t\trte_exit(EXIT_FAILURE,\n+\t\t\t\t \"rte_graph_create(): graph_id invalid for lcore %u\\n\",\n+\t\t\t\t lcore_id);\n+\t\tqconf->graph_id = graph_id;\n+\t\tqconf->graph = rte_graph_lookup(qconf->name);\n+\t\tif (!qconf->graph)\n+\t\t\trte_exit(EXIT_FAILURE,\n+\t\t\t\t \"rte_graph_lookup(): graph %s not found\\n\",\n+\t\t\t\t qconf->name);\n+\t}\n+}\n+\n int\n main(int argc, char **argv)\n {\n@@ -840,6 +1023,9 @@ main(int argc, char **argv)\n \tif (check_lcore_params() < 0)\n \t\trte_exit(EXIT_FAILURE, \"check_lcore_params() failed\\n\");\n \n+\tif (check_worker_model_params() < 0)\n+\t\trte_exit(EXIT_FAILURE, \"check_worker_model_params() failed\\n\");\n+\n \tret = init_lcore_rx_queues();\n \tif (ret < 0)\n \t\trte_exit(EXIT_FAILURE, \"init_lcore_rx_queues() failed\\n\");\n@@ -1079,51 +1265,20 @@ main(int argc, char **argv)\n \n \tmemset(&graph_conf, 0, sizeof(graph_conf));\n \tgraph_conf.node_patterns = node_patterns;\n+\tgraph_conf.nb_node_patterns = nb_patterns;\n \n \t/* Pcap config */\n \tgraph_conf.pcap_enable = pcap_trace_enable;\n \tgraph_conf.num_pkt_to_capture = packet_to_capture;\n \tgraph_conf.pcap_filename = pcap_filename;\n \n-\tfor (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id++) {\n-\t\trte_graph_t graph_id;\n-\t\trte_edge_t i;\n-\n-\t\tif (rte_lcore_is_enabled(lcore_id) == 0)\n-\t\t\tcontinue;\n-\n-\t\tqconf = &lcore_conf[lcore_id];\n-\n-\t\t/* Skip graph creation if no source exists */\n-\t\tif (!qconf->n_rx_queue)\n-\t\t\tcontinue;\n-\n-\t\t/* Add rx node patterns of this lcore */\n-\t\tfor (i = 0; i < qconf->n_rx_queue; i++) {\n-\t\t\tgraph_conf.node_patterns[nb_patterns + i] =\n-\t\t\t\tqconf->rx_queue_list[i].node_name;\n-\t\t}\n-\n-\t\tgraph_conf.nb_node_patterns = nb_patterns + i;\n-\t\tgraph_conf.socket_id = rte_lcore_to_socket_id(lcore_id);\n-\n-\t\tsnprintf(qconf->name, sizeof(qconf->name), \"worker_%u\",\n-\t\t\t lcore_id);\n-\n-\t\tgraph_id = rte_graph_create(qconf->name, &graph_conf);\n-\t\tif (graph_id == RTE_GRAPH_ID_INVALID)\n-\t\t\trte_exit(EXIT_FAILURE,\n-\t\t\t\t \"rte_graph_create(): graph_id invalid\"\n-\t\t\t\t \" for lcore %u\\n\", lcore_id);\n+\tif (model_conf == RTE_GRAPH_MODEL_MCORE_DISPATCH)\n+\t\tgraph_config_mcore_dispatch(graph_conf);\n+\telse\n+\t\tgraph_config_rtc(graph_conf);\n \n-\t\tqconf->graph_id = graph_id;\n-\t\tqconf->graph = rte_graph_lookup(qconf->name);\n-\t\t/* >8 End of graph initialization. */\n-\t\tif (!qconf->graph)\n-\t\t\trte_exit(EXIT_FAILURE,\n-\t\t\t\t \"rte_graph_lookup(): graph %s not found\\n\",\n-\t\t\t\t qconf->name);\n-\t}\n+\trte_graph_worker_model_set(model_conf);\n+\t/* >8 End of graph initialization. */\n \n \tmemset(&rewrite_data, 0, sizeof(rewrite_data));\n \trewrite_len = sizeof(rewrite_data);\n",
    "prefixes": [
        "v8",
        "15/17"
    ]
}