Chromium snap invalid GPU

Chromium snap incorrectly identifies GPUs and as result incorrectly applies driver workarounds and consumes more resources. The output of the chrome://gpu :

Chrome deb:
GPU0 VENDOR= 0x10de, DEVICE=0x134e
GPU1 VENDOR= 0x8086, DEVICE=0x591b  *ACTIVE*
Optimus true
Chromium snap:
GPU0 VENDOR= 0x0000 [Intel Open Source Technology Center], DEVICE=0x0000 [Mesa DRI Intel® HD Graphics 630 (Kaby Lake GT2) ]  *ACTIVE*
Optimus false

In this case, for example, msaa_is_slow isn’t applied. This is true also for other Chromium based snaps like Opera.

I think this problem is general to all snaps, unfortunately. This thread discusses exposing host drivers to snaps and would probably help, when implemented.

Maybe it is, but you’ve transitioned Chromium to snap and now laptop fan goes nuts on CSS animations. Maybe passing right DEVICE ID without exposing host drivers will be enough. I hope there will be a solution soon.

2 Likes

How does chromium inspect the driver? Some aspects of the GPU host drivers are exposed to snaps via i.e. dynamic libraries in /var/lib/snapd/libs/gl/..., so perhaps chromium just needs to be told to look there instead of in /usr/lib/.... ?