DPDK patches and discussions
 help / color / mirror / Atom feed
From: Huichao cai <chcchc88@163.com>
To: jerinj@marvell.com, kirankumark@marvell.com,
	ndabilpuram@marvell.com, yanzhirun_163@163.com
Cc: dev@dpdk.org
Subject: [PATCH] graph: add some print to the node dump
Date: Tue, 22 Oct 2024 20:28:05 +0800	[thread overview]
Message-ID: <1729600085-67064-1-git-send-email-chcchc88@163.com> (raw)

The function node_dump add some printing of node information.

Signed-off-by: Huichao cai <chcchc88@163.com>
---
 lib/graph/graph_debug.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/lib/graph/graph_debug.c b/lib/graph/graph_debug.c
index 9def306..37088ce 100644
--- a/lib/graph/graph_debug.c
+++ b/lib/graph/graph_debug.c
@@ -35,8 +35,17 @@
 	fprintf(f, "  flags=0x%" PRIx64 "\n", n->flags);
 	fprintf(f, "  addr=%p\n", n);
 	fprintf(f, "  process=%p\n", n->process);
+	if (n->parent_id == RTE_NODE_ID_INVALID)
+		fprintf(f, "  parent_id=RTE_NODE_ID_INVALID\n");
+	else
+		fprintf(f, "  parent_id=%" PRIu32 "\n", n->parent_id);
+	fprintf(f, "  init=%p\n", n->init);
+	fprintf(f, "  fini=%p\n", n->fini);
+	fprintf(f, "  xstats=%p\n", n->xstats);
+	fprintf(f, "  next node addr=%p\n", STAILQ_NEXT(n, next));
+	if (STAILQ_NEXT(n, next))
+		fprintf(f, "  next node name=%s\n", STAILQ_NEXT(n, next)->name);
 	fprintf(f, "  nb_edges=%d\n", n->nb_edges);
-
 	for (i = 0; i < n->nb_edges; i++)
 		fprintf(f, "     edge[%d] <%s>\n", i, n->next_nodes[i]);
 }
-- 
1.8.3.1


             reply	other threads:[~2024-10-22 12:28 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-22 12:28 Huichao cai [this message]
2024-10-22 13:40 ` [EXTERNAL] " Kiran Kumar Kokkilagadda

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1729600085-67064-1-git-send-email-chcchc88@163.com \
    --to=chcchc88@163.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=kirankumark@marvell.com \
    --cc=ndabilpuram@marvell.com \
    --cc=yanzhirun_163@163.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).