Live data from Hacker News

Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

twitter.com

111–120 of 754 posts

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#111
post #91
post #75

Very impressive that they could do this so quickly because I have been on a similar project (porting TypeScript to Rust) for 5 months. But I guess I don't have access to Mythos and unlimited tokens. I'm also close to 100% pass rate. 99.6% at the time of writing. https://tsz.dev Rust is perfect for writing all of code using LLM. It's strict type system makes is less likely to make very dumb mistakes that other languag…

When Microsoft rewrote it in go, there was a comment from one of the leads that they chose it over rust because of the similarity in paradigms (garbage collection, etc), and that using rust would've been more difficult, requiring a lot of "hoop jumping". Now that you've done it... Thoughts?

Is GC useful for a static type checker? Or did they make a new runtime?

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#112
post #91

Earlier quoted context omitted.

When Microsoft rewrote it in go, there was a comment from one of the leads that they chose it over rust because of the similarity in paradigms (garbage collection, etc), and that using rust would've been more difficult, requiring a lot of "hoop jumping". Now that you've done it... Thoughts?

Yes indeed. More than 1 million lines of code (including tests) is jumping lots of hoops but with LLMs it's not as painful so you can just ask it to do the hard things. Example of a Claude Code session after 2 hours of "Crunching" that came out without results https://github.com/mohsen1/tsz/pull/4868 (Edit I force pushed to PR to solve the problem, you can see the initial refuse message in the initial version of PR d…

You should try GPT, I’d be really interested to hear if it works better. (Exclusively using GPT for systems work at $DAYJOB, but compare with opus every couple weeks and GPT consistently gives me better results)

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#113
Bun is going this route because their proposed fix wasn’t great. https://ziggit.dev/t/bun-s-zig-fork-got-4x-faster-compilatio...

Cannot imagine this agent rewrite had anyone review any the code (you can’t at that speed).

I’m positive this will go extremely well :p

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#114

Earlier quoted context omitted.

You could have said the same thing about steam power or electricity. And it’s not just an analogy: The magic of these things is in being universal information engines. You spend capital to build them, using well-understood, scalable techniques, plug them into electricity, and out comes value. My point is, there’s no chance of a “haves and have nots” emerging, any more than electricity turned out that way in the moder…

>My point is, there’s no chance of a “haves and have nots” emerging, any more than electricity turned out that way in the modern world. Energy costs vary widely across the world and that has enormous capacity for the economies of different countries and their industrial capacity.

https://worldpopulationreview.com/country-rankings/cost-of-e...

Electricity looks pretty even. Higher in Europe but they can afford that.

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#115

I think the industry is moving to English as the programming language, and specifications-context-tdd as the framework for building software. Many find it distasteful, and many finding liberating. I think it's broadly correlates with how they feel about expressing themselves in english vs say C++. As a side question, is there anyone who's using LLMs primarily in non-english mode to program? I suspect there's quite a…

Natural language doesn’t have the precision required for building systems. We already have languages for specifying systems precisely. It’s called “code”…

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#116
> and crashes and stability issues

inb4 .unwrap() / slice / etc hell + livelocks & deadlocks + resource leaks & toctou bugs + larger exposure to supply chain attacks

Still, ~1M LOC ported in a work week (400 LOC/min, wtf?) and almost all of it working is pretty wild. I hope the guy managed to maintain normal function, cause I found that getting into the flow but with AI is even more self-consuming and intoxicating than without it, which was already potentially rather rough.

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#117
post #22

What license is this ? Let me guess, its is no GPL...

Unlike the GNU coreutils rewrite in Rust, the Bun rewrite in Rust is being undertaken by the owners of the project. That said, yes, you’re correct that Bun isn’t GPL: https://github.com/oven-sh/bun?tab=License-1-ov-file

Hmm, that's unfortunate - why does so much Rust stuff seem to default to MIT/BSD ? Just because Mozilla used that for most of the Rust stuff ?

Do developers using Rust even know the difference ? Like how anyone can basically take all you work & base a proprietary fork on it with maybe saying "thanks" (attribution) if they feel like it ? :P

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#118
post #105

From 4 days ago: https://news.ycombinator.com/item?id=48019226 > I work on Bun and this is my branch > > This whole thread is an overreaction. 302 comments about code that does not work. We haven’t committed to rewriting. There’s a very high chance all this code gets thrown out completely. > > I’m curious to see what a working version of this looks, what it feels like, how it performs and if/how hard it’d be to get i…

cargo check reported over 16,000 compiler errors when I wrote that message. It could not print a version number or run JavaScript. I didn’t expect it to work this quickly and I also didn’t expect the performance to be as competitive. There’ll be a blog post with more details.

> I am so tired of worrying about & spending lots of time fixing memory leaks and crashes and stability issues. it would be so nice if the language provided more powerful tools for preventing these things.

haven't used zig...(only used rust)

but zig doesn't solve those problems?

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#119
post #32

Earlier quoted context omitted.

Exactly

This is exactly how Anthropic will market this rewrite towards companies thinking about doing more layoffs. 1 person did a rust rewrite that took 6 days that would have taken hundreds of engineers more than a year to do.

> 1 person did a rust rewrite that took 6 days that would have taken hundreds of engineers more than a year to do.

Even cheaper would just be to not do it in the first place. Was there a pressing need to rewrite it?

Re: Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc

#120
post #91

Earlier quoted context omitted.

When Microsoft rewrote it in go, there was a comment from one of the leads that they chose it over rust because of the similarity in paradigms (garbage collection, etc), and that using rust would've been more difficult, requiring a lot of "hoop jumping". Now that you've done it... Thoughts?

Yes indeed. More than 1 million lines of code (including tests) is jumping lots of hoops but with LLMs it's not as painful so you can just ask it to do the hard things. Example of a Claude Code session after 2 hours of "Crunching" that came out without results https://github.com/mohsen1/tsz/pull/4868 (Edit I force pushed to PR to solve the problem, you can see the initial refuse message in the initial version of PR d…

That might be opus 4.7 behaviour because I also get that all the time in the past few weeks. Also complex code base, but likely an order of magnitude simpler than yours.
Post reply on HN