From 37ffe56c01e4a9e80a3b3c4f5beb86d80a0663db Mon Sep 17 00:00:00 2001 From: Martin Liska Date: Thu, 24 Sep 2020 13:34:58 +0200 Subject: Revert "switch lowering: limit number of cluster attemps" This reverts commit c6df6039e9180c580945266302ec14047d358364. --- gcc/tree-switch-conversion.c | 17 ----------------- 1 file changed, 17 deletions(-) (limited to 'gcc/tree-switch-conversion.c') diff --git a/gcc/tree-switch-conversion.c b/gcc/tree-switch-conversion.c index e6a2c7a..186411f 100644 --- a/gcc/tree-switch-conversion.c +++ b/gcc/tree-switch-conversion.c @@ -1183,7 +1183,6 @@ jump_table_cluster::find_jump_tables (vec &clusters) min.quick_push (min_cluster_item (0, 0, 0)); - HOST_WIDE_INT attempts = 0; for (unsigned i = 1; i <= l; i++) { /* Set minimal # of clusters with i-th item to infinite. */ @@ -1195,14 +1194,6 @@ jump_table_cluster::find_jump_tables (vec &clusters) if (i - j < case_values_threshold ()) s += i - j; - if (attempts++ == param_max_switch_clustering_attempts) - { - if (dump_file) - fprintf (dump_file, ";; Bail out: " - "--param=max-switch-clustering-attempts reached\n"); - return clusters.copy (); - } - /* Prefer clusters with smaller number of numbers covered. */ if ((min[j].m_count + 1 < min[i].m_count || (min[j].m_count + 1 == min[i].m_count @@ -1317,7 +1308,6 @@ bit_test_cluster::find_bit_tests (vec &clusters) min.quick_push (min_cluster_item (0, 0, 0)); - HOST_WIDE_INT attempts = 0; for (unsigned i = 1; i <= l; i++) { /* Set minimal # of clusters with i-th item to infinite. */ @@ -1325,13 +1315,6 @@ bit_test_cluster::find_bit_tests (vec &clusters) for (unsigned j = 0; j < i; j++) { - if (attempts++ == param_max_switch_clustering_attempts) - { - if (dump_file) - fprintf (dump_file, ";; Bail out: " - "--param=max-switch-clustering-attempts reached\n"); - return clusters.copy (); - } if (min[j].m_count + 1 < min[i].m_count && can_be_handled (clusters, j, i - 1)) min[i] = min_cluster_item (min[j].m_count + 1, j, INT_MAX); -- cgit v1.1