public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "josh.m.conner at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/55701] New: Inline some instances of memset for ARM Date: Sat, 15 Dec 2012 01:11:00 -0000 [thread overview] Message-ID: <bug-55701-4@http.gcc.gnu.org/bugzilla/> (raw) http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55701 Bug #: 55701 Summary: Inline some instances of memset for ARM Classification: Unclassified Product: gcc Version: 4.8.0 Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: target AssignedTo: unassigned@gcc.gnu.org ReportedBy: josh.m.conner@gmail.com memset() is almost never inlined on ARM, even at -O3. If the target is known to be 4-byte aligned or greater, it will be inlined for 1, 2, or 4 byte lengths. If the target alignment is unknown, it will be inlined only for a single byte. I don't see this problem with similar builtins (memcpy, memmove, and memclear (memset with a target value of zero)) - they all inline small cases. It probably makes sense for memset to be inlined up to at least 16 bytes or so in all cases. When aligned, memcpy and memmove use a ldmia/stmia (load multiple/store multiple) sequence to create fairly compact inline code. We could consider doing the same sort of optimization with memset, using stmia only.
next reply other threads:[~2012-12-15 1:11 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2012-12-15 1:11 josh.m.conner at gmail dot com [this message] 2014-06-10 7:34 ` [Bug target/55701] " ramana at gcc dot gnu.org 2014-07-21 12:24 ` amker at gcc dot gnu.org 2014-07-23 16:02 ` amker at gcc dot gnu.org 2014-07-24 11:05 ` ramana at gcc dot gnu.org 2014-09-05 3:46 ` amker at gcc dot gnu.org 2015-02-16 6:02 ` amker at gcc dot gnu.org 2015-02-17 11:09 ` rearnsha at gcc dot gnu.org
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=bug-55701-4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.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: linkBe 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).