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

Module Dependency Problem Cleared by Restart

smedvedoff
Beginner
435 Views

I encountered a module depency problem when compiling today. The compiler tried to compile a file that uses a module before the .mod was built. This is the thirdtimeI've seen this since upgrading from CVF to IVF. Funny thing was, if I copied the build folder to a different machine, it built fine. After stopping and restarting Visual Studio, the build succeeded on my machine. This same type of dependency problem has occurred on two other machines. I've tried to find documentation on how the compiler determines build order, hoping that might shed some light, but haven't found any. I had cleared out all .obj and .mod files, and was doing a rebuild of the project (tried rebuild of solution, too, with same results). I don't understand what caused the compiler to spontaneously start the build with a different source file and in a different order, or why restarting Visual Studio cleared it up. Has anyone seen anything like this?

I'm using IVF 10.0.026.

Thanks,

Steve

0 Kudos
1 Reply
Steven_L_Intel1
Employee
435 Views
My guess is that the build succeeded the second time because the module was already built. The only cases of this I have seen with IVF is where there are circular dependencies on modules - module A depends on module B which depends on module A. You can also get this if the module is in the same source file but later in the file from the USE.

There is no documentation on the build dependency analyzer. Generally, it "just works". If you have a project that consistently causes a problem, please let us know at support.

BTW, I recommend using a newer compiler version. 10.1.014 is current.
0 Kudos
Reply