https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77689
Jeffrey A. Law <law at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |law at redhat dot com --- Comment #12 from Jeffrey A. Law <law at redhat dot com> --- WRT c#5. Rather than jump threading this seems more suited to the erroneous path isolation code. I suspect the reason that code does not fire is the shape of the CFG. If the PHI for iftmp.2_40 were in BB 8, then I'd expect the erroneous path optimizer to catch this. It's a known limitation. To catch it, the erroneous path optimizer would have to do block duplication in a manner similar to what jump threading does for join blocks (or the backwards threader does for regions with embedded control flow).