frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Zig and GPUs

https://alichraghi.github.io/blog/zig-gpu/
57•Cloudef•1y ago

Comments

LegNeato•1y ago
See also https://github.com/Rust-GPU/rust-gpu and https://github.com/rust-gpu/rust-cuda
ladyanita22•1y ago
Surprisingly, it seems this project just supports Spir-V and PTX, but not DXIL or AMDGCN.

I say surprisingly, because I'd expect Rust support to be more mature than Zig's.

lostmsu•1y ago
Microsoft indicated they are switching to SPIR-V from DXIL: https://devblogs.microsoft.com/directx/directx-adopting-spir...
skywal_l•1y ago
I am a complete noob in GPU but is AMDGCN the older generation with the new one being RDNA? If you generate a binary for AMDGCN, will it run on the newest cards?

Also, I though that these GPU ISAs were "proprietary". I wonder how reliable the binary generation can be.

AliChraghi•1y ago
AMD ISAs are changing for almost every generation so LLVM[1] continues to keep the architecture name "amdgcn" and handle the variation based on the model flag (e.g., -mcpu=gfx1030 for RDNA2, -mcpu=gfx1100 for RDNA3).

> I though that these GPU ISAs were "proprietary"

PTX spec[2] is publicly available but the actual hardware assembly (SASS) is not. Although i believe Nsight allows you to view it.

1. https://llvm.org/docs/AMDGPUUsage.html#processors

2. https://docs.nvidia.com/cuda/parallel-thread-execution

imtringued•1y ago
If LLVM can target AMD GPUs what exactly prevents AMD and ROCm from supporting all the damn GPUs?

At this point I'm convinced that the real problem with AMD GPUs isn't necessarily the compilers (although they do produce mediocre code) or even the hardware itself, but some crappy C++ driver code that can't handle running graphics and compute at the same time. The datacenter GPUs never had to run graphics in the first place, so they are safe.

slavik81•1y ago
In my experience, the compiler, compute drivers, and HIP runtime work fine for all modern AMD GPUs. The only parts of the stack that don't run on all GPUs are the math and AI libraries. And that is mostly because AMD isn't building and testing those libraries for unsupported GPUs. The actual work required to enable functional support was straightforward enough that I ported them myself when packaging the libraries for Debian. Though, I had a lot of help on the testing.

See the Debian Trixie Supported GPU list: https://salsa.debian.org/rocm-team/community/team-project/-/...

SomaticPirate•1y ago
While I admire the work of hobbyists it still looks like C/C++ will be the default until a GPU vender makes the decision to support these libraries.

From my understanding, Vulkan and OpenGL are nice but the true performance lies in the specific toolkits (ie CUDA, Metal).

Wrapping the vendor provided frameworks is liable to break and that isn't tenable for someone who wants to do this on a professional basis.

pjmlp•1y ago
They also miss that on CUDA's case it is an ecosystem.

Actually it is C, C++, Fortran, OpenACC and OpenMP, PTX support for Java, Haskell, Julia, C#, alongside the libraries, IDE tooling and GPU graphical debugging.

Likewise Metal is plain C++14 plus extensions.

On the graphics side, HLSL dominates, following by GLSL and now slang. There are then MSL, PSSL and whatever NVN uses.

By the way, at GTC NVIDIA announced going all in with Python JIT compilers for CUDA, with feature parity with existing C++ tooling. There is now a new IR for doing array programming, Tile IR.

dismalaf•1y ago
I don't quite get this comment.

This is supposed to be used in place of CUDA, HIP, Metal, Vulkan, OpenGL, etc... It's targeting the hardware directly so doesn't need to be supported as such.

The site also seems to clearly state it's a work in progress. It's just an interesting blog post...

slowmovintarget•1y ago
The Zig compiler can compile C, though.

Back to classics: dynebolic IV released

https://news.dyne.org/dynebolic-iv-is-out-in-da-wild/
1•heptazoid•1m ago•0 comments

Interpreter spill stack on the process stack and trait

https://xnacly.me/posts/2026/keeping-interpreter-stack-on-thread-stack/
1•ibobev•3m ago•0 comments

Additional authentication assurance in FusionAuth without using step-up MFA

https://fusionauth.io/community/forum/topic/3244/additional-authentication-assurance-without-usin...
1•mooreds•4m ago•0 comments

Fun with low-rank vocab matrices (and a bonus test loss reduction)?

https://www.gilesthomas.com/2026/10/low-rank-vocab-matrices
1•ibobev•4m ago•0 comments

World’s oldest shipwreck discovered off coast of Turkey

https://www.independent.co.uk/news/science/archaeology/oldest-shipwreck-turkey-coast-discovery-b3...
2•geox•4m ago•0 comments

Making 1,750 programmable PCB badges for a hackathon

https://va3ndf.com/blog/hacker-badges/
1•va3ndf•5m ago•0 comments

America's Crisis of Social Connection, with Adam Grant [audio]

https://www.theringer.com/podcasts/plain-english-with-derek-thompson/2026/10/13/americas-crisis-o...
2•mooreds•6m ago•0 comments

Trust me i built DAMA,cyber threat console TRUEE2E soon

https://www.cpcdev.it/
1•cpcd3v•6m ago•0 comments

Conversations: Doorknobs

https://www.therapybytes.net/home/conversations-doorknobs
1•mooreds•6m ago•0 comments

Will China overtake the US in the AI race? (In charts)

https://salvozappa.com/will-china-overtake-the-us-in-the-ai-race.html
1•salvozappa•6m ago•0 comments

Why 'externalized' proofs of cyclic trait impls does not work

https://smallcultfollowing.com/babysteps/blog/2026/10/10/modular-vs-external-proofs/
1•ibobev•7m ago•0 comments

PejavaDock – many macOS docks on any edge of any display, with widgets

https://dock.pejava.com/
1•romankh•7m ago•0 comments

CPI-U rises 7.2% annualized in September (3.7% YoY)

https://www.bls.gov/news.release/cpi.nr0.htm?
1•JumpCrisscross•8m ago•0 comments

Hacking the Go compiler to efficiently map IPv4 to IPv6

https://vincent.bernat.ch/en/blog/2026-go-netip-addrto6
1•surprisetalk•9m ago•0 comments

Anthropic's 2021 Research Roadmap [pdf]

https://i.smitop.com/concise-research-roadmap.pdf
1•yusufozkan•10m ago•0 comments

A Sane JSON Facade for App Store Connect

https://parsequerade.mainbrella.com
2•cs1996•11m ago•0 comments

Has the AI Boom Impacted the U.S. Current Account?

https://libertystreeteconomics.newyorkfed.org/2026/10/has-the-ai-boom-impacted-the-u-s-current-ac...
1•jnord•11m ago•0 comments

Show HN: Llms.py – Lightweight, self-hosted ChatGPT alternative to OpenWebUI

https://llmspy.org
1•mythz•14m ago•0 comments

Ukraine accuses SpaceX of crippling drone missions as ties with US worsen

https://www.reuters.com/business/media-telecom/ukraine-accuses-spacex-crippling-drone-missions-ti...
3•JumpCrisscross•15m ago•0 comments

Ask HN: Why not allow AI-written posts with a "human disclosure" section?

2•amichail•15m ago•0 comments

Show HN: Tunr- pivotted from a localhost tunnel to home for vibecoded apps

https://github.com/tunr-dev/tunr
1•metvural•18m ago•0 comments

Show HN: Code Like It's 198x

https://code198x.com/
1•stevehill1981•18m ago•1 comments

Ynotbit 0.7.0 – a desktop Bitmessage client (Qt, MIT)

https://github.com/yshurik/ynotbit
1•yshuri•20m ago•0 comments

Nixmap – An interactive map of Nix concepts and their prerequisites

https://vimjoyer.com/nixmap/
1•taheris•20m ago•0 comments

Biham-Middleton-Levine traffic model

https://en.wikipedia.org/wiki/Biham%E2%80%93Middleton%E2%80%93Levine_traffic_model
1•fzeindl•21m ago•0 comments

Show HN: Google, Outlook and iCloud in one superpowered calendar

https://www.calendar0.app
1•aafloarei•22m ago•2 comments

DeepMind and Singapore fine-tune an on-device Gemma model for scam detection

https://deepmind.google/blog/on-device-ai-scam-detection-mddi/
3•acossta•24m ago•1 comments

Men with Queer Nerves: The Jumping Frenchmen of Maine

https://publicdomainreview.org/essay/the-jumping-frenchmen-of-maine
1•acossta•26m ago•0 comments

Show HN: Organ – Run your company with autonomous agents

https://organ.app/start
1•johmu•27m ago•0 comments

AI CEO Interviews be like

https://www.youtube.com/watch?v=DlTNN0gvkLM
1•amai•27m ago•0 comments