Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 14 Aug 2016 15:52:00 +0000 (UTC)
From:      Bruce Evans <bde@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r304083 - head/sys/kern
Message-ID:  <201608141552.u7EFq0tu073969@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bde
Date: Sun Aug 14 15:52:00 2016
New Revision: 304083
URL: https://svnweb.freebsd.org/changeset/base/304083

Log:
  Print the tid of curthread in "show pcpu" in ddb.
  
  It was remarkably hard to trace all current threads.  "show pcpu" only
  showed the pid, and there was nothing (?) better than searching ps output
  to find the tids on CPUs.  This change simplifies the search, but you
  still have to trace the tid for each CPU manually.

Modified:
  head/sys/kern/subr_pcpu.c

Modified: head/sys/kern/subr_pcpu.c
==============================================================================
--- head/sys/kern/subr_pcpu.c	Sun Aug 14 15:50:38 2016	(r304082)
+++ head/sys/kern/subr_pcpu.c	Sun Aug 14 15:52:00 2016	(r304083)
@@ -354,8 +354,8 @@ show_pcpu(struct pcpu *pc)
 	db_printf("curthread    = ");
 	td = pc->pc_curthread;
 	if (td != NULL)
-		db_printf("%p: pid %d \"%s\"\n", td, td->td_proc->p_pid,
-		    td->td_name);
+		db_printf("%p: pid %d tid %d \"%s\"\n", td, td->td_proc->p_pid,
+		    td->td_tid, td->td_name);
 	else
 		db_printf("none\n");
 	db_printf("curpcb       = %p\n", pc->pc_curpcb);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608141552.u7EFq0tu073969>