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

IVF runtime dependencies

lloydchriswilson
Beginner
2,553 Views

My program has a small exe stub that calls the computational dll. It works fine on my development computer. When I install on a test machine, I get the error message "The application failed to initialize properly (0xc0150002)." I have similar problems loading that sameDLL from my VB.Net application using LoadLibraryA (again, works fine on dev machine).

I installed dependency walker and ran. Found that I needed a few IVF dlls, which I included: libifcoremdd, libmmdd, msvcr80D. I also installed the C++ redist available from MS.

I've attached the dep walker file, in case you have a chance to pull it up and view it.

The application is compiled in debug mode--I'd like to distribute that way, at least initially.

I'm using IVF 11.0.061.

Thanks

0 Kudos
1 Solution
Steven_L_Intel1
Employee
2,526 Views

1. The manual does have some text on redistributing applications. Dependency Walker is the tool I recommend, but you need to know that the MSVC DLLs have to come from the Microsoft redistributable installer. We are in the process of building our own redistributable installer - not there yet,

2. No, unfortunately. Errors that are detected by generated code, such as array bounds, are not "catchable". There is an open feature request on this - I'll add your name to the list.

3. Not directly. There is SIGNALQQ which will let you be notified when an exception occurs, but you can't really recover from it. The Building Applications part of the documentation has a long chapter on exception handling which is worth a read. In some cases, you may need to wrap your Fortran code with some C++. For floating point exceptions in particular, we now support the Fortran 2003 IEEE modules which allow you nice control over the IEEE floating point exception environment.

I am curious - what prompted you to switch from Absoft to Intel?

View solution in original post

0 Kudos
30 Replies
Steven_L_Intel1
Employee
1,926 Views

Remove the MSVCR80.DLL that you added - that should come from the MSVC redistributable package only as it has to be installed as part of an assembly.

0 Kudos
lloydchriswilson
Beginner
1,926 Views

OK, I removed that file from the directory, but still get the same error message when trying to load the DLL. I will try to create a simple Hello World application and get it to work on that computer.

0 Kudos
lloydchriswilson
Beginner
1,926 Views

OK, I removed that file from the directory, but still get the same error message when trying to load the DLL. I will try to create a simple Hello World application and get it to work on that computer.

I created a Hello World EXE that ran fine on test computer--no dependencies. Then I added a simple call to a routine in myFortran DLL and the "failed to initialize" error occurred; again the same test program runs fine on my development machine.

So it appears that a IVF dependency is not there still. Is there a runtime installer for IVF dependencies? Am I prohibited from distributing Debug releases? Is there any way to get more information about exactly why the app is failing when the CLL routine is called?

More information: I've tried my best to utilize the Dependency Walker program to see what else might be needed. When I removed the MSVCR80D.dll file as you suggested, DW reports it as missing and needed; this despite the fact that I installed the Microsoft Visual C++ 2008 redistributable (x86 9.0.30729.17). When I restore that file, the only warning icon in DW is for MPR.DLL which DW specifically says is not a problem. However the log says:

Error: The Side-by-Side configuration information for "c:program filesepdriv1 v1.2RIV1H.DLL" contains errors. This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem (14001).
Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module.

So I'm really stuck.

Thanks in advance.

0 Kudos
lloydchriswilson
Beginner
1,926 Views

Well, I'm kinda answering my own questions. I recompiled the Fortran DLLs in release mode and it worked fine on the test machine. The debug libraries were being referenced. I suppose they are non-distributable, but it is curious that they didn't show up using DW.

I liked IVF because when a runtime error occurred, a decent dialog (albeit too large) would appear rather than the DLL just crashing without warning. I need to investigate other means of error trapping.

Some of my previous questions still are pertinent, and I'd appreciate enlightenment.

0 Kudos
lloydchriswilson
Beginner
1,926 Views

OK, you guys have to cut me some slack! I'm coming from Absoft and things were much more difficult there! :)

All I need to do is turn on on error trapping but still compile as a release version; the big error dialog still appears, but dependencies are still not a problem.

IVF is really good!

0 Kudos
Steven_L_Intel1
Employee
1,926 Views

Slack duly cut. What do you still need help with?

You are correct - the debug DLLs are not redistributable.

0 Kudos
lloydchriswilson
Beginner
1,926 Views


Just to finish up this posting, please answer the following questions:

  1. What is the best way to determine IVF dependencies and resolve them?
    • Does the help manual address this issue and/or list possible dependencies?
    • Is there an Intel install package available?
    • Is DW the best way to go?
  2. Are there also equivalent SIGNALQQ signals that will catch array out of bounds, etc.?
  3. For release code, are there other mechanisms to trap errors that may occur while loading a DLL or inside the DLL? Absoft was bad in that if the DLL crashed the entire application just went away, and there was no opportunity to write a log file or prompt the user. For example, does IVF have something similar to TRY/CATCH?

Thanks.

0 Kudos
Steven_L_Intel1
Employee
2,527 Views

1. The manual does have some text on redistributing applications. Dependency Walker is the tool I recommend, but you need to know that the MSVC DLLs have to come from the Microsoft redistributable installer. We are in the process of building our own redistributable installer - not there yet,

2. No, unfortunately. Errors that are detected by generated code, such as array bounds, are not "catchable". There is an open feature request on this - I'll add your name to the list.

3. Not directly. There is SIGNALQQ which will let you be notified when an exception occurs, but you can't really recover from it. The Building Applications part of the documentation has a long chapter on exception handling which is worth a read. In some cases, you may need to wrap your Fortran code with some C++. For floating point exceptions in particular, we now support the Fortran 2003 IEEE modules which allow you nice control over the IEEE floating point exception environment.

I am curious - what prompted you to switch from Absoft to Intel?

0 Kudos
lloydchriswilson
Beginner
1,926 Views

Absoft: don't get me started! Was recommended by colleague, and resulting code was very fast compared to what we had before, so performance was great. Their editor is terrible and debugger is worse. We wasted so much time trying to figure out the quirks of their compiler settings too. Then they did an upgrade a few months after we bought and wanted us to pay full price for new version

At first we were put off by IVF's separate debugger (I didn't understand that the VS debugger was perfectly adequate for almost everything we were doing). Benchmarking initially showed Absoft being faster than IVF for our app, but we are writing large binary file and found that if we set IVF BUFFERS to non-default value, performance is somewhat better then Absoft.

Tech support has been fantastic, especially compared to Absoft, which appears to pay somewhat less attention to the Windows market. Thanks alot.

BTW: Absoft caused same difficulty with runtime dependencies--would be good if you could add an KB article clearly discussing what you and I just went through.

0 Kudos
johnnyontheweb
Beginner
1,926 Views
Hi all, I have the same version of Intel Fortran Compiler, 11.0.061, and the problem isn't solved for me compiling in Release mode. I'm using Visual Studio 2008 and Win7 and I have to compile a fortran project that generates a 32bit DLL for the program OpenSees. I can't redistribute the DLL because, even if I install the IVF redist packages or copying the IVF DLLs from bin dir, my DLL won't work in any machine and in any version of Win OS! The only 3 dependencies I found with dependency walker are: libifcoremd.dll libmmd.dll msvcr90.dll Please help me, I'm trying to do this for 3 months! Giovanni
0 Kudos
Steven_L_Intel1
Employee
1,926 Views
Johnny, the default for a DLL is to link against the DLL libraries. Change the project setting Fortran > Libraries > Run-Time Library to "Multithreaded" and not "Multithread DLL", then rebuild.
0 Kudos
johnnyontheweb
Beginner
1,926 Views
Thank you for the anwer, but I can't do this because the program that will use the library needs the DLL compiled as "Multithread DLL" (otherwise the DLL won't work, I have no idea why), I need to redistribute the needed DLLs. Giovanni
0 Kudos
Steven_L_Intel1
Employee
1,926 Views
Then you will have to distribute the dependent DLLs as well - you can't have it both ways. Note that for MSVCR90.DLL, you'll need to use Microsoft's redsistributable installer for Visual C++ 2008. We provide a redistributable installer for our DLLs.
0 Kudos
johnnyontheweb
Beginner
1,926 Views
Thanks, I know there is a redist pack but I can't figure out why any of the one I tried works. My compiler has version 11.0.061 and I tried with the package for redist ver. 11.1.048 (update 2 revised) but nothing works. I tried also with a pack that I found here: http://software.intel.com/en-us/articles/redistributable-libraries-for-the-intel-c-and-visual-fortran-composer-xe-for-windows/ but nothing. Dependency Walker continues to give me Error: The Side-by-Side configuration information for WOODSPR.DLL contains errors. Impossibile avviare l'applicazione specificata. La configurazione dell'applicazione non corretta. Una nuova installazione dell'applicazione potrebbe risolvere il problema (14001). (in Italian, that means, more or less: "Impossible to start the selected application. Application configuration can be uncorrect. A new installation of the program can solve this problem (14001).") Error: At least one required implicit or forwarded dependency was not found. Warning: At least one delay-load dependency module was not found. Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module. and said that the following files are not found: MSVCR90.DLL, IESHIMS.DLL, WER.DLL. Thanks God there is not lib????.dll missing now. Giovanni
0 Kudos
Steven_L_Intel1
Employee
1,926 Views
It's the MSVCR90.DLL you need - and you can't simply copy that DLL because Microsoft uses shared assemblies. You need http://www.microsoft.com/en-us/download/details.aspx?id=29 as well.
0 Kudos
johnnyontheweb
Beginner
1,926 Views
Already tried, nothing. I'm desperate; if it helps, I attach the dwi file of my DLL from Dependency Walker (rename it do .dwi). I suppose that the problem is in the DLL code or configuration, but not sure. I try contacting the OpenSees community, I'll let you know what will happen. Giovanni
0 Kudos
Steven_L_Intel1
Employee
1,926 Views
You should not be seeing a plain reference to MSVCR90 - it should be referencing the shared assembly instead. Did you disable the use of manifests when linking? Did you put a copy of MSVCR90.DLL in the executable folder or in PATH? (If so, remove it).
0 Kudos
johnnyontheweb
Beginner
1,926 Views
MSVCR90.DLL is not in the folder now, and it isn't in PATH. Nothing works. The linker flag "Generate manifest" is set to Yes: I can't disable it because, if I do so, the DLL won't work anymore with opensees. Giovanni
0 Kudos
Steven_L_Intel1
Employee
1,926 Views
I don't want you to disable manifests. But I thought you did, as otherwise there would not be a simple reference to MSVCR90.DLL. Did you install the VC2008 redistributables?
0 Kudos
johnnyontheweb
Beginner
1,704 Views
Yes, I installed it on the target machine but, as I wrote, it didn't solve my problem. Giovanni
0 Kudos
Reply