[gold] Merging string literals with bigger alignment
Tue Mar 26 11:23:00 GMT 2013
> Also, when processing the section in
> Output_merge_string::do_add_input_section, we count the strings in the
> section essentially by counting the null characters. This will count
> each padding byte as a separate string, so we'll get an inflated
> estimate of the number of strings. If we accept the above convention,
> the compiler should never point to any of these (unaligned) padding
> bytes as a null string, so we shouldn't need to count them or call
> add_with_length_and_alignment for all those null strings. In other
> words, once we add a string, we should skip ahead to the next
> alignment boundary.
Thank you, that sounds correct to me, I attached the new version
that gives a warning if we encounter an incorrectly aligned string.
Also we don't count padding here (except for the padding in the end
of the section).
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 19056 bytes
Desc: not available
More information about the Binutils