-
January 18th, 2014, 06:49 AM
#28
Re: Multiple thread question
Originally Posted by Codeplug
If you the time (and same curiosity as me), I'd be interested in an HD Tach screenshot.
Or you could run my I/O profiling code: http://forums.codeguru.com/showthrea...64#post1801264 (code attached at end of thread). You'll need to run the code posted in the thread first to create the files that profiling code works on.
gg
using stdio_read(), the i/o profiling code gives
Code:
Reading large file...please wait
Reading file chunks...please wait
Big file size = 2147483647
Chunk file size = 10485760
# Chunks = 205
Chunk Total = 2149580800
Test = stdio_read
Buffer size = 4 K
Time to read big file = 433809 ms
Time to read chunks = 453293 ms
Big throughput = 4.9503 MB/s
Chunk throughput = 4.74214 MB/s
Throughput %Diff = -4.29517 %
Test = stdio_read
Buffer size = 32 K
Time to read big file = 230442 ms
Time to read chunks = 261077 ms
Big throughput = 9.31898 MB/s
Chunk throughput = 8.23351 MB/s
Throughput %Diff = -12.3682 %
Test = stdio_read
Buffer size = 64 K
Time to read big file = 229467 ms
Time to read chunks = 258999 ms
Big throughput = 9.35857 MB/s
Chunk throughput = 8.29957 MB/s
Throughput %Diff = -11.9945 %
Test = stdio_read
Buffer size = 128 K
Time to read big file = 234273 ms
Time to read chunks = 262008 ms
Big throughput = 9.16659 MB/s
Chunk throughput = 8.20426 MB/s
Throughput %Diff = -11.0798 %
Test = stdio_read
Buffer size = 1024 K
Time to read big file = 228264 ms
Time to read chunks = 257756 ms
Big throughput = 9.40789 MB/s
Chunk throughput = 8.3396 MB/s
Throughput %Diff = -12.0389 %
Test = stdio_read
Buffer size = 4096 K
Time to read big file = 229798 ms
Time to read chunks = 257806 ms
Big throughput = 9.34509 MB/s
Chunk throughput = 8.33798 MB/s
Throughput %Diff = -11.3907 %
Using win32_read() gives GetOverlappedResult failed error 38 (MessageId: ERROR_HANDLE_EOF //// MessageText://// Reached the end of the file.) on reading file chunks.
All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!
C++23 Compiler: Microsoft VS2022 (17.6.5)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|