This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 1/5][v2][BZ #15022] Avoid repeated calls to DL_STATIC_INIT
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: Roland McGrath <roland at hack dot frob dot com>
- Cc: "Maciej W. Rozycki" <macro at codesourcery dot com>, GNU C Library <libc-alpha at sourceware dot org>
- Date: Wed, 19 Jun 2013 17:41:08 -0700
- Subject: Re: [PATCH 1/5][v2][BZ #15022] Avoid repeated calls to DL_STATIC_INIT
- References: <alpine dot DEB dot 1 dot 10 dot 1301152056590 dot 4834 at tp dot orcam dot me dot uk> <20130116215545 dot 7A37A2C0B0 at topped-with-meat dot com> <alpine dot DEB dot 1 dot 10 dot 1301240655220 dot 4834 at tp dot orcam dot me dot uk> <20130531200059 dot C94C02C077 at topped-with-meat dot com> <alpine dot DEB dot 1 dot 10 dot 1306140202520 dot 16287 at tp dot orcam dot me dot uk> <20130619233103 dot A913F2C0A6 at topped-with-meat dot com>
On Wed, Jun 19, 2013 at 4:31 PM, Roland McGrath <roland@hack.frob.com> wrote:
> It seems fine to me. If HJ can explain the rationale for it being any
> other way in the first place, then we'll have to reconsider.
>
> This affects only mips and ia64. Their uses are nearly identical so it
> seems unlikely it would break ia64 when you've tested mips. But prudence
> suggests letting the ia64 maintainer (or whoever else) test and confirm.
>
>
DL_STATIC_INIT is used to initialize variables in ld.so from
static binaries::
http://www.sourceware.org/ml/libc-alpha/2001-01/msg00110.html
The difference between calling from dl_open_worker
and _dl_open is nested locks, which may be a problem.
--
H.J.