diff options
| author | Arthur Hanson Rasmusson <arthur@vgpu.io> | 2026-09-29 14:47:17 -0400 |
|---|---|---|
| committer | Arthur Hanson Rasmusson <arthur@vgpu.io> | 2026-09-29 14:47:17 -0400 |
| commit | 0cbe5604adff2bc386960edbc58f45e35e61bae8 (patch) | |
| tree | d5b803fffddd5ab201254a40ec8a5138d65b38f7 /tools/guest-diag/track_waits.sh | |
| parent | fa31d766d548a0e07426b6d231a42f05c07521a8 (diff) | |
| download | open-iov-0cbe5604adff2bc386960edbc58f45e35e61bae8.tar.gz open-iov-0cbe5604adff2bc386960edbc58f45e35e61bae8.zip | |
guest-diag: cheaper trace read, optional push sampler, bigger pagemap batches
Under load the semfix poll grepped the whole (growing) trace file and the
track_waits push block spawned three guest processes per sample, both of
which slowed the pin path into the client's failure window. The trace read
now tails 128 KB; track_waits.sh gates the push dump behind PUSH=0; the
pagemap helper reads 32 KB chunks.
Diffstat (limited to 'tools/guest-diag/track_waits.sh')
| -rw-r--r-- | tools/guest-diag/track_waits.sh | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/tools/guest-diag/track_waits.sh b/tools/guest-diag/track_waits.sh index 45a9a66..6ae9154 100644 --- a/tools/guest-diag/track_waits.sh +++ b/tools/guest-diag/track_waits.sh @@ -16,6 +16,7 @@ PAGE_VA="${PAGE_VA:-0x20400f000}" COUNT="${COUNT:-20}" STRIDE="${STRIDE:-16}" OFFSET="${OFFSET:-0xec0}" +PUSH="${PUSH:-1}" : > /tmp/trk.log : > /tmp/cnt.log @@ -58,14 +59,16 @@ for i in $(seq 1 "$N"); do | grep -vE "^\[|Reading symbols|^0x[0-9a-f]+ in |warning:" >> /tmp/trk.log fi - { - echo "=== $TS push pages ===" - python3 /tmp/guest_pmap.py "$PID" 0x201000000 0x203400000 0x203400020 2>&1 - for va in 0x201000000 0x203400000 0x203400020; do - echo "--- $va" - timeout 5 python3 /tmp/read_va.py "$PID" "$va" 64 --u32 2>&1 - done - } >> /tmp/push.log + if [ "$PUSH" = "1" ]; then + { + echo "=== $TS push pages ===" + python3 /tmp/guest_pmap.py "$PID" 0x201000000 0x203400000 0x203400020 2>&1 + for va in 0x201000000 0x203400000 0x203400020; do + echo "--- $va" + timeout 5 python3 /tmp/read_va.py "$PID" "$va" 64 --u32 2>&1 + done + } >> /tmp/push.log + fi sleep "$SLEEP" done |
