powerpc64 (and more): procstat -kk does not report sched_switch, just mi_switch's call to it.
Mark Millard
marklmi at yahoo.com
Sun Feb 24 00:22:01 UTC 2019
Take, for example (from a powerpc64 context),
# procstat -kk 23
PID TID COMM TDNAME KSTACK
23 100074 bufdaemon - mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c buf_daemon+0x2f8 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100080 bufdaemon bufspacedaemon-0 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100081 bufdaemon bufspacedaemon-1 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100082 bufdaemon bufspacedaemon-2 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100083 bufdaemon bufspacedaemon-3 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100084 bufdaemon bufspacedaemon-4 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100085 bufdaemon bufspacedaemon-5 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100086 bufdaemon bufspacedaemon-6 mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c bufspace_daemon+0x438 fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
23 100106 bufdaemon / worker mi_switch+0x134 sleepq_switch+0x2ec sleepq_timedwait+0x48 _sleep+0x41c softdep_flush+0x38c fork_exit+0xb0 fork_trampoline+0x18 .TOC.+0x1fffffff642c6efc
then using objdump on /boot/kernel/kernel :
0000000000751868 <mi_switch+0x130> mr r3,r30
000000000075186c <mi_switch+0x134> bl 0000000000789f14 <sched_switch+0x8>
0000000000751870 <mi_switch+0x138> nop
But I see the same sort of thing on amd6:
# procstat -kk 46
PID TID COMM TDNAME KSTACK
46 100274 bufdaemon - mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 buf_daemon+0x158 fork_exit+0xbd fork_trampoline+0xe
46 100275 bufdaemon bufspacedaemon-0 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100277 bufdaemon bufspacedaemon-1 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100279 bufdaemon bufspacedaemon-2 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100280 bufdaemon bufspacedaemon-3 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100282 bufdaemon bufspacedaemon-4 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100283 bufdaemon bufspacedaemon-5 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100284 bufdaemon bufspacedaemon-6 mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 bufspace_daemon+0x4d6 fork_exit+0xbd fork_trampoline+0xe
46 100297 bufdaemon / worker mi_switch+0x131 sleepq_timedwait+0x36 _sleep+0x289 softdep_flush+0x2c9 fork_exit+0xbd fork_trampoline+0xe
ffffffff81139d0c <mi_switch+0x12c> callq ffffffff81177760 <sched_switch>
ffffffff81139d11 <mi_switch+0x131> mov %gs:0x18,%rbx
Is this lack of listing sched_switch information intended behavior?
Note for powerpc64 relative to the "+8":
0000000000789f0c <sched_switch> addis r2,r12,190
0000000000789f10 <sched_switch+0x4> addi r2,r2,-12044
0000000000789f14 <sched_switch+0x8> mflr r0
0000000000789f18 <sched_switch+0xc> std r0,16(r1)
===
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)
More information about the freebsd-ppc
mailing list