ICE in gfc_enforce_clean_symbol_state, at fortran/symbol.c:4273
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gcc-9 (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
The following f90 file :
$ cat test.f90
module test
contains
function matimul(a,b)
implicit none
real(kind=4), dimension(
real(kind=4), dimension(
matimul=
end function
end module test
compiled with flags '-O2 -fexternal-blas' give the following ICE :
$ gfortran -c test.f90 -O2 -fexternal-blas -o test.o
f951: internal compiler error: in gfc_enforce_
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:/
It is the combination of a matmul used in a module and compiled with both flags '-O2' and '-fexternal-blas' which trigger this error. This error did not occur with previous gcc versions.
$ lsb_release -rd
Description: Ubuntu 19.10
Release: 19.10
$ gfortran -v
Using built-in specs.
COLLECT_
COLLECT_
OFFLOAD_
OFFLOAD_
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-
Thread model: posix
gcc version 9.2.1 20191008 (Ubuntu 9.2.1-9ubuntu2)
This bug is the same as the following on gcc bugzilla
https:/ /gcc.gnu. org/bugzilla/ show_bug. cgi?id= 92321
and comment #3 gives a workaround : /gcc.gnu. org/bugzilla/ show_bug. cgi?id= 92321#c3
https:/
using -fno-frontend- optimize on the compilation line will remove the error at the price of some inlining optimizations.