[google gcc-4_9] Fix bad LIPO profile produced by gcov-tool

Xinliang David Li davidxl@google.com
Wed Dec 2 01:12:00 GMT 2015


So that field was never inited/used before?

Also saved_compressed_len = (unsigned long) gcov_read_unsigned ();

should use unsigned not unsigned long type.

On Tue, Dec 1, 2015 at 4:53 PM, Rong Xu <xur@google.com> wrote:
> This is only needed for gcov-tool as we need to rewrite the
> moduel-info to the profile (this is only used in decompress)
>
> The transitional compiler path does not need it because the string is
> already decompressed. It only needs to use the strings.
>
> gcov-dump in theory does not need it either if it only dumps the
> strings. But now I added the printing of both lengths. So now it is
> also needed.
>
> On Tue, Dec 1, 2015 at 4:46 PM, Xinliang David Li <davidxl@google.com> wrote:
>> Not sure about this line:
>>
>> mod_info->combined_strlen = saved_compressed_len;
>>
>> This did not exist for the compiler path before.
>>
>> On Tue, Dec 1, 2015 at 4:34 PM, Rong Xu <xur@google.com> wrote:
>>>
>>> Hi,
>>>
>>> This patch fixes the issue when using gcov-tool to merge LIPO profiles
>>> after we compressing the module infomration . We should not decompress
>>> the string as the compressed string should be written directly to the
>>> profile later. Tested with some LIPO profiles.
>>>
>>> Thanks,
>>>
>>> -Rong
>>
>>



More information about the Gcc-patches mailing list