Hacker News Viewer

Zig Libc

by ingve on 2/2/2026, 5:28:19 PM

https://ziglang.org/devlog/2026/#2026-01-31

Comments

by: xrd

"Abolish ICE" at the bottom. Obviously a Bad Bunny fan, as I am.

2/2/2026, 10:29:34 PM


by: OsamaJaber

250 C files were deleted. 2032 to go. Watching Zig slowly eat libc from the inside is one of the more satisfying long term projects to follow

2/2/2026, 10:46:04 PM


by: jzelinskie

Cool idea, for sure, but I can't help but wonder: for the code that's been ported, is there a concern that you'd have to perpetually watch out for CVEs in glibc/musl and determine if they also apply to the Zig implementations?

2/2/2026, 9:54:56 PM


by: meisel

&gt; It’s kind of like enabling LTO (Link-Time Optimization) across the libc boundary, except it’s done properly in the frontend instead of too late, in the linker<p>Why is the linker too late? Is Zig able to do optimizations in the frontend that, e.g., a linker working with LLVM IR is not?

2/2/2026, 10:45:35 PM


by: nesarkvechnep

&quot;Furthermore, when this work is combined with the recent std.Io changes, there is potential for users to seamlessly control how libc performs I&#x2F;O - for example forcing all calls to read and write to participate in an io_uring event loop&quot;<p>This is exciting! I particularly care more about kqueue but I guess the quote applies to it too.

2/2/2026, 9:36:31 PM


by:

2/2/2026, 8:35:58 PM


by: cies

Super cool project.<p>I expect a lot of C code may be quite mechanically translated to Zig (by help of LLMs). Unlike C-&gt;Rust or C-&gt;C++, where there&#x27;s more of a paradigm shift.

2/2/2026, 9:30:43 PM


by: self_awareness

[flagged]

2/2/2026, 10:53:25 PM


by: nemo1618

This strikes me as a <i>very</i> agent-friendly problem. Given a harness that enforces sufficiently-rigorous tests, I&#x27;m sure you could spin up an agent loop that methodically churns through these functions one by one, finishing in a few days.

2/2/2026, 9:52:36 PM