PR91176: Skip debug insns when computing inline costs
authorJan Hubicka <hubicka@ucw.cz>
Tue, 16 Jul 2019 08:12:05 +0000 (10:12 +0200)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Tue, 16 Jul 2019 08:12:05 +0000 (08:12 +0000)
Apply Honza's fix for an aarch64-linux-gnu bootstrap failure.

2019-07-16  Jan Hubicka  <hubicka@ucw.cz>

gcc/
PR bootstrap/91176
* ipa-fnsummary.c (analyze_function_body): Skip debug stmts

From-SVN: r273507

gcc/ChangeLog
gcc/ipa-fnsummary.c

index 7ab87dad279174a46040dff0ba51c946bad8b3bf..82a8f0b199ff51c771f24c06965da29d27f3631d 100644 (file)
@@ -1,3 +1,8 @@
+2019-07-16  Jan Hubicka  <hubicka@ucw.cz>
+
+       PR bootstrap/91176
+       * ipa-fnsummary.c (analyze_function_body): Skip debug stmts
+
 2019-07-15  Segher Boessenkool  <segher@kernel.crashing.org>
 
        PR target/91050
index 78eb8cb6f50d0cc33f19c46f521b93445a371630..fe125aca62c51ee7688af00f5cca9cb3e9a6235f 100644 (file)
@@ -2078,8 +2078,8 @@ analyze_function_body (struct cgraph_node *node, bool early)
 
       fix_builtin_expect_stmt = find_foldable_builtin_expect (bb);
 
-      for (gimple_stmt_iterator bsi = gsi_start_bb (bb); !gsi_end_p (bsi);
-          gsi_next (&bsi))
+      for (gimple_stmt_iterator bsi = gsi_start_nondebug_bb (bb);
+          !gsi_end_p (bsi); gsi_next_nondebug (&bsi))
        {
          gimple *stmt = gsi_stmt (bsi);
          int this_size = estimate_num_insns (stmt, &eni_size_weights);