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

Trouble using -check uninit

vanderwb
Novice
85 Views

We're trying to use the -check uninit feature in ifx and running into what appear to be very basic false positives with glibc. Here is a test program:

program test
implicit none
integer :: i = 4
end program test

 This is then compiled using:

$ ifx -check uninit -g -O0 test.f90

and then when it is run, we get:

$ ./a.out
==34877==WARNING: MemorySanitizer: use-of-uninitialized-value
#0 0x00000040d2d2 in _GLOBAL__sub_I_fast_mem_ops.c fast_mem_ops.c
#1 0x7fabb902b43e in __libc_start_main@GLIBC_2.2.5 (/lib64/libc.so.6+0x2b43e) (BuildId: 8523b213e7586a93ab00f6dd476418b1e521e62c)
#2 0x00000040d344 in _start /home/abuild/rpmbuild/BUILD/glibc-2.42-build/glibc-2.42/csu/../sysdeps/x86_64/start.S:115

Uninitialized value was created by an allocation of 'a.i.i' in the stack frame
#0 0x00000040c741 in _GLOBAL__sub_I_fast_mem_ops.c fast_mem_ops.c

SUMMARY: MemorySanitizer: use-of-uninitialized-value fast_mem_ops.c in _GLOBAL__sub_I_fast_mem_ops.c
Exiting

We're using Intel OneAPI Compilers 2025.2.1, but have tried multiple versions through 2025.3. This is on SLES 15.6.

0 Kudos
0 Replies
Reply