This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/54303] -fdata-sections -ffunction-sections and -fmerge-constants do not work well together


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54303

Paul Brook <pbrook at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pbrook at gcc dot gnu.org

--- Comment #7 from Paul Brook <pbrook at gcc dot gnu.org> 2012-10-01 17:55:28 UTC ---
I believe the arm v.s. x86 differences are a red herring.  You'll notice that
one of the strings happens to be a multiple of 8 bytes long, so by default gcc
chooses to align it, in the hope that we'll hit a fast patch in memcpy.  On ARM
we choose to use word alignment unconditionally for similar reasons.  This is
reasonable, the effectiveness of this alignment will depend on the performance
characteristics of the str* and mem* functions.

Arguably this is a linker bug.  It should be able to remove unused elements
from mergeable string sections.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]