index | ~dongdigua

pia! Slow down processes using cgroup v2

A few days ago I watched Tsinghua's video 《破壁少年》,
in which it mentioned a resource control script called pia.sh, which is crutial for winning SC15.

Another day I was compiling an AUR package, but it by default uses all the cores, making my laptop very hot.
Meanwhile, I can't watch bilibili smoothly, but I don't want to cancel the compilation.
So I implemented the same functionality of the "pia".

here's the code: (download)

dongdigua CC BY-NC-SA 禁止转载到私域(公众号,非自己托管的博客等)

Email me to add comment

Proudly made with Emacs Org mode

Date: 2025-01-11 Sat 00:00 Build: 2025-01-19 Sun 00:16 Size: 4.0K