[patch] SH: Bootstrap failure

Joern RENNECKE joern.rennecke@st.com
Tue Jun 28 14:15:00 GMT 2005


Kaz Kojima wrote:

>Hi,
>
>Mainline fails to build libstdc++-v3 for sh4-unknown-linux-gnu with
>
>gcc/libstdc++-v3/src/strstream.cc: In member function 'void std::strstream::_ZTv0_n12_NSt9strstreamD0Ev()':
>gcc/libstdc++-v3/src/strstream.cc:415: internal compiler error: Segmentation fault
>
>The segfault is caused with accessing null bb->il.rtl pointer in
>life_analysis.  The patch
>
>http://gcc.gnu.org/ml/gcc-patches/2005-06/msg00978.html
>
>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.



More information about the Gcc-patches mailing list