https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88481

--- Comment #5 from Alexander Monakov <amonakov at gcc dot gnu.org> ---
The code shown in the opening comment looks fine to me, so please isolate the
issue further using debug counters.

Add -fdbg-cnt=if_conversion:99,if_after_combine:99 to -O1. This should lead to
broken code as with plain -O1.

Add -fdbg-cnt=if_conversion:0,if_after_combine:0 to -O1. This should lead to
correct code as with -O1 -fno-if-conversion.

Then you can try 99/0 and 0/99 combinations to find which of two passes is
broken. After that you can bisect by the value of debug counter to find exact
threshold at which it becomes broken (e.g. 0/42 works, 0/43 breaks). Please
attach the two resulting assembly dumps obtained with -S after that.

Reply via email to