Date: Wed, 6 Sep 2000 01:34:32 +1100 (EST) From: Bruce Evans <bde@zeta.org.au> To: Kenjiro Cho <kjc@csl.sony.co.jp> Cc: altq@csl.sony.co.jp, akorud@polynet.lviv.ua, freebsd-net@FreeBSD.ORG Subject: Re: [altq 575] Re[2]: [altq 565] Running ALTQ Message-ID: <Pine.BSF.4.21.0009060123480.24432-100000@besplex.bde.org> In-Reply-To: <20000905133613H.kjc@csl.sony.co.jp>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 5 Sep 2000, Kenjiro Cho wrote:
> Andriy Korud wrote:
> > And few more questions:
> > 1. What does ALTQ_NOPCC option mean? Will disabling it (using
> > processor counters) improve limit resolution?
>
> It requires only one machine cycle to read a processor cycle couner
> (timestamp counter for pentium), which is much cheaper than using
> microtime(). However, it doesn't affect the kernel timer resolution.
It takes more than one cycle, at least in a loop. I just retried the
following:
main()
{
__asm("
movl $100000000,%ecx
.align 4,0x90
1:
rdtsc
decl %ecx
nop
jne 1b
");
}
and it took 30 cycles on a Celeron and 12 cycles on a P5 (32 and 14
cycles, respectively, including 2 cycles of loop overhead).
Bruce
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" 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.0009060123480.24432-100000>
