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

internal compiler error ifort vs ifx

ansayre
Beginner
598 Views

I am switching from ifort to ifx 2024.2.1.

 

I get a "xfortcom: Fatal: There has been an internal compiler error (C0000005)." when I compile the following with ifx, but not with ifort.

 


subroutine get_howoft()
implicit none

interface
function **bleep**(msg_)
structure /message/
integer(kind=4) :: level
end structure
! integer(kind=4), value, intent(in) :: asme_msg_
record /message/ :: msg_
real(kind=8) :: **bleep**
end function **bleep**
end interface

end

 

When I modify the source to remove the record/structure it compiles with ifx:


subroutine get_howoft()
implicit none

interface
function **bleep**(msg_)
! structure /message/
! integer(kind=4) :: level
! end structure
integer(kind=4), value, intent(in) :: msg_
! record /message/ :: msg_
real(kind=8) :: **bleep**
end function **bleep**
end interface

end

Unfortunately the subroutine compiles with ifx if the subroutine with the record/structure (needed for C interoperability) is moved to its own source file.

 

Are there any reported problems similar to this?

 

Thanks,

 

Alan

0 Kudos
1 Solution
andrew_4619
Honored Contributor III
561 Views

 

subroutine get_howoft()
implicit none

interface
        function bleep(msg_)
            structure /message/
            integer(kind=4) :: level
        end structure
        record /message/ :: msg_
        real(kind=8) :: bleep
    end function bleep
end interface

end

 

Well that compile just fine in ifx 2025.0.0 I am not sure what your ** was about that won't compile but I assume your code does not have that.

 

But maybe standard Fortran rather than very old intel extensions would be better.

subroutine get_howoft()
implicit none

interface
    function bleep(msg_)
        type, bind(c) :: message
            integer(kind=4) :: level
        end type
        type(message) :: msg_
        real(kind=8) :: bleep
    end function bleep
end interface

end

 

View solution in original post

3 Replies
andrew_4619
Honored Contributor III
562 Views

 

subroutine get_howoft()
implicit none

interface
        function bleep(msg_)
            structure /message/
            integer(kind=4) :: level
        end structure
        record /message/ :: msg_
        real(kind=8) :: bleep
    end function bleep
end interface

end

 

Well that compile just fine in ifx 2025.0.0 I am not sure what your ** was about that won't compile but I assume your code does not have that.

 

But maybe standard Fortran rather than very old intel extensions would be better.

subroutine get_howoft()
implicit none

interface
    function bleep(msg_)
        type, bind(c) :: message
            integer(kind=4) :: level
        end type
        type(message) :: msg_
        real(kind=8) :: bleep
    end function bleep
end interface

end

 

ansayre
Beginner
540 Views

Andrew,

Thank you for having a look! The "**bleep**" was an automatic renaming of "**bleep**" where I renamed to obfuscate my source.

I am getting more ifx compiler errors that are unrelated to usage of records/structures. Looks like we are nearing the end of over 70 years Fortran usage.

Thanks,

Alan

0 Kudos
andrew_4619
Honored Contributor III
524 Views
The compiler you are testing is already way out of date. Ifx is on a steep curve. You should use the latest.
Reply