Skip to content

ac/gpu_info: Use most significant SE mask bit for num_se

Friedrich Vock requested to merge pixelcluster/mesa:ac-cumask-last-bit into main

Using the bit count is flawed when there are SEs with a 0 CU mask.

The CU mask for a 7900GRE looks like this:

    cu_mask[SE0][SA0] = 0xff
    cu_mask[SE0][SA1] = 0xff
    cu_mask[SE1][SA0] = 0xff
    cu_mask[SE1][SA1] = 0xff
    cu_mask[SE2][SA0] = 0xff
    cu_mask[SE2][SA1] = 0xff
    cu_mask[SE3][SA0] = 0xff
    cu_mask[SE3][SA1] = 0xff
    cu_mask[SE4][SA0] = 0x0
    cu_mask[SE4][SA1] = 0x0
    cu_mask[SE5][SA0] = 0xff
    cu_mask[SE5][SA1] = 0xff

We should treat this as 6 SEs for the purpose of scratch allocation etc., otherwise there can be hangs.

Merge request reports