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

            Bug ID: 105555
           Summary: ICE: in fold_offsetof, at c-family/c-common.cc:6815
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zhenyang.xu at uwaterloo dot ca
  Target Milestone: ---

$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/scratch/software/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/13.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /tmp/tmp.lx931ugYgb-gcc-builder/gcc/configure
--enable-languages=c,c++,lto --enable-checking-yes --enable-multiarch
--prefix=/scratch/software/gcc-trunk --disable-bootstrap
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 13.0.0 20220510 (experimental) [master -gbb2921ab8] (GCC)

$ cat mutant_93391780_1648415763714.c
a() {
  &__imag *(_Complex *)a

$ gcc-trunk -O3 -g -Wall -Wextra -c mutant_93391780_1648415763714.c
mutant_93391780_1648415763714.c:1:1: warning: return type defaults to ‘int’
[-Wimplicit-int]
    1 | a() {
      | ^
mutant_93391780_1648415763714.c: In function ‘a’:
mutant_93391780_1648415763714.c:2:3: internal compiler error: in fold_offsetof,
at c-family/c-common.cc:6815
    2 |   &__imag *(_Complex *)a
      |   ^
0x6dc39a fold_offsetof(tree_node*, tree_node*, tree_code)
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c-family/c-common.cc:6815
0x9c345e build_unary_op(unsigned int, tree_code, tree_node*, bool)
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-typeck.cc:4915
0x9d09fe parser_build_unary_op(unsigned int, tree_code, c_expr)
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-typeck.cc:3771
0x9ec947 c_parser_unary_expression
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:8170
0x9edd6f c_parser_cast_expression
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:8103
0x9ee01f c_parser_binary_expression
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:7906
0x9ef51e c_parser_conditional_expression
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:7606
0x9efdc0 c_parser_expr_no_commas
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:7521
0x9f0051 c_parser_expression
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:10697
0x9f0827 c_parser_expression_conv
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:10736
0xa05ff7 c_parser_statement_after_labels
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:6263
0xa08374 c_parser_compound_statement_nostart
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:5800
0xa08a64 c_parser_compound_statement
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:5609
0xa0a443 c_parser_declaration_or_fndef
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:2544
0xa133e3 c_parser_external_declaration
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:1779
0xa13e4b c_parser_translation_unit
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:1652
0xa13e4b c_parse_file()
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c/c-parser.cc:23357
0xa77029 c_common_parse_file()
        /tmp/tmp.lx931ugYgb-gcc-builder/gcc/gcc/c-family/c-opts.cc:1235
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.

Reply via email to