Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP 3.0/5.0 Memory and performance
Message
De
03/03/1997 13:42:41
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00022631
Message ID:
00022695
Vues:
37
>>Feb 1997 issue of FoxTalk had an excellent
>>article on How Visual FoxPro Memory useage
>>affects performance.

I'm working on how to automate the settings.

What I've been doing in tuning is to load VFP first.
Adjust SYS(3050,1) until System Info says there is free physical memory.
Set SYS(3050,2) to the same value (** see later)

Then load other applications.


My first guess is:

Call a Windows API function to get the amount of physical memory.
Call a Windows API function to get the amount of memory in use.
Call a Windows API function to get he amount of swapfile in use.

Memory in use - Swapfile in use => Gives physical memory in use
Physical memory - Physical memory in use gives VFP headroom

If headroom is 0 - you're in trouble.

Decrease SYS(3050,1) by 1/2 then wait 10 seconds for disk thrashing <g> and recalculate.
If no free physical memory, repeat until less than 1MB allocated, then warn user no buffer space and stop.

If you get free physical memory, then go up 1MB at a time (unless less than 1MB free) and reaculate each time.


(** I think this might matter!)

Once I have a buffer memory setting that works, set SYS(3050,2) to the same value.

I don't like the idea of relinquishing memory and then reclaiming it. How can I be certain it comes back into physical memory on a task switch?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform