- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a COM Automation module that was generated by the Intel Fortran Module Wizard. It is quite a long file (200K+ lines), but has been compiling just fine for many years with ifort. It produces the following output when I try to compile it with ifx. I've attached a zipped/compressed version of the source code and compilation output.
------ Build started: Configuration: Debug|x64 ------
Compiling with Intel® Fortran Compiler 2024.1.0 [Intel(R) 64]...
Excel2016Mod.f90
Excel2016Mod.f90(204587): warning #6843: A dummy argument with an explicit INTENT(OUT) declaration is not given an explicit value. [DATA]
Excel2016Mod.f90(28163): warning #6843: A dummy argument with an explicit INTENT(OUT) declaration is not given an explicit value. [IMPORTMAP]
Excel2016Mod.f90(28134): warning #6843: A dummy argument with an explicit INTENT(OUT) declaration is not given an explicit value. [IMPORTMAP]
handle_memory_allocation_error: out of memory
#0 0x00007ff6d7b8046a (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x112046a)
#1 0x00007ff6d7b80525 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x1120525)
#2 0x00007ff6d78e218b (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0xe8218b)
#3 0x00007ff6d78e11d4 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0xe811d4)
#4 0x00007ff6d7c4c489 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11ec489)
#5 0x00007ff6d7c4c3e6 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11ec3e6)
#6 0x00007ff6d7c4c42b (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11ec42b)
#7 0x00007ff6d6a764b0 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x164b0)
#8 0x00007ff6d6a75556 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x15556)
#9 0x00007ff6d7ab6dfc (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x1056dfc)
#10 0x00007ff6d7ab99bd (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10599bd)
#11 0x00007ff6d7b55955 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10f5955)
#12 0x00007ff6d7b558b9 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10f58b9)
#13 0x00007ff6d7ad307e (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x107307e)
#14 0x00007ff6d7b54cfb (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10f4cfb)
#15 0x00007ff6d7b5aeee (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10faeee)
#16 0x00007ff6d7b5a286 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10fa286)
#17 0x00007ff6d7b57284 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10f7284)
#18 0x00007ff6d7b57619 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x10f7619)
#19 0x00007ff6d7bcd4d9 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x116d4d9)
#20 0x00007ff6d7bc80a3 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11680a3)
#21 0x00007ff6d7bc84ea (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11684ea)
#22 0x00007ff6d7bc6150 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x1166150)
#23 0x00007ff6d7bc80a3 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11680a3)
#24 0x00007ff6d7bc58bd (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11658bd)
#25 0x00007ff6d7bc80a3 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x11680a3)
#26 0x00007ff6d7a97173 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x1037173)
#27 0x00007ff6d7a96930 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x1036930)
#28 0x00007ff6d6a74a8e (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0x14a8e)
#29 0x00007ff6d78c8518 (C:\PROGRA~2\Intel\oneAPI\compiler\2024.1\bin\compiler\xfortcom.exe+0xe68518)
#30 0x00007ffd8f477344 (C:\WINDOWS\System32\KERNEL32.DLL+0x17344)
#31 0x00007ffd90c626b1 (C:\WINDOWS\SYSTEM32\ntdll.dll+0x526b1)
2080046.i90: error #5629: **Internal compiler error: abort signal raised**
Please report this error along with the circumstances in which it occurred in a Software Problem Report.
Note: File and line given may not be explicit cause of this error.
compilation aborted for Excel2016Mod.f90 (code 3)
Build log written to "file://BuildLog.htm"
2 error(s), 3 warning(s)
---------------------- Done ----------------------
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This is one huge module! How long does this take to compile with ifort?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It takes just about 8 minutes to build using ifort.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I built this without error with a nightly build from our main branch. This compiler will be in the 2025.0 release. It took about 5-10 minutes to compile.
What I will test tomorrow is to try our preview candidate for the 2024.2.0 release. We have been doing some work on extending internal limits. I want to see if 2024.2.0 builds.
I just did the compile with
ifx -c
with VS2022 on Win10.
what options do you use?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here are the compiler options from the Buildlog.htm file:
ifx /nologo /debug:full /Od /fpp /DPLATFORM_INTEL_FORTRAN /warn:interfaces /module:"x64\Debug\\" /object:"x64\Debug\\" /traceback /check:bounds /check:stack /libs:dll /threads /dbglibs /c /Qlocation,link,"C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\bin\HostX64\x64" /Qm64 "Excel2016Mod.f90"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I got the same error when I tried: ifx /c Excel2016Mod.f90
I'm using VS 2022 version 17.9.7 with version 2024.1.0 of the Fortran compiler on Windows 10 Enterprise version 2H22. The machine has 16 GB of RAM installed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
interesting , the 2024.1.0 compiler also builds this if I just use -c as the only compiler option. The error must be triggered by compiler options. Do you have the Buildlog.htm file?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here is the Buildlog.htm file. I had to rename to bypass the forum restriction on htm files.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
From the message, it looks like your machine ran out of memory. Does reducing the optimisation level for this file fix the issue?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have optimization disabled. That's the /Od compiler option above.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@Mike33 a good concern or question was raised by @Andrew_Smith regarding being out of memory. The PC server I'm using for test has 128GB. How much RAM do you have? Perhaps I should try a PC of similar memory capacity as yours.
Have you tried running Resource Monitor, Memory during compilation? I just did and this server was up around 52% memory usage, or a little above 64GB for ifx. I didn't see that with ifort, but after the parsing they are completely different compilers. I am triaging this to see if there is a bug here or if it's just that internal structs for this are sizeable.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The PC I'm testing on has 16 GB of RAM. The xfortcom.exe was using about 240 MB for a long time, but right after the three warnings were issued, it immediately spiked up to over 12 GB and then it crashed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
what I saw was the memory usage ramp up AFTER the last warning message came out. During this phase I expect the language parsing and building of the AST is done. The phase where the memory use ramps appears to be during the lower of the AST to LLVM IR. In ifort the AST is lowered to IL0 which is much more compact. It does look like perhaps a slow or sloppy use of structs in the lowering, probably a bug but not necessarily. It could be an attribute of the size of structs needed to pass this off to LLVM. I need the team to look at this more carefully.
If you do have a PC with 128GB handy, problem solved. but let's get to the bottom of this memory usage. For sure it's an attribute of this most unusually HUGE single module. 205,000 or so source lines, right?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I was able to compile it on a machine with 64 GB of RAM. The xfortcom.exe used about 240 MB for a long as before and then spiked to about 30-50 GB after the warnings. After that, it came back down to about 800 MB - 1 GB for awhile and finished compiling.
I guess that solves the immediate issue, but everyone on my team only has 16 GB of RAM and the PC with 64 GB is my personal device so it can't be hooked into our office network.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I will get to the bottom of this. I suspect a bug, a memory leak. I will make sure we get this fixed. I'll open a bug report to track it.
I tried a number of compiler options but so far I've not found a way to avoid the memory usage from changing compiler options. This is why I suspect it's in the AST lowering code (which is different in IFX than in IFORT).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The bug ID for this one is CMPLRLLVM-59278.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The fix will be available in 2025.2 ifx release.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you! Do you have a feel for when the 2025.2 version of ifx will be available for download?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page