This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/53016] memcpy optimization can cause unaligned access on ARM
- From: "mikpe at it dot uu.se" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 17 Apr 2012 17:27:20 +0000
- Subject: [Bug target/53016] memcpy optimization can cause unaligned access on ARM
- Auto-submitted: auto-generated
- References: <bug-53016-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53016
--- Comment #7 from Mikael Pettersson <mikpe at it dot uu.se> 2012-04-17 17:27:20 UTC ---
The problem is the fact that you attach explicit child_t/parent_t types to
pointers not aligned accordingly. Casting those typed pointers to void*
doesn't eliminate the implied alignment. Marking those types packed fixes the
test case.