ICE "verify_gimple failed" with OpenMP

Andrew Benson abenson@obs.carnegiescience.edu
Tue Jun 23 03:19:00 GMT 2015


On Monday, June 22, 2015 09:33:39 PM Tim Prince wrote:
> 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.

The undefined function igrt() is present in the original code which triggered 
this ICE. I agree though, the ICE is most likely a symptom of a bug in my code 
- I just haven't been able to figure out what it is yet.....

-Andrew

-- 

* Andrew Benson: http://users.obs.carnegiescience.edu/abenson/contact.html

* Galacticus: http://sites.google.com/site/galacticusmodel



More information about the Fortran mailing list