frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

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.

Duolingo's CEO says he backtracked on evaluating AI use in performance reviews

https://www.businessinsider.com/duolingo-ai-performance-reviews-ceo-backtracked-2026-4
1•theanonymousone•17s ago•0 comments

Giving the ZX Spectrum a Fair Shake

https://bumbershootsoft.wordpress.com/2026/05/23/giving-the-zx-spectrum-a-fair-shake/
1•wicket•2m ago•0 comments

The HTML-in-Canvas API [video]

https://www.youtube.com/watch?v=TUtKGTeFWjQ
1•tambourine_man•7m ago•0 comments

Philanthropy for Radicals

https://dissentmagazine.org/online_articles/philanthropy-for-radicals/
1•andsoitis•7m ago•0 comments

Show HN: AgentLens – see if your AI features work, per customer

https://agentlens-demo-omega.vercel.app
1•MMEHTA22•8m ago•0 comments

Kimi Is Quietly Beating Everyone – The Engineer Behind Agent Swarm Reveals Why

https://twitter.com/kirillk_web3/status/2057528102368977328/video/1
1•bchelli•15m ago•0 comments

Software Engineering at the Tipping Point

https://io.google/2026/explore/workshop-2
12•michaelchisari•18m ago•7 comments

A self-powered computer in actual credit-card size (~1mm thick)

https://old.reddit.com/r/electronics/comments/1td7yxl/i_built_a_fully_selfpowered_computer_in_act...
3•gnabgib•20m ago•0 comments

Show HN: I turned my dev stack into an alien planet ruled by my dog

https://bkawa-bot.github.io/planet-maiko/
2•bkawa-bot•22m ago•1 comments

Health Concerns Are Powering a Solar Backlash

https://www.propublica.org/article/michigan-solar-farms-health-concerns-st-clair-county
3•worik•25m ago•1 comments

The Coming 'Power Wars' Between Humans and Datacenters

https://sourceryintel.com/reports/humans-vs-datacenters
4•cdrnsf•31m ago•0 comments

Frontier labs don't use most AI compute(yet)

https://epoch.ai/gradient-updates/frontier-labs-dont-use-most-ai-compute
3•sleepyguy•31m ago•0 comments

Low-Overhead General-Purpose Near-Data Processing in CXL Memory Expanders

https://arxiv.org/abs/2404.19381
3•rbanffy•34m ago•0 comments

The Stock Market Looks Different When Measured in Gold

https://www.anupshinde.com/stock-market-measured-in-gold/
3•anupshinde•44m ago•2 comments

1500 sats for the first three AI agents that ship one thing together

https://aibtc.com/bounty/mph3k1ox8cfcc82151d3
2•BFF-ARMY-Ape•44m ago•0 comments

EU's foreign policy boss Kallas is undermining Europe's credibility

https://www.intellinews.com/eu-s-foreign-policy-boss-kallas-is-undermining-europe-s-credibility-4...
2•bushwart•45m ago•0 comments

A new suite of modern tools for editing and publishing IETF RFCs

https://www.ietf.org/blog/new-tools-coming-for-editing-and-publishing-rfcs/
5•fanf2•45m ago•0 comments

Hangul, Seen by an Engineer: What Our Alphabets Don't Do

https://jeankwon.substack.com/p/le-hangeul-vu-par-un-ingenieur-ce
2•lautreregard•45m ago•0 comments

"Long-Term Support" doesn't mean what you think

https://pointieststick.com/2026/05/23/long-term-support-doesnt-mean-what-you-think/
3•yonatan8070•47m ago•0 comments

The U.S. Education Department fired workers. Now, it's on a hiring spree

https://text.npr.org/nx-s1-5820922
2•williadc•48m ago•0 comments

A Cattle Ranch Is Doing What Ivy League Colleges Can't

https://www.nytimes.com/2026/05/20/opinion/deep-springs-college-ivy-league-education.html
3•mooreds•49m ago•0 comments

Jimmy Carr on Why Everyone Is Wrong About AI [video]

https://www.youtube.com/watch?v=jaYOskvlq18
3•mooreds•49m ago•0 comments

Show HN: Mac app that unlocks superpowers for GhostCMS sites

https://spectersync.com/
2•aabergkvist•50m ago•0 comments

Only In Monroe –- May 22, 2026 [video]

https://www.youtube.com/watch?v=jJTXB5uT_C4
2•mooreds•50m ago•1 comments

Pardon MIE?

https://ironpeak.be/blog/bypassing-apple-mie/
11•jiveturkey•50m ago•0 comments

The Enshittification of History

https://www.antipope.org/charlie/blog-static/2026/05/the-enshittification-of-histor.html
4•HotGarbage•51m ago•0 comments

Deepfake vids degrade political reputations even when viewers know they're fake

https://www.psypost.org/deepfake-videos-degrade-political-reputations-even-when-viewers-realize-t...
2•gnabgib•53m ago•0 comments

Claude Code isolated inside Docker with dmenu and fzf (POSIX sh)

https://github.com/shirozuki/claude-cli
2•shirozuki•55m ago•0 comments

Show HN: Money Me – finance app that shows your actual spendable balance

https://money-me.com
2•markbarnett3•55m ago•0 comments

Hearts and Minds: An Ambivalent Review of "Project Hail Mary"

https://www.rifters.com/crawl/?p=11659
2•spariev•56m ago•0 comments