Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why one code works, while other doesn't?
Message
 
 
À
24/01/2001 13:31:50
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00466654
Message ID:
00468070
Vues:
31
>>If files are sitting on the local drive, the second approach works faster (difference about 1 sec.). If they are located on the NetWork drive, the first approach is faster ~3sec. File is 5MB.
>>
>>I also can not find the optimum size in fread().
>
>When I said 'round numbers', I meant ROUND, like 2048, 4096, 8192, 16384, 32768, 65536 and such :).

You know, sometimes you have to be explicit :) Different cultures, mentalities, etc. :) I understood you wrongly...


With numbers which just have zeros when written in decimal, I wouldn't know which would give you better alignment and less overhead (or does it matter at all - simple matter of network being more or less loaded at some point may ruin your benchmarking).

Well, I ran few tests (since each took 10-14 sec. I finished with the tests for now). Seems like 131072 is the winner. I put it here for a while...
>
>I figure you'd need a little more testing, probably with the buffer size about four times bigger each time, to find what suits your OS/network the best. I can't imagine any rule here, it all depends.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform