https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100499
--- Comment #39 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Richard Biener <rgue...@gcc.gnu.org>: https://gcc.gnu.org/g:625f16c798757dcbfdded841f01d7c566d15c55c commit r12-6939-g625f16c798757dcbfdded841f01d7c566d15c55c Author: Richard Biener <rguent...@suse.de> Date: Mon Jan 24 14:59:00 2022 +0100 Fix multiple_of_p behavior with NOP_EXPR We were passing down the original type to recursive invocations of multiple_of_p for say (int)(unsigned * unsigned). 2022-01-24 Richard Biener <rguent...@suse.de> PR tree-optimization/100499 * fold-const.cc (multiple_of_p): Pass the correct type of the expression to the recursive invocation of multiple_of_p for conversions and use CASE_CONVERT.