r/vulkan • u/QwertyChouskie • 5h ago
r/vulkan • u/pablogonz12 • 17h ago
Translating a console's RDNA2 shader ISA straight to SPIR-V: looking for people who know SPIR-V and subgroups
I work on Scarlight, an open-source (GPL-3.0) compatibility tool that runs Xbox Series games on Linux through Proton, drawing with Mesa's Vulkan drivers. Today the console's RDNA2 shaders are recompiled to DXIL and go through vkd3d-proton and dxil-spirv. An experimental translator now goes from the console's instruction words straight to SPIR-V instead:
- 223 of the 442 compute programs we have emit SPIR-V that passes spirv-val and builds a real RADV pipeline, with no failures among those 223.
- Memory goes through buffer device addresses and push constants, no descriptor heaps; images bind one site per image instruction, and the view carries the console's format.
- The hard parts left: typed buffer formats, exact DPP and lane-shuffle semantics as subgroup ops, and per-lane EXEC as structured control flow instead of a dispatcher loop.
If you know SPIR-V, subgroup operations or VK_EXT_descriptor_buffer, I would value review or help. The tests are hand-built instruction words, so you do not need any game files: https://github.com/pablogonz12/Scarlight/pull/120
Disclosure: this project is written with AI assistance (Claude and DeepSeek), reviewed and tested by me; the numbers above come from offline checks on one RX 9070 XT.
r/vulkan • u/SnooStories6404 • 1d ago
Ray tracing large, dynamic worlds with RT-MLAS
gpuopen.comr/vulkan • u/Queasy_Total_914 • 1d ago
Why SPIR-V Cross rejects to return a value for Bool types here?
chromium.googlesource.comr/vulkan • u/Delicious_Abies_9708 • 1d ago
AI content [Project] MLIR-to-Vulkan HAL Prototype — looking for feedback on [lowering / architecture]. Ai was used on this prototype
reddit.comr/vulkan • u/LunarGInc • 2d ago
LunarG at Vulkanised 2027 + Real-Time Shading Symposium
Happy to announce that LunarG will present six talks at these two events in February:
- Descriptor Heaps debugging
- SyncVal 2027: Synchronization Evolved
- VK_KHR_shader_abort & shader debugging
- KosmicKrisp — Vulkan 1.4-conformant on Apple silicon via Metal
- Shader Objects
- SPIRV-Integrated Teste
Vulkanised: Feb 8–10, 2027 RTSS: Feb 11–12, 2027 Venue: Howest University / The Penta, Kortrijk
If you’re working on modern Vulkan, validation, debugging, or cross-platform (especially macOS) GPU software, this is a must-attend week.
Full details:
https://www.lunarg.com/lunarg-at-vulkanised-2027-real-time-shading-symposium/
r/vulkan • u/Human-Coffee2436 • 1d ago
AI content [POC, Experiment, AI, Slop?] QtPhase — Retained Hybrid CPU / Vulkan 1.3 Renderer for Unmodified Qt Widgets
Hello,
I was playing around with how far we could push GUI rendering to have the snappiest desktop experiences. Do we actually have to rewrite legacy GUI toolkits from scratch to get modern GPU-accelerated latency (like Zed's GPUI), or can we retrofit a retained GPU scene graph underneath stock Qt Widgets without changing a single public API? Initial idea was to make the CPU do rasterizing while Vulkan was waking up, then switiching pipelines the next frame. This worked, and has evolved from there into a complex project with multiple pluggable algorithms that govern which pipeline to use.
Full disclosure: I'm not a GPU/Vulkan engineer — this is a vibe-coded research POC on qtbase (v6.11.2, Linux Wayland) and I don't plan on maintaining a Qt fork. I'm sharing the code, demos, benchmarks, and failed experiments hoping competent Qt/KDE/graphics folks can tear it
apart, test it on other GPUs, or steal the ideas that worked.
What it actually does under stock QWidget**:**
• Zero-wait CPU wl_shm boot → atomic Vulkan 1.3 DMA-BUF cutover on the exact same wl_surface (no VkSwapchainKHR resize stalls — 256 px-bucketed tiled DMA-BUFs + wp_viewport).
• **Retained per-**QWidget scene arena (moving widgets updates a 32-byte transform with 0 paintEvent()s) + HarfBuzz 15 hb-gpu analytical curve text (no glyph-atlas thrash) + single-pass SDF uber-shader.
• 11 pluggable CPU-vs-GPU scheduling policies (QT_PHASE_POLICY=...) — including racing CPU vs. GPU, cadence-based GPU sleep, a contextual bandit learner, and widget-aware routing (e.g., keeping popups/tooltips on CPU wl_shm in 0.53 ms with 0 GPU rings).
Unmodified stock KDE apps on Wayland (AMD Renoir iGPU, 1.5× DPR, Breeze Dark):
• Dolphin: 6.8 ms resize vs 29.0 ms upstream (4.3× faster), 0.71–0.85 ms Key_Down nav
• Okular (20-page PDF): 2.2–2.6 ms resize vs 23.9 ms (9–11× faster), 2.0 ms smooth scroll vs 7.2 ms (3.6× faster)
• Konsole: 10.5 ms resize vs 27.6 ms (2.6× faster)
• Cold startup: no regression (225.6 ms vs 234.6 ms Dolphin)
What went wrong / got falsified (all in the README):
• Okular Peak RSS jumped +165 MB (Vulkan driver + DMA-BUF rings/staging — needs work).
• Several "smart" dynamic policies got crushed by reality (e.g., demoting heavy fallback canvases to CPU was 2× slower due to double-rasterization; routing Konsole's dense text to per-widget CPU raster was 2× slower than native hb-gpu).
• Only tested on an AMD iGPU so far — would love to see what happens on NVIDIA, Intel, dGPUs, and llvmpipe.
Full story, architecture map, 7-stage CPU↔GPU pixel-diff heatmaps, all 11 policy breakdowns, and reproducible benchmark scripts are in the repo:
r/vulkan • u/PhysicsDisastrous462 • 4d ago
Hierarchos-Native v0.2.5 is finally out! P3 WMMA update
so, after quite a bit of work since the v0.2.0 release, i've finally managed to get v0.2.5 published!
for anyone who followed the previous release, v0.2.0 was where i first introduced the opt-in RDNA3 WMMA implementation. since then i've been working on improving the Full FP16 path, specifically its numerical accuracy and performance, without having to sacrifice the execution structure that was already working.
the biggest change in this release is something i've been calling P3.
previously, the Full FP16 WMMA kernel merged its eight accumulator-bank partials using multiple intermediate FP16 additions. this meant that the result was rounded to FP16 several times along the way. P3 changes that final merge so all eight partials are summed in FP32, with just one final rounding to FP16.
the actual two-wave workgroup structure, K-slice stream, bank assignment, staging, cooperative multiplication and barriers are all preserved. i wanted to improve the accuracy of the final result without having to redesign the kernel all over again.
some of the results from the new qualification:
- 37/37 numerical gates passed across all eight qualification seeds.
- 32/32 preserved K=96 outputs were bit-identical to the previously qualified P3 GPU results.
- REF64F16 maximum error improved from
0.03035259to0.02593803. - 31 of 32 cases improved, with zero cases getting worse.
- The maximum tile16 distance is
0.03125, meeting the existing hard numerical limit.
i also ran another full performance sweep. this time using 24 paired measurement blocks per workload, GPU timestamps, and corrected 95% confidence intervals.
the measured improvements against the preserved Main kernel baseline were:
2048×768×2048— 1.0243×512×2048×768— 1.1246×512×768×768— 1.1163×128×8192×768— 1.2722×
all four protected workloads passed independently, including the lower bounds of their confidence intervals. the largest measured improvement was around 27%.
just to clarify, these are per-dispatch GPU GEMM measurements, not end-to-end training speedups. i don't want to imply that an entire training run is suddenly 27% faster when that isn't what was measured.
there were some other changes too.
i tightened up the production dispatch admission so the profitability predicate is checked against each actual batch, rather than relying only on the maximum batch size supplied when creating the projection. the existing 16,000,000 MAC profitability floor has not changed.
i also went through the actual portable binaries and verified that they dispatch the P3 kernel when an eligible workload is supplied. the packaged trainer produced 8 cooperative P3 dispatches, and the packaged logits executable produced another 3. disabling WMMA resulted in zero cooperative dispatches, as expected.
the numerical comparison for the packaged logits test covered 262,144 finite elements, with a maximum absolute difference of 0.000738330 and RMS difference of 0.000122237.
the new release is available as a portable Windows x64 package too.
i've included seven executables, and the package was built with a statically linked MSVC runtime. there's no need to install Rust, Cargo, Python, PyTorch, Visual Studio, or the MSVC redistributable just to run it.
you will still need a compatible Vulkan-capable GPU driver and the Vulkan runtime loader. model weights aren't included.
one thing i want to make clear is that WMMA is still opt-in globally. the default is still off, and you have to explicitly select full-fp16 to use the P3 path. P3 is simply the default implementation within that mode. the Mixed precision path is separate and hasn't been replaced.
the hardware qualification was performed on my AMD Radeon Graphics adapter, PCI ID 1002:15bf (RDNA3 / Phoenix). i haven't qualified this on every RDNA3 GPU, RDNA3.5, RDNA4, Intel or NVIDIA hardware, so please don't assume universal compatibility.
there are still things i haven't been able to test, including independent clean-machine/second-device acceptance, GUI interaction, Windows 10 acceptance, and code signing. the executables are currently unsigned.
anyway, i'm really happy to finally have this one out. v0.2.0 was the first public release of the WMMA implementation, and v0.2.5 is a pretty substantial improvement to that foundation. a lot of time went into checking that the numerical improvements were real, that the performance was actually measurable, and that the distributed binaries were doing what they were supposed to do.
Release: https://github.com/necat101/Hierarchos-Native/releases/tag/v0.2.5
Source: https://github.com/necat101/Hierarchos-Native
thank you to everyone who's been following the project, testing things, reporting issues, or just keeping an eye on development. it genuinely means a lot! thank you so much everyone!! :3 also, sorry for the AI posts lately, I've been trying to save as much time as possible to work on the project itself due to live events getting tough! this one is completely human written! :3
Vulkan Dynamic Lighting - Directional, Point, Spot Lights, Tonemapping & glTF Lights
Hey, here's the next video in my vulkan series, focusing on dynamic lighting, various light types, gltf lights and tonemapping.
r/vulkan • u/PeterBrobby • 6d ago
Physics Programming Part 5: Spring Physics
youtu.beI explain the mathematics underpinning spring mechanics then implement a solution in C++ using a net as an example. Implementation begins at 10:05. Feedback is welcome.
r/vulkan • u/Delicious_Abies_9708 • 7d ago
Anyone think it would be cool to create VUDA(CUDA) using vulkan? Its a big task I know but probably will be a proof of concept thing to begin with.
I think it would be cool, I mean cuda is the holy grail of GPU programming and we're at a point now where reverse engineering it or whatever could possibly be done. What do y'all think? Am I stupid?
r/vulkan • u/Delicious_Abies_9708 • 7d ago
vknumpy is my next attempt at something useful. A real drop in NumPy but using gemm and blas from llama.cpp and adding remaining functions over time slowly
github.comIf someone wants to help out just read the readme and see if you want to vibe code with me lol..seriously though there is no dataframe package for vulkan so we will build that on top of this https://github.com/billyblackburn/vknumpy/blob/main/docs/ROADMAP.md
r/vulkan • u/SnooSquirrels9028 • 7d ago
What are some initial architectural decisions to be made before start building a professional graphics engine ?
reddit.comr/vulkan • u/Delicious_Abies_9708 • 9d ago
AI content Initial VuPy release: Numpy/CuPy-like GPU array library backed by vulkan
github.comAI was used for this project . gemini 4 hydrogen.
r/vulkan • u/tuxdance • 10d ago
cudash - run Cuda and Vulkan compute graphs the easy way
I took my problem - Vulkan compute needs a lot of boilerplate - and ran with it to understand what I need to do to have it run a simple way with capabilities like Cuda and Cuda Graph.
What I did
- Kernel arguments are plain pointers, with no descriptor sets, using buffer device addresses.
- Streams map onto the Vulkan queue, with automatic ordering between streams.
- Graph capture records command buffers.
- Slang compiles the same source to SPIR-V and PTX to help me check if my Vulkan Compute and Cuda parts are doing the same.
I'm currently very happy with it for my use cases so I'd like to share it and get some feedback: Any Vulkan pitfalls I’ve missed? (What) would you want a layer like this to do your compute?
r/vulkan • u/Temporary_Accident53 • 11d ago
Native Vulkan ar / 3d Viewer for android : Raster and Ray tracing Hybrid
Hi..
I am in the process of making an ar viewer in vulkan for android to run natively.
For rendering i am following a hybrid structure mixing Raster IBL approximations and path tracing, the gems are traced with tracing the ray directions and metals with split sum approximations and only traced for inter reflections once the movement stops.
The engine is general purpose focusing on jewellery embedded in an sdk to integrate with 3 lines of kotlin.
The c++ engine takes care of initializing the context based on the hardware capabilities like vulkan 1.1 support, hardware RT cores and compute path fallbacks.I have tested on mali, adreno and xclipse(Exynos) gpus.
Most of the optimization i did are around the memory and cache coherency on mobile gpus, since last couple of years got really obsessed with graphics maths and its implementations but i come from c++ background so pls let me know about the visuals of the same and how can i improve further.
It is closed source for now but happy to share any details to any one interested.
Thanks
r/vulkan • u/Few-Flamingo-6678 • 10d ago
Mutter Vulkan backend: release 1.2 improves GPU memory management
reddit.comr/vulkan • u/Delicious_Abies_9708 • 10d ago
vulkan-py easymode. all the boilerplate is in easy.py. vulkan-py fork https://github.com/billyblackburn/vulkan-py-easy/tree/main
Example Line-Count Reduction
| Example | Before | After | What changed |
|---|---|---|---|
examples/vector_add.py | ~300+ lines (raw vulkan_py) | ~57 lines | Uses get_default_device(), create_buffer_with_data(), create_shader_module(), dispatch() |
examples/hello_triangle.py | 534 lines | 71 lines | Uses GraphicsDevice, create_render_pass(), create_graphics_pipeline(), create_framebuffers(), FrameSync |
examples/lighting_demo.py | 1,860 lines | 815 lines | Uses GraphicsDevice, create_depth_resources(), create_uniform_descriptor_sets(), create_graphics_pipeline(), begin_render_pass() |