public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Florian Weimer <fw@deneb.enyo.de>
To: Noah Goldstein <goldstein.w.n@gmail.com>
Cc: "H.J. Lu" <hjl.tools@gmail.com>,
	 "H.J. Lu via Libc-alpha" <libc-alpha@sourceware.org>,
	 GCC Development <gcc@gcc.gnu.org>,
	 Arjan van de Ven <arjan@linux.intel.com>
Subject: Re: [PATCH] x86-64: Optimize memset for zeroing
Date: Fri, 31 Dec 2021 23:05:14 +0100	[thread overview]
Message-ID: <874k6ofn1h.fsf@mid.deneb.enyo.de> (raw)
In-Reply-To: <CAFUsyfJ4KgiFjP1Fpt_Dg2spkDiiwcO7+98yS0Gms9oxRmS05w@mail.gmail.com> (Noah Goldstein's message of "Fri, 31 Dec 2021 15:15:57 -0600")

* Noah Goldstein:

>> >> bzero does not have the interface ambiguity that bcmp has.  So the
>> >> only reason for not using it would be namespace cleanliness.
>> >
>> > bzero isn't a standard C function and it isn't optimized like memset
>> > in glibc.
>
> It could be an issue if the "optimization" was made and then the
> binary was run with an older version of GCC that was still using
> the aliasing bzero. Would end up being a deoptimization then.

That's a fair point.

  reply	other threads:[~2021-12-31 22:05 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20211231182010.107040-1-hjl.tools@gmail.com>
     [not found] ` <CAFUsyfJ5wHJHkfcL84j+GLCX-Dba4qVt_RuCpu=aLy7-_YbHLA@mail.gmail.com>
2021-12-31 20:35   ` H.J. Lu
2021-12-31 20:43     ` Florian Weimer
2021-12-31 20:52       ` H.J. Lu
2021-12-31 21:02         ` Florian Weimer
2021-12-31 21:15           ` Noah Goldstein
2021-12-31 22:05             ` Florian Weimer [this message]
2021-12-31 22:14     ` Noah Goldstein
2021-12-31 22:19       ` Noah Goldstein
2021-12-31 22:21         ` H.J. Lu

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=874k6ofn1h.fsf@mid.deneb.enyo.de \
    --to=fw@deneb.enyo.de \
    --cc=arjan@linux.intel.com \
    --cc=gcc@gcc.gnu.org \
    --cc=goldstein.w.n@gmail.com \
    --cc=hjl.tools@gmail.com \
    --cc=libc-alpha@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).