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

Comments

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

Choosing a vector database for ANN search at Reddit

https://old.reddit.com/r/RedditEng/comments/1ozxnjc/choosing_a_vector_database_for_ann_search_at/
1•jonbaer•2m ago•0 comments

Billionaire warns 'last time to buy' as Bitcoin crashes

https://finance.yahoo.com/news/billionaire-warns-last-time-buy-172037475.html
1•MarcoDewey•3m ago•0 comments

Valar Atomics Says It's the First Nuclear Startup to Achieve Criticality

https://www.wired.com/story/valar-atomics-says-its-the-first-nuclear-startup-to-achieve-criticality/
2•MarcoDewey•6m ago•0 comments

Intuit signs $100M+ deal with OpenAI to bring its apps to ChatGPT

https://techcrunch.com/2025/11/18/intuit-signs-100m-deal-with-openai-to-bring-its-apps-to-chatgpt/
5•jimt1234•13m ago•1 comments

Crypto Could Trigger the Next Financial Crisis

https://www.theatlantic.com/ideas/2025/11/cryptocurrency-economy-financial-crisis/684960/
3•JumpCrisscross•19m ago•0 comments

Loose wire on ship may have led to Baltimore Key Bridge collision and collapse

https://www.cbsnews.com/baltimore/news/ntsb-key-bridge-collapse-probable-cause-dali-maryland/
2•1659447091•22m ago•0 comments

Crypto got everything it wanted. Now it's sinking.

https://www.economist.com/finance-and-economics/2025/11/18/crypto-got-everything-it-wanted-now-it...
4•petethomas•23m ago•0 comments

How the $128M Balancer Exploit Happened

https://harrydonnelly.substack.com/p/how-the-128m-balancer-exploit-happened
1•gowthamhn10•27m ago•0 comments

Show HN: Startup Simulator

https://startup-simulator-phi.vercel.app/
1•paperplaneflyr•30m ago•0 comments

Startup Mode Engineering

https://moduloware.ai/blog/engineering-approach-startup-mode-vs-big-tech-mode/
1•zuzuen_1•31m ago•0 comments

New method spots signs of Earth's primordial life in ancient rocks

https://www.reuters.com/science/new-method-spots-signs-earths-primordial-life-ancient-rocks-2025-...
2•c420•32m ago•0 comments

Baby Shark: How a 90-second clip created a $400M business

https://www.bbc.com/news/articles/cn8xzgw623go
4•RickJWagner•33m ago•1 comments

The Hot New Dubai Restaurant Run by an AI Chef

https://www.bloomberg.com/news/articles/2025-11-18/dubai-s-hottest-new-restaurant-woohoo-is-run-b...
1•petethomas•38m ago•0 comments

Meth Rx

https://desoxyn.com/
2•brianhama•40m ago•2 comments

Honest Take on Amazon Layoffs

https://old.reddit.com/r/amazonemployees/comments/1ox0zwj/honest_take_on_layoffs
5•gpi•49m ago•0 comments

Don't Refactor Like Uncle Bob (Second Edition)

https://theaxolot.wordpress.com/2025/11/18/dont-refactor-like-uncle-bob-second-edition/
1•Axol•52m ago•0 comments

Max Out Your 401k

https://awealthofcommonsense.com/2025/11/max-out-your-401k/
2•raw_anon_1111•58m ago•0 comments

Top 200 Most Common Passwords 2025

https://nordpass.com/most-common-passwords-list/
4•ChrisArchitect•58m ago•0 comments

Valar Atomics: First Startup to Split Atom in Cold Criticality Test

https://news.ycombinator.com/from?site=twitter.com/isaiah_p_taylor
1•mariecurie•1h ago•1 comments

AWS announces flat-rate pricing plans for website delivery and security

https://aws.amazon.com/about-aws/whats-new/2025/11/aws-flat-rate-pricing-plans/
8•arkon_hn•1h ago•6 comments

Game Boy Advance SP with 162Wh Replaceable Battery

https://old.reddit.com/r/Gameboy/comments/1oiwk9g/gba_sp_with_162000mwh_replaceable_battery/
2•gnabgib•1h ago•0 comments

Zoomers are officially worse at passwords than 80-year-olds

https://www.theregister.com/2025/11/18/zoomer_passwords/
5•pseudolus•1h ago•2 comments

Middle-class pulls back, alarming retailers: 'signs of real distress'

https://www.businessinsider.com/middle-class-shoppers-pull-back-warning-signs-economy-home-depot-...
8•zerosizedweasle•1h ago•0 comments

SupaPwn: Hacking Our Way into Lovable's Office and Helping Secure Supabase

https://www.youtube.com/watch?v=jAWDq6bSOBw
3•zeyu1337•1h ago•1 comments

YouTube Unblocked – Safe Ways to Watch at School, Work

https://www.goproxy.com/blog/youtube-unblocked/
2•rgggggggg•1h ago•0 comments

Asymmetry of Verification and Verifier's Rule

https://www.jasonwei.net/blog/asymmetry-of-verification-and-verifiers-law
3•gmays•1h ago•0 comments

Context Management in Amp

https://ampcode.com/guides/context-management
1•gmays•1h ago•0 comments

Visual Studio Code Private Marketplace

https://code.visualstudio.com/blogs/2025/11/18/PrivateMarketplace
2•soheilpro•1h ago•1 comments

What If 'America First' Appears to Work?

https://www.theatlantic.com/international/2025/11/trump-foreign-policy/684969/
2•petethomas•1h ago•5 comments

Microsoft making major changes to how drivers are built, verified on Windows 11

https://www.windowscentral.com/microsoft/windows-11/microsoft-is-raising-the-bar-and-making-major...
4•thunderbong•1h ago•0 comments