Skip to content

[CLANG18] MSAN: use-of-uninitialized-value in lib_enc/igf_enc_fx.c:4298:9

Basic Info

Bug description

Clang 18 MSAN found an use-of-uninitialized-value error at lib_enc/igf_enc_fx.c:4298:9:

==36992==WARNING: MemorySanitizer: use-of-uninitialized-value
#0 0x55836f524b4d in IGFEncApplyStereo_fx /ivas-basop/lib_enc/igf_enc_fx.c:4298:9
#1 0x55836f22ea45 in ProcessStereoIGF_fx /ivas-basop/lib_enc/tcx_utils_enc_fx.c:4010:5
#2 0x55836f79a4cd in stereo_mdct_core_enc_fx /ivas-basop/lib_enc/ivas_stereo_mdct_core_enc_fx.c:626:21
#3 0x55836f56e2f9 in ivas_core_enc_fx /ivas-basop/lib_enc/ivas_core_enc_fx.c:559:17
#4 0x55836f5ebd4b in ivas_cpe_enc_fx /ivas-basop/lib_enc/ivas_cpe_enc_fx.c:1273:5
#5 0x55836ec12423 in ivas_enc_fx /ivas-basop/lib_enc/ivas_enc_fx.c:180:9
#6 0x55836eb0e675 in IVAS_ENC_EncodeFrameToSerial /ivas-basop/lib_enc/lib_enc_fx.c:1502:13
#7 0x55836eaed94a in main /ivas-basop/apps/encoder.c:877:28
#8 0x7f245dd531c9 in __libc_start_call_main csu/../sysdeps/nptl/libc_start_call_main.h:58:16
#9 0x7f245dd5328a in __libc_start_main csu/../csu/libc-start.c:360:3
#10 0x55836ea4d454 in _start (/ivas-basop/IVAS_cod+0x38454) (BuildId: 789f3dc0ffff33f27110c73bbbf592b3990dac4e)

SUMMARY: MemorySanitizer: use-of-uninitialized-value /ivas-basop/lib_enc/igf_enc_fx.c:4298:9 in IGFEncApplyStereo_fx

How to reproduce

⚠️ Make sure to use CLANG v18 for building the codec :warning

Build with

make clean
make -j CLANG=1

Then run

IVAS_cod -stereo -dtx 48000 48 scripts/testv/stvST48n.wav stvST48n.wav_stereo_at_48_kbps_48_kHz_in_48_kHz_out_DTX_on_FER_with_burst_error_before_SID.192

or

python3 -m pytest "test_param_file_tests[stv-stereo at 48 kbps, 48 kHz in, 48 kHz out, DTX on, FER with burst error before SID]" -n auto --update_ref --ref_encoder_path ./IVAS_cod --ref_decoder_path ./IVAS_dec
Edited by Jan Kiene