public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: "Wilco Dijkstra" <wdijkstr@arm.com>
To: "'Ondřej Bílka'" <neleai@seznam.cz>
Cc: "'GNU C Library'" <libc-alpha@sourceware.org>
Subject: RE: [PATCH][AArch64] Add optimized memchr
Date: Mon, 28 Sep 2015 09:23:00 -0000	[thread overview]
Message-ID: <003601d0f9cf$5070f170$f152d450$@com> (raw)
In-Reply-To: <20150926084544.GA31280@domone>

> Ondřej Bílka wrote:
> On Fri, Sep 25, 2015 at 02:21:13PM +0100, Wilco Dijkstra wrote:
> > An optimized memchr was missing for AArch64. This version is similar to strchr and is
> significantly
> > faster than the C version. Passes GLIBC tests.
> >
> > OK for commit?
> >
> > ChangeLog:
> > 2015-09-25  Wilco Dijkstra  <wdijkstr@arm.com>
> > 2015-09-25  Kevin Petit  <kevin.petit@arm.com>
> >
> > 	* sysdeps/aarch64/memchr.S (__memchr): New file.
> 
> How you tested performance. I think that also here loading first 32
> bytes unaligned should be better. Could you use dryrun to verify?
> 
> Also same optimization could be used for memrchr.

I haven't tuned this at all, this is an existing implementation that
was added to Newlib last year but not yet ported to GLIBC.

For maximum performance doing the first 16/32 bytes unaligned will likely 
be fastest just like it was for strlen.

Wilco


  reply	other threads:[~2015-09-28  9:23 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-25 13:21 Wilco Dijkstra
2015-09-26  8:46 ` Ondřej Bílka
2015-09-28  9:23   ` Wilco Dijkstra [this message]
2015-12-15 16:41 Wilco Dijkstra
2016-04-15 12:42 ` Wilco Dijkstra
2016-05-12 14:02 ` Fw: " Wilco Dijkstra
2016-06-03 12:41   ` Wilco Dijkstra
2016-06-21 13:35     ` Wilco Dijkstra
2016-10-19 14:58 ` Wilco Dijkstra
2016-10-25 17:08   ` Adhemerval Zanella
2016-11-02 16:45   ` Wilco Dijkstra
2016-11-04  9:01     ` Marcus Shawcroft

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='003601d0f9cf$5070f170$f152d450$@com' \
    --to=wdijkstr@arm.com \
    --cc=libc-alpha@sourceware.org \
    --cc=neleai@seznam.cz \
    /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).