Rust-Based Linux Scheduler Is Faster | Prime Reacts
Unlock all features
FREE: Get instant access to 10 AI summaries, chats, or transcripts per day.
Unlock all features
FREE: Get instant access to 10 AI summaries, chats, or transcripts per day.
Unlock all features
FREE: Get instant access to 10 AI summaries, chats, or transcripts per day.
Unlock all features
FREE: Get instant access to 10 AI summaries, chats, or transcripts per day.
Unlock all features
FREE: Get instant access to 10 AI summaries, chats, or transcripts per day.
Related videos
Linus On C vs Rust Linux Problems
ThePrimeTime
273.0k views
what is wrong with rust and linux????
ThePrimeTime
229.4k views
Java Is Better Than Rust
ThePrimeTime
435.7k views
Why CS Is Dead | Prime Reacts
ThePrimeTime
250.8k views
LeetCode Isnt Real | Prime Reacts
ThePrimeTime
286.5k views
AI Interview | Prime Reacts
ThePrimeTime
82.9k views
Minecraft Server In Bash | Prime Reacts
ThePrimeTime
131.1k views
I Hate Rust | Prime Reacts
ThePrimeTime
211.9k views
Mojo Is FASTER Than Rust
ThePrimeTime
123.0k views
Async Rust Is The Bane Of My Existence | Prime Reacts
ThePrimeTime
119.8k views
Top Comments (10)
Whoa whoa whoa I game all the time on Linux
The default scheduler algorithm in Linux is a trade off to be good in a wide range of tasks and situations. I personally worked in the past to hack the Linux kernel/scheduler to be more performant for our specific embedded product. Usually when you optimize some aspects of the system, you end up deteriorating the performance of something else.
An "apples to apples" comparison would be to have the same code written in C rewritten in Rust. If the Linux scheduler algorithm is different between the C and Rust versions then you are not comparing the languages, you are comparing the algorithms.
Gaming is great on Linux. It was my sole dealbreaker when I decided to switch away from Windows and I'm yet to find any issue that's made me go back. Performance is often on par or better and I think a lot of people have no idea how good it's gotten since they've last checked.
I remember my Intro to Operating Systems course at university. And we spent a really long time discussing different scheduling algorithms and their benefits and drawbacks. One of the issues that we discussed constantly about the different algorithms was starvation. Without looking at it I'd say the most likely explanation for the "improved performance" was that it was making choices that would lead to thread starvation more generally.
The aim of the scheduler is not to improve the main task that the user is using, but increasing the efficiency of utilization of resources by going around the system bottlenecks. If the user wants fast framerates, then it should stop the background tasks. What the guy should have done was showing that all resources are being used to their maximum limit, minimizing the effect of the largest bottleneck.
For this one I think you are kind of missing the point: A scheduler is always a tradeoff between - throughput - latency / interactive performance - fairness (no task is ever stalled / suffocated) I could easily write a scheduler (well not easy but ykwim) that runs terraria 10x faster with a compilation in the background: the scheduler that always prioritizes terraria over everything else. Now does the rust scheduler have 2x performance in terraria while compiling a Kernel? Maybe Is it as good at throughput, latency, fairness as the Linux scheduler? Probably not. Also the language of the scheduler has basically nothing to do with the performance because a somewhat decent scheduler maybe runs 0.01% of the time on a system The author also never claimed that it had anything to do with rust
there is a whole science in measuring program performance... this guy never got the memo.
Compiling in background is a good approximation for discord and twitch stream.
Never had any issue gaming on Linux. I use Arch btw
Unlock the Data Inside
Turn Videos into Knowledge
- Get FREE 10/day: transcripts, summaries, chats
- Chat with videos, export text & PDF
- $1 free API credit for RAG, chatbots & research
Free forever plan • All features unlocked
Top Comments (10)
Whoa whoa whoa I game all the time on Linux
The default scheduler algorithm in Linux is a trade off to be good in a wide range of tasks and situations. I personally worked in the past to hack the Linux kernel/scheduler to be more performant for our specific embedded product. Usually when you optimize some aspects of the system, you end up deteriorating the performance of something else.
An "apples to apples" comparison would be to have the same code written in C rewritten in Rust. If the Linux scheduler algorithm is different between the C and Rust versions then you are not comparing the languages, you are comparing the algorithms.
Gaming is great on Linux. It was my sole dealbreaker when I decided to switch away from Windows and I'm yet to find any issue that's made me go back. Performance is often on par or better and I think a lot of people have no idea how good it's gotten since they've last checked.
I remember my Intro to Operating Systems course at university. And we spent a really long time discussing different scheduling algorithms and their benefits and drawbacks. One of the issues that we discussed constantly about the different algorithms was starvation. Without looking at it I'd say the most likely explanation for the "improved performance" was that it was making choices that would lead to thread starvation more generally.
The aim of the scheduler is not to improve the main task that the user is using, but increasing the efficiency of utilization of resources by going around the system bottlenecks. If the user wants fast framerates, then it should stop the background tasks. What the guy should have done was showing that all resources are being used to their maximum limit, minimizing the effect of the largest bottleneck.
For this one I think you are kind of missing the point: A scheduler is always a tradeoff between - throughput - latency / interactive performance - fairness (no task is ever stalled / suffocated) I could easily write a scheduler (well not easy but ykwim) that runs terraria 10x faster with a compilation in the background: the scheduler that always prioritizes terraria over everything else. Now does the rust scheduler have 2x performance in terraria while compiling a Kernel? Maybe Is it as good at throughput, latency, fairness as the Linux scheduler? Probably not. Also the language of the scheduler has basically nothing to do with the performance because a somewhat decent scheduler maybe runs 0.01% of the time on a system The author also never claimed that it had anything to do with rust
there is a whole science in measuring program performance... this guy never got the memo.
Compiling in background is a good approximation for discord and twitch stream.
Never had any issue gaming on Linux. I use Arch btw