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

I mean, that's a real advantage. But personally I'm not so keen for all my system software to have the performance of garbage collected languages. I don't want my software to suddenly get 1.5x-4x slower and start using twice as much RAM. For pam and sudo it wouldn't matter, sure. But across the whole linux system? I'd rather a slow and careful rewrite in rust over that sort of system wide slowdown.


There will never be a slow and careful rewrite in Rust. Nobody wants to do it, and doing it without introducing new bugs and security issues (not linked to memory) is even more difficult.


> There will never be a slow and careful rewrite in Rust. Nobody wants to do it

Lots of people want to do it. Whether you want to run any of their code is an open question - but rewriting old things from scratch is a very popular passtime.

In fact, people are already doing it. For example, the recent sudo-rs rewrite. Or the uutils coreutils package:

https://github.com/uutils/coreutils

- Which passes almost all conformance tests now by the way. (Though they could certainly use a few more tests):

https://uutils.github.io/coreutils/docs/test_coverage.html

> doing it without introducing new bugs and security issues (not linked to memory) is even more difficult.

Difficult, but not impossible. Plenty of alternate C compilers exist. And alternate SQL databases. And some web browsers. And email servers. And TLS implementations. And on and on. Arguably there already are several reimplementations of the "linux userland", with various tweaks. They're just called Freebsd. And Illumos. And MacOS.

Why would the linux userland be uniquely impossible to reimplement in another language? I feel like people celebrate when someone makes a new text editor or gameboy emulator. Why so much hate at the idea of more implementations of unix tools?


It works perfectly fine in the legions of schools using Chromebooks, TVs with WebOS, and about 70% of mobile devices.

The only three Linux kernel powered systems that have actually achieved The Year of Linux Desktop success among non technical users.


Except ChromeOS and webOS are both based on linux, which is written in normal, fast C.

The computer on my desk cost about $3000. If all my programs ran twice as slow, thats sort of like removing $1500 of my computer away. Could I get away with a $1500 computer? Probably. But I'm not going to be happy about it.


They are based on the Linux kernel, the userspace is mostly written in managed languages, and don't have any access to GNU/Linux.

And best of all, they run much better than folks using Electron crap for all their apps.

Finally, my phone is better than all my computers between 1986 and 2006, combined.

1980's Lisp Machines and Smalltalk would fly with 2025 hardware, JIT compilers and pauseless GC algorithms.

C is mostly fast when devs actually know their algorithms and data structures.


If you are happy to pay the cost of a garbage collector, why C at all and not Java, C#, Go, Typescript, or any of the other fine options? They’re simpler languages with better tooling and cleaner syntax. I understand Fil-C for running legacy code. But for new code, the only reason I’d ever pick C is performance and Fil-C takes that benefit away.


For legacy code that no one is going to rewrite, of course.

For new code, I would go further than that, first of all languages can have a GC and have C like performance, it is a matter of implementation, algorithms, data structures and design application with mechanical affinity in mind.

I would go for what the last OS designed by UNIX and C authors, C only gets to be used in the kernel, and some more low level drivers, everything else is managed, like Inferno and Limbo.

Many fail to realise that UNIX and C authors moved on from their original creations, improving what they saw as flaws.




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

Search: