https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115494
Mikael Morin <mikael at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mikael at gcc dot gnu.org --- Comment #12 from Mikael Morin <mikael at gcc dot gnu.org> --- Created attachment 59781 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59781&action=edit Possible patch I have had a look at this PR and can propose the attached patch that seems to fix the issue. It does so by creating new variables during phi translation of expression whose variables are not defined in the current block. I suppose there could be an alternative fix that would avoid the creation of new variables, and just reset the flow sensitive information of existing variables when using them outside of their definition scope. I didn't try it though, and I won't have time to study this further, so I'm posting the patch so that it's not lost.