[PATCH 1/N] Clean-up usage of ipa_fn_summary and ipa_call_summary summaries.

Jan Hubicka hubicka@ucw.cz
Tue Jun 19 15:12:00 GMT 2018


> > Hmm, I do not think we should try to merge -O0 functions :)
> > But again, if you have testcase that triggers this path, we could
> > handle it later.
> 
> This is valid:
> 
> ./xgcc -B. /home/marxin/Programming/gcc/gcc/testsuite/g++.dg/ipa/pr64146.C -fipa-icf
> during IPA pass: icf
> /home/marxin/Programming/gcc/gcc/testsuite/g++.dg/ipa/pr64146.C:36:1: internal compiler error: Segmentation fault
>  }
>  ^
> 0xdbb6bf crash_signal
> 	/home/marxin/Programming/gcc/gcc/toplev.c:324
> 0x7ffff6d8ba6f ???
> 	/usr/src/debug/glibc-2.27-5.1.x86_64/signal/../sysdeps/unix/sysv/linux/x86_64/sigaction.c:0
> 0x162186f ipa_icf::sem_function::merge(ipa_icf::sem_item*)
> 	/home/marxin/Programming/gcc/gcc/ipa-icf.c:1202
> 0x161c0b4 ipa_icf::sem_item_optimizer::merge_classes(unsigned int)
> 	/home/marxin/Programming/gcc/gcc/ipa-icf.c:3562
> 0x1626756 ipa_icf::sem_item_optimizer::execute()
> 	/home/marxin/Programming/gcc/gcc/ipa-icf.c:2641
> 0x1628d76 ipa_icf_driver
> 	/home/marxin/Programming/gcc/gcc/ipa-icf.c:3726
> 0x1628d76 ipa_icf::pass_ipa_icf::execute(function*)
> 	/home/marxin/Programming/gcc/gcc/ipa-icf.c:3773
> 
> Looks reasonable to not rely on ipa_fn_summaries here.

OK, so this is -O0 -fipa-icf?  At -O0 we make most of -f<enable-opt>
flags do nothing.  I am not sure if we want to keep ipa-icf as an
exception just because we can, but I guess it does not harm.
Please add comment that this is !optimize scenario only.

Honza
> 
> > 
> > Thanks! Patch is OK with keeping those two hunks after the
> > remaining few changes.
> > Honza
> > 
> 
> I'm going to install patch with 2 comments added as you requested.
> 
> Martin



More information about the Gcc-patches mailing list