This is the mail archive of the 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]

Re: [patch] SH: Bootstrap failure

Kaz Kojima wrote:


Mainline fails to build libstdc++-v3 for sh4-unknown-linux-gnu with

gcc/libstdc++-v3/src/ In member function 'void std::strstream::_ZTv0_n12_NSt9strstreamD0Ev()':
gcc/libstdc++-v3/src/ internal compiler error: Segmentation fault

The segfault is caused with accessing null bb->il.rtl pointer in
life_analysis.  The patch

requires explicit initializations of the new field bb->il.rtl.
The attached patch appears to do the minimal thing. Tested on
sh4-unknown-linux-gnu with bootstrap and "make -k check".
Ok for mainline?

I'm not sure if we need to do this extra initialization also for the
optimize && flag_delayed_branch case (I.e. if we compile with
-O2 -fno-schedule-insns-2)  Even if we don't, this
selective initializing becomes ever more brittle as we add more
things that need to be initialized, all of which might become used
in more passes later on.  I think we should make the extra
initializations - up to the "find_basic_blocks (insns);" - dependent
on "if  (optimize)" only.  Likewise for the entire clean-up code
(free_basic_block_vars is harmless and quick if there is nothing to clean
up).  The extra initialization code before dbr_schedule can then go.

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