Problem with Intel's ifx compiler

I have just installed the latest standalone Intel Fortran compiler. I then created a directory with fpm and set the compiler to ifx. The run failed with being unable to find llvm-copy but after some googling https://community.intel.com/t5/Intel-Fortran-Compiler/ifx-missing-clang-rt-msan-to-link-Fortran-program-in-debug-build/m-p/1533430, I installed the standalone DPC++ compiler.

Now, the simple Hello program runs successfully but spits out this error at the end:

Uninitialized bytes in write at offset 0 inside [0x725000000000, 13)
==37228==WARNING: MemorySanitizer: use-of-uninitialized-value

The link above says to do -check all,nouninit but I don’t know where to include this.

Currently, I just add source setvars.sh and source vars.sh in my .bashrc file.

1 Like

Either you add it to your compilation command:

$ ifx -check all,nouninit ...

or you add it to the ifx.cfg config file.

Note that due to the all, this command turns on other runtime checks.

Thanks. That worked.

sorry you hit this bug.

our first implementaton of LLVM Memory Sanitizer could have been better. We have a redesign in the works to get around this bug. It involves renaming the msan versions of the FRTl along with driver changes to ifx. That redesign will show up in 2024 Update 1.

I have encountered this bug too. Spent an hour trying to find the uninit variable with no success. I look forward to installing the patch for this bug.