From: Segher Boessenkool Date: Tue, 1 Oct 2019 11:12:03 +0000 (+0200) Subject: regrename: Use PC instead of CC0 to hide operands X-Git-Tag: upstream/12.2.0~21501 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=58e721d255c111b2ae012bb452cf39a0ee58ed27;p=platform%2Fupstream%2Fgcc.git regrename: Use PC instead of CC0 to hide operands The regrename pass temporarily changes some operand RTL to CC0 so that note_stores and scan_rtx don't see those operands. CC0 is deprecated and we want to remove it, so we need to use something else here. PC fits the bill fine. * regrename.c (hide_operands): Use pc_rtx instead of cc0_rtx. (build_def_use): Use PC instead of CC0 in a comment. From-SVN: r276401 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 2c515e1..4d0ce47 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2019-10-01 Segher Boessenkool + + * regrename.c (hide_operands): Use pc_rtx instead of cc0_rtx. + (build_def_use): Use PC instead of CC0 in a comment. + 2019-10-01 Richard Sandiford * rtl.def (CLOBBER_HIGH): Delete. diff --git a/gcc/regrename.c b/gcc/regrename.c index 8c3bae8..408bccc 100644 --- a/gcc/regrename.c +++ b/gcc/regrename.c @@ -1517,7 +1517,7 @@ scan_rtx (rtx_insn *insn, rtx *loc, enum reg_class cl, enum scan_actions action, } /* Hide operands of the current insn (of which there are N_OPS) by - substituting cc0 for them. + substituting pc for them. Previous values are stored in the OLD_OPERANDS and OLD_DUPS. For every bit set in DO_NOT_HIDE, we leave the operand alone. If INOUT_AND_EC_ONLY is set, we only do this for OP_INOUT type operands @@ -1541,7 +1541,7 @@ hide_operands (int n_ops, rtx *old_operands, rtx *old_dups, continue; if (!inout_and_ec_only || recog_data.operand_type[i] == OP_INOUT || op_alt[i].earlyclobber) - *recog_data.operand_loc[i] = cc0_rtx; + *recog_data.operand_loc[i] = pc_rtx; } for (i = 0; i < recog_data.n_dups; i++) { @@ -1551,7 +1551,7 @@ hide_operands (int n_ops, rtx *old_operands, rtx *old_dups, continue; if (!inout_and_ec_only || recog_data.operand_type[opn] == OP_INOUT || op_alt[opn].earlyclobber) - *recog_data.dup_loc[i] = cc0_rtx; + *recog_data.dup_loc[i] = pc_rtx; } } @@ -1754,7 +1754,7 @@ build_def_use (basic_block bb) /* Step 2: Mark chains for which we have reads outside operands as unrenamable. - We do this by munging all operands into CC0, and closing + We do this by munging all operands into PC, and closing everything remaining. */ hide_operands (n_ops, old_operands, old_dups, untracked_operands,