public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/111810] New: GCC-14 segfault: error: expected declaration or statement at end of input
@ 2023-10-14 16:03 141242068 at smail dot nju.edu.cn
2023-11-04 19:24 ` [Bug c/111810] rtlFE: nested inline RTL function cause ICE pinskia at gcc dot gnu.org
0 siblings, 1 reply; 2+ messages in thread
From: 141242068 at smail dot nju.edu.cn @ 2023-10-14 16:03 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111810
Bug ID: 111810
Summary: GCC-14 segfault: error: expected declaration or
statement at end of input
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: ---
When compile this program with `gcc-14 -O0`, gcc crashes:
```
void = {0};
void uninliner_1() {
{}
inline __RTL test(void) {
uninliner_1();
```
This crash can be verified at https://godbolt.org/z/rc9oW43EE
The full stack backtrace is pasted below:
<source>:1:6: error: expected identifier or '(' before '=' token
1 | void = {0};
| ^
<source>: In function 'uninliner_1':
<source>:4:14: warning: return type defaults to 'int' [-Wimplicit-int]
4 | inline __RTL test(void) {
| ^~~~
<source>: In function 'test':
<source>:5:3: error: no closing brace
5 | uninliner_1();
| ^~~~~~~~~~~
<source>: At top level:
<source>:5:3: error: expected declaration or statement at end of input
<source>:5:3: internal compiler error: Segmentation fault
0x22ff3ee internal_error(char const*, ...)
???:0
0xa2621e finish_function(unsigned int)
???:0
0xaa468d c_parse_file()
???:0
0xb17919 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
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug c/111810] rtlFE: nested inline RTL function cause ICE
2023-10-14 16:03 [Bug c/111810] New: GCC-14 segfault: error: expected declaration or statement at end of input 141242068 at smail dot nju.edu.cn
@ 2023-11-04 19:24 ` pinskia at gcc dot gnu.org
0 siblings, 0 replies; 2+ messages in thread
From: pinskia at gcc dot gnu.org @ 2023-11-04 19:24 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111810
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed| |2023-11-04
Status|UNCONFIRMED |NEW
Summary|GCC-14 segfault: error: |rtlFE: nested inline RTL
|expected declaration or |function cause ICE
|statement at end of input |
Ever confirmed|0 |1
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Just like the gimple front-end, the RTL level front-end is for internal
testing.
Reduced testcase:
```
void j() {inline void __RTL test(void) {}}
```
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-11-04 19:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-14 16:03 [Bug c/111810] New: GCC-14 segfault: error: expected declaration or statement at end of input 141242068 at smail dot nju.edu.cn
2023-11-04 19:24 ` [Bug c/111810] rtlFE: nested inline RTL function cause ICE 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).