[Pkg-utopia-maintainers] Bug#1093142: more information
Russell Coker
russell at coker.com.au
Thu Jan 16 13:11:53 GMT 2025
I currently can't reproduce the situation of taking more than 1 CPU core. I
didn't do anything differently, just rebooted it a day later and got different
results.
Now I'm seeing the following, not a huge amount of CPU time, but more than
expected from an idle system with the screen locked and nothing happening.
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1913 mobian 20 0 5447112 410056 196544 S 2.0 5.3 0:24.27
plasmashell
1537 mobian 20 0 106568 10732 6916 S 1.3 0.1 0:07.15
pipewire
1544 mobian 20 0 186116 17092 7492 S 1.3 0.2 0:07.00
pipewire-pulse
root at op6a:~# strace -p 1537
strace: Process 1537 attached
epoll_pwait(5,
The pipewire process is waiting, how can it be using CPU time?
root at op6a:~# strace -p 1544 2>&1|head
strace: Process 1544 attached
epoll_pwait(4, [{events=EPOLLIN, data={u32=201999296, u64=187651618128832}}],
32, -1, NULL, 8) = 1
read(5, "\1\0\0\0\0\0\0\0", 8) = 8
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLOUT|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLOUT, data={u32=205036208, u64=187651621165744}}],
32, -1, NULL, 8) = 1
sendto(44, "\0\0\0\4\0\0\0\1\0\0\0\0\0\0\0\0\0\0\0\0", 20, MSG_DONTWAIT|
MSG_NOSIGNAL, NULL, 0) = 20
sendto(44, "\0\0\0\0", 4, MSG_DONTWAIT|MSG_NOSIGNAL, NULL, 0) = 4
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLIN, data={u32=201999296, u64=187651618128832}}],
32, -1, NULL, 8) = 1
read(5, "\1\0\0\0\0\0\0\0", 8) = 8
root at op6a:~# strace -p 1544 2>&1|head -20
strace: Process 1544 attached
epoll_pwait(4, [{events=EPOLLIN, data={u32=201999296, u64=187651618128832}}],
32, -1, NULL, 8) = 1
read(5, "\1\0\0\0\0\0\0\0", 8) = 8
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLOUT|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLOUT, data={u32=205036208, u64=187651621165744}}],
32, -1, NULL, 8) = 1
sendto(44, "\0\0\0\4\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 20, MSG_DONTWAIT|
MSG_NOSIGNAL, NULL, 0) = 20
sendto(44, "\0\0\0\0", 4, MSG_DONTWAIT|MSG_NOSIGNAL, NULL, 0) = 4
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLIN, data={u32=201999296, u64=187651618128832}}],
32, -1, NULL, 8) = 1
read(5, "\1\0\0\0\0\0\0\0", 8) = 8
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLOUT|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLOUT, data={u32=205036208, u64=187651621165744}}],
32, -1, NULL, 8) = 1
sendto(44, "\0\0\0\4\0\0\0\1\0\0\0\0\0\0\0\0\0\0\0\0", 20, MSG_DONTWAIT|
MSG_NOSIGNAL, NULL, 0) = 20
sendto(44, "\0\0\0\0", 4, MSG_DONTWAIT|MSG_NOSIGNAL, NULL, 0) = 4
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLIN, data={u32=201999296, u64=187651618128832}}],
32, -1, NULL, 8) = 1
read(5, "\1\0\0\0\0\0\0\0", 8) = 8
epoll_ctl(4, EPOLL_CTL_MOD, 44, {events=EPOLLIN|EPOLLOUT|EPOLLERR|EPOLLHUP,
data={u32=205036208, u64=187651621165744}}) = 0
epoll_pwait(4, [{events=EPOLLOUT, data={u32=205036208, u64=187651621165744}}],
32, -1, NULL, 8) = 1
sendto(44, "\0\0\0\4\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 20, MSG_DONTWAIT|
MSG_NOSIGNAL, NULL, 0) = 20
root at op6a:~# ls -l /proc/1544/fd/5
lrwx------ 1 mobian mobian 64 Jan 17 00:08 /proc/1544/fd/5 -> 'anon_inode:
[eventfd]'
root at op6a:~# ls -l /proc/1544/fd/44
lrwx------ 1 mobian mobian 64 Jan 17 00:02 /proc/1544/fd/44 -> 'socket:
[18425]'
The pipewire-pulse program is looking on an eventfd and writing to a socket in
a fairly tight loop.
As for plasmashell, what it does is more complex and I'm not sure if it's
connected to the pipewire CPU use.
For desktop use probably most people would be happy to let these processes use
1% CPU time each for as long as the system is used. For even a laptop this
probably isn't a problem. But for a phone it's a real problem.
--
My Main Blog http://etbe.coker.com.au/
My Documents Blog http://doc.coker.com.au/
More information about the Pkg-utopia-maintainers
mailing list