Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Trying to track down memory leak(s)
Message
De
23/09/2011 08:54:18
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Divers
Thread ID:
01398453
Message ID:
01524447
Vues:
152
>>>>>Does the memory come back if you release and reinstanciate the VFP COM objects?
>>>>
>>>>I don't know and that would be extremely hard to test in this app. What I have been testing today (left running the last 3 hours to get some real data) is what happens if I run with those objects built in instead of COM.
>>>
>>>That should at least tell you the same thing - is the leak because of the COM interop or is it something else. Are you using GDI+ here? If so, it could be leaking memory there.
>>
>>Looks like it is the COM interop. When I run the whole thing from the Command Window without the COM objects registered, memory usage goes up much more slowly. So it looks like it's VFP, not me, and I'll need to use Bernard Bout's trick for releasing memory periodically. (http://www.foxite.com/faq/default.aspx?id=55)
>>
>>Off to play with that.
>>
>>Tamar
>
>So,
>
>What did you find out after implementing this trick?
>BTW, adding call to this procedure from multithreaded VFP dll in each 50 iterations made no effect in our case.

My vague memory is that Bernard's trick didn't really help, though I don't remember for sure.

I added code to the app that lowers its overall memory load by doing some garbage collection and so forth. (We have a bunch of collections that tend to grow and grow and grow.) We got it down to the point that it hasn't been a problem for the customers.

Tamar
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform