Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Where is the memory???
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00290506
Message ID:
00291176
Vues:
18
>My application in VFP 6.0 slows down after a longer time running. I checked the SYS(1016) function, that shows the amount of memory used by User Objects. The amount is continuously increasing! Then I tried this:
>
>New started VFP 6.0:
>at the beginning sys(1016) shows 308 012 B.
>
>execute m.O=CreateObject("Form") (a new clear form)
>
>sys(1016) shows 315 172 B. (form takes 7160 B of memory)
>
>now I execute RELEASE m.O (or m.O.Release and Release m.O, doesn't matter)
>
>sys(1016) shows 309 832 B - so part of memory was released, but 1820 B is still hanging somewhere !
>
>Repeating creating and releaseing objects (and that's what all application do mostly) cause more and more memory is used and application is slow and slow more...
>
>After executing CLEAR MEMO, sys(1016) shows 309768 (still 1756 B hanging somewhere). I tried also others partial CLEARs, but with no effect. Executing CLEAR ALL (shows 308 360 - remains only 348 B, but you never return to former value 308 012 B). And using CLEAR ALL inside the application is really impossible.
>
>Do you know any explanation? Where is the memory? How to free it?
>Thanks for all suggetions...
>Petr

Petr,

VFP6.0 (SP3) is very stable and does not leak memory in this fashion. What you might have is what is called dangling references, that is, objects that are instantiated in your form but are not killed when you destroy your form. Also, don't trust the VFP memory functions too much... I also see strange things with SYS(1016), yet my apps are stable.
Another point that might get your attention is the reports, where a bad printer driver might leak memory.

By the way, I was in Prague last August, and enjoyed your city very much.

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

Click here to load this message in the networking platform