https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69546
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Author: jakub Date: Sat Jan 30 18:04:13 2016 New Revision: 233012 URL: https://gcc.gnu.org/viewcvs?rev=233012&root=gcc&view=rev Log: PR tree-optimization/69546 * wide-int.cc (wi::divmod_internal): For unsigned division where both operands fit into uhwi, if o1 is 1 and o0 has msb set, if divident_prec is larger than bits per hwi, clear another quotient word and return 2 instead of 1. Similarly for remainder with msb in HWI set, if dividend_prec is larger than bits per hwi. * gcc.dg/torture/pr69546.c: New test. Added: trunk/gcc/testsuite/gcc.dg/torture/pr69546-1.c trunk/gcc/testsuite/gcc.dg/torture/pr69546-2.c Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/wide-int.cc