Mesa/Turnip: Vulkan rendering artifacts on Adreno 830 in Termux-X11
Description
I am experiencing severe rendering artifacts when using Turnip/Freedreno Vulkan on an Adreno 830 (Snapdragon 8 Elite) GPU under Termux-X11 on Android.
The problem is reproducible with scrcpy when using the Vulkan renderer directly.
The Vulkan device is detected correctly and Turnip initializes successfully, but the rendered output contains visual corruption/artifacts. In some configurations the displayed frame can also become frozen/stale.
Environment
- GPU: Adreno 830
- SoC: Snapdragon 8 Elite
- Device: Samsung Galaxy S25
- OS: Android 15
- Environment: Termux + Termux-X11
- Display server: X11
DISPLAY=:0
- Mesa:
26.3.0-devel (git-98f3d6229d)
- Vulkan Loader:
1.4.362
- Vulkan driver: Turnip / Freedreno
- ICD:
freedreno_icd.aarch64.json
- GPU node:
/dev/kgsl-3d0
- scrcpy:
4.1
The application being mirrored by scrcpy is running on a separate Android device.
Reproduction
Run:
scrcpy --render-driver=vulkan -V debug --no-audio
To make sure MangoHud is not involved:
VK_LOADER_LAYERS_DISABLE=MangoHud scrcpy --render-driver=vulkan -V debug --no-audio
The relevant scrcpy output is:
INFO: Renderer: vulkan
DEBUG: Trilinear filtering disabled (not an OpenGL renderer)
INFO: Texture: 1220x2712
The Vulkan loader detects the GPU as:
and loads:
from the Termux Mesa installation.
Actual behavior
scrcpy successfully creates a Vulkan renderer and detects the Adreno 830, but the displayed image contains severe rendering artifacts.
Depending on the configuration, the output can also become stuck on an old frame instead of displaying the current video frames.
This does not appear to be a simple Vulkan initialization failure: the Vulkan renderer starts successfully and the texture is created.
Additional observations
With:
TU_DEBUG=all scrcpy --render-driver=vulkan -V debug --no-audio
Turnip initializes successfully and GPU work is submitted, but the visual output can still be corrupted or remain frozen.
When using the default OpenGL/Zink path, enabling TU_DEBUG=all causes a different failure:
TU: error: ... invalid global priority (VK_ERROR_INITIALIZATION_FAILED)
MESA: error: ZINK: vkCreateDevice failed (VK_ERROR_INITIALIZATION_FAILED)
glx: failed to create drisw screen
failed to load driver: zink
scrcpy then falls back to OpenGL ES:
INFO: Renderer: opengles2
INFO: OpenGL version: OpenGL ES 3.2 Mesa 26.3.0-devel
This makes the rendering problem appear to disappear, but it is only because Zink fails and another renderer is used. It is therefore not considered a workaround for the Vulkan problem.
Vulkan loader / WSI information
The Vulkan loader selects:
with:
/data/data/.../libvulkan_freedreno.so
The direct Vulkan path requests Xlib surface support, so the affected path appears to involve:
scrcpy → SDL/Vulkan → Vulkan X11/Xlib WSI → Turnip/Freedreno → Adreno 830
MangoHud has been explicitly disabled during testing, with no improvement.
Relevant environment variables
The environment also contains:
ZINK_DESCRIPTORS=auto
VK_DRIVER_FILES=<Termux Mesa Freedreno ICD>
MESA_LOADER_DRIVER_OVERRIDE=zink
DISPLAY=:0
XDG_RUNTIME_DIR=<Termux runtime directory>
However, the issue is also reproducible when explicitly selecting:
scrcpy --render-driver=vulkan
so this does not appear to be exclusively a Zink issue.
Expected behavior
The Vulkan renderer should display the scrcpy video stream correctly without:
- corrupted frames,
- visual artifacts,
- stale/frozen frames,
- or incorrect image contents.
Actual behavior
The Vulkan renderer initializes successfully on Adreno 830, but the resulting image is corrupted and/or becomes frozen.
Possible area to investigate
I suspect the problem may be related to the Turnip Vulkan presentation/WSI path on A8xx, potentially involving:
- Vulkan swapchain handling,
- image layout transitions,
- synchronization between rendering and presentation,
- X11/Xlib WSI,
- dmabuf-backed images,
- buffer ownership/synchronization,
- or Adreno 830/A8xx-specific behavior.
I would appreciate guidance on whether this looks like a Turnip/Freedreno issue, a Vulkan WSI issue, or an interaction with Termux-X11/SDL.
I can provide additional TU_DEBUG, Vulkan loader, or GPU trace information if needed.
Minimal reproduction
VK_LOADER_LAYERS_DISABLE=MangoHud \
scrcpy --render-driver=vulkan -V debug --no-audio
GPU:
Mesa:
26.3.0-devel (git-98f3d6229d)
Vulkan:
Mesa/Turnip: Vulkan rendering artifacts on Adreno 830 in Termux-X11
Description
I am experiencing severe rendering artifacts when using Turnip/Freedreno Vulkan on an Adreno 830 (Snapdragon 8 Elite) GPU under Termux-X11 on Android.
The problem is reproducible with
scrcpywhen using the Vulkan renderer directly.The Vulkan device is detected correctly and Turnip initializes successfully, but the rendered output contains visual corruption/artifacts. In some configurations the displayed frame can also become frozen/stale.
Environment
DISPLAY=:026.3.0-devel (git-98f3d6229d)1.4.362freedreno_icd.aarch64.json/dev/kgsl-3d04.1The application being mirrored by scrcpy is running on a separate Android device.
Reproduction
Run:
To make sure MangoHud is not involved:
The relevant scrcpy output is:
The Vulkan loader detects the GPU as:
and loads:
from the Termux Mesa installation.
Actual behavior
scrcpysuccessfully creates a Vulkan renderer and detects the Adreno 830, but the displayed image contains severe rendering artifacts.Depending on the configuration, the output can also become stuck on an old frame instead of displaying the current video frames.
This does not appear to be a simple Vulkan initialization failure: the Vulkan renderer starts successfully and the texture is created.
Additional observations
With:
Turnip initializes successfully and GPU work is submitted, but the visual output can still be corrupted or remain frozen.
When using the default OpenGL/Zink path, enabling
TU_DEBUG=allcauses a different failure:scrcpy then falls back to OpenGL ES:
This makes the rendering problem appear to disappear, but it is only because Zink fails and another renderer is used. It is therefore not considered a workaround for the Vulkan problem.
Vulkan loader / WSI information
The Vulkan loader selects:
with:
The direct Vulkan path requests Xlib surface support, so the affected path appears to involve:
scrcpy → SDL/Vulkan → Vulkan X11/Xlib WSI → Turnip/Freedreno → Adreno 830
MangoHud has been explicitly disabled during testing, with no improvement.
Relevant environment variables
The environment also contains:
However, the issue is also reproducible when explicitly selecting:
so this does not appear to be exclusively a Zink issue.
Expected behavior
The Vulkan renderer should display the scrcpy video stream correctly without:
Actual behavior
The Vulkan renderer initializes successfully on Adreno 830, but the resulting image is corrupted and/or becomes frozen.
Possible area to investigate
I suspect the problem may be related to the Turnip Vulkan presentation/WSI path on A8xx, potentially involving:
I would appreciate guidance on whether this looks like a Turnip/Freedreno issue, a Vulkan WSI issue, or an interaction with Termux-X11/SDL.
I can provide additional
TU_DEBUG, Vulkan loader, or GPU trace information if needed.Minimal reproduction
GPU:
Mesa:
Vulkan: