Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid race condition in crutest rand-read/write #1261

Merged
merged 1 commit into from
Apr 17, 2024

Conversation

mkeeter
Copy link
Contributor

@mkeeter mkeeter commented Apr 17, 2024

Previously, the IO tasks could stop before the stat-gathering main loop, so you could get nonsensical readings like

 713.4 MiB/sec ± 14.2 MiB/sec      (713 IOPS)
 683.6 MiB/sec ± 11.2 MiB/sec      (683 IOPS)
 698.8 MiB/sec ± 409.6 KiB/sec     (698 IOPS)
 722.2 MiB/sec ± 10.2 MiB/sec      (722 IOPS)
 674.4 MiB/sec ± 13.6 MiB/sec      (674 IOPS)
   737 MiB/sec ± 5.8 MiB/sec       (737 IOPS)
 709.6 MiB/sec ± 16.8 MiB/sec      (709 IOPS)
 728.6 MiB/sec ± 10.6 MiB/sec      (728 IOPS)
 723.6 MiB/sec ± 15.2 MiB/sec      (723 IOPS)
 694.6 MiB/sec ± 8.6 MiB/sec       (694 IOPS)
 713.2 MiB/sec ± 7.2 MiB/sec       (713 IOPS)
 stopping guest [0 jobs remaining]
----------------------------------------------
average read performance: 650.1 MiB/sec ± 196.6 MiB/sec (650 IOPS)

Notice the average read performance is nowhere near the average values reported during runtime!

This is because the last two IO samples are captured as the system is shutting down. Here are the raw samples:

[733164339.2, 762943897.6, 728550604.8, 705062502.4, 732325478.4, 733164339.2,
 746586112.0, 767977062.4, 692899020.8, 721420288.0, 778882252.8, 766718771.2,
 726453452.8, 761685606.4, 775107379.2, 752877568.0, 742811238.4, 774687948.8,
 719323136.0, 737358643.2, 755394150.4, 740294656.0, 3774873.6, 0.0]

@mkeeter mkeeter merged commit 2e80400 into oxidecomputer:main Apr 17, 2024
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants