ICE "verify_gimple failed" with OpenMP

Tim Prince n8tm@aol.com
Tue Jun 23 01:33:00 GMT 2015



On 6/22/2015 9:24 PM, Andrew Benson wrote:
> I just opened a PR for this bug:
>
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66633
>
> -Andrew
>
> --
>
> The following causes an ICE in gfortran 6.0.0 (r224761):
>
> module spls
>   type :: spc
>    contains
>      procedure :: l => spcL
>   end type spc
>  
> contains
>   function spl()
>     class(spc), pointer :: spc_
>     !$omp parallel
>     write (0,*) igrt(fli)
>     !$omp end parallel
>   contains
>     double precision function fli()
>       fli=spc_%l()
>     end function fli
>   end function spl
>   double precision function spcL(s)
>     implicit none
>     class(spc), intent(inout) :: s
>     return
>   end function spcL
> end module spls
>
>
> $ gfortran -v
> Using built-in specs.
> COLLECT_GCC=/opt/gcc-trunk/bin/gfortran
> COLLECT_LTO_WRAPPER=/opt/gcc-trunk/libexec/gcc/x86_64-unknown-linux-
> gnu/6.0.0/lto-wrapper
> Target: x86_64-unknown-linux-gnu
> Configured with: ../gcc-trunk/configure --prefix=/opt/gcc-trunk --enable-
> languages=c,c++,fortran --disable-multilib
> Thread model: posix
> gcc version 6.0.0 20150622 (experimental) (GCC) 
>
>
>  gfortran -c tmp.F90 -o tmp.o -fopenmp
> tmp.F90:11:0:
>
>      write (0,*) igrt(fli)
> ^
> Error: invalid argument to gimple call
>
and if you don't set -fopenmp there is still the undefined reference
symbol.  True, ICE is likely a symptom of a bug.

-- 
Tim Prince



More information about the Fortran mailing list