https://gcc.gnu.org/bugzilla/show_bug.cgi?id=129213

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <[email protected]>:

https://gcc.gnu.org/g:113193c951e6b0c9065cf41a4cc3cbd73d3b5c04

commit r17-7068-g113193c951e6b0c9065cf41a4cc3cbd73d3b5c04
Author: Jakub Jelinek <[email protected]>
Date:   Thu Dec 3 11:13:21 2026 +0100

    bitintlower: Fix ICE on lowered IFN_BITEXPAND [PR129213]

    When lowering IFN_BITEXPAND, we need to add vdefs/vuses because the
    implementation uses a temporary array, but the ifn itself is const,
    so doesn't have vops.  I thought it is fine to get this fixed at the end
    of the pass, but as the following testcase shows, it is not, already
    later during the pass due to the load handling we walk_aliased_vdefs
    and that is unhappy to encounter VAR_DECLs instead of SSA_NAMEs in
    gimple_vdef/gimple_vuse.

    So, the following patch notes if we've lowered any IFN_BITEXPAND calls
    and at the end of the third phase calls
    update_ssa (TODO_update_ssa_only_virtuals)
    in that case.

    2026-12-03  Jakub Jelinek  <[email protected]>

            PR middle-end/129213
            * gimple-lower-bitint.cc (gimple_lower_bitint): Call
            update_ssa (TODO_update_ssa_only_virtuals) if any IFN_BITEXPAND
            calls with large/huge _BitInt operands/result were lowered.

            * gcc.dg/bitint-157.c: New test.

    Reviewed-by: Richard Biener <[email protected]>

Reply via email to