public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/111862] New: GCC: internal compiler error: tree check: expected class 'type', have 'exceptional' (error_mark) in c_parser_omp_clause_reduction, at c/c-parser.cc:16234
@ 2023-10-18  9:21 141242068 at smail dot nju.edu.cn
  2023-10-18 19:02 ` [Bug c/111862] " pinskia at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: 141242068 at smail dot nju.edu.cn @ 2023-10-18  9:21 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 111862
           Summary: GCC: internal compiler error: tree check: expected
                    class 'type', have 'exceptional' (error_mark) in
                    c_parser_omp_clause_reduction, at c/c-parser.cc:16234
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: 141242068 at smail dot nju.edu.cn
  Target Milestone: ---

The bug triggering program, compile it with option `-O1 -fopenmp-simd`, gcc
crashes:
```
union S {};
void baz (void *);

int const_1 = 0;
void f (void)
{
  struct S s;
  int i;
  #pragma omp taskloop simd reduction(+:s)
  for (i = const_1; i < 1; i++)
    baz (&s);
}
```

Compiler Explorer: https://godbolt.org/z/361KvMv41

This bug seems similar to #110500, maybe it was not fully fixed in #110500?

Stack dump:
```
<source>: In function 'f':
<source>:7:10: error: 'S' defined as wrong kind of tag
    7 |   struct S s;
      |          ^
<source>:7:12: error: storage size of 's' isn't known
    7 |   struct S s;
      |            ^
<source>:9:11: internal compiler error: tree check: expected class 'type', have
'exceptional' (error_mark) in c_parser_omp_clause_reduction, at
c/c-parser.cc:16234
    9 |   #pragma omp taskloop simd reduction(+:s)
      |           ^~~
0x231210e internal_error(char const*, ...)
        ???:0
0x8a8b5c tree_class_check_failed(tree_node const*, tree_code_class, char
const*, int, char const*)
        ???:0
0xaa6d8d c_parse_file()
        ???:0
0xb1a0c9 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.
```

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug c/111862] GCC: internal compiler error: tree check: expected class 'type', have 'exceptional' (error_mark) in c_parser_omp_clause_reduction, at c/c-parser.cc:16234
  2023-10-18  9:21 [Bug c/111862] New: GCC: internal compiler error: tree check: expected class 'type', have 'exceptional' (error_mark) in c_parser_omp_clause_reduction, at c/c-parser.cc:16234 141242068 at smail dot nju.edu.cn
@ 2023-10-18 19:02 ` pinskia at gcc dot gnu.org
  0 siblings, 0 replies; 2+ messages in thread
From: pinskia at gcc dot gnu.org @ 2023-10-18 19:02 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |DUPLICATE
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Dup of bug 110500 (which was not fixed yet; just a patch was posted to the bug
report for someone to finish up).

*** This bug has been marked as a duplicate of bug 110500 ***

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-10-18 19:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-18  9:21 [Bug c/111862] New: GCC: internal compiler error: tree check: expected class 'type', have 'exceptional' (error_mark) in c_parser_omp_clause_reduction, at c/c-parser.cc:16234 141242068 at smail dot nju.edu.cn
2023-10-18 19:02 ` [Bug c/111862] " pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).