buggy coarray element assignment for derived type with allocatable component

buggy coarray element assignment for derived type with allocatable component

I have seen a couple of similar bug reports on the forum, but not sure this is identical, so here goes.

With ifort using -assume realloc_lhs, the following code gives a segfault at line 12, which looks to me like a compiler bug.

module my_class_module
    type my_type
        real, allocatable :: arr(:,:)
        procedure :: my_assignment
        generic :: assignment(=) => my_assignment
    end type
    subroutine my_assignment(lhs,rhs)
        class(my_type),  intent(inout) :: lhs
        type(my_type),  intent(in)    :: rhs
        lhs%arr = rhs%arr
    end subroutine
end module

program hello
    use my_class_module
    type(my_type)           ::  c[*]


    c%arr = 0.0

    if (this_image() .gt. 1) c%arr = c[1]%arr ! this is ok
    if (this_image() .gt. 1) c     = c[1]     ! this line triggers a segfault
end program


8 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Is this the same issue as DPD200247881 reported in this thread?

May we expect a fix in the next minor release?

I would appreciate a comment from someone at Intel. I suspect this is a bug in the Intel compiler's coarray implementation, in which case I'd appreciate an issue number I can track.

Please accept our apologies for overlooking your earlier post. It could be related to DPD200247881. The fix for the earlier issue noted in that other post is in the upcoming major release later this year but it does not address your issue or the later issue Steve captured in the internal tracking number you noted.

I submitted your case to Development under a separate tracking id (noted below) so it can be analyzed separately and will let you know what information I receive from Development regarding your case.

(Internal tracking id: DPD200255059)

Has a fix for DPD200255059 been found? If so, which release is it targeted for?

I note that DPD200255059 is not listed in the XE2015 Update 1 list of fixes. Any other updates on this issue?

My apologies. I wasn't aware of your inquiry back in August.

That defect has not yet been fixed. Shortly after submitting the Developers indicated it may take some digging to get to the bottom of this one. I did inquire whether there's any current status and will share that with you if there is anything new.

The Developer said it is on the radar, that they have investigated further and expect fixing it requires significant work and thus time. I will keep you updated.

Leave a Comment

Please sign in to add a comment. Not a member? Join today