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

COM Object Build - Fatal compilation error: Out of memory asking for xxx

Intel_C_Intel
Employee
837 Views
Hi All,

I'm in the process of building a COM object, the interface is rather large and i've run into the problem that the fortcom.exe process hits the 32bit Windows 2GB virtual memory limit when compiling and the build subsequently fails.

I'm just wondering if are there any quick and easy tips that may cut down the memory consumption of the build process so that it may compile without having to break up the COM interface into smaller components.

FYI, the auto-generated Fortran source files for the COM interface are around the 700KB size.

Regards,

Darren
0 Kudos
3 Replies
Steven_L_Intel1
Employee
837 Views
I just want to verify something; you are creating a COM server and not using the module wizard to generate an interface for something already on your system? I suppose the first thing I would try is to right-click on the interface source file, select properties, and change the optimization level of that one source file to no optimization. This assumes, of course, that you are building a release configuration with optimization.

I am somewhat surprised that you are running into this problem with a source file of "only" 700 KB as I have successfully built much larger collections of module procedures.

Would you please submit an issue to Intel Premier Support and attache a ZIP of your project? Ask that it be assigned to Steve Lionel, I'd like to see it.
0 Kudos
Intel_C_Intel
Employee
837 Views
Hello Steve,

Yes, i'm creating a COM Server from scratch and I already had optimization turned off.

The default interface for the server in the "hie" file has around 240 "properties" in the default COM interface, ie each property has both a get and put method.

Subsequent to my inital post i've found another solution that suits my needs, however it does require me to define multiple (smaller) COM interfaces.

Still i'm quite surprised that even this number of methods in a single COM interface causes such extreme memory consumption. It seems there is a polynomial (exponential??) relationship between com interface size (number of methods) and compilation memory consumption. With the testing i've done even cutting out half the inteface methods results in significantly lower memory consumption.

Darren
0 Kudos
Steven_L_Intel1
Employee
837 Views
It has nothing to do with COM, specifically. The compiler does have a problem compiling sources with a very large number of module procedures, and each method is its own procedure.

Please do send us the sources - perhaps there's something we can do.
0 Kudos
Reply