On 10/21/2021 2:12 AM, Aldy Hernandez wrote:
The backward threader keeps a hash of visited blocks to avoid crossing
the same block twice.  Interestingly, we haven't been checking it for
the final block out of the path.  This may be inherited from the old
code, as it was simple enough that it didn't matter.  With the
upcoming changes enabling the fully resolving threader, it gets
tripped often enough to cause wrong code to be generated.

Tested on x86-64 Linux.

Committed as obvious.

gcc/ChangeLog:

        * tree-ssa-threadbackward.c (back_threader::maybe_register_path):
        Avoid threading circular paths.
I noticed you already reverted.  I won't complain about the morning test results :-)

Jeff


Reply via email to