Date: Thu, 23 Mar 2017 08:08:34 +0000 (UTC) From: Andriy Gapon <avg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r315838 - stable/11/sys/kern Message-ID: <201703230808.v2N88YJQ090468@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: avg Date: Thu Mar 23 08:08:34 2017 New Revision: 315838 URL: https://svnweb.freebsd.org/changeset/base/315838 Log: MFC r315075: trace thread running state when a thread is run for the first time Modified: stable/11/sys/kern/sched_4bsd.c stable/11/sys/kern/sched_ule.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/sched_4bsd.c ============================================================================== --- stable/11/sys/kern/sched_4bsd.c Thu Mar 23 08:02:29 2017 (r315837) +++ stable/11/sys/kern/sched_4bsd.c Thu Mar 23 08:08:34 2017 (r315838) @@ -1666,6 +1666,10 @@ sched_fork_exit(struct thread *td) lock_profile_obtain_lock_success(&sched_lock.lock_object, 0, 0, __FILE__, __LINE__); THREAD_LOCK_ASSERT(td, MA_OWNED | MA_NOTRECURSED); + + KTR_STATE1(KTR_SCHED, "thread", sched_tdname(td), "running", + "prio:%d", td->td_priority); + SDT_PROBE0(sched, , , on__cpu); } char * Modified: stable/11/sys/kern/sched_ule.c ============================================================================== --- stable/11/sys/kern/sched_ule.c Thu Mar 23 08:02:29 2017 (r315837) +++ stable/11/sys/kern/sched_ule.c Thu Mar 23 08:08:34 2017 (r315838) @@ -2756,6 +2756,10 @@ sched_fork_exit(struct thread *td) TDQ_LOCK_ASSERT(tdq, MA_OWNED | MA_NOTRECURSED); lock_profile_obtain_lock_success( &TDQ_LOCKPTR(tdq)->lock_object, 0, 0, __FILE__, __LINE__); + + KTR_STATE1(KTR_SCHED, "thread", sched_tdname(td), "running", + "prio:%d", td->td_priority); + SDT_PROBE0(sched, , , on__cpu); } /*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201703230808.v2N88YJQ090468>