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•9mo ago

Comments

LegNeato•9mo ago
See also https://github.com/Rust-GPU/rust-gpu and https://github.com/rust-gpu/rust-cuda
ladyanita22•9mo 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•9mo ago
Microsoft indicated they are switching to SPIR-V from DXIL: https://devblogs.microsoft.com/directx/directx-adopting-spir...
skywal_l•9mo 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•9mo 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•9mo 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•9mo 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•9mo 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•9mo 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•9mo 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•9mo ago
The Zig compiler can compile C, though.

Amthropic CEO claims we are 1yr away where AI can do everything SWEs

https://twitter.com/i/status/2013682941201678804
1•thewhitetulip•6m ago•0 comments

Trump admin sought redactions on China war game report warning

https://www.foxnews.com/politics/trump-admin-sought-redactions-key-china-war-game-report-warning-...
2•mudil•13m ago•0 comments

Vibe Coding Is Over, Now Just "Coding"

https://upstreamutopia.com/articles/?id=20260121-060942-vibe-coding-is-over,-now-ju
1•upstreamutopia•13m ago•0 comments

EU plans cybersecurity overhaul to block foreign high-risk suppliers

https://www.bleepingcomputer.com/news/security/eu-plans-cybersecurity-overhaul-to-block-foreign-h...
2•Yularar•16m ago•0 comments

Why neither Asia nor the US has produced a rival to ASML

https://www.ft.com/content/e47375fb-8c9f-4a4f-8526-8d46ededb805
2•perihelions•20m ago•0 comments

Curl removes bug bounties because of AI slop

https://etn.se/index.php/nyheter/72808-curl-removes-bug-bounties.html
2•jnord•20m ago•0 comments

Newbridge Cutlery to cease production of silver-plated tableware

https://www.rte.ie/news/business/2026/0120/1554085-newbridge-cutlery-company-to-close-factory/
1•austinallegro•25m ago•0 comments

Wolfi: Linux OS by Chainguard closed now for OSS

https://github.com/orgs/wolfi-dev/discussions/77550
1•shyim•25m ago•1 comments

Understanding Modern AI Is Understanding Embeddings: A Guide for Non-Programmers

https://sgnt.ai/p/embeddings-explainer/
2•dekervin•28m ago•0 comments

Show HN: Upgrade from Ralph to Eric for a more autonomous AI

https://dbuild.dev/blog/black-hole-from-ralph-to-eric/
1•Dbuild•28m ago•0 comments

Token Issuer Metadata: A Proposal for Config-as-Code SSO

https://docs.meetchar.ai/explanation/token-issuer-metadata
1•miguelspizza•29m ago•0 comments

88x31 badge for gen-AI free, 100% human-made works

https://aspiz.uk/100percenthuman/
1•aspizu•29m ago•2 comments

Hootsuite looking to work with ICE to 'build trust'

https://www.theglobeandmail.com/business/article-hootsuite-canada-vancouver-ice-social-media-cont...
1•petethomas•31m ago•0 comments

Alice and Bob in Wonderland - Identity and authority without servers (2024)

https://herbcaudill.com/words/20240602-local-first-auth
1•apitman•36m ago•0 comments

Implementing Dino from Scratch

https://logits.bearblog.dev/implementing-dino-from-scratch/
2•tgnk2341•37m ago•0 comments

Kleis: Structural Modeling with Symbolic Math and Types

https://kleis.io/
1•eatik•38m ago•0 comments

UK government considers social media ban for children

https://www.ft.com/content/15298c8c-d937-419c-8c9d-191589302704
2•1vuio0pswjnm7•39m ago•1 comments

Creating a Domain Specific Language with Roslyn

https://www.themacaque.com/2026/01/17/dsl-with-roslyn.html
1•azhenley•42m ago•0 comments

Why your power bill is spiking faster than a nearby data center's

https://www.washingtonpost.com/climate-environment/2026/01/15/power-electricity-cost-data-centers/
1•1vuio0pswjnm7•43m ago•0 comments

When to Use GenAI: A Practical Decision Framework

https://thenewstack.io/when-to-use-genai-a-practical-decision-framework/
1•bhaskarkollu•44m ago•0 comments

Governors confront electricity's rising costs as data centers expand

https://www.washingtonpost.com/business/2026/01/16/pjm-data-centers-electricity-bipartisan/
1•1vuio0pswjnm7•45m ago•0 comments

The Link List – Jan 2026 (Newsletter)

https://www.thelinklist.dev/blog/2026-01/
1•cwisecarver•47m ago•0 comments

Deutsche Bank says the 'honeymoon is over' for AI – CNBC

https://www.cnbc.com/2026/01/20/deutsche-bank-says-the-honeymoon-is-over-for-ai.html
5•g-b-r•48m ago•2 comments

Show HN: LLM-Powered Writing: Trends, Advantages, and Curation to Notion

https://blackeagle.cozyai.chat/blog/curate-to-notion.html
1•cuteeaglet•49m ago•0 comments

After Every Clue

https://www.thenation.com/article/society/seymour-hersh-cover-up/
1•samclemens•53m ago•0 comments

Show HN: Metric-Registry

https://metric-registry.base14.io/
1•rnjn•53m ago•0 comments

Best Curved Text Generator: MockoFun

https://www.mockofun.com/tutorials/curved-text-generator/
1•codingdudecom•57m ago•0 comments

Algorithms for Optimization, Decision Making, and Validation (3 Books)

https://algorithmsbook.com
1•thetwentyone•58m ago•0 comments

Show HN: Train Core ML models from the command line

https://github.com/schappim/createml-cli
1•schappim•59m ago•0 comments

Show HN: MCP Chatbot

https://github.com/mikesmallhelp/chatbot-and-mcp-servers
1•mikesmallhelp•1h ago•0 comments