https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94287
Bug ID: 94287
Summary: [10 Regression] ICE in linemap_ordinary_map_lookup, at
libcpp/line-map.c:993
Product: gcc
Version: 10.0
Status: UNCONFIRMED
Keywords: error-recovery, ice-on-invalid-code
Severity: normal
Priority: P3
Component: preprocessor
Assignee: unassigned at gcc dot gnu.org
Reporter: asolokha at gmx dot com
Target Milestone: ---
gcc-10.0.1-alpha20200322 snapshot (g:83aa5aa313af9463c6962c72f7c238f914677824)
ICEs most of the time when compiling the following testcase w/ -std=c11 on a
glibc-based target:
int df;
typeof (df) ea;
% MALLOC_PERTURB_=1 MALLOC_CHECK_=3 gcc-10.0.1 -std=c11 -w -c jvjp59nm.c
jvjp59nm.c: In function 'typeof':
jvjp59nm.c:2:13: error: expected declaration specifiers before 'ea'
2 | typeof (df) ea;
| ^~
jvjp59nm.c:2: error: expected '{' at end of input
2 | typeof (df) ea;
|
during GIMPLE pass: lower
jvjp59nm.c:2:1: internal compiler error: in linemap_ordinary_map_lookup, at
libcpp/line-map.c:993
2 | typeof (df) ea;
| ^~~~~~
0x1838d8d linemap_ordinary_map_lookup
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/libcpp/line-map.c:993
0x1839356 get_pure_location(line_maps*, unsigned int)
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/libcpp/line-map.c:331
0x1042367 get_pure_location
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/gcc/input.h:148
0x1042367 set_block(unsigned int, tree_node*)
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/gcc/tree.c:14835
0x168a705 gimple_set_block
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/gcc/gimple.h:1865
0x168a705 lower_function_body
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/gcc/gimple-low.c:136
0x168a705 execute
/var/tmp/portage/sys-devel/gcc-10.0.1_alpha20200322/work/gcc-10-20200322/gcc/gimple-low.c:195