http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48822
Richard Guenther <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2011.04.29 13:58:16 Known to work| |4.4.5, 4.6.0 Target Milestone|--- |4.5.4 Summary|G++ gets stucks and never |[4.5 Regression] G++ gets |finishes compilation when |stucks and never finishes |enabling -O2/3 optimization |compilation when enabling |options. |-O2/3 optimization options. Ever Confirmed|0 |1 Known to fail| |4.5.3 --- Comment #2 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-04-29 13:58:16 UTC --- Confirmed. It's stuck in SCCVN/FRE visiting g_37 = PHI <g_36(12), g_38(13)> g_38 = PHI <g_35(12), g_39(13)> g_39 = g_37 % g_38; Value numbering g_37 stmt = g_37 = PHI <g_36(12), g_38(13)> Setting value number of g_37 to g_37 (changed) Value numbering g_38 stmt = g_38 = PHI <g_35(12), g_39(13)> Setting value number of g_38 to 0 (changed) Value numbering g_39 stmt = g_39 = g_37 % g_38; Setting value number of g_39 to g_39 (changed) Value numbering g_37 stmt = g_37 = PHI <g_36(12), g_38(13)> Setting value number of g_37 to 0 (changed) Value numbering g_38 stmt = g_38 = PHI <g_35(12), g_39(13)> Setting value number of g_38 to g_38 (changed) Value numbering g_39 stmt = g_39 = g_37 % g_38; RHS g_37 % g_38 simplified to 0 has constants 1 Setting value number of g_39 to 0 (changed) thus it oscillates. Maybe latent everywhere else. Workaround: -fno-tree-fre -fno-tree-pre