From 85a059e76fa91989e4fce3bc1bd14e234e1aad69 Mon Sep 17 00:00:00 2001 From: K11MCH1 <81425424+K11MCH1@users.noreply.github.com> Date: Sat, 24 Oct 2026 02:21:52 +0900 Subject: [PATCH] Enable experimental Steam browser GPU path for Qualcomm drivers (cherry picked from commit 7ecf2affb647b36d237600b037ba504f4119a313) (cherry picked from commit 0de60b7ce979c003823767ab026fc7c9870862df) --- .../com/droiddeck/launcher/gpu/QualcommSystemDriver.kt | 1 - tools/qualcomm/README.md | 10 +++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/com/droiddeck/launcher/gpu/QualcommSystemDriver.kt b/app/src/main/java/com/droiddeck/launcher/gpu/QualcommSystemDriver.kt index 4025466e7..cab5f463b 100644 --- a/app/src/main/java/com/droiddeck/launcher/gpu/QualcommSystemDriver.kt +++ b/app/src/main/java/com/droiddeck/launcher/gpu/QualcommSystemDriver.kt @@ -87,7 +87,6 @@ object QualcommSystemDriver { "HYBRIS_LD_LIBRARY_PATH=/system/lib64:/system_ext/lib64:/vendor/lib64/egl:/vendor/lib64/hw:/vendor/lib64", "DROIDDECK_SYSTEM_QUALCOMM=1", "BL_GAMESCOPE_BACKEND=sdl", "DROIDDECK_QUALCOMM_DRIVER=$id", - "BL_STEAM_CEF_SOFTWARE=1", "BL_GAMESCOPE_BINARY=${File(dir, "bin/gamescope").path}", "DROIDDECK_QUALCOMM_ROOT=${dir.path}", "DROIDDECK_QUALCOMM_SHADERS=${File(dir, "shaders").path}", diff --git a/tools/qualcomm/README.md b/tools/qualcomm/README.md index fb0838567..c3f9120c9 100644 --- a/tools/qualcomm/README.md +++ b/tools/qualcomm/README.md @@ -16,9 +16,13 @@ The import's metadata advertises Vulkan **1.4.359**, but this device's Linux Vul ## Steam browser hardware-rendering investigation -Games, Gamescope and Android presentation already use Vulkan hardware acceleration. The software overrides apply to Steam's CEF browser and its SDL window surface. RedMagic 11 Pro/v891.7 trials on 2026-10-24 removed the CEF software override, tried ANGLE Vulkan and OpenGL/Zink, explicitly passed Chromium backend switches, removed the requested in-process GPU switch, and retried without the SDL software-surface override. None produced a stable usable Steam UI. The browser restarted or exited and the session subsequently shut down; logs include command-buffer creation and X11 connection errors. These observations do not isolate the root cause, and `READY` alone does not confirm the Steam window is usable. +Games, Gamescope and Android presentation use Vulkan hardware acceleration. Experimental builds now also use Steam's regular GPU-enabled browser launch path for both system and imported Qualcomm drivers. This is a shared backend default with no GPU-model allowlist. The helper's `SDL_FRAMEBUFFER_ACCELERATION=0` workaround remains scoped to its SDL window surface; it does not disable Chromium GPU compositing. Browser rendering correctness is not yet established. -The working software UI fallback was restored. No hardware CEF mode is shipped or claimed as working. Reproduction logs and trial scripts are retained in ignored `build/research/qualcomm/cef-gpu-*` and `cef-trial-*`; device sessions are `2026-10-24-04-steam` through `2026-10-24-08-steam`. Chromium/ANGLE backend switches are documented in [ANGLE debugging tips](https://github.com/google/angle/blob/main/doc/DebuggingTips.md). +Earlier RedMagic 11 Pro/v891.7 trials on 2026-10-24 failed to produce a stable hardware-rendered Steam UI. They tried ANGLE Vulkan and OpenGL/Zink, explicit Chromium backend switches, removing the in-process GPU switch, and removing the SDL workaround. The browser restarted or exited; logs include command-buffer creation and X11 connection errors. Those trials preceded the private Mesa integration. Evidence remains in ignored `build/research/qualcomm/cef-gpu-*` and `cef-trial-*`, device sessions `2026-10-24-04-steam` through `2026-10-24-08-steam`. The current components still require retesting on Adreno 840. Chromium/ANGLE switches are documented in [ANGLE debugging tips](https://github.com/google/angle/blob/main/doc/DebuggingTips.md). + +On Adreno 740/Qualcomm 0.676.1, session `2026-10-24-13-steam` enabled the regular browser GPU path with the private Mesa integration and retained the SDL workaround. Steam reached its visible library and the user confirmed faster interaction, then reported UI corruption. Captures show persistent black rectangles obscuring portions of the library. The browser command line lacked `--disable-gpu` and `--disable-gpu-compositing`; its process mapped the Qualcomm HAL, libhybris ICD, private Zink library and Steam's ANGLE libraries, held an open `/dev/kgsl-3d0` descriptor, and did not map SwiftShader. Disabling partial swap in session `2026-10-24-14-steam` did not remove the visible corruption; that flag is not packaged. Investigation was paused at the user's request to prepare an Adreno 840 test APK. This path is experimental and has not passed rendering acceptance. An explicit `BL_STEAM_CEF_SOFTWARE=1` session environment override remains available for diagnosis or fallback. + +Qualcomm sessions also leave the Steam client CPU affinity unrestricted by default, preserving explicitly saved overrides. The previous SM8550 default pinned Steam, its browser and Gamescope to one core. The affinity loop now applies client masks only to Steam and its browser. A startup recording after that fix showed the complete six-second DroidDeck animation followed by the library; a brief initial white window remained before playback. `runtime.json` pins the downloaded bridge and WSI archives, the locally built private Gamescope binary and corresponding source archive, and every private Mesa runtime file. `fetch_runtime.py` checks these pins before Gradle stages them. Missing local build outputs fail the build. Qualcomm's proprietary device libraries are loaded from the phone and are not included in these archives. The bridge archive includes its licenses, source snapshot and patches. @@ -39,7 +43,7 @@ The connected vivo V2243A/SM8550 reports Adreno 740, proprietary Qualcomm 0.676. Mesa 26.2.3 made maintenance5 mandatory for Zink. `zink-optional-maintenance5.patch` restores the earlier optional extension check, preserves point-size shader stores without that feature, and omits the maintenance5 buffer-view usage structure when unsupported. The private build uses the same Mesa release as the installed runtime, exposes a distinct GLVND vendor, and includes only Zink as its Gallium driver. `qualcomm-gl.sh` selects its libraries for applications and Mangoapp in Qualcomm sessions. It does not change the Vulkan device's reported features or enable software rendering. This does not establish full OpenGL conformance or game compatibility. -Hardware verification on 2026-10-24 installed the full-runtime development APK and reached the visible Steam Big Picture library on this Adreno 740. Steam and Gamescope mapped `/vendor/lib64/hw/vulkan.adreno.so` through the bridge; Steam also mapped the private GLX vendor and `libgallium-26.2.3.so`. `egl_probe.c` reported **OpenGL 3.2 Compatibility Profile**, rendered a triangle through `zink Vulkan 1.3(Adreno (TM) 740 (QUALCOMM_PROPRIETARY))`, and verified all 256 readback pixels. Evidence is under ignored `build/research/qualcomm/adreno740`, device session `2026-10-24-05-steam`. Steam's CEF software fallback remains enabled. Games have not been verified on this phone, and the newly rebuilt components have not yet been retested on Adreno 840. +Hardware verification on 2026-10-24 installed the full-runtime development APK and reached the visible Steam Big Picture library on this Adreno 740. Steam and Gamescope mapped `/vendor/lib64/hw/vulkan.adreno.so` through the bridge; Steam also mapped the private GLX vendor and `libgallium-26.2.3.so`. `egl_probe.c` reported **OpenGL 3.2 Compatibility Profile**, rendered a triangle through `zink Vulkan 1.3(Adreno (TM) 740 (QUALCOMM_PROPRIETARY))`, and verified all 256 readback pixels. Evidence is under ignored `build/research/qualcomm/adreno740`, initially device session `2026-10-24-05-steam`, followed by the browser GPU trial described above. Games have not been verified on this phone, and the newly rebuilt components have not yet been retested on Adreno 840. Build the private components on ARM64 Linux with their normal development dependencies (GCC/C++, Meson, Ninja, pkg-config, Wayland/X11/SDL2 headers, Vulkan headers, glslang, and Mesa's Python Mako/packaging/PyYAML, Flex and Bison requirements):