https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94026
--- Comment #2 from Fei Yang <felix.yang at huawei dot com> --- The test case is reduced from spec2017 benchmark. int FastBoard::count_pliberties(const int i) { return count_neighbours(EMPTY, i); } // count neighbours of color c at vertex v int FastBoard::count_neighbours(const int c, const int v) { assert(c == WHITE || c == BLACK || c == EMPTY); return (m_neighbours[v] >> (NBR_SHIFT * c)) & 7; } bool FastBoard::self_atari(int color, int vertex) { assert(get_square(vertex) == FastBoard::EMPTY); // 1) count new liberties, if we add 2 or more we're safe if (count_pliberties(vertex) >= 2) { return false; } ......