Originally posted by ZarathustraDK
View Post
Rust-Written Linux Scheduler Showing Promising Results For Gaming Performance
Collapse
X
-
Originally posted by commodore256 View PostOh the Rustaceans are at it again. I like the idea of memory safety on a core OS level, but as much as I like the idea, I feel if you're going to have a memory safe successor to C, do it right. I wish there was more stuff in Zig, a way better language.
Comment
-
-
Originally posted by F.Ultra View Post
This is one area where macOS is a bit better since you there can inform the system when you create a thread if it would benefit from a performance core or if it is for more background things and thus can better run on a efficiency core.
GUI threads should probably be set to FIFO or RR? i wonder which one would be better.
https://man7.org/linux/man-pages/man...heduler.2.htmlLast edited by cj.wijtmans; 17 January 2024, 05:16 PM.
Comment
-
-
Originally posted by F.Ultra View Post
This is one area where macOS is a bit better since you there can inform the system when you create a thread if it would benefit from a performance core or if it is for more background things and thus can better run on a efficiency core.
Comment
-
-
Originally posted by bug77 View PostIt's easy to describe that in words. The problems start arising when you have to deal with tasks that they all need higher priority than everything else.
Essentially you only need 5 different priorities:- lowest background: everything that should never interfere with anything else (like updates)
- normal
- user: everything with a GUI that has to interact with the user
- active: the active window and everything that the user want's to prioritize.
- RT: audio, video, games
Scheduling is ultimately at kernel's discretion, a DE can only set hints. And a DE does not start all the processes in an OS (Ctrl+Alt+F3 anyone?).
A DE should do its best to keep the priorities of rendering and event processing threads above everything else.
Comment
-
Originally posted by ffs_ View Post
I'd test at least more than one scenario:
0. Minimal background tasks
1. Many light load background tasks
2. Running heavy load task in the background
3. 1+2 combined
Comment
-
-
Originally posted by cj.wijtmans View Post
you can do the same on linux though? You can either set niceness to 19 to 1 or -1 to -19 or you can set sched policy to SCHED_IDLE or SCHED_BATCH.
GUI threads should probably be set to FIFO or RR? i wonder which one would be better.
https://man7.org/linux/man-pages/man...heduler.2.html
What macOS have is a pthread function (pthread_set_qos_class_self_np) to set the QoS Class for a thread where the QoS Class can be "User-interactive", "User-initiated", "Utility" and "Background". And this is something that I hope that we could copy to Linux if the use of P-cores and E-cores becomes prevalent.
Last edited by F.Ultra; 18 January 2024, 10:07 AM.
Comment
-
-
Originally posted by bug77 View Post
Are you sure macOS does that? On which heterogeneous CPU does it run?
Comment
-
-
Originally posted by phoronix View PostPhoronix: Rust-Written Linux Scheduler Showing Promising Results For Gaming Performance
A Canonical engineer has been experimenting with implementing a Linux scheduler within the Rust programming language. His early results are interesting and hopeful around the potential of a Rust-based scheduler that works via sched_ext for implementing a scheduler using eBPF that can be loaded during run-time...
https://www.phoronix.com/news/Rust-L...ler-Experiment
Comment
-
-
Originally posted by V1tol View PostI am not sure what happens with that scheduler but the effect looks to me the same as applying schedtool and ionice. On my 5950X doing nice by only 1 makes a huge difference in responsiveness. Confirmed multiple times by compiling kernel or mesa and doing casual internet surfing at the same time - impact becomes almost unnoticeable. Didn't try to game ofc since all my games are very demanding.
I did not try using nice, but specifying -j n-1 likewise makes the compilation absolutely unnoticeable for normal web browsing.
you mentioned ionice, do you have a slow storage media that becomes bottleneck? (but why would this affect internet browsing which is not hitting the disk?)Last edited by varikonniemi; 21 January 2024, 08:27 AM.
Comment
-
Comment