This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/78821] GCC7: Copying whole 32 bits structure field by field not optimised into copying whole 32 bits at once
- From: "ubizjak at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 20 Nov 2017 16:03:30 +0000
- Subject: [Bug tree-optimization/78821] GCC7: Copying whole 32 bits structure field by field not optimised into copying whole 32 bits at once
- Auto-submitted: auto-generated
- References: <bug-78821-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78821
--- Comment #30 from Uroš Bizjak <ubizjak at gmail dot com> ---
Another unhandled case:
--cut here--
typedef __SIZE_TYPE__ size_t;
void baz (char *buf, size_t base, unsigned int data)
{
buf[base] = data;
buf[base+1] = data >> 8;
}
--cut here--
compiles to:
movb %dl, (%rdi,%rsi)
movb %dh, 1(%rdi,%rsi)
ret