Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/dev/tprof



Module Name:    src
Committed By:   ryo
Date:           Fri Dec 16 07:59:42 UTC 2022

Modified Files:
        src/sys/dev/tprof: tprof.c

Log Message:
- Add support select(2)/poll(2) on /dev/tprof.
- Changed sampling buffer switching frequency (which is the frequency of tprof_worker()
  calls and also the maximum block time of read(2) of /dev/tprof) from 1sec to 125ms.
  This improve tprof top responsiveness.
- The maximum number of sampling buffers is now adjusted according to the number of CPUs.
  Previously it was fixed at 100 and was insufficient if ncpu was greater than this.

The maximum number of samples per second per CPU is calculated by
"TPROF_MAX_SAMPLES_PER_BUF * (HZ of tprof_worker)".
Therefore, currently, 10000 * (1000/125) = 80000 maximum samplings per CPU.
The actual value will vary slightly from this due to tprof_worker and read(2) timing.
This value may need to be adjusted more in the future.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/dev/tprof/tprof.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index