public inbox for libc-help@sourceware.org
 help / color / mirror / Atom feed
From: Jeffrey Walton <noloader@gmail.com>
To: Florian Weimer <fweimer@redhat.com>
Cc: libc-help@sourceware.org
Subject: Re: getauxv and ARMv7 platform detection
Date: Tue, 21 May 2019 06:45:00 -0000	[thread overview]
Message-ID: <CAH8yC8muQYwrnb5LLyjLuP4nw_ROQ6gHD-JmSBA_j7uzSUmOyg@mail.gmail.com> (raw)
In-Reply-To: <87mujgfhde.fsf@oldenburg2.str.redhat.com>

On Tue, May 21, 2019 at 2:31 AM Florian Weimer <fweimer@redhat.com> wrote:
>
> * Jeffrey Walton:
>
> > On Tue, May 21, 2019 at 2:03 AM Florian Weimer <fweimer@redhat.com> wrote:
> >>
> >> * Jeffrey Walton:
> >>
> >> > My question is, how do we use getauxval to detect ARMv7 platforms?
> >>
> >> What is the actual problem you are trying to solve?
> >
> > I'm trying to detect if the platform is ARMv7 at runtime.
>
> Yes, but why?  Just to print a diagnostic?

We switch to ARMv7 and NEON implementations at runtime if the CPU
supports it. We can usually achieve 2x or 3x speedups over
ARMv{4|5|6}.

We've got SIGILL probes in place but they are an expensive fallback.
We prefer a faster and cleaner solution on Linux like getauxv().

We don't control how the library is built. Users and distros do their
own things. About the only thing we can count on is, -march=native is
useless (and sometimes segfaults the compiler), -march=XXX is missing
and -mfpu=YYY is missing.

Jeff

  reply	other threads:[~2019-05-21  6:45 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-21  2:52 Jeffrey Walton
2019-05-21  6:03 ` Florian Weimer
2019-05-21  6:11   ` Jeffrey Walton
2019-05-21  6:31     ` Florian Weimer
2019-05-21  6:45       ` Jeffrey Walton [this message]
2019-05-21 20:53         ` Adhemerval Zanella

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAH8yC8muQYwrnb5LLyjLuP4nw_ROQ6gHD-JmSBA_j7uzSUmOyg@mail.gmail.com \
    --to=noloader@gmail.com \
    --cc=fweimer@redhat.com \
    --cc=libc-help@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).