re PR tree-optimization/64058 (Performance degradation after r216304)
authorJeff Law <law@redhat.com>
Wed, 23 Mar 2016 13:20:16 +0000 (07:20 -0600)
committerJeff Law <law@gcc.gnu.org>
Wed, 23 Mar 2016 13:20:16 +0000 (07:20 -0600)
commit478baf913e79d1d3219b513b494943c830850593
treea015e0e499c5e938dbce68a3de2ecabc309f489a
parentb01e88e56b3ad6bf76c18500035bc4ed8ef036cd
re PR tree-optimization/64058 (Performance degradation after r216304)

PR tree-optimization/64058
* tree-ssa-coalesce.c (struct coalesce_pair): Add new field
CONFLICT_COUNT.
(struct ssa_conflicts): Move up earlier in the file.
(conflicts_, var_map_): New static variables.
(initialize_conflict_count): New function to initialize the
CONFLICT_COUNT field for each conflict pair.
(compare_pairs): Lazily initialize the conflict count and use it
as the first tie-breaker.
(sort_coalesce_list): Add new arguments conflicts, map.  Initialize
and wipe conflicts_ and map_ around the call to qsort.  Remove
special case for 2 coalesce pairs.
* bitmap.c (bitmap_count_unique_bits): New function.
(bitmap_count_bits_in_word): New function, extracted from
bitmap_count_bits.
(bitmap_count_bits): Use bitmap_count_bits_in_word.
* bitmap.h (bitmap_count_unique_bits): Declare it.

From-SVN: r234425
gcc/ChangeLog
gcc/bitmap.c
gcc/bitmap.h
gcc/tree-ssa-coalesce.c