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

Compiler crash -- segmentation violation raised

ereisch
New Contributor II
694 Views
Compilation on the following code fails:

[bash]      Module ModA
        Public
      Contains
        Subroutine ModA_Sub()
        Integer(4) :: dummy

!DEC$   ATTRIBUTES ALIGN: 4096 :: CBLK
        Common/CBLK/ dummy
      End Module ModA

      Program CrashProgram
      Use ModA
      Call ModA_Sub()
      end Program CrashProgram[/bash]

Compile with "ifort -extend-source 132 -assume nounderscore -assume nobscc -align dcommons -static-libgcc -zero -fp-port -save -c -fpe0 -ftz -prec-div -fp-stack-check -ccdefault fortran -traceback -fp-model precise -xSSE2 -axSSE2 -g -debug full -debug-parameters -check bounds -O0 -m32 Crash.for"

"Crash.for: catastrophic error: **Internal compiler error: segmentation violation signal raised** Please report this error along with the circumstances in whcih it occurred in a Software Problem Report. Note: File and line given may not be explicit cause of this error."

Removing the page-align directive eliminates the crash.

Intel Fortran Compiler XE for applications running on IA-32, Version 12.0.1.107 Build 20101116
0 Kudos
6 Replies
ereisch
New Contributor II
694 Views
For some reason, the syntax highlighter removed the first part of Line 7. It should read:

!DEC$ ATTRIBUTES ALIGN: 4096 :: CBLK
0 Kudos
Steven_L_Intel1
Employee
694 Views
The END SUBROUTINE is also missing, but if I add that I can reproduce the problem. Thanks - I will escalate this to development. Issue ID is DPD200169285.

I found that the use of the subroutine was not required - even putting the common at the top level of the module triggered the error. Might you be able to use an ALLOCATABLE array in the module and an ATTRIBUTES ALIGN on that? You would need to allocate it at the start of the program but otherwise it should not require code changes.
0 Kudos
mecej4
Honored Contributor III
694 Views
The syntax highlighter did not remove the first part; if you choose "view plain" you will see that the line is intact.

I agree that it is annoying that the line gets mangled when seen in the browser. Similarly, leading blanks in the first line of code added using the syntax highlighter are not shown. I wish Intel would show us at least a work-around to avoid such problems (what-you-see-is-not-what-you-have and vice versa).
0 Kudos
Steven_L_Intel1
Employee
694 Views
I know the syntax highlighter has issues. We're using an open source module for this with Fortran-specific definitions I provided. I don't understand why it corrupts lines sometimes. It is being worked on.
0 Kudos
Steven_L_Intel1
Employee
694 Views
The internal compiler error has been fixed for an update later this year. However, the ALIGN directive will be ignored for a COMMON in a module. A future version will enable that feature.
0 Kudos
Steven_L_Intel1
Employee
694 Views

The "future version" will be released later this year.

0 Kudos
Reply