Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Dec 2009 20:32:41 +0100
From:      =?UTF-8?B?TW9yZ2FuIFdlc3N0csO2bQ==?= <>
To:        FreeBSD Questions <>
Subject:   Re: SMP and ALTQ_NOPCC
Message-ID:  <>
In-Reply-To: <>
References:  <>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
APseudoUtopia wrote:
> Hello,
> With the improvements in SMP in FreeBSD 8.0, is the ALTQ_NOPCC option
> still required? In the handbook and other older documentation, it says
> ALTQ_NOPCC is in fact required on SMP systems because the TSC is
> unstable. I was wondering if this is still the case after the
> improvements done with SMP.
> Thanks.

Not every CPU has an unstable TSC. It mostly affects AMD processors and
Intel Pentium M. Wikipedia has a great listing of models and families

However, in /usr/src/sys/amd64/amd64/tsc.c you can find the following code:

#ifdef SMP
         * We can not use the TSC in SMP mode unless the TSCs on all CPUs
         * are somehow synchronized.  Some hardware configurations do
         * this, but we have no way of determining whether this is the
         * case, so we do not use the TSC in multi-processor systems
         * unless the user indicated (by setting kern.timecounter.smp_tsc
         * to 1) that he believes that his TSCs are synchronized.
        if (mp_ncpus > 1 && !smp_tsc)
                tsc_timecounter.tc_quality = -100;

It will set the quality of the timestamp counter to -100 if SMP is
detected and effectively disable it so by default the TSC won't be used
on an SMP system and consequently you don't have to use ALTQ_NOPCC. It
is "probably" safe to enable and use TSC in pf, as described in the
code, if you have a modern Intel CPU but I have not tested it.


Want to link to this message? Use this URL: <>