|
|
Log in / Subscribe / Register

The Rust for Linux project

The Rust for Linux project

Posted Sep 26, 2021 8:08 UTC (Sun) by marcH (subscriber, #57642)
In reply to: The Rust for Linux project by error27
Parent article: The Rust for Linux project

For small and trivial pieces of C maybe (I wrote "non-trivial"). Are the equivalent parts in Rust harder to predict and if so why? Interesting question.


to post comments

The Rust for Linux project

Posted Sep 27, 2021 13:06 UTC (Mon) by mathstuf (subscriber, #69389) [Link]

My gut feeling is that it is more around figuring out what the optimizer can help out with. Rust can probably optimize iterator method chains far better than C's loops, but at that point, you're also fiddling with details that affect the inline heuristic engine and other such details that vary between compiler implementations and versions of the same compiler, so even there I'd think that "what my specific compiler does" may not be suitable because the optimization could fall on the other side of the line in the next release too.


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds