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

            Bug ID: 119176
           Summary: ICE: Segmentation fault at c_push_function_context()
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: bic60176 at gmail dot com
  Target Milestone: ---

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

Compiler Explorer: https://godbolt.org/z/KKq4jeTaK

Console:
<source>:29:3: error: expected expression before '#pragma'
   29 |   _Pragma("GCC novector") for (int i = 0; i < DIST * 2; ++i) {         
       \
      |   ^~~~~~~
<source>:14:3: note: in expansion of macro 'DO_TEST'
   14 |   M(sc) M(uc) M(ss) M(us) M(si) M(ui) M(sll) M(ull) M(float) M(double)
      |   ^
<source>:47:15: note: in expansion of macro 'FOR_EACH_TYPE'
   47 | int const_1 = FOR_EACH_TYPE(DO_TEST);
      |               ^~~~~~~~~~~~~
<source>:29:45: error: expected '=', ',', ';', 'asm' or '__attribute__' before
'<' token
   29 |   _Pragma("GCC novector") for (int i = 0; i < DIST * 2; ++i) {         
       \
      |                                             ^
<source>:14:3: note: in expansion of macro 'DO_TEST'
   14 |   M(sc) M(uc) M(ss) M(us) M(si) M(ui) M(sll) M(ull) M(float) M(double)
      |   ^
<source>:47:15: note: in expansion of macro 'FOR_EACH_TYPE'
   47 | int const_1 = FOR_EACH_TYPE(DO_TEST);
      |               ^~~~~~~~~~~~~
<source>:29:57: error: expected identifier or '(' before '++' token
   29 |   _Pragma("GCC novector") for (int i = 0; i < DIST * 2; ++i) {         
       \
      |                                                         ^~
<source>:14:3: note: in expansion of macro 'DO_TEST'
   14 |   M(sc) M(uc) M(ss) M(us) M(si) M(ui) M(sll) M(ull) M(float) M(double)
      |   ^
<source>:47:15: note: in expansion of macro 'FOR_EACH_TYPE'
   47 | int const_1 = FOR_EACH_TYPE(DO_TEST);
      |               ^~~~~~~~~~~~~
<source>:29:3: internal compiler error: Segmentation fault
   29 |   _Pragma("GCC novector") for (int i = 0; i < DIST * 2; ++i) {         
       \
      |   ^~~~~~~
<source>:14:9: note: in expansion of macro 'DO_TEST'
   14 |   M(sc) M(uc) M(ss) M(us) M(si) M(ui) M(sll) M(ull) M(float) M(double)
      |         ^
<source>:47:15: note: in expansion of macro 'FOR_EACH_TYPE'
   47 | int const_1 = FOR_EACH_TYPE(DO_TEST);
      |               ^~~~~~~~~~~~~
0x25f8ee5 diagnostic_context::diagnostic_impl(rich_location*,
diagnostic_metadata const*, diagnostic_option_id, char const*, __va_list_tag
(*) [1], diagnostic_t)
        ???:0
0x260feb6 internal_error(char const*, ...)
        ???:0
0xa21351 c_push_function_context()
        ???:0
0xab28de c_parse_file()
        ???:0
0xb31559 c_common_parse_file()
        ???:0
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.
Compiler returned: 1

Reply via email to