re PR tree-optimization/81463 (ICE in scale_loop_profile at gcc/cfgloopmanip.c:603)
authorJan Hubicka <hubicka@ucw.cz>
Tue, 18 Jul 2017 13:51:22 +0000 (15:51 +0200)
committerJan Hubicka <hubicka@gcc.gnu.org>
Tue, 18 Jul 2017 13:51:22 +0000 (13:51 +0000)
PR middle-end/81463
* cfgloopmanip.c (scale_loop_profile): Watch out for zero frequency
again.

From-SVN: r250311

gcc/ChangeLog
gcc/cfgloopmanip.c

index 892c0258534c60ccb2c5dedc2d791d493a19b535..601de6a110ad71d7d99abaf1beb7c27a59f1db3e 100644 (file)
@@ -1,3 +1,9 @@
+2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
+
+       PR middle-end/81463
+       * cfgloopmanip.c (scale_loop_profile): Watch out for zero frequency
+       again.
+
 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
 
        PR middle-end/81462
index f62c829bd5fe3816190f84416534d97d2550c21f..fd335c3fe1dd5e36844bb74bf59322b441ea422c 100644 (file)
@@ -591,7 +591,7 @@ scale_loop_profile (struct loop *loop, profile_probability p,
              determined = true;
            }
        }
-      if (!determined)
+      if (!determined && loop->header->frequency)
        {
          int freq_in = 0;