https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107767
--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> --- So the optimization is enabled after r13-1184-g57424087e82db140 where we newly convert if-else-if series to switch, that's later converted by switch conversion pass to the array lookup. Now the question is why the CSWITCH happens with -Os.