diff options
Diffstat (limited to 'gcc/bt-load.c')
-rw-r--r-- | gcc/bt-load.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/bt-load.c b/gcc/bt-load.c index 5384d01d525..09eea06e379 100644 --- a/gcc/bt-load.c +++ b/gcc/bt-load.c @@ -900,7 +900,7 @@ augment_live_range (bitmap live_range, HARD_REG_SET *btrs_live_in_range, { basic_block *worklist, *tos; - tos = worklist = XNEWVEC (basic_block, n_basic_blocks + 1); + tos = worklist = XNEWVEC (basic_block, n_basic_blocks_for_fn (cfun) + 1); if (dominated_by_p (CDI_DOMINATORS, new_bb, head_bb)) { @@ -1328,7 +1328,8 @@ migrate_btr_def (btr_def def, int min_cost) def_basic_block_freq = basic_block_freq (def->bb); for (attempt = get_immediate_dominator (CDI_DOMINATORS, def->bb); - !give_up && attempt && attempt != ENTRY_BLOCK_PTR && def->cost >= min_cost; + !give_up && attempt && attempt != ENTRY_BLOCK_PTR_FOR_FN (cfun) + && def->cost >= min_cost; attempt = get_immediate_dominator (CDI_DOMINATORS, attempt)) { /* Try to move the instruction that sets the target register into |