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

            Bug ID: 129213
           Summary: ICE: tree check: expected ssa_name, have var_decl in
                    walk_non_aliased_vuses, at tree-ssa-alias.cc:4007 with
                    __builtin_bitexpandg() on _BitInt(129)
           Product: gcc
           Version: 17.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zsojka at seznam dot cz
                CC: jakub at gcc dot gnu.org
  Target Milestone: ---
              Host: x86_64-pc-linux-gnu
            Target: x86_64-pc-linux-gnu

Created attachment 66360
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=66360&action=edit
reduced testcase

Compiler output:
$ x86_64-pc-linux-gnu-gcc -O testcase.c 
during GIMPLE pass: bitintlower
testcase.c: In function 'foo':
testcase.c:4:1: internal compiler error: tree check: expected ssa_name, have
var_decl in walk_non_aliased_vuses, at tree-ssa-alias.cc:4007
    4 | foo()
      | ^~~
0x2ef5289 internal_error(char const*, ...)
        /repo/gcc-trunk/gcc/diagnostic-global-context.cc:787
0x9f0655 tree_check_failed(tree_node const*, char const*, int, char const*,
...)
        /repo/gcc-trunk/gcc/tree.cc:9394
0x9a5e72 tree_check(tree_node*, char const*, int, char const*, tree_code)
        /repo/gcc-trunk/gcc/tree.h:4063
0x9a5e72 walk_non_aliased_vuses(ao_ref*, tree_node*, bool, void* (*)(ao_ref*,
tree_node*, void*), void* (*)(ao_ref*, tree_node*, void*, translate_flags*),
bool (*)(edge_def*, void*), tree_node* (*)(tree_node*), unsigned int&, void*)
        /repo/gcc-trunk/gcc/tree-ssa-alias.cc:4007
0x2b27fdf before_dom_children
        /repo/gcc-trunk/gcc/gimple-lower-bitint.cc:7233
0x2ae617e dom_walker::walk(basic_block_def*)
        /repo/gcc-trunk/gcc/domwalk.cc:311
0x2b4b9ad gimple_lower_bitint
        /repo/gcc-trunk/gcc/gimple-lower-bitint.cc:8818
/repo/gcc-trunk/binary-trunk-20261201171750-gc314ed9c5f4-checking-yes-rtl-df-extra-nobootstrap-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/17.0.0/cc1
-quiet -iprefix
/repo/gcc-trunk/binary-trunk-20261201171750-gc314ed9c5f4-checking-yes-rtl-df-extra-nobootstrap-amd64/bin/../lib/gcc/x86_64-pc-linux-gnu/17.0.0/
testcase.c -quiet -dumpdir a- -dumpbase testcase.c -dumpbase-ext .c
-mtune=generic -march=x86-64 -O -o /tmp/cchI20wU.s
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

$ x86_64-pc-linux-gnu-gcc -v
Using built-in specs.
COLLECT_GCC=/repo/gcc-trunk/binary-latest-amd64/bin/x86_64-pc-linux-gnu-gcc
COLLECT_LTO_WRAPPER=/repo/gcc-trunk/binary-trunk-20261201171750-gc314ed9c5f4-checking-yes-rtl-df-extra-nobootstrap-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/17.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++
--enable-valgrind-annotations --disable-nls --enable-checking=yes,rtl,df,extra
--disable-bootstrap --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu
--target=x86_64-pc-linux-gnu --with-ld=/usr/bin/x86_64-pc-linux-gnu-ld
--with-as=/usr/bin/x86_64-pc-linux-gnu-as --enable-libsanitizer
--disable-libstdcxx-pch
--prefix=/repo/gcc-trunk//binary-trunk-20261201171750-gc314ed9c5f4-checking-yes-rtl-df-extra-nobootstrap-amd64
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 17.0.0 20261201 (experimental) (GCC)

Reply via email to