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

Regression in OneAPI 2024.1 - access violation linking with LTO

Mark_Lewy
Valued Contributor I
734 Views

I have reported this as 06184037 on ICS, but has anyone else had issues with programs that linked fine with LTO on Windows now causing access violations with IFX 2024.1?  Beyond disabling LTO ( removing /Qipo), which significantly degrades performance in our case, has anyone found any particular coding idiom that trips this?

Debug builds are fine.

Linux release builds using LTO are fine.

This is a large commercial code, so obviously I can't supply its source.

Update: I did a release build on a development branch this morning and it was successful, so I switched back to the master branch and it built fine too!

FYI output is

<br/><br/>Compiling with Intel&reg; Fortran Compiler 2024.1.0 [Intel(R) 64]...<br/>ws_cs_engine.F90<br/>Linking...<br/>PLEASE submit a bug report to https://software.intel.com/en-us/support/priority-support and include the crash backtrace.<br/>Stack dump:<br/>0. Program arguments: C:\\PROGRA~2\\Intel\\oneAPI\\compiler\\2024.1\\bin\\compiler\\lld-link.exe @C:\\Users\\lewym\\AppData\\Local\\Temp\\2109233arg25<br/>Exception Code: 0xC0000005<br/>

Followed by the stack trace.

0 Kudos
5 Replies
Mark_Lewy
Valued Contributor I
697 Views

... and now the linker is crashing with the access violation again with both branches, back to 2024.0 for now.

0 Kudos
Ron_Green
Moderator
683 Views

@Mark_Lewy sorry to hear that about 2024.1.   I will alert the support staff to be on the lookout for bugs in LTO.  I'll go check the C++ bug DB to see if anyone there has reported this.  If it's LTO, it's probably in LLVM.   One question I had - do you use parallel build, and if so, have you tried to serially build?  Probably irrelevant if you moved. back to 2024.0

 

 

0 Kudos
Ron_Green
Moderator
681 Views

@Mark_Lewy  found the bug report.  It was reported last month AND there is a reproducer in the bug report.  Let me escalate this issue and see if we can get a fix faster.

 

The existing bug ID is CMPLRLLVM-57125

There is a lot of activity on this issue.  

0 Kudos
Mark_Lewy
Valued Contributor I
595 Views

@Ron_Green Thanks - if you can provide any suggestions on what idioms may cause an LTO issue on Windows, we may be able to work around this.  Otherwise, I see no problem in continuing to build with 2024.0 with the 2024.1 IDE integration for now. 

0 Kudos
Mark_Lewy
Valued Contributor I
522 Views

@Ron_Green Our latest Linux source now seg faults in ld when doing a release build (I assume this is the same problem as Windows), so I've split the main static library in two, compiling one with LTO, the other without.  This has allowed me to isolate one particular module as the culprit.  Given that it contains over 5000 lines, I suspect some judicious use of submodules may eliminate the link issue; I'll continue with this next week.

0 Kudos
Reply