Bug 257160 - SCHED_4BSD produces nonsense in top.
Summary: SCHED_4BSD produces nonsense in top.
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-13 18:53 UTC by dgilbert
Modified: 2021-07-13 18:53 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dgilbert 2021-07-13 18:53:14 UTC
While I'm testing this on riscv64, I strongly suspect that it's not architecture dependant.  It may, however, depend on having a multi-cpu system.

Due to the nature of my quad-core risv64 (it's slow) and what I want to do with it(it's fairly busy), I was annoyed that SCHED_ULE was mostly ignoring my nice levels giving more than 0 time to processes marked as nice -20 vs. processes not nice.  Anyways, I installed a kernel with SCHED_4BSD.

Keep in mind this is a quad core CPU:

  PID USERNAME    THR PRI NICE   SIZE    RES STATE    C   TIME    WCPU COMMAND
  604 dgilbert      1  45    0   109M    66M CPU3     3   0:02 1039.89% c++
  605 dgilbert      1  45    0   109M    66M CPU1     1   0:02 1031.29% c++
  606 dgilbert      1  45    0   109M    66M RUN      2   0:02 1020.32% c++
  603 dgilbert      1  44    0   109M    66M CPU0     0   0:02 1011.41% c++
  854 root          1  40    0    17M  4764K select   1   3:04   0.17% tmux
  425 root          1  40    0    14M  4040K CPU2     2   0:03   0.15% top

... that is a sample top output --- and the >100% _single thread_ processes continue to be significantly more than 100% until they die.

Obviously, top is not reporting reality here.