public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Joe Korty <joe.korty@ccur.com>
To: "Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>
Cc: Ingo Molnar <mingo@elte.hu>, H Peter Anvin <hpa@zytor.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] x86: Support always running TSC on Intel CPUs
Date: Tue, 18 Nov 2008 11:54:33 -0500	[thread overview]
Message-ID: <20081118165433.GA1511@tsunami.ccur.com> (raw)
In-Reply-To: <7E82351C108FA840AB1866AC776AEC464291BB4F@orsmsx505.amr.corp.intel.com>

On Tue, Nov 18, 2008 at 11:47:35AM -0500, Pallipadi, Venkatesh wrote:
> 
>>-----Original Message-----
>>From: Ingo Molnar [mailto:mingo@elte.hu]
>>Sent: Tuesday, November 18, 2008 8:06 AM
>>To: Joe Korty
>>Cc: Pallipadi, Venkatesh; H Peter Anvin; Thomas Gleixner; linux-kernel
>>Subject: Re: [PATCH] x86: Support always running TSC on Intel CPUs
>>
>>* Joe Korty <joe.korty@ccur.com> wrote:
>>> On Tue, Nov 18, 2008 at 09:09:52AM +0100, Ingo Molnar wrote:
>>>> * Venki Pallipadi <venkatesh.pallipadi@intel.com> wrote:
>>>>
>>>> > +        if (c->x86_power & (1 << 8)) {
>>>> >                  set_cpu_cap(c, X86_FEATURE_CONSTANT_TSC);
>>>> > +                set_cpu_cap(c, X86_FEATURE_NOSTOP_TSC);
>>>> > +        }
>>>>
>>>> hm, the naming is a bit confusing. We now have 3 variants:
>>>>
>>>>   X86_FEATURE_TSC
>>>>   X86_FEATURE_CONSTANT_TSC
>>>>   X86_FEATURE_NOSTOP_TSC
>>>>
>>>> NOSTOP_TSC is basically what CONSTANT_TSC should have been
>>to begin
>>>> with ;-)
>>>>
>>>> i'd suggest to rename it to this:
>>>>
>>>>   X86_FEATURE_TSC
>>>>   X86_FEATURE_CONSTANT_FREQ_TSC
>>>>   X86_FEATURE_STABLE_TSC
>>>>
>>>> ... with CONSTANT_FREQ_TSC not having any real role in the long run.
>>>> (it's similarly problematic to a completely unstable TSC)
>>>>
>>>> does this sound ok?
>>>
>>>
>>> To me, the new naming has the same head-scratching potential
>>> as the old....
>>>
>>> How about:
>>>
>>>      X86_FEATURE_TSC
>>>      X86_FEATURE_STABLE_TSC_OBSOLETE
>>>      X86_FEATURE_STABLE_TSC
>>
>>the _honest_ naming would be:
>>
>>       X86_FEATURE_TSC
>>       X86_FEATURE_STABLE_TSC_BUT_NOT_ALWAYS
>>       X86_FEATURE_STABLE_TSC
>>
>>;-)
>>
>>what's head-scratching about X86_FEATURE_CONSTANT_FREQ_TSC? It's a
>>limited TSC variant: it follows a reference frequency that does not
>>change with cpufreq changes, but it can stop at a whim in C states. So
>>it's not "stable" nor really "constant" in the everyday sense.
>>
> 
> I don't like STABLE_TSC_OBSOLETE as it does not say anything
> descriptive about what it means and people have to look at the code
> to find out.
> 
> My original intention was to split this into two features
> - P/T state invariant TSC which counts at constant rate
> - C-state invariant TSC that never stops
> Some CPUs will have only first feature. Others may have both.
> 
> But, I agree it is confusing.
> 
> How about?
> X86_FEATURE_FIXEDFREQ_MAYSTOP_TSC
> X86_FEATURE_ALWAYS_RUNNING_TSC
> 
> Thanks,
> Venki


Much nicer...
Regards,
Joe

  reply	other threads:[~2008-11-18 16:55 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-18  0:11 [PATCH] x86: Support always running TSC on Intel CPUs Venki Pallipadi
2008-11-18  0:13 ` H. Peter Anvin
2008-11-18  0:16   ` Pallipadi, Venkatesh
2008-11-18  0:18     ` H. Peter Anvin
2008-11-18  0:49       ` Venki Pallipadi
2008-11-18  0:52         ` H. Peter Anvin
2008-11-18  1:05           ` Venki Pallipadi
2008-11-18  1:07             ` H. Peter Anvin
2008-11-18  3:26               ` Arjan van de Ven
2008-11-18  3:27                 ` H. Peter Anvin
2008-11-18  8:09 ` Ingo Molnar
2008-11-18 14:55   ` Joe Korty
2008-11-18 16:05     ` Ingo Molnar
2008-11-18 16:47       ` Pallipadi, Venkatesh
2008-11-18 16:54         ` Joe Korty [this message]
2008-11-18 17:01         ` H. Peter Anvin
2008-11-18 16:48       ` Joe Korty

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081118165433.GA1511@tsunami.ccur.com \
    --to=joe.korty@ccur.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=tglx@linutronix.de \
    --cc=venkatesh.pallipadi@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox