// If the end of the block already has an artificial use, that use
// acts to make DEF live at the appropriate point.
- use_info *use = def->last_nondebug_insn_use ();
- if (use && use->insn () == bb->end_insn ())
+ if (find_use (def, bb->end_insn ()).matching_use ())
return;
// Currently there is no need to maintain a backward link from the end
// instruction to the list of live-out uses. Such a list would be
// expensive to update if it was represented using the usual insn_info
// access arrays.
- use = allocate<use_info> (bb->end_insn (), def->resource (), def);
+ auto *use = allocate<use_info> (bb->end_insn (), def->resource (), def);
use->set_is_live_out_use (true);
add_use (use);
}
basic_block pred_cfg_bb = single_pred (ebb->first_bb ()->cfg_bb ());
bb_info *pred_bb = this->bb (pred_cfg_bb);
- if (!bitmap_set_bit (DF_LR_IN (ebb->first_bb ()->cfg_bb ()), regno))
+ if (bitmap_set_bit (DF_LR_IN (ebb->first_bb ()->cfg_bb ()), regno))
{
// The register was not previously live on entry to EBB and
// might not have been live on exit from PRED_BB either.
- if (bitmap_set_bit (DF_LR_OUT (pred_cfg_bb), regno))
- add_live_out_use (pred_bb, def);
+ bitmap_set_bit (DF_LR_OUT (pred_cfg_bb), regno);
+ add_live_out_use (pred_bb, def);
}
else
{