Originally posted by rmoog
View Post
Announcement
Collapse
No announcement yet.
Rust Bindings Are Being Worked On For Linux CPUFreq Drivers
Collapse
X
-
Originally posted by NotMine999 View PostIs Rust being implemented in kernel sections that NEED the memory protections provided by Rust?
Or is Rust being implemented where it is EASIEST to implement ... so as to build up it's footprint within the Linux kernel?
- Likes 2
Comment
-
Originally posted by NotMine999 View PostIs Rust being implemented in kernel sections that NEED the memory protections provided by Rust?
Or is Rust being implemented where it is EASIEST to implement ... so as to build up it's footprint within the Linux kernel?
Comment
-
Originally posted by darkonix View Post
Nobody asked for what exactly? Please be more specific.
Sonarqube, bulleyes and valgrind can not provide the exact same guarantees that the Rust compiler provides out of the box. Also they are optional tools that not everyone uses. Still probably they can be used with Rust too. Valgrind surely, not fully sure if the others are compatible with Rust.
GDB is a debugger and can be used with Rust programs, same that with other languages. Not sure why you mentioned it.
"Bugs" would be handled by either `cargo test` or `cargo clippy`, since Rust's stance is "If it's unarguably a bug, fail the build. If it's probably a bug, have Clippy complain."
Code coverage may take a little longer since I recently saw the discussion on getting push-button coverage support in Cargo turn in a "let's let the ecosystem iterate a bit longer first" direction.
Bullseye is C++ code coverage, so more or less the same applies, but anything which supports coverage for LLVM Clang (i.e. no special compilation options or requiring options LLVM supports) should do fine. I've used kcov with Rust in the past.
Probably best to also throw in some fuzzing since, as the rust-fuzz trophy case shows, while security-vulnerable fuzzing hits are rare, no practical programming language can guarantee that coders haven't Implemented a reachable "ASSERT: This should be unreachable". (It's one of the reasons I'm willing to tie my code in an extra knot or two to do stuff like using slice patterns in match instead of indexing. The compiler can prove that slice patterns won't silently become reachable panics (or UB-invoking memory accesses in C) during refactoring.)Last edited by ssokolow; 07 April 2024, 09:25 PM.
- Likes 1
Comment
-
Originally posted by NotMine999 View PostIs Rust being implemented in kernel sections that NEED the memory protections provided by Rust?
Or is Rust being implemented where it is EASIEST to implement ... so as to build up it's footprint within the Linux kernel?
- Likes 3
Comment
-
- Likes 1
Comment
-
Originally posted by darkonix View Post
I'm not an expert in MISRA but it seems to assume many C shortcomings that simply can not happen in a language like Rust.
Static Analyzer Rudra Found over 200 Memory Safety Issues in Rust Crates
Developed at the Georgia Institute of Technology, Rudra is a static analyzer able to report potential memory safety bugs in Rust programs. Rudra has been used to scan the entire Rust package registry and identified 264 new memory safety bugs.
CVEs (Common Vulnerabilities and Exposures) in Rust programs:
The mission of the CVE® Program is to identify, define, and catalog publicly disclosed cybersecurity vulnerabilities.
If a sound static analyzer were deployed, we could make C code with zero memory safety issues and do it without the hack of compiler added runtime checks that Rust uses to claim memory safety. The aviation and nuclear power industries have been doing this for years. It is a shame that no one is willing to follow their lead and the wider community instead pursues new languages when what it actually needs is better tooling, which at present only exists for C (and C++ if you don't insist on having a formally verified compiler). Those new languages do not have such tooling and need it to reach parity with what is possible with C when using tools like sound static analyzers and formally verified compilers. :/
-- ryao on https://www.phoronix.com/forums/foru...35#post1385835
- Likes 1
Comment
Comment