This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] hp-timing for ppc32/64
- From: Steve Munroe <sjmunroe at us dot ibm dot com>
- To: Benjamin Herrenschmidt <benh at kernel dot crashing dot org>
- Cc: libc-alpha at sources dot redhat dot com, Tom Gall <tom_gall at vnet dot ibm dot com>
- Date: Mon, 14 Nov 2005 16:13:14 -0600
- Subject: Re: [PATCH] hp-timing for ppc32/64
Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote on 11/14/2005
03:32:16 PM:
>
> > The whole idea of hp-timing is that is fast, simple, and inline code.
It
> > is not a general purpose clock. It must also work in the restricted
> > environment of the dynamic loader itself, like before and the durring
the
> > time the loader is relocating its self!
>
> AT_HWCAP is available at all time since it's passed by the kernel
>
AT_HWCAP is but dl_hwcap is not. The loader has to complete relocating
itself before it can call the functions the set up dl_hwcap etc
(dl_sysdep_start). Looking at the code it seems the HP_TIMING_NOW() is
being used very early in rtld.c (dl_start and dl_start_final), as far as I
can tell dl_hwcap is not available until the middle of dl_start_final(),
well after HP_TIMING needs to be functional.
Steven J. Munroe
Linux on Power Toolchain Architect
IBM Corporation, Linux Technology Center