diff options
| author | Paul Buetow <paul@buetow.org> | 2026-05-08 19:43:33 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-05-08 19:43:33 +0300 |
| commit | f86699a94bdde7d973ba5d6fa3e7ca4ab2f234fb (patch) | |
| tree | c2e11bfa4fdac965623a8058716c514fce507eba /internal/tui/dashboard/files.go | |
| parent | c41a38ef55bb80681a6cc0b2161f8e84bfabcf17 (diff) | |
add duration metric, tolerate missing tracepoints, ship el8 build
- Bubbles, treemap, icicle, and the live flamegraph 'b' cycle now include
syscall duration (sum) as a third metric alongside events and bytes.
Statsengine snapshots expose TotalLatencyNs to support this.
- AttachAll takes an optional warn callback. Production passes one so older
kernels that lack newer tracepoints log a warning and keep going instead
of aborting startup.
- Dockerfile.el8 + scripts/build-with-docker-el8.sh + mage buildDockerEl8
produce ior.el8, a static binary built against Rocky Linux 8 glibc for
RHEL/Rocky/Alma 8 hosts.
- README.md documents installing mage and the new el8 target.
Diffstat (limited to 'internal/tui/dashboard/files.go')
| -rw-r--r-- | internal/tui/dashboard/files.go | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/internal/tui/dashboard/files.go b/internal/tui/dashboard/files.go index df850ab..3b85a73 100644 --- a/internal/tui/dashboard/files.go +++ b/internal/tui/dashboard/files.go @@ -17,9 +17,10 @@ type DirSnapshot struct { BytesRead uint64 BytesWritten uint64 - AvgLatencyNs float64 - MaxLatencyNs uint64 - FileCount uint64 + AvgLatencyNs float64 + MaxLatencyNs uint64 + TotalLatencyNs uint64 + FileCount uint64 } type fileSortKey uint8 @@ -401,7 +402,6 @@ func aggregateFilesByDir(files []statsengine.FileSnapshot) []DirSnapshot { } dirs := make(map[string]DirSnapshot, len(files)) - weightedLatency := make(map[string]float64, len(files)) for _, f := range files { dir := filepath.Dir(f.Path) s := dirs[dir] @@ -413,14 +413,14 @@ func aggregateFilesByDir(files []statsengine.FileSnapshot) []DirSnapshot { s.MaxLatencyNs = f.MaxLatencyNs } s.FileCount++ - weightedLatency[dir] += f.AvgLatencyNs * float64(f.Accesses) + s.TotalLatencyNs += f.TotalLatencyNs dirs[dir] = s } out := make([]DirSnapshot, 0, len(dirs)) - for dir, s := range dirs { + for _, s := range dirs { if s.Accesses > 0 { - s.AvgLatencyNs = weightedLatency[dir] / float64(s.Accesses) + s.AvgLatencyNs = float64(s.TotalLatencyNs) / float64(s.Accesses) } out = append(out, s) } |
