This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/29375] gcc4.0.3 produces code that copies a structure twice
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Oct 2006 04:05:16 -0000
- Subject: [Bug c++/29375] gcc4.0.3 produces code that copies a structure twice
- References: <bug-29375-13259@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #4 from pinskia at gcc dot gnu dot org 2006-10-07 04:05 -------
(In reply to comment #2)
>
> Also, are you saying that the fix for PR23372 also brings us back to avoiding
> direct calls to memcpy?
No just the duplicated memcpy. not inlining memcpy is most likely not a bug,
just tunning differences.
If you want it inlined you should use -minline-all-stringops which just inlines
always most of standard C string functions including memcpy but you should do
timings before you do that because memcpy can be optimized for your target more
than what gets inlined. For an example it could use SSE registers to do the
copy if they exist.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29375