lkml.org 
[lkml]   [2000]   [Nov]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Error in x86 CPU capabilities starting with test5/6
On Fri, Nov 17, 2000 at 01:04:18PM +0100, Andi Kleen wrote:
> The program would be broken if it executed CPUID itself, because it has no way to guarantee
> that the CPUID is executed on all CPUs the scheduler may later move the task too.

I wonder what's the right way for an app to ask the kernel if, for example,
tsc is available. As you stated above, executing CPUID is probably wrong.
But if the process parses /proc/cpuinfo, it has to make sure tsc is available
on all cpus it may run on, doesn't it?

What about some system call stating 'I want to use feature XYZ'. If all CPUs
implement XYZ, the system call simply returns some ACK, and NACK if no CPU
implements it (and no emulation is available).

If only some CPUs implement the feature, the kernel may return NACK,
or it may make sure the process will only run on CPUs implementing the
feature and return ACK. Is this usefull? It's just an idea ;-) I wonder
if there are many features that may be available only on some CPUs in an
'SMP' system.

Jan

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:47    [W:0.132 / U:2.776 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site