This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: PATCH: Check GLIBC_IFUNC to enable/disable ifunc features
- From: Szabolcs Nagy <szabolcs dot nagy at arm dot com>
- To: "H.J. Lu" <hjl dot tools at gmail dot com>
- Cc: <nd at arm dot com>, Carlos O'Donell <carlos at redhat dot com>, GNU C Library <libc-alpha at sourceware dot org>, Siddhesh Poyarekar <sid at reserved-bit dot com>
- Date: Thu, 30 Jun 2016 18:23:55 +0100
- Subject: Re: PATCH: Check GLIBC_IFUNC to enable/disable ifunc features
- Authentication-results: sourceware.org; auth=none
- Nodisclaimer: True
- References: <CAMe9rOq1+_rMbs1mt3=Md=Wx=7ZxUbD+BhOx-qrO5TBRBrRLww at mail dot gmail dot com> <20160630013716 dot GY4685 at vapier dot lan> <CAMe9rOrgshV6t5quE01r_oc91ps0JJ7fYfAC=MuQOs96qNv1uQ at mail dot gmail dot com> <57752F1B dot 7010809 at arm dot com> <CAMe9rOoy2q3+NV26RjCe0KNCUEc5U1OcBb5_PUKBLLPf-eQk4A at mail dot gmail dot com> <CAMe9rOrxQYG7T0QgNwJ2unonB_JdQ5Unp8vu94h9LfoZe2aWEw at mail dot gmail dot com>
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
On 30/06/16 17:21, H.J. Lu wrote:
> + /* Can't use strlen because it may trigger an ifunc resolve
> + loop. */
> + for (; *end != '\0'; end++);
the compiler can optimize this into a strlen call.
but e.g. -ffreestanding can solve that
(i wonder why glibc does not use that already
at least for early startup code).