[Bug ipa/77905] [5/6/7 Regression] ICE at -Os and above in both 32-bit and 64-bit modes on x86_64-linux-gnu (internal compiler error: in ipa_comdats, at ipa-comdats.c:352)
jakub at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Dec 12 10:59:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77905
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |jakub at gcc dot gnu.org
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 40309
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40309&action=edit
gcc7-pr77905.patch
Untested fix. The problem is that during local pure/const pass, it is
determined to be const, but looping, so DECL_STATIC_CONSTRUCTOR is not removed
from it. Only during the ipa pure/const pass it is determined not looping,
which removes DECL_STATIC_CONSTRUCTOR, but has_cdtor is not set because it is
already const (but looping), so we don't do TODO_remove_functions.
More information about the Gcc-bugs
mailing list