ROCm / amdsmi

AMD SMI
https://rocm.docs.amd.com/projects/amdsmi/en/latest
MIT License
39 stars 23 forks source link

Fix address sanatizer issue in DiscoverAmdgpuDevices #32

Closed laundrei closed 2 weeks ago

laundrei commented 4 months ago

I was running a test that exercised this code and AddressSanatizer flagged this line as a 8-byte-read-stack-buffer-overflow-far-from-bounds. I believe the issue is that the iterator returned from allSystemNodes.lower_bound(device_uuid) is dereferenced unconditionally.

dmitrii-galantsev commented 2 weeks ago

Looks like we pulled in the same patch from someone else... even though you were the first to find the issue! Sorry! https://github.com/ROCm/amdsmi/pull/44