https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79529
--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> --- (In reply to Aldy Hernandez from comment #1) > Looks reasonable, thanks. > > I would probably check for def == NULL too, just in case: > > if (!def || gimple_nop_p (def)) > return true; > > ...since I see that replace_ssa_name can set it to NULL: > > /* Now that we've used the def stmt to define new_name, make sure it > doesn't define name anymore. */ > SSA_NAME_DEF_STMT (name) = NULL; > > Would you care to test and submit a patch to the list? Ok, I'll include that check and re-test the patch and send to ML. Thanks for hint.