Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
The 50% solution, VFP and performance
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00075915
Message ID:
00076077
Vues:
28
>>Perhaps an optimum solution (in lieu of VFP doing the job properly itself), is to have as part of your applications state machine a process that checks the available physical memory periodically and adjusts the buffer size to suit. It might also make VFP a better behaved app to change buffer sizes around particularly hungry queries.
>>
>>I think I've rambled more than enough now :-)
>
>Most excellent rambling Simon, Thanks much for this helpful insight!! This optimum solution you describe above would be worth it's wait in gold for my data warehouse apps!!!! If by chance you and/or anybody else would be interested in perhaps developing something like this that developers could maybe call from strategically placed hooks in an app, I'd be more than happy to do the testing on it with all my large tables and hefty queries. Maybe we can do this a group project here on UT and hopefully make it available in the files section? If you don't like the idea of developing this for freeware so-to-speak, I would also be willing to discuss purchasing such a add-on if it's proven to be reliable.

Well I don't know how golden it's going to prove but I've put together a prototype for such a utility. It's a prototype because it has a form rather than being just a class but it has proved to be interesting. I'll put the class and the necessary DLL into the Files area.

It's interesting because the foreground buffer size seems to be being managed by VFP dynamically on some occasions but that when it starts up its value is way too large. The class gets the current GlobalMemoryStatus on a timer event whose default is 30 seconds, the values of available memory are displayed then.

At the same time the value of available memory is checked against the watermark property (default 1Mb) if its less than this then the foreground buffersize is reduced by 20%.

Finally the size of the foreground buffer is compared with available physical memory if its greater then it is reduced to available physical memory less the watermark.

Tweak with it all you like, :-).

Simon
_________________________________________
Objective 2000 Ltd
http://www.objective2k.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform