Page MenuHomeFreeBSD

usr.bin/top: fix displaying load average for loads of at least 100
ClosedPublic

Authored by pkubaj on May 21 2024, 10:34 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Aug 8, 1:20 AM
Unknown Object (File)
Fri, Jul 11, 2:22 AM
Unknown Object (File)
Jul 5 2025, 4:14 AM
Unknown Object (File)
Jul 4 2025, 11:19 AM
Unknown Object (File)
Jun 28 2025, 11:41 AM
Unknown Object (File)
Jun 8 2025, 12:53 PM
Unknown Object (File)
Jun 7 2025, 12:53 PM
Unknown Object (File)
Jun 4 2025, 5:48 AM
Subscribers
None

Details

Summary

After top registers load average of at least 100 which then gets reduced to
below 100, there are left stray digits.
Supporting load over 100 requires increasing the width only to 6, but since
we support over 1000 CPU's now, let's increase it to 7.

Test Plan

Run top while running with load over 100 (or even better, over 1000) which
then gets reduced to below 100.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

pkubaj created this revision.

So for mostly idle machines, this increases the spacing between ':', ',', and values. Perhaps doing it conditionally is worse because the placement of the values would blink.

This revision is now accepted and ready to land.May 21 2024, 9:13 PM