Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
29286 Discussions

Program Exception (157) through static library

Mohil_P_
Beginner
448 Views

Hello,

I am using an Intel Fortran static library to run a physics based simulation engine. Running the simulation engine through a fortran project linked to the static library gives me a program exception (157). Using the debugger I found in what subroutine the simulation breaks with the exception (157). However, if I take out the subroutine where the simulation breaks with exception from the static library and simply add this subroutine to the fortran project there is no exception or issue with the simulation. I am not sure what could be going wrong here. Having researched this on the Intel forums, I have checked the subroutine. It does not have any logic issues or any problems with the arguments. 

Any advice on this bizarre issue will be much appreciated.

 

Thanks,

MP

0 Kudos
1 Reply
mecej4
Honored Contributor III
448 Views

The behavior of a program that has bugs such as array bounds being violated, uninitialized variables used, etc., is "unpredictable", and "unpredictable" may see "bizarre" to some. I find the described behavior rather normal, and indicative of bugs being present.

To find a resolution, recompile with /traceback and possible some checks enabled, and run again. You may also post the subroutine source code and provide information about the actual arguments that it gets called with.

0 Kudos
Reply