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

Derived-type co-array error if nested allocatable components

FlyingHermes
New Contributor I
424 Views

Hi,

I'm using the following version of ifort:

[bash]$ ifort -V
Intel(R) Fortran Intel(R) 64 Compiler XE for applications running on Intel(R) 64, Version 13.1.1.163 Build 20130313
Copyright (C) 1985-2013 Intel Corporation.  All rights reserved.
FOR NON-COMMERCIAL USE ONLY[/bash]

I've found a error when using a derived-type co-array which has a two-level nested allocatable component.

Runing the code with the "-coarray-num-images=1" option gives:

[bash]$ make clean; make; ./a.out
ifort -coarray -coarray-num-images=1 -c mesh_class.f90 -o mesh_class.o
ifort -coarray -coarray-num-images=1 -c main.f90 -o main.o
ifort -coarray -coarray-num-images=1 main.o mesh_class.o -o a.out

[Main]:1/1:             Starting

[Main]:1/1:             Calling Construct_Mesh
  [Construct_Mesh]:1/1: Entering
  [Construct_Mesh]:1/1: This%NBlock = 1
  [Construct_Mesh]:1/1: iBlock = 1   This%Block(iBlock)%Nx = 2   This%Block(iBlock)%Ny = 3   This%Block(iBlock)%NVertex = 6
  [Construct_Mesh]:1/1: iBlock = 1   i = 1   j = 1   This%Block(iBlock)%Xv(i,j) = 1
  [Construct_Mesh]:1/1: iBlock = 1   i = 2   j = 1   This%Block(iBlock)%Xv(i,j) = 2
  [Construct_Mesh]:1/1: iBlock = 1   i = 1   j = 2   This%Block(iBlock)%Xv(i,j) = 3
  [Construct_Mesh]:1/1: iBlock = 1   i = 2   j = 2   This%Block(iBlock)%Xv(i,j) = 4
  [Construct_Mesh]:1/1: iBlock = 1   i = 1   j = 3   This%Block(iBlock)%Xv(i,j) = 5
  [Construct_Mesh]:1/1: iBlock = 1   i = 2   j = 3   This%Block(iBlock)%Xv(i,j) = 6

  [Construct_Mesh]:1/1: Printing local data
  [Construct_Mesh]:1/1: i =   1   size(This%Block)            =   1
  [Construct_Mesh]:1/1: i =   1   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:1/1: i =   1   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:1/1: i =   1   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   3
  [Construct_Mesh]:1/1: i =   1   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:1/1: i =   1   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   3
  [Construct_Mesh]:1/1: i =   1   This%Block(1)%Xv            =     1       2       3       4       5       6
  [Construct_Mesh]:1/1: i =   1   This%Block(1)%Xv(1,1)       =     1

  [Construct_Mesh]:1/1: Printing image data
  [Construct_Mesh]:1/1: i =   1   size(This%Block)            =   1
  [Construct_Mesh]:1/1: i =   1   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:1/1: i =   1   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:1/1: i =   1   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   2
  [Construct_Mesh]:1/1: i =   1   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:1/1: i =   1   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   2
  [Construct_Mesh]:1/1: i =   1   This%Block(1)%Xv            =     1       2       3       4       5       6
  [Construct_Mesh]:1/1: i =   1   This%Block(1)%Xv(1,1)          =     1
  [Construct_Mesh]:1/1: Exiting

[Main]:1/1:             Ending[/bash]

As you can seen, the local data is ok, but when printing the data of image 1 (using the co-index notation "This" with i=1) the data is erroneous: the upper bound of the 2nd dimension is wrong. This can be see by comparing lines 20 and 29 (or 22 and 31).

Although the upper bound is incorrect, the array it-self is correct as showed by lines 23 and 32.

However, when launching the code with more than one image a segmentation fault is encountered when a given image is trying to access the array on an other image.

The output using "-coarray-num-images=2" option is the following:

[bash]make clean; make; ./a.out
ifort -coarray -coarray-num-images=2 -c mesh_class.f90 -o mesh_class.o
ifort -coarray -coarray-num-images=2 -c main.f90 -o main.o
ifort -coarray -coarray-num-images=2 main.o mesh_class.o -o a.out

[Main]:1/2:             Starting

[Main]:1/2:             Calling Construct_Mesh
  [Construct_Mesh]:1/2: Entering
  [Construct_Mesh]:1/2: This%NBlock = 1
  [Construct_Mesh]:1/2: iBlock = 1   This%Block(iBlock)%Nx = 2   This%Block(iBlock)%Ny = 3   This%Block(iBlock)%NVertex = 6
  [Construct_Mesh]:1/2: iBlock = 1   i = 1   j = 1   This%Block(iBlock)%Xv(i,j) = 1
  [Construct_Mesh]:1/2: iBlock = 1   i = 2   j = 1   This%Block(iBlock)%Xv(i,j) = 2
  [Construct_Mesh]:1/2: iBlock = 1   i = 1   j = 2   This%Block(iBlock)%Xv(i,j) = 3
  [Construct_Mesh]:1/2: iBlock = 1   i = 2   j = 2   This%Block(iBlock)%Xv(i,j) = 4
  [Construct_Mesh]:1/2: iBlock = 1   i = 1   j = 3   This%Block(iBlock)%Xv(i,j) = 5
  [Construct_Mesh]:1/2: iBlock = 1   i = 2   j = 3   This%Block(iBlock)%Xv(i,j) = 6

  [Construct_Mesh]:1/2: Printing local data
  [Construct_Mesh]:1/2: i =   1   size(This%Block)            =   1
  [Construct_Mesh]:1/2: i =   1   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:1/2: i =   1   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:1/2: i =   1   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   3
  [Construct_Mesh]:1/2: i =   1   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:1/2: i =   1   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   3
  [Construct_Mesh]:1/2: i =   1   This%Block(1)%Xv            =     1       2       3       4       5       6
  [Construct_Mesh]:1/2: i =   1   This%Block(1)%Xv(1,1)       =     1

  [Construct_Mesh]:1/2: Printing image data
  [Construct_Mesh]:1/2: i =   1   size(This%Block)            =   1
  [Construct_Mesh]:1/2: i =   1   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:1/2: i =   1   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:1/2: i =   1   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   2
  [Construct_Mesh]:1/2: i =   1   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:1/2: i =   1   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   2
  [Construct_Mesh]:1/2: i =   1   This%Block(1)%Xv            =     1       2       3       4       5       6
  [Construct_Mesh]:1/2: i =   1   This%Block(1)%Xv(1,1)          =     1

[Main]:2/2:             Starting

[Main]:2/2:             Calling Construct_Mesh
  [Construct_Mesh]:2/2: Entering
  [Construct_Mesh]:2/2: This%NBlock = 1
  [Construct_Mesh]:2/2: iBlock = 1   This%Block(iBlock)%Nx = 2   This%Block(iBlock)%Ny = 3   This%Block(iBlock)%NVertex = 6
  [Construct_Mesh]:2/2: iBlock = 1   i = 1   j = 1   This%Block(iBlock)%Xv(i,j) = 1
  [Construct_Mesh]:2/2: iBlock = 1   i = 2   j = 1   This%Block(iBlock)%Xv(i,j) = 2
  [Construct_Mesh]:2/2: iBlock = 1   i = 1   j = 2   This%Block(iBlock)%Xv(i,j) = 3
  [Construct_Mesh]:2/2: iBlock = 1   i = 2   j = 2   This%Block(iBlock)%Xv(i,j) = 4
  [Construct_Mesh]:2/2: iBlock = 1   i = 1   j = 3   This%Block(iBlock)%Xv(i,j) = 5
  [Construct_Mesh]:2/2: iBlock = 1   i = 2   j = 3   This%Block(iBlock)%Xv(i,j) = 6

  [Construct_Mesh]:2/2: Printing local data
  [Construct_Mesh]:2/2: i =   2   size(This%Block)            =   1
  [Construct_Mesh]:2/2: i =   2   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:2/2: i =   2   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:2/2: i =   2   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   3
  [Construct_Mesh]:2/2: i =   2   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:2/2: i =   2   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   3
  [Construct_Mesh]:2/2: i =   2   This%Block(1)%Xv            =     1       2       3       4       5       6
  [Construct_Mesh]:2/2: i =   2   This%Block(1)%Xv(1,1)       =     1

  [Construct_Mesh]:2/2: Printing image data
  [Construct_Mesh]:2/2: i =   1   size(This%Block)            =   1
  [Construct_Mesh]:2/2: i =   1   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:2/2: i =   1   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:2/2: i =   1   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   2
  [Construct_Mesh]:2/2: i =   1   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:2/2: i =   1   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   2
forrtl: severe (174): SIGSEGV, segmentation fault occurred
In coarray image 2
Image              PC                Routine            Line        Source             
a.out              000000000042D275  Unknown               Unknown  Unknown
a.out              0000000000410903  Unknown               Unknown  Unknown
a.out              0000000000405B49  Unknown               Unknown  Unknown
a.out              000000000040390E  Unknown               Unknown  Unknown
a.out              000000000040377C  Unknown               Unknown  Unknown
libc.so.6          000000310F621735  Unknown               Unknown  Unknown
a.out              0000000000403659  Unknown               Unknown  Unknown
  [Construct_Mesh]:1/2: i =   2   size(This%Block)            =   1
  [Construct_Mesh]:1/2: i =   2   allocated(This%Block(1)%Xv) =   T
  [Construct_Mesh]:1/2: i =   2   This%Block(1)%Nx            =   2   This%Block(1)%Ny           =   3
  [Construct_Mesh]:1/2: i =   2   size(This%Block(1)%Xv,1)    =   2   size(This%Block(1)%Xv,2)   =   2
  [Construct_Mesh]:1/2: i =   2   lbound(This%Block(1)%Xv,1)  =   1   lbound(This%Block(1)%Xv,2) =   1
  [Construct_Mesh]:1/2: i =   2   ubound(This%Block(1)%Xv,1)  =   2   ubound(This%Block(1)%Xv,2) =   2
forrtl: severe (174): SIGSEGV, segmentation fault occurred
In coarray image 1
Image              PC                Routine            Line        Source             
a.out              000000000042D275  Unknown               Unknown  Unknown
a.out              0000000000410903  Unknown               Unknown  Unknown
a.out              0000000000405B49  Unknown               Unknown  Unknown
a.out              000000000040390E  Unknown               Unknown  Unknown
a.out              000000000040377C  Unknown               Unknown  Unknown
libc.so.6          000000310F621735  Unknown               Unknown  Unknown
a.out              0000000000403659  Unknown               Unknown  Unknown[/bash]

The code is attached.

0 Kudos
12 Replies
Anonymous66
Valued Contributor I
424 Views

Thank you for reporting this issue. I have escalated it to the developers. The issue number is DPD200244116. I will post any updates on this issue here.

0 Kudos
FlyingHermes
New Contributor I
424 Views

I've simplified the sample code.

The error does not come from the derived-type nesting.

[fortran]Program Main

  implicit none

  Type          ::      Mesh_Type
    integer ,allocatable ,dimension(:,:) :: Xv
  End Type
 
  type(Mesh_Type)       ,codimension

  • ::      Mesh
      integer       ,parameter              ::      Nx=2
      integer       ,parameter              ::      Ny=10
      integer                               ::      i, j, ij
      character(:)  ,allocatable            ::      Info
     
      allocate( character(len('[X/X]: ')) :: Info )         
      write(Info,"('[',i1,'/',i1,']: ')") This_Image(),Num_Images()
     
      if ( allocated(Mesh%Xv) ) deallocate(Mesh%Xv)
      allocate( Mesh%Xv(Nx,Ny) )
      forall( i=1:Nx, j=1:Ny ) Mesh%Xv(i,j) = (j-1) * Nx + i

      sync all
      i = 0
      write(*,"(/,a,'Printing local data')") Info
      write(*,"(a,'i = ',i3,3x,'Nx                    = ',i3,3X,'Ny                   = ',i3)") Info, This_Image(), Nx,                Ny
      write(*,"(a,'i = ',i3,3x,'size(Mesh%Xv,1)       = ',i3,3X,'size(Mesh%Xv,2)      = ',i3)") Info, This_Image(), size(Mesh%Xv,1),   size(Mesh%Xv,2)
      write(*,"(a,'i = ',i3,3x,'lbound(Mesh%Xv,1)     = ',i3,3X,'lbound(Mesh%Xv,2)    = ',i3)") Info, This_Image(), lbound(Mesh%Xv,1), lbound(Mesh%Xv,2)
      write(*,"(a,'i = ',i3,3x,'ubound(Mesh%Xv,1)     = ',i3,3X,'ubound(Mesh%Xv,2)    = ',i3)") Info, This_Image(), ubound(Mesh%Xv,1), ubound(Mesh%Xv,2)
      write(*,"(a,'i = ',i3,3x,'Mesh%Xv               = ',*(i3,3x))") Info, This_Image(), Mesh%Xv(:,:)

      sync all
      write(*,"(/,a,'Printing image data')") Info
      do i = 1,Num_Images()
        write(*,"(a,'i = ',i3,3x,'Nx                    = ',i3,3X,'Ny                   = ',i3)") Info, i, Nx,                   Ny
        write(*,"(a,'i = ',i3,3x,'size(Mesh%Xv,1)    = ',i3,3X,'size(Mesh%Xv,2)   = ',i3)") Info, i, size(Mesh%Xv,1),   size(Mesh%Xv,2)
        write(*,"(a,'i = ',i3,3x,'lbound(Mesh%Xv,1)  = ',i3,3X,'lbound(Mesh%Xv,2) = ',i3)") Info, i, lbound(Mesh%Xv,1), lbound(Mesh%Xv,2)
        write(*,"(a,'i = ',i3,3x,'ubound(Mesh%Xv,1)  = ',i3,3X,'ubound(Mesh%Xv,2) = ',i3)") Info, i, ubound(Mesh%Xv,1), ubound(Mesh%Xv,2)
        write(*,"(a,'i = ',i3,3x,'Mesh%Xv            = ',*(i3,3x))") Info, i, Mesh%Xv(:,:)
      end do
     
    End Program[/fortran]
  • The output with a single image is:

    [bash]ifort -coarray -coarray-num-images=1 main.f90; ./a.out

    [1/1]: Printing local data
    [1/1]: i =   1   Nx                    =   2   Ny                   =  10
    [1/1]: i =   1   size(Mesh%Xv,1)       =   2   size(Mesh%Xv,2)      =  10
    [1/1]: i =   1   lbound(Mesh%Xv,1)     =   1   lbound(Mesh%Xv,2)    =   1
    [1/1]: i =   1   ubound(Mesh%Xv,1)     =   2   ubound(Mesh%Xv,2)    =  10
    [1/1]: i =   1   Mesh%Xv               =   1     2     3     4     5     6     7     8     9    10    11    12    13    14    15    16    17    18    19    20

    [1/1]: Printing image data
    [1/1]: i =   1   Nx                    =   2   Ny                   =  10
    [1/1]: i =   1   size(Mesh%Xv,1)    =   2   size(Mesh%Xv,2)   =   2
    [1/1]: i =   1   lbound(Mesh%Xv,1)  =   1   lbound(Mesh%Xv,2) =   1
    [1/1]: i =   1   ubound(Mesh%Xv,1)  =   2   ubound(Mesh%Xv,2) =   2
    [1/1]: i =   1   Mesh%Xv            =   1     2     3     4     5     6     7     8     9    10    11    12    13    14    15    16    17    18    19    20[/bash]

    0 Kudos
    Anonymous66
    Valued Contributor I
    424 Views

    A fix has been found for this issue. We are currently planning to include it in the next major release which is scheduled for later this year.

    Annalee

    0 Kudos
    FlyingHermes
    New Contributor I
    424 Views

    Hi,

    Here is a similar example which still generate a segmentation fault using the new ifort version 14.0.0 (64). The difference with the previous example is that there is an extra nested-derived-type.

    [fortran]

    Program Main

      implicit none

      logical ,parameter :: i_Debug_Loc=.true.
      integer ,parameter :: NBlock=1
      integer ,parameter :: Nx=2
      integer ,parameter :: Ny=3
     
      Type                                   ::      Block_Type
        integer                              ::      Nx
        integer                              ::      Ny
        integer ,allocatable ,dimension(:,:) ::      Xv
      End Type

      Type                                                          ::      Mesh_Type
        integer                                                     ::      NBlock
        type(Block_Type) ,allocatable ,dimension(:), codimension[:] ::      Block
      End Type

      type(Mesh_Type) ::      Mesh
      integer         ::      iBlock
      integer         ::      i, j, ij
     
      Mesh%NBlock   =       NBlock
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': Mesh%NBlock = ',i0)") This_Image(),Num_Images(), Mesh%NBlock

      allocate( Mesh%Block(Mesh%NBlock)

  • )

      do iBlock = 1,Mesh%NBlock
        Mesh%Block(iBlock)%Nx       =       Nx
        Mesh%Block(iBlock)%Ny       =       Ny
        write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': iBlock = ',i0,3x,'Mesh%Block(iBlock)%Nx = ',i0,3x,'Mesh%Block(iBlock)%Ny = ',i0)") This_Image(),Num_Images(), iBlock, Mesh%Block(iBlock)%Nx, Mesh%Block(iBlock)%Ny
        allocate( Mesh%Block(iBlock)%Xv(Nx,Ny) )
        do j = 1,Ny
        do i = 1,Nx
          ij        =       (j-1) * Mesh%Block(iBlock)%Nx + i
          Mesh%Block(iBlock)%Xv(i,j)        =       ij
          write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': iBlock = ',i0,3x,'i = ',i0,3x,'j = ',i0,3x,'Mesh%Block(iBlock)%Xv(i,j) = ',g0)") This_Image(),Num_Images(), iBlock, i, j, Mesh%Block(iBlock)%Xv(i,j)
        end do
        end do
      end do           
     
      sync all
      i = 0
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': Printing local data')") This_Image(),Num_Images()
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'size(Mesh%Block)               = ',i3)") This_Image(),Num_Images(), i, size( Mesh%Block )
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'allocated(Mesh%Block(1)%Xv)    = ',l3)") This_Image(),Num_Images(), i, allocated( Mesh%Block(1)%Xv )
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'Mesh%Block(1)%Nx               = ',i3,3X,'Mesh%Block(1)%Ny           = ',i3)") This_Image(),Num_Images(), i, Mesh%Block(1)%Nx, Mesh%Block(1)%Ny
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'size(Mesh%Block(1)%Xv,1)       = ',i3,3X,'size(Mesh%Block(1)%Xv,2)   = ',i3)") This_Image(),Num_Images(), i, size(Mesh%Block(1)%Xv,1), size(Mesh%Block(1)%Xv,2)
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'lbound(Mesh%Block(1)%Xv,1)     = ',i3,3X,'lbound(Mesh%Block(1)%Xv,2) = ',i3)") This_Image(),Num_Images(), i, lbound(Mesh%Block(1)%Xv,1), lbound(Mesh%Block(1)%Xv,2)
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'ubound(Mesh%Block(1)%Xv,1)     = ',i3,3X,'ubound(Mesh%Block(1)%Xv,2) = ',i3)") This_Image(),Num_Images(), i, ubound(Mesh%Block(1)%Xv,1), ubound(Mesh%Block(1)%Xv,2)
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'Mesh%Block(1)%Xv               = ',*(g0,3x))") This_Image(),Num_Images(), i, Mesh%Block(1)%Xv(:,:)
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'Mesh%Block(1)%Xv(1,1)          = ',*(g0,3x))") This_Image(),Num_Images(), i, Mesh%Block(1)%Xv(1,1)
     
      sync all
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': Printing remote data')") This_Image(),Num_Images()
      do i = 1,Num_Images()
        write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'size(Mesh%Block)            = ',i3)") This_Image(),Num_Images(), i, size( Mesh%Block )
        write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'Mesh%Block(1)%Nx            = ',i3,3X,'Mesh%Block(1)%Ny           = ',i3)") This_Image(),Num_Images(), i, Mesh%Block(1)%Nx, Mesh%Block(1)%Ny
    ! ! **************************** THESE LINES CREATE A SEGMENTATION FAULT OCCURRED ****************************
    !     write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'size(Mesh%Block(1)%Xv,1)    = ',i3,3X,'size(Mesh%Block(1)%Xv,2)   = ',i3)") This_Image(),Num_Images(), i, size(Mesh%Block(1)%Xv,1), size(Mesh%Block(1)%Xv,2)
    !     write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'lbound(Mesh%Block(1)%Xv,1)  = ',i3,3X,'lbound(Mesh%Block(1)%Xv,2) = ',i3)") This_Image(),Num_Images(), i, lbound(Mesh%Block(1)%Xv,1), lbound(Mesh%Block(1)%Xv,2)
    !     write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'ubound(Mesh%Block(1)%Xv,1)  = ',i3,3X,'ubound(Mesh%Block(1)%Xv,2) = ',i3)") This_Image(),Num_Images(), i, ubound(Mesh%Block(1)%Xv,1), ubound(Mesh%Block(1)%Xv,2)
    !     write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'Mesh%Block(1)%Xv            = ',*(i5,3x))") This_Image(),Num_Images(), i, Mesh%Block(1)%Xv(:,:)
    !     write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': i = ',i3,3x,'Mesh%Block(1)%Xv(1,1)          = ',*(i5,3x))") This_Image(),Num_Images(), i, Mesh%Block(1)%Xv(1,1)
    ! ! **************************** THESE LINES CREATE A SEGMENTATION FAULT OCCURRED ****************************
      end do
     
      write(*,"(2x,'[Construct_Mesh]:',i1,'/',i1,': Ending')") This_Image(),Num_Images()
     
    End Program
  • [/fortran]

    0 Kudos
    Steven_L_Intel1
    Employee
    424 Views

    Thanks for the new example - I can reproduce the error.  Escalated as issue DPD200247881.

    0 Kudos
    FlyingHermes
    New Contributor I
    424 Views

    Any updates on this bug ?

    0 Kudos
    Steven_L_Intel1
    Employee
    424 Views

    Sorry, no. I will ping the developer.

    0 Kudos
    FlyingHermes
    New Contributor I
    424 Views

    Hi,

    Any update here?

    And, I was wondering where could I found info on the optimization status of the intel fortran compiler regarding coarrays.

    I've read on this forum that, for the time being, coarray implementation in ifort is not optimized at all.

    Is there any schedule for such optimization?

    Thanks

    0 Kudos
    Steven_L_Intel1
    Employee
    424 Views

    Issue DPD200247881 is still not fixed.

    I would not agree that coarrays are "not optimized at all". We have done some optimization work and have more in progress. It will be an ongoing thing. We recently obtained some useful benchmark programs (though they contain bugs, which the authors acknowledged), and are using these to guide our efforts.

    0 Kudos
    Steven_L_Intel1
    Employee
    424 Views

    I was just told that the bug for issue DPD200247881 has now been fixed. I expect the fix to appear in an update to the 15.0 compiler later this year (not the initial release.)

    0 Kudos
    FlyingHermes
    New Contributor I
    424 Views

    Is this issue fixed with  ifort version 15.1 ?

    Thanks.

    0 Kudos
    Kevin_D_Intel
    Employee
    424 Views

    Yes, it should be. The defect is named in our IPS XE 2015 Update 1 fixes list.
     

    0 Kudos
    Reply