Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

ICE using ifort 19

FlyingHermes
New Contributor I
356 Views

Here is another ICE from ifort 19.0.0

File library.F90:

Module Section_Class
  implicit none
  Type :: InputSection_Type
  contains
    procedure :: Exists
  End Type
  Interface
    Module Subroutine ReadSections( Sections )
      type(InputSection_Type) ,intent(in)  :: Sections
    End Subroutine
    Module Function Exists(This) result(Res)
      class(InputSection_Type) ,intent(in)  :: This
      logical                               :: Res
    End Function
  End Interface
End Module

SubModule(Section_Class) InputSection_SubClass
  implicit none
  contains
  Module Procedure ReadSections
  End Procedure
  Module Procedure Exists
  End Procedure
End SubModule

Module Input_Class
  implicit none
  Type  ::  Input_Type
  End Type
End Module

Module Library
  use Section_Class ,only:  ReadSections
  use Input_Class   ,only:  Input_Type
  implicit none
  private
  public  ::  ReadSections
  public  ::  Input_Type
End Module

File example.F90

Module MyModule
!   use Library ,only:  Input_Type    ! Workaround
  implicit none
  Interface
    Module Subroutine Proc( Input )
      use Library ,only:  Input_Type  ! Bug
      class(Input_Type) ,intent(in) :: Input
    End Subroutine
  End Interface
End Module

SubModule(MyModule) MySubModule
  implicit none
  contains
  Module Procedure Proc
  End Procedure
End SubModule

and the script to compile:

#! /bin/bash

Compile() {
  ifort -v
  ifort -c library.F90
  ifort -c example.F90
  rm -f *.o *.mod *.smod
}

source /opt/intel/compilers_and_libraries_2018.0.128/linux/bin/compilervars.sh intel64
Compile

source /opt/intel/compilers_and_libraries_2019.0.117/linux/bin/compilervars.sh intel64
Compile

When running the script, I get the following error:

./build.sh                                                                          
ifort version 18.0.0                                                                                                                                  
ifort version 19.0.0.117                                                                                                                              
/tmp/ifortwDW6H6.i90: catastrophic error: **Internal compiler error: segmentation violation signal raised** Please report this error along with the circumstances in which it occurred in a Software Problem Report.  Note: File and line given may not be explicit cause of this error.                    
compilation aborted for example.F90 (code 1)

 

0 Kudos
1 Reply
FlyingHermes
New Contributor I
356 Views

A request support (03651378) has been issued on the Online Service Center for this ICE.

0 Kudos
Reply