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

migrate mixed-language project from winXP to win7

wen_s_
Beginner
195 Views

WinXP(X86) project based on VS6.0 and Compaq Fortran 6.5 called projectXPCMF;

Win7(X86) project based on VS6.0 and Compaq Fortran 6.5 called projectCMF; 

Win7(X86) project based on VS2010 and intelVisualFortran called projectIVF; 

The project is for image processing!  Mainly use c++ to parse images and preprocess, fortran.static.lib and c++.static.lib to caculate.

Recently I tried to migrate projectXPCMF to win7, and firstly I built projectIVF without error, but when I run the c++.exe file(linked with xx.static.lib),  calculation  was interrupted  in fortran.static.lib and different images may interrupted at different positions. Thus I built projectCMF base on projectXPCMF, when it runs on win7  ,there are similar problems like projectIVF, but it runs well on winXP.

Two questions:

1.I use "write()" in fortran to log, but seems may cause interruption position changing, so how to debug fortran.static.lib?

2.what do  you think about projectCMF can run XP but cannot run on Win7 where it is built?

0 Kudos
1 Reply
jimdempseyatthecove
Honored Contributor III
195 Views

When you see crash location migrate when you insert a diagnostic print (e.g. write(*,*) "here I am"), then this is indicative of writing to undefined addresses (array bounds exceeded, unallocated memory, uninitialized variables). The first thing to do is recompile all components including your static library with full diagnostics enabled including both compile time checks for interfaces and runtime checks for array bounds checking and uninitialized variable checking. This procedure will catch most of the programming errors, but not necessarily all.

A program that runs on one platform and not the other may also be indicative of writing to undefined addresses (array bounds exceeded, unallocated memory, uninitialized variables). In one case it accidentally runs.

After making the diagnostic runs, if this did not help you resolve your problems (completely), then write back.

Jim Dempsey

0 Kudos
Reply