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

segmentation fault depending on compiler flags

mpahlowifm-geomar_de
1,959 Views
I use ifort version 12.1 fromcomposer_xe_2011_sp1.6.038 on mac osx 10.6.8. I am trying to compile an ocean circulation model (UVic_ESCM), which did work with a previous version of ifort (11.1.058). With the new ifort version, however, I got a segmentation fault, which I could not debug. I think this is a compiler bug, but maybe the problem is somewhere else.
The segmentation fault occurs only with compile options -O2, -O3, of -fast but not with -O1. Using the option -check bounds prevents the segmentation fault but the executable is very slow.
I have trimmed down the subroutine where the error occurs as much as possible (files testsolv.f and solve.f). The file tstslv is a bash shellscript compiling and running the test files. Adding a line with a WRITE command in the inner loop in solve.f also prevents the error, even when inside an IF statement preventing the WRITE from being executed (see inside the file solve.f).
0 Kudos
7 Replies
TimP
Honored Contributor III
1,959 Views
This option -mp1 hasn't been well supported for several years, since the superior replacement options were instituted. I doubt it was ever tested on osx. It's not really a compiler bug when you use unsupported options which happen to remain available.
Applications which required -mp1 under ifort 9.1 and earlier might wish to use options
-assume protect_parens -prec-div -prec-sqrt
or options such as -fp-model source and -standard-semantics might be useful.

I haven't been able to reproduce your problem; I don't have osx available.
0 Kudos
Udit_P_Intel
Employee
1,959 Views
Thank you. I was able to reproduce your problem with our latest Mac compilers. I have started a new internal tracker DPD200230196, and we will keep you updated about any developments.

Best!
-Udit

NB. I could reproduce your problem without the -mp1 flag. Can you confirm that?
0 Kudos
mpahlowifm-geomar_de
1,959 Views
Thank you very much for your quick reply. Yes, the error occurs with and without the -mp1 flag.
Best,
Markus
0 Kudos
Udit_P_Intel
Employee
1,959 Views
Sounds good. We're now starting to work on it.
Best!
-Udit
0 Kudos
mpahlowifm-geomar_de
1,959 Views
Are there any new developments on this bug?
Best regards,
Markus
0 Kudos
Udit_P_Intel
Employee
1,959 Views
I believe work is still ongoing on this bug. Short of putting an exact time frame on when the defect will be fixed, I can say that its priority is high.
Best!
-Udit
0 Kudos
Steven_L_Intel1
Employee
1,959 Views
I believe that this bug will be fixed in Update 9, scheduled for February.
0 Kudos
Reply