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

Internal Compiler Error with IFX 2024.2.0: -dyncom and -g and ENTRY

P-W
Novice
545 Views

This is a reproducer for the issue, greatly simplified from the full context where the issue was observed.  Removing either "-g" or "-dyncom" results in no error, suggesting this error is caused by the combination of these options along with the subroutine Foo having alternate entry point "Foo_I".

Command: "ifx -g -dyncom "BLK_A" foo.F90 ice002.F90 -o ice002.out
Version: 2024.2.0 Build 20240602
Error:  "error #5633: **Internal compiler error: segmentation violation signal raised ** "

ice002.F90

program ice002
    implicit none
    
    interface
        subroutine Foo(x)
            integer, intent(in) :: x
        end subroutine
        
        subroutine Foo_I
        end subroutine
    end interface
    
    call Foo_I
    call Foo(5)
end program

foo.F90

subroutine Foo(x)
    implicit none
    
    integer :: blk_a_y
    common /BLK_A/ blk_a_y
    
    integer, intent(in) :: x
    
    blk_a_y = x + blk_a_y
    write(*,*) "Foo: blk_a_y:", blk_a_y
    return
    
    entry Foo_I
        blk_a_y = 100
        write(*,*) "Foo_I: blk_a_y:", blk_a_y
    return
end subroutine

 

0 Kudos
1 Reply
Devorah_H_Intel
Moderator
518 Views

This builds fine in the upcoming 2025 ifx. I have tested it internally.

 

tmp$ ifx -g -dyncom "BLK_A" foo.f90 ice002.f90 -o ice002.out
ifx: remark #10440: Note that use of a debug option without any optimization-level option will turnoff most compiler optimizations similar to use of '-O0'
 tmp$

0 Kudos
Reply