Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chrome does not use hardware acceleration #192599

Open
davidak opened this issue Sep 23, 2022 · 2 comments
Open

Chrome does not use hardware acceleration #192599

davidak opened this issue Sep 23, 2022 · 2 comments

Comments

@davidak
Copy link
Member

davidak commented Sep 23, 2022

Describe the bug

A lot of features are disabled at chrome://gpu/.

Screenshot from 2022-09-23 04-23-30

Use hardware acceleration when available

is enabled at chrome://settings/system and i have working drivers for my GPU.

Steps To Reproduce

Steps to reproduce the behavior:

  1. open chrome://gpu/
  2. check if hardware acceleration works

Expected behavior

In best case, everything should work.

Additional context

I specifically need WebGL to test Third Room (matrix-org/thirdroom#330).

My GPU is an AMD RX 6600XT using amdgpu driver.

Also using:

hardware.opengl.extraPackages = with pkgs; [ amdvlk rocm-opencl-icd rocm-opencl-runtime ];

HW Acceleration for open source AMD driver is blacklisted by default. Ignoring the blacklist does not help.

https://www.khronos.org/webgl/wiki/BlacklistsAndWhitelists#Chrome_on_Linux

Workaround: It works out-of-the-box in Edge, so i used that for testing.

Notify maintainers

@primeos

Metadata

  • system: "x86_64-linux"
  • host os: Linux 5.15.67, NixOS, 22.05 (Quokka), 22.05.3065.178fea1414a
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.8.1
  • channels(root): "home-manager-22.05.tar.gz, nixos-22.05, nixos-hardware, nixos-unstable"
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos
@zendo
Copy link
Contributor

zendo commented Sep 24, 2022

Try this:

(google-chrome.override {
      commandLineArgs = [
        "--ozone-platform=wayland"
        "--enable-features=VaapiVideoDecoder"
        "--use-gl=egl"
      ];
    })

@davidak
Copy link
Member Author

davidak commented Sep 25, 2022

@zendo that does not work because i don't use wayland.

[davidak@gaming:~]$ google-chrome-stable --process-per-site
[852646:852646:0925/065657.787716:ERROR:wayland_connection.cc(215)] Failed to connect to Wayland display
[852646:852646:0925/065657.787741:ERROR:ozone_platform_wayland.cc(220)] Failed to initialize Wayland platform
[852646:852646:0925/065657.787744:ERROR:env.cc(255)] The platform failed to initialize.  Exiting.

and also when removing the first argument and adding some more i found at https://wiki.archlinux.org/title/Chromium#Force_GPU_acceleration it does not work

    (google-chrome.override {
      commandLineArgs = [
        "--enable-features=VaapiVideoDecoder"
        "--use-gl=egl"
        "--ignore-gpu-blocklist"
        "--enable-gpu-rasterization"
        "--enable-zero-copy"
      ];
    })

here are some errors i get in terminal

[853172:853172:0925/065757.450955:ERROR:gpu_init.cc(486)] Passthrough is not supported, GL is egl, ANGLE is 
Error in cpuinfo: failed to parse processor information from /proc/cpuinfo
[853172:853252:0925/065817.516612:ERROR:platform_shared_memory_region_posix.cc(47)] Descriptor access mode (0) differs from expected (2)
[0925/065817.535506:ERROR:process_memory_range.cc(75)] read out of range
[854055:1:0925/065820.955719:ERROR:command_buffer_proxy_impl.cc(128)] ContextResult::kTransientFailure: Failed to send GpuControl.CreateCommandBuffer.
[854855:1:0925/065820.956200:ERROR:command_buffer_proxy_impl.cc(325)] GPU state invalid after WaitForGetOffsetInRange.
[853128:853128:0925/065821.216586:ERROR:gpu_process_host.cc(965)] GPU process exited unexpectedly: exit_code=133
Fontconfig error: Cannot load default config file: No such file: (null)
[856674:856674:0925/065833.248438:ERROR:shared_image_factory.cc(795)] CreateSharedImage: could not create backing.
[857016:1:0925/065833.248474:ERROR:command_buffer_proxy_impl.cc(128)] ContextResult::kTransientFailure: Failed to send GpuControl.CreateCommandBuffer.
[856674:856674:0925/065833.248499:ERROR:shared_image_stub.cc(159)] SharedImageStub: Unable to create shared image
[856674:856674:0100/000000.702865:ERROR:raster_decoder.cc(1651)] Error: 1 for Command Noop
[856674:856674:0100/000000.703051:ERROR:gles2_cmd_decoder.cc(6002)] Error: 4 for Command SetBucketData
[853128:853128:0925/065842.390020:ERROR:page_load_metrics_update_dispatcher.cc(162)] Invalid first_paint 41.959 s for first_image_paint 33.274 s

these repeat many times...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants