https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93674
--- Comment #20 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-8 branch has been updated by Bin Cheng <am...@gcc.gnu.org>: https://gcc.gnu.org/g:386f23b84aafbdb43701b5a50ebe2dc1f4e6201f commit r8-10234-g386f23b84aafbdb43701b5a50ebe2dc1f4e6201f Author: Bin Cheng <bin.ch...@linux.alibaba.com> Date: Mon May 4 16:56:34 2020 +0800 Add unsigned type iv_cand for iv_use with non mode-precision type Precisely, for iv_use if it's not integer/pointer type, or non-mode precision type, add candidate for the corresponding scev in unsigned type with the same precision, rather than its original type. Backport from master. 2020-04-09 Bin Cheng <bin.ch...@linux.alibaba.com> PR tree-optimization/93674 gcc/ * tree-ssa-loop-ivopts.c (langhooks.h): New include. (add_iv_candidate_for_use): For iv_use of non integer or pointer type, or non-mode precision type, add candidate in unsigned type with the same precision. gcc/testsuite/ * g++.dg/pr93674.C: New test.