On 11/13/20 1:21 AM, Richard Sandiford via Gcc-patches wrote:
> This patch adds a routine for finding a “simple” SET for a register
> definition. See the comment in the patch for details.
>
> gcc/
> * rtl.h (simple_regno_set): Declare.
> * rtlanal.c (simple_regno_set): New function.
So I was a bit confused that this is supposed to reject read-write, but
what it's really rejecting is a narrow subset of read-write. In
particular it rejects things that are potentially RMW via subregs. It
doesn't prevent the destination from appearing as a source operand. You
might consider clarifying the comment.
OK
jeff