gccrs
Rust-for-Linux
gccrs | Rust-for-Linux | |
---|---|---|
104 | 84 | |
2,506 | 4,028 | |
2.0% | 0.8% | |
9.8 | 0.0 | |
5 days ago | 4 days ago | |
C++ | C | |
GNU General Public License v3.0 only | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
gccrs
- Rust Needs an Official Specification
-
Why am I writing a Rust compiler in C?
The community has been very supportive of the gccrs (https://github.com/Rust-GCC/gccrs) project, which is the main project to write a Rust compiler written in C.
-
FreeBSD evaluating Rust's adoption into base system
There is a Rust front-end for GCC that is under active development [1]. If the chip vendors are not willing to develop and upstream a LLVM back-end then they can feel free to start contributing to it.
[1] https://rust-gcc.github.io/
-
Why do lifetimes need to be leaky?
That's why gccrs doesn't even consider lifetime checking a part of the language (they plan to use Polonius, too).
- Rust-GCC: GCC Front-End for Rust
-
How hard would it be to port the Rust toolchain to a new non-POSIX OS written in Rust and get it to host its own development? What would that process entail?
There's ongoing work on a Rust front-end for GCC (https://github.com/Rust-GCC/gccrs). Bit barebones right now -- ie, even core doesn't compile -- but there's funding, demand, and regular progress, so it'll only get better from there. Once gccrs can compile core, it should be ready to compile most of Rust, and thus if you've taught the calling conventions for C to GCC, you're golden.
-
How hard is it to write a front end for a more complex language like Rust or Kotlin?
I recommend checking out the GCC Rust frontend project.
-
Rust contributions for Linux 6.4 are finally merged upstream!
That is what theyre refering to, yes. The GitHub is named https://github.com/Rust-GCC/gccrs
-
GCC 13 and the State of Gccrs
- But this misses so much extra context information
3. Macro invocations there are really subtle rules on how you treat macro invocations such as this which is not documented at all https://github.com/Rust-GCC/gccrs/blob/master/gcc/rust/expan...
Some day I personally want to write a blog post about how complicated and under spec'd Rust is, then write one about the stuff i do like it such as iterators being part of libcore so i don't need reactive extensions.
- Break rust Easter Egg Merged Into gccrs
Rust-for-Linux
- Rewriting Rust
-
Committing to Rust in the Kernel
You're welcome.
> Any concerns of the same kind of thing?
Here's the canonical list: https://github.com/Rust-for-Linux/linux/issues/2
There's a lot, and I don't know the status of many of them, personally. But I don't see anything there that I know is not gonna work out, like for example, they aren't using specialization. Most of it feels like very nuts and bolts codegen options and similar things.
That said, back in August, the Rust Project announced their goals for the second half of this year: https://blog.rust-lang.org/2024/08/12/Project-goals.html
They say that they're committed to getting this stuff done, and in particular: https://rust-lang.github.io/rust-project-goals/2024h2/rfl_st...
> Closing these issues gets us within striking distance of being able to build the RFL codebase on stable Rust.
So, things sound good, in my mind.
-
Deploying Rust in Existing Firmware Codebases
The goal of rust for linux isn't to wholesale translate linux into rust, but simply to be able to write pieces of linux (largely new ones) in rust. I think it's very unlikely anyone (including google) will take on a wholesale translation anytime soon. That said
> It's unlikely that Google has much sway here
Google has helped fund the rust for linux project pretty much from the start [1], they're one of three organizations mentioned on the homepage due to their sponorship [2]. They're actively involved in it, and have already ported their android "binder" driver into it with the intent to ship it in android. This strikes me as a very weird take.
[1] https://www.memorysafety.org/blog/supporting-miguel-ojeda-ru...
[2] https://rust-for-linux.com/
- Rust for Linux
-
The Linux Kernel Prepares for Rust 1.77 Upgrade
Rust is backwards compatible when you stick to stable features, but the kernel uses unstable features that can and do incur breaking changes.
https://github.com/Rust-for-Linux/linux/issues/2
- Rust in Linux Kernel
-
Mark Russinovich: “Working towards enabling Windows driver development in Rust”
> How would this work?
Don't know exactly what you're asking.
> And why would it be a better idea?
Poorly written device drivers are a significant attack vector. It's one of the reasons Linux is now exploring using Rust for its own device drivers.[0] You may be asking -- why Rust and not some other language? Rust has many of the performance and interoperability advantages of C and C++, but as noted, makes certain classes of memory safety issues impossible. Rust also has significant mindshare among systems programming communities.
[0]: https://rust-for-linux.com
- The Linux Kernel Module Programming Guide
- Teknisk karrierevej i Danmark som softwareudvikler
-
The state of Flatpak security: major Projects are the worst?
Rust-for-Linux issue tracker
What are some alternatives?
gcc-rust - a (WIP) Rust frontend for gcc / a gcc backend for rustc
jakt - The Jakt Programming Language
rustc_codegen_gcc - libgccjit AOT codegen for rustc
rustig - A tool to detect code paths leading to Rust's panic handler
mold - Mold: A Modern Linker 🦠
rfcs - RFCs for changes to Rust
rustc_codegen_gcc - libgccjit AOT codegen for rustc
dafny - Dafny is a verification-aware programming language
rust - Empowering everyone to build reliable and efficient software.
PrawnOS - Libre Mainline Kernel and Debian for arm laptops
polonius - Defines the Rust borrow checker.
koka - Koka language compiler and interpreter