On 12/28/2025 7:26 PM, Andrew Pinski wrote:
Since r16-6332-g2a84a753afcf37, if_info->cond is not used indirectly any more
for creating the conditional. So this patch stops doing the swap and fixes up
so the case where if_info->rev_cond might be null.
gcc/ChangeLog:
* ifcvt.cc (noce_try_cond_zero_arith): Don't swap if_info->cond
but use it directly with if_info->rev_cond.
Funny. The swapping (and undoing the swap) was something Daniel and I
were poking at not too long ago. We were looking at our internal
version of that code to see if we could bolt on another case and
realized we didn't always put things back the way they were and our
local copies of those objects were getting out of sync. So more than
happy to see this going away.
OK for the trunk.
Jeff