Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 13 Dec 2000 02:04:40 +1100 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        John Baldwin <jhb@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/kern kern_ktr.c
Message-ID:  <Pine.BSF.4.21.0012130124150.585-100000@besplex.bde.org>
In-Reply-To: <200012120043.eBC0hqx94479@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 11 Dec 2000, John Baldwin wrote:

> jhb         2000/12/11 16:43:50 PST
> 
>   Modified files:
>     sys/kern             kern_ktr.c 
>   Log:
>   - Don't bother taking a trace message if we have panic'd since doing so
>     can lead to further panics.
>   - Call getnanotime() instead of nanotime() for the timestamp.  nanotime()
>     is more precise, but it also calls into the timer code, which results
>     in mutex operations on the i386 arch.  If KTR_LOCK is turned on, then

Mutex operations actually resulted only on the i386 arch, only if the
i8254 timecounter was used (i.e., mainly on pre-PCI pre-Pentium
systems).  Both the alpha and the i386 have an i8254 timecounter which
should use mutex operations, but the alpha version was copied from
the i386 version before mutex operations were added to the latter,
and it has rotted.

High resolution kernel profiling has similar problems.  mcount() and
mexitcount() need to be callable from almost anywhere, and they call
timer/counter code (cputime()) which needs to use locks for certain
timer/cointers (i8254, and maybe performance counters).  Things
currently sort of work because the necessary locking is missing.

Bruce



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0012130124150.585-100000>