diff options
author | vmakarov <vmakarov@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-01-15 17:32:47 +0000 |
---|---|---|
committer | vmakarov <vmakarov@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-01-15 17:32:47 +0000 |
commit | e374deeb07276ff155d8081e07b291db99f00a08 (patch) | |
tree | 4b6cdf1a3a3ac85f215b25daa4443679c1411cc8 /gcc/lra-coalesce.c | |
parent | 71035007f8217a5221f549c646cec7c365b98a00 (diff) | |
download | gcc-e374deeb07276ff155d8081e07b291db99f00a08.tar.gz |
2014-01-15 Vladimir Makarov <vmakarov@redhat.com>
PR rtl-optimization/59511
* ira.c (ira_init_register_move_cost): Use memory costs for some
cases of register move cost calculations.
* lra-constraints.c (lra_constraints): Use REG_FREQ_FROM_BB
instead of BB frequency.
* lra-coalesce.c (move_freq_compare_func, lra_coalesce): Ditto.
* lra-assigns.c (find_hard_regno_for): Ditto.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@206636 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/lra-coalesce.c')
-rw-r--r-- | gcc/lra-coalesce.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/gcc/lra-coalesce.c b/gcc/lra-coalesce.c index 431b3e21048..350977ca220 100644 --- a/gcc/lra-coalesce.c +++ b/gcc/lra-coalesce.c @@ -79,8 +79,8 @@ move_freq_compare_func (const void *v1p, const void *v2p) rtx mv2 = *(const rtx *) v2p; int pri1, pri2; - pri1 = BLOCK_FOR_INSN (mv1)->frequency; - pri2 = BLOCK_FOR_INSN (mv2)->frequency; + pri1 = REG_FREQ_FROM_BB (BLOCK_FOR_INSN (mv1)); + pri2 = REG_FREQ_FROM_BB (BLOCK_FOR_INSN (mv2)); if (pri2 - pri1) return pri2 - pri1; @@ -277,7 +277,7 @@ lra_coalesce (void) fprintf (lra_dump_file, " Coalescing move %i:r%d-r%d (freq=%d)\n", INSN_UID (mv), sregno, dregno, - BLOCK_FOR_INSN (mv)->frequency); + REG_FREQ_FROM_BB (BLOCK_FOR_INSN (mv))); /* We updated involved_insns_bitmap when doing the merge. */ } else if (!(lra_intersected_live_ranges_p @@ -291,7 +291,7 @@ lra_coalesce (void) " Coalescing move %i:r%d(%d)-r%d(%d) (freq=%d)\n", INSN_UID (mv), sregno, ORIGINAL_REGNO (SET_SRC (set)), dregno, ORIGINAL_REGNO (SET_DEST (set)), - BLOCK_FOR_INSN (mv)->frequency); + REG_FREQ_FROM_BB (BLOCK_FOR_INSN (mv))); bitmap_ior_into (&involved_insns_bitmap, &lra_reg_info[sregno].insn_bitmap); bitmap_ior_into (&involved_insns_bitmap, @@ -316,7 +316,8 @@ lra_coalesce (void) /* Coalesced move. */ if (lra_dump_file != NULL) fprintf (lra_dump_file, " Removing move %i (freq=%d)\n", - INSN_UID (insn), BLOCK_FOR_INSN (insn)->frequency); + INSN_UID (insn), + REG_FREQ_FROM_BB (BLOCK_FOR_INSN (insn))); lra_set_insn_deleted (insn); } } |