-----BEGIN PGP SIGNATURE-----
iQIzBAEBCAAdFiEEEi7VNYRx9KT37vF+JtlcIZXoGKIFAlsNl6kACgkQJtlcIZXo
GKI4DRAAo6VXVSnePIjyqT9B2Bp6r9LAn2UTOsfCfYd78Ns40QUpDzWBM3JUBTPw
D4zLSZg2sDN+ig2LjwdvrUdCmuZCX/RP7A6vPEjPTiAbnKidU7HXGffa+QrOQBMo
kdmjr1G5clkOX53UcubOBNVT3BgV+gtmVyS+RA25youGLlreirpM8JVXjoZNKxKv
Mi7yu7Tb757XDpdYQyky+w8Ay2bpbAu8XUCdxI/aO3i5E3XGzrldeVYdtP12e1i7
3cp1k/AqoXHRR0dcyl5/BJXAu7zI5pImzCzgoXAPECmH60ccQaJzoT4smXGZ9B5C
AlzG/NN5/3KzQ58vjBEPfve1tDU5uxaK6+i42lQfWzVRVEn66Td5rIi6Yy9NObpe
tOsV8MBpB1CDiCYhlgSc6AU0nUZOGOMNP+6pIDP7/ebjziLkcq/ddUYpBNlsCP/a
zzv0Gp6Km0sbsCQK58fJxuulWDEsbg5zxsBJZCtoanOWQL43wqzzMM08B4enO6Rl
tuCW8c6U2oi+KE+7VRECmqA8kGaI4Opr6HGbvXJxn3py3BhcHcEH+A550mkhIvZD
F0c1EDgJKVHEh3hqUxLN5ciaQarw1Ks9GAtMfV5zJnHf0pNvl7VOCAMRlp6ou8E6
vjLMvxtLGK51yTCawyBleYA3+v3CE7JAIHHFetzz7Soog39GjL0=
=b0TG
-----END PGP SIGNATURE-----
On 05/27/18 13:07, Maximilian Pichler wrote:
> Is it possible to limit the CPU usage of a given process to, say, 20%?
>
> I'd like to slow down the web browser since it is draining my laptop's
> battery. With enough tabs open it's often consuming ~50% of CPU but
> not doing anything productive. Apparently with RLIMIT_CPU in
> setrlimit(2) the total CPU time of a process can be limited. Can a
> similar limit be set for the percentage?
Honest question… Have you tried blocking ads with something like uBlock
Origin? I use several approaches to make web browsing palatable on old
hardware, and blocking ads is what makes the biggest difference for me.
(Using NoScript or equivalents to selectively enable JavaScript for
sites where I actually need it is a distant second.)
Capping CPU resources is not the way to go on a laptop in my opinion,
unless you have some demanding job that always runs in the background in
your browser, and that's a problem by itself in your scenario. Capping
will not change the fact that you'll still spend the same resources on
loading web pages, however it will slow you down and annoy you.
No comments:
Post a Comment