Re: Linux 2.4.19ac3rc3 on IBM x330/x340 SMP - "ps" time skew
Alan Cox (alan@lxorguk.ukuu.org.uk)
01 Aug 2002 01:37:17 +0100
On Wed, 2002-07-31 at 20:14, Albert D. Cahalan wrote:
> Alan Cox writes:
> > On Wed, 2002-07-31 at 13:59, David Luyer wrote:
>
> >> printf("%d\n", sysconf(_SC_NPROCESSORS_CONF));
> >> }
> >> luyer@praxis8:~$ ./cpus
> >> 4
> >> luyer@praxis8:~$ grep 'processor ' /proc/cpuinfo
> >> processor : 0
> >> processor : 1
> >
> > In which case I suggest you file a glibc bug. sysconf looks at the /proc
> > stuff as I understand it
>
> First you blame ps. Then you blame libc. How about you
> place the fault right where it belongs?
ps is certainly buggy. HZ is 100. ps grovelling around in /proc is bogus
to say the least. That code wasn't exactly well written.
> Counting processors in /proc/cpuinfo is a joke of an ABI.
>
> Add a proper ABI now, and userspace can transition to it
> over the next 4 years.
Which is what I've been talking to Ulrich about.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/