-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
I don't think these are my fault, but I found a few leaks in the openCL api:
Valgrind shows the errors from clCreateKernel:
==21141==
==21141== 19 bytes in 5 blocks are definitely lost in loss record 88 of 7,186
==21141== at 0x48557A8: malloc (vg_replace_malloc.c:446)
==21141== by 0x496D62F: strdup (strdup.c:42)
==21141== by 0xDA4FA34: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA5074A: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA49992: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA493DE: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA54A04: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA1EF54: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xD9D250C: clCreateKernel (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0x4008337: qb_configure_program (in /home/leios/projects/quibble/build/bin/quibble)
==21141== by 0x4009BB7: quibble_program_tests (in /home/leios/projects/quibble/build/bin/quibble)
==21141== by 0x4009D37: main (in /home/leios/projects/quibble/build/bin/quibble)
==21141==
==21141== 29 bytes in 5 blocks are definitely lost in loss record 297 of 7,186
==21141== at 0x48557A8: malloc (vg_replace_malloc.c:446)
==21141== by 0x496D62F: strdup (strdup.c:42)
==21141== by 0xDA4F946: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA5074A: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA49992: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA493DE: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA54A04: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xDA1EF54: ??? (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0xD9D250C: clCreateKernel (in /opt/intel/oneapi/compiler/2025.0/lib/libintelocl.so.2024.18.12.0)
==21141== by 0x4008337: qb_configure_program (in /home/leios/projects/quibble/build/bin/quibble)
==21141== by 0x4009BB7: quibble_program_tests (in /home/leios/projects/quibble/build/bin/quibble)
==21141== by 0x4009D37: main (in /home/leios/projects/quibble/build/bin/quibble)
ASan shows the errors from clIcdGetPlatformIDsKHR:
Direct leak of 144 byte(s) in 2 object(s) allocated from:
#0 0x7f0c72b21a2d in operator new(unsigned long) /usr/src/debug/gcc/gcc/libsanitizer/asan/asan_new_delete.cpp:86
#1 0x7b0c4ce73c88 (/opt/rocm/lib/libhsa-runtime64.so.1+0x73c88) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#2 0x7b0c66d2860d (/opt/rocm/lib/libamdocl64.so+0x7960d) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#3 0x7b0c66d29336 (/opt/rocm/lib/libamdocl64.so+0x7a336) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#4 0x7b0c66cdcdaf in clIcdGetPlatformIDsKHR (/opt/rocm/lib/libamdocl64.so+0x2ddaf) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#5 0x7f0c732a5562 (/opt/intel/oneapi/compiler/latest/lib/libOpenCL.so.1+0x7562)
Direct leak of 72 byte(s) in 1 object(s) allocated from:
#0 0x7f0c72b21a2d in operator new(unsigned long) /usr/src/debug/gcc/gcc/libsanitizer/asan/asan_new_delete.cpp:86
#1 0x7b0c4ce73c88 (/opt/rocm/lib/libhsa-runtime64.so.1+0x73c88) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#2 0x7b0c4ce9b5ee (/opt/rocm/lib/libhsa-runtime64.so.1+0x9b5ee) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#3 0x7b0c4ce9b7b8 (/opt/rocm/lib/libhsa-runtime64.so.1+0x9b7b8) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#4 0x7b0c4cea0db8 (/opt/rocm/lib/libhsa-runtime64.so.1+0xa0db8) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#5 0x7b0c4cea103b (/opt/rocm/lib/libhsa-runtime64.so.1+0xa103b) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#6 0x7b0c4ce66572 (/opt/rocm/lib/libhsa-runtime64.so.1+0x66572) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#7 0x7b0c66d26350 (/opt/rocm/lib/libamdocl64.so+0x77350) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#8 0x7b0c66d29336 (/opt/rocm/lib/libamdocl64.so+0x7a336) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#9 0x7b0c66cdcdaf in clIcdGetPlatformIDsKHR (/opt/rocm/lib/libamdocl64.so+0x2ddaf) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#10 0x7f0c732a5562 (/opt/intel/oneapi/compiler/latest/lib/libOpenCL.so.1+0x7562)
Direct leak of 29 byte(s) in 5 object(s) allocated from:
#0 0x7f0c72b1a58a in strdup /usr/src/debug/gcc/gcc/libsanitizer/asan/asan_interceptors.cpp:593
#1 0x7b0c64d52946 (/opt/intel/oneapi/compiler/latest/lib/libintelocl.so+0x3552946)
Direct leak of 19 byte(s) in 5 object(s) allocated from:
#0 0x7f0c72b1a58a in strdup /usr/src/debug/gcc/gcc/libsanitizer/asan/asan_interceptors.cpp:593
#1 0x7b0c64d52a34 (/opt/intel/oneapi/compiler/latest/lib/libintelocl.so+0x3552a34)
Indirect leak of 96 byte(s) in 2 object(s) allocated from:
#0 0x7f0c72b2073d in calloc /usr/src/debug/gcc/gcc/libsanitizer/asan/asan_malloc_linux.cpp:74
#1 0x7b0c4cf31058 (/opt/rocm/lib/libhsa-runtime64.so.1+0x131058) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#2 0x7b0c4ce767bf (/opt/rocm/lib/libhsa-runtime64.so.1+0x767bf) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#3 0x7b0c4ce76cad (/opt/rocm/lib/libhsa-runtime64.so.1+0x76cad) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#4 0x7b0c4ce73c9d (/opt/rocm/lib/libhsa-runtime64.so.1+0x73c9d) (BuildId: 0fa854987e89a1a171070daf21758e93d72c8f8e)
#5 0x7b0c66d2860d (/opt/rocm/lib/libamdocl64.so+0x7960d) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#6 0x7b0c66d29336 (/opt/rocm/lib/libamdocl64.so+0x7a336) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#7 0x7b0c66cdcdaf in clIcdGetPlatformIDsKHR (/opt/rocm/lib/libamdocl64.so+0x2ddaf) (BuildId: b2555696643260ffd4ab74b9c0db6c50782eeb7c)
#8 0x7f0c732a5562 (/opt/intel/oneapi/compiler/latest/lib/libOpenCL.so.1+0x7562)
Related: ROCm/clr#178
Metadata
Metadata
Assignees
Labels
No labels