This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Question regarding preventing optimizing out of register in expansion
On 6/26/18 4:05 AM, Peryt, Sebastian wrote:
> With some changes simplified implementation of my expansion is as follows:
> tmp_op0 = gen_reg_rtx (mode);
> emit_move_insn (tmp_op0, op0);
You set tmp_op0 here, and then....
> emit_insn (gen_rtx_SET (tmp_op0, reg));
You set it again here without ever using it above, so it's dead code,
which explains why it's removed.
Peter