diff options
author | Tejun Heo <tj@kernel.org> | 2019-09-04 21:45:56 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2019-09-10 20:31:39 +0200 |
commit | 7c1ee704a1d6450f92372d57f5b76a458b51c1d4 (patch) | |
tree | cdb9966b5b5097f711ee380ab6bb8c4cf6cdbaae /tools/cgroup | |
parent | iocost_monitor: Report more info with higher accuracy (diff) | |
download | linux-7c1ee704a1d6450f92372d57f5b76a458b51c1d4.tar.xz linux-7c1ee704a1d6450f92372d57f5b76a458b51c1d4.zip |
iocost_monitor: Report debt
Report debt and rename del_ms row to delay for consistency.
Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'tools/cgroup')
-rw-r--r-- | tools/cgroup/iocost_monitor.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/cgroup/iocost_monitor.py b/tools/cgroup/iocost_monitor.py index 5d8bac603ffa..f79b23582a1d 100644 --- a/tools/cgroup/iocost_monitor.py +++ b/tools/cgroup/iocost_monitor.py @@ -135,7 +135,7 @@ class IocStat: def table_header_str(self): return f'{"":25} active {"weight":>9} {"hweight%":>13} {"inflt%":>6} ' \ - f'{"del_ms":>6} {"usages%"}' + f'{"dbt":>3} {"delay":>6} {"usages%"}' class IocgStat: def __init__(self, iocg): @@ -159,6 +159,7 @@ class IocgStat: else: self.inflight_pct = 0 + self.debt_ms = iocg.abs_vdebt.counter.value_() / VTIME_PER_USEC / 1000 self.use_delay = blkg.use_delay.counter.value_() self.delay_ms = blkg.delay_nsec.counter.value_() / 1_000_000 @@ -181,6 +182,7 @@ class IocgStat: 'hweight_active_pct' : str(self.hwa_pct), 'hweight_inuse_pct' : str(self.hwi_pct), 'inflight_pct' : str(self.inflight_pct), + 'debt_ms' : str(self.debt_ms), 'use_delay' : str(self.use_delay), 'delay_ms' : str(self.delay_ms), 'usage_pct' : str(self.usage), @@ -195,6 +197,7 @@ class IocgStat: f'{self.inuse:5}/{self.active:5} ' \ f'{self.hwi_pct:6.2f}/{self.hwa_pct:6.2f} ' \ f'{self.inflight_pct:6.2f} ' \ + f'{min(math.ceil(self.debt_ms), 999):3} ' \ f'{min(self.use_delay, 99):2}*'\ f'{min(math.ceil(self.delay_ms), 999):03} ' for u in self.usages: |