Initialize a BB count in switch lowering.
authorMartin Liska <mliska@suse.cz>
Wed, 4 Dec 2019 10:13:49 +0000 (11:13 +0100)
committerMartin Liska <marxin@gcc.gnu.org>
Wed, 4 Dec 2019 10:13:49 +0000 (10:13 +0000)
2019-12-04  Martin Liska  <mliska@suse.cz>

* tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
Initialize count of newly created BB.

From-SVN: r278959

gcc/ChangeLog
gcc/tree-switch-conversion.c

index 7b518af4612141b2185630c5cea63e40455e092e..97e2c97a851fda7a3de91ce734e85a9ab2af81c7 100644 (file)
@@ -1,3 +1,8 @@
+2019-12-04  Martin Liska  <mliska@suse.cz>
+
+       * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
+       Initialize count of newly created BB.
+
 2019-12-04  Jakub Jelinek  <jakub@redhat.com>
 
        PR tree-optimization/92734
index e741f56b520360752b9cf9e30f57b646fb000e8e..4940038b1251c4069d712e56c68ef54e3cd7bc74 100644 (file)
@@ -1829,6 +1829,7 @@ switch_decision_tree::try_switch_expansion (vec<cluster *> &clusters)
     if (clusters[i]->get_type () != SIMPLE_CASE)
       {
        clusters[i]->m_case_bb = create_empty_bb (bb);
+       clusters[i]->m_case_bb->count = bb->count;
        clusters[i]->m_case_bb->loop_father = bb->loop_father;
       }