How can I write a program which can test throughput of disk?
-
22-08-2019 - |
Question
How can I write a program which can test throughput of disk in Windows systems using c++?
What's the mainly steps and APIs that I can use to programming?
Solution
One open-source benchmark is bonnie, which mostly uses the standard C API. You'll need to change some of the timing functions to suit Windows.
OTHER TIPS
In outline:
- write a known (large) amount of data to disk ( see write() )
- start clock (see time() or clock() )
- read data from disk (see read() )
- stop clock (see above)
- report results (see cout)
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow