aboutsummaryrefslogtreecommitdiff
path: root/gcc/lra-constraints.c
diff options
context:
space:
mode:
authorRichard Sandiford <richard.sandiford@arm.com>2019-09-09 17:59:19 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2019-09-09 17:59:19 +0000
commit44942965f4eae141bd1f8300e7f77d0c9a3936e4 (patch)
tree4813d3c9507c4d469a9cc04f2662bae23d1b3e58 /gcc/lra-constraints.c
parentdc333d8ff60909dbed89126443e3024f1592f8a4 (diff)
downloadgcc-44942965f4eae141bd1f8300e7f77d0c9a3936e4.zip
gcc-44942965f4eae141bd1f8300e7f77d0c9a3936e4.tar.gz
gcc-44942965f4eae141bd1f8300e7f77d0c9a3936e4.tar.bz2
Remove IOR_HARD_REG_SET
Use "x |= y" instead of "IOR_HARD_REG_SET (x, y)" (or just "x | y" if the result is a temporary). 2019-09-09 Richard Sandiford <richard.sandiford@arm.com> gcc/ * hard-reg-set.h (HARD_REG_SET::operator|): New function. (HARD_REG_SET::operator|=): Likewise. (IOR_HARD_REG_SET): Delete. * config/gcn/gcn.c (gcn_md_reorg): Use "|" instead of IOR_HARD_REG_SET. * config/m32c/m32c.c (m32c_register_move_cost): Likewise. * config/s390/s390.c (s390_adjust_loop_scan_osc): Likewise. * final.c (collect_fn_hard_reg_usage): Likewise. * hw-doloop.c (scan_loop, optimize_loop): Likewise. * ira-build.c (merge_hard_reg_conflicts): Likewise. (ior_hard_reg_conflicts, create_cap_allocno, propagate_allocno_info) (propagate_some_info_from_allocno): Likewise. (copy_info_to_removed_store_destinations): Likewise. * ira-color.c (add_allocno_hard_regs_to_forest, assign_hard_reg) (allocno_reload_assign, ira_reassign_pseudos): Likewise. (fast_allocation): Likewise. * ira-conflicts.c (ira_build_conflicts): Likewise. * ira-lives.c (make_object_dead, process_single_reg_class_operands) (process_bb_node_lives): Likewise. * ira.c (setup_pressure_classes, setup_reg_class_relations): Likewise. * lra-assigns.c (find_hard_regno_for_1): Likewise. (setup_live_pseudos_and_spill_after_risky_transforms): Likewise. * lra-constraints.c (process_alt_operands, inherit_in_ebb): Likewise. * lra-eliminations.c (spill_pseudos, update_reg_eliminate): Likewise. * lra-lives.c (mark_pseudo_dead, check_pseudos_live_through_calls) (process_bb_lives): Likewise. * lra-spills.c (assign_spill_hard_regs): Likewise. * postreload.c (reload_combine): Likewise. * reginfo.c (init_reg_sets_1): Likewise. * regrename.c (merge_overlapping_regs, find_rename_reg) (merge_chains): Likewise. * reload1.c (maybe_fix_stack_asms, order_regs_for_reload, find_reg) (find_reload_regs, finish_spills, choose_reload_regs_init) (emit_reload_insns): Likewise. * reorg.c (redundant_insn): Likewise. * resource.c (find_dead_or_set_registers, mark_set_resources) (mark_target_live_regs): Likewise. * rtlanal.c (find_all_hard_reg_sets): Likewise. * sched-deps.c (sched_analyze_insn): Likewise. * sel-sched.c (mark_unavailable_hard_regs): Likewise. (find_best_reg_for_expr): Likewise. * shrink-wrap.c (try_shrink_wrapping): Likewise. From-SVN: r275531
Diffstat (limited to 'gcc/lra-constraints.c')
-rw-r--r--gcc/lra-constraints.c21
1 files changed, 7 insertions, 14 deletions
diff --git a/gcc/lra-constraints.c b/gcc/lra-constraints.c
index c3f0c6e..d4eea85 100644
--- a/gcc/lra-constraints.c
+++ b/gcc/lra-constraints.c
@@ -2373,14 +2373,12 @@ process_alt_operands (int only_alternative)
if (mode == BLKmode)
break;
this_alternative = reg_class_subunion[this_alternative][cl];
- IOR_HARD_REG_SET (this_alternative_set,
- reg_class_contents[cl]);
+ this_alternative_set |= reg_class_contents[cl];
if (costly_p)
{
this_costly_alternative
= reg_class_subunion[this_costly_alternative][cl];
- IOR_HARD_REG_SET (this_costly_alternative_set,
- reg_class_contents[cl]);
+ this_costly_alternative_set |= reg_class_contents[cl];
}
winreg = true;
if (REG_P (op))
@@ -6245,8 +6243,7 @@ inherit_in_ebb (rtx_insn *head, rtx_insn *tail)
bitmap_clear (&invalid_invariant_regs);
last_processed_bb = NULL;
CLEAR_HARD_REG_SET (potential_reload_hard_regs);
- live_hard_regs = eliminable_regset;
- IOR_HARD_REG_SET (live_hard_regs, lra_no_alloc_regs);
+ live_hard_regs = eliminable_regset | lra_no_alloc_regs;
/* We don't process new insns generated in the loop. */
for (curr_insn = tail; curr_insn != PREV_INSN (head); curr_insn = prev_insn)
{
@@ -6316,8 +6313,7 @@ inherit_in_ebb (rtx_insn *head, rtx_insn *tail)
else
setup_next_usage_insn (src_regno, curr_insn, reloads_num, false);
if (hard_reg_set_subset_p (reg_class_contents[cl], live_hard_regs))
- IOR_HARD_REG_SET (potential_reload_hard_regs,
- reg_class_contents[cl]);
+ potential_reload_hard_regs |= reg_class_contents[cl];
}
else if (src_regno < 0
&& dst_regno >= lra_constraint_new_regno_start
@@ -6334,8 +6330,7 @@ inherit_in_ebb (rtx_insn *head, rtx_insn *tail)
if (process_invariant_for_inheritance (SET_DEST (curr_set), SET_SRC (curr_set)))
change_p = true;
if (hard_reg_set_subset_p (reg_class_contents[cl], live_hard_regs))
- IOR_HARD_REG_SET (potential_reload_hard_regs,
- reg_class_contents[cl]);
+ potential_reload_hard_regs |= reg_class_contents[cl];
}
else if (src_regno >= lra_constraint_new_regno_start
&& dst_regno < lra_constraint_new_regno_start
@@ -6357,8 +6352,7 @@ inherit_in_ebb (rtx_insn *head, rtx_insn *tail)
/* Invalidate. */
usage_insns[dst_regno].check = 0;
if (hard_reg_set_subset_p (reg_class_contents[cl], live_hard_regs))
- IOR_HARD_REG_SET (potential_reload_hard_regs,
- reg_class_contents[cl]);
+ potential_reload_hard_regs |= reg_class_contents[cl];
}
else if (INSN_P (curr_insn))
{
@@ -6593,8 +6587,7 @@ inherit_in_ebb (rtx_insn *head, rtx_insn *tail)
if (ira_class_hard_regs_num[cl] <= max_small_class_regs_num)
reloads_num++;
if (hard_reg_set_subset_p (reg_class_contents[cl], live_hard_regs))
- IOR_HARD_REG_SET (potential_reload_hard_regs,
- reg_class_contents[cl]);
+ potential_reload_hard_regs |= reg_class_contents[cl];
}
}
if (NONDEBUG_INSN_P (curr_insn))