Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

it's 20 million lines of code.


Right, but you don't have to rewrite it at once. There are certain areas of the kernel that have historically had more issues, are at higher risk of attack, etc. Those will make up far less code than 20 million lines, and you can start there.


You could triage. Zorro bus support can probably wait until someone has a specific itch to scratch.


Firefox is 17 million!


They rewrote 160,000 lines and it took them more than a year

> It replaces approximately 160,000 lines of C++ with 85,000 lines of Rust.

https://blog.rust-lang.org/2017/11/14/Fearless-Concurrency-I...


The whole Firefox codebase has not been ported to Rust and will not be anytime soon. So your argument doesn't hold true.


Isn't that a point in the rewrite's favor? You don't have to port everything to gain a lot of the benefits.


> You don't have to port everything to gain a lot of the benefits.

I agree with this. But just saying Firefox has X millions of lines of code doesn't say anything about the possibility for Linux to be ported to Rust.


It does say that the 20 million lines statistic isn't sufficient to dismiss the idea. That's not saying much, but I think it's a valid response to someone pointing out that the Linux kernel is 20 million lines.


you're comparing apples and rutabagas. code line count is a hilariously inaccurate way to measure the complexity required for a portable OS kernel vs a userspace application.


> code line count is a hilariously inaccurate way to measure the complexity required for a portable OS kernel vs a userspace application

I never said that. My whole premise is that you can't say anything like this by just saying code count on two very different projects. Maybe you didn't read my comments properly.


What benefits, precisely, though? New bugs? http://insert-script.blogspot.de/2017/11/firefox-settings-co...


What's the relation with Rust? I don't see it mentioned in the post, it affects Firefox before version 57, but not 57 (not that there wasn't any Rust code in Firefox before 57) and it seems to be a bug in DOMParser, which as far as I know is not written in Rust.


Better security. Oh wait ... Chrome still wins although it's written in C++.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: