This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Use uname not sysctl to get the kernel revision
- From: Benjamin Herrenschmidt <benh at kernel dot crashing dot org>
- To: Steve Munroe <sjmunroe at us dot ibm dot com>
- Cc: Theodore Tso <tytso at mit dot edu>, libc-alpha at sourceware dot org, linux-kernel at vger dot kernel dot org, Andi Kleen <ak at suse dot de>, akpm at osdl dot org, Arjan van de Ven <arjan at infradead dot org>, Ulrich Drepper <drepper at redhat dot com>, "Eric W. Biederman" <ebiederm at xmission dot com>, "Randy.Dunlap" <rdunlap at xenotime dot net>
- Date: Sat, 15 Jul 2006 04:49:55 +1000
- Subject: Re: [PATCH] Use uname not sysctl to get the kernel revision
- References: <OF1343C031.500862D1-ON862571A9.00817A27-862571A9.00826BED@us.ibm.com>
> We will need an implementation that will fall back to sys_sysctl for older
> kernels. This is already common practice in glibc. I don't really
> understand the performance concern because it seems to me that
> _is_smp_system() is only called once per process.
>
> But isn't this the kind of thing that the Aux Vector is for? I like vDSO
> too, but I think it is best deployed for information of a more dynamic
> nature and performance sensitive.
For a simple "is_smp" kind of flag, I would tend to agree with the
above... for more complex NUMA topology and/or cache characteristics,
which is quite a bigger amount of information, I'm not sure it's worth
copying all of that data on every process exec (and making the initial
AT_ parsing slower). Especially since very few processes actually care
about those.
Ben.