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

ifort crash on programming error

e745200
Beginner
897 Views

[fortran]module a_mod
type a_type
   character(8) :: name
   real(8), allocatable :: values(:)
end type
end module

program test
use a_mod
  type(a_type) :: A = a_type('a',[1,2])
end
[/fortran]

I know the above program (eee.f90) is wrong, because it tries to assign an array to a component which has not been allocated yet.

What I would not expect is a crash at compile time due to that error, instead of an error message  :

[plain]ifort  eee.f90
eee.f90: 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 eee.f90 (code 1)[/plain]

I would have submitted this as an issue in the Intel Premier Support Section, but the Fortran compiler does not appear in the form's list. I hope this is useful anyway.

0 Kudos
7 Replies
TimP
Honored Contributor III
897 Views
If you have registered an ifort linux license to your support account, the corresponding category option should appear when you start up a problem report. I'm having difficulty downloading your case to see if it pertains to a current compiler version.
0 Kudos
e745200
Beginner
897 Views
Tim, thanks for your prompt response. Should you need more info about the compiler version: [plain]ifort -V eee.f90 Intel(R) Fortran Intel(R) 64 Compiler XE for applications running on Intel(R) 64, Version 13.0.1.117 Build 20121010 Copyright (C) 1985-2012 Intel Corporation. All rights reserved. FOR NON-COMMERCIAL USE ONLY Intel(R) Fortran 13.0-2074 eee.f90: 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 eee.f90 (code 1) [/plain] For you convenience, I'm uploading the eee.f90 file. I see the Fortran compiler in the list of products in the "MyProfile/Products, ManageByProduct" page, but not in the "Submit issue" page, where I only see a "Download, Licensing and Registration" which I do not see as appropriate for this issue. Is this due to the LtdSup of my personal non-commercial account ? I'll try using my company's commercial account in a next future. However, this was more a communication for Intel compiler developers than a request for support. Best regards.
0 Kudos
TimP
Honored Contributor III
897 Views
I see the same problem as you reported, although the corresponding Windows compiler has no problem (but should have reported one). I'm also seeing problems with the functionality of this web site, not allowing me to edit my post.
0 Kudos
Steven_L_Intel1
Employee
897 Views
If you have a non-commercial license, this forum is the place to report problems. Intel Premier Support is not available to non-commercial users. I'll look into this problem and let you know what I find.
0 Kudos
Steven_L_Intel1
Employee
897 Views
I have escalated this as issue DPD200239788. As you note, the program is incorrect - in a constant expression, as would appear in an initialization, a value in a structure constructor corresponding to an allocatable component is allowed to be only a reference to the NULL() intrinsic function. The compiler should properly diagnose this error - thanks for bringing it to our attention.
0 Kudos
e745200
Beginner
897 Views
Thanks to you all. Have a happy new year.
0 Kudos
Steven_L_Intel1
Employee
897 Views

This is fixed for a future release.

0 Kudos
Reply