https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98272
--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Eric Botcazou <ebotca...@gcc.gnu.org>: https://gcc.gnu.org/g:61e3c180ad6913fa5af39059de5ba7b3bde50cda commit r11-6110-g61e3c180ad6913fa5af39059de5ba7b3bde50cda Author: Eric Botcazou <ebotca...@adacore.com> Date: Wed Dec 16 09:39:07 2020 +0100 Fix PR tree-optimization/98272 This fixes the precision mismatch introduced by the previous change. gcc/ChangeLog: PR tree-optimization/98272 * tree-switch-conversion.c (bit_test_cluster::emit): When finding out whether the entry test can be merged in the bit test, do the computation using the type of the index expression. gcc/testsuite/ChangeLog: * gcc.dg/pr98272.c: New test.