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



--- Comment #5 from Teresa Johnson <tejohnson at google dot com> 2012-12-01 
07:12:24 UTC ---

Hmm, I'm not sure how that assert can be hit, since we would have

returned earlier if none of the files being merged has any profile

runs. Presumably any profile run should have a sum_all of the counters

> 0, so the saved_profile_info would have to be set in the above loop.

If it is possible somehow that it doesn't, though, the following

additional patch would fix it:



Index: lto-cgraph.c

===================================================================

--- lto-cgraph.c        (revision 193999)

+++ lto-cgraph.c        (working copy)

@@ -1345,7 +1345,8 @@ merge_profile_summaries (struct lto_file_decl_data

         /* Save a pointer to the profile_info with the largest

            scaled sum_all and the scale for use in merging the

            histogram.  */

-        if (lto_gcov_summary.sum_all > saved_sum_all)

+        if (!saved_profile_info

+            || lto_gcov_summary.sum_all > saved_sum_all)

           {

             saved_profile_info = &file_data->profile_info;

             saved_sum_all = lto_gcov_summary.sum_all;



Can you try adding this patch and seeing if that fixes the issue? I

will hold off on sending the first fix for review  to see if I should

add this one.



Thanks,

Teresa



On Fri, Nov 30, 2012 at 10:51 PM, markus at trippelsdorf dot de

<gcc-bugzi...@gcc.gnu.org> wrote:

>

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

>

> --- Comment #4 from Markus Trippelsdorf <markus at trippelsdorf dot de> 
> 2012-12-01 06:51:14 UTC ---

> With your patch applied, Firefox fails to build:

>

> /var/tmp/moz-build-dir/_virtualenv/bin/python

> /var/tmp/mozilla-central/config/pythonpath.py -I../../../config

> /var/tmp/mozilla-central/config/expandlibs_exec.py --depend

> .deps/libsoundtouch.so.pp --target libsoundtouch.so --uselist --  c++

> -pedantic -Wall -Wpointer-arith -Woverloaded-virtual -Werror=return-type

> -Wtype-limits -Wempty-body -Wno-ctor-dtor-privacy -Wno-overlength-strings

> -Wno-invalid-offsetof -Wno-variadic-macros -Wcast-align -Wno-long-long -w

> -march=native -fno-exceptions -fno-strict-aliasing -fno-rtti

> -ffunction-sections -fdata-sections -fno-exceptions -std=gnu++0x -pthread 
> -pipe

>  -DNDEBUG -DTRIMMED -flto=4 -fno-fat-lto-objects -fprofile-use

> -fprofile-correction -Wcoverage-mismatch -O3 -fomit-frame-pointer -fPIC 
> -shared

> -Wl,-z,defs -Wl,--gc-sections -Wl,-h,libsoundtouch.so -o libsoundtouch.so

> AAFilter.o cpu_detect_x86.o FIFOSampleBuffer.o FIRFilter.o RateTransposer.o

> SoundTouch.o TDStretch.o sse_optimized.o    -lpthread -fuse-linker-plugin

> -Wl,-O1,--hash-style=gnu -Wl,-z,noexecstack -Wl,--icf=safe  -fprofile-use

> -Wl,-rpath-link,/var/tmp/moz-build-dir/dist/bin -Wl,-rpath-link,/usr/lib

> ../../../dist/lib/libmozalloc.a  -ldl

> lto1: internal compiler error: in merge_profile_summaries, at 
> lto-cgraph.c:1356

>

> I will try to reduce this later.

>

> --

> Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email

> ------- You are receiving this mail because: -------

> You are on the CC list for the bug.

Reply via email to