Board index » delphi » Best way to use FastMM4?

Best way to use FastMM4?


2005-07-19 04:14:28 PM
delphi12
I'd like to use fastMM4 in a project group consisting of a large number of
ActiveX modules (both in-process and out-of-process COM servers).
Which way would you recommend?
- Let each module use its own copy by linking Unit fastmm4.pas ?
- Use borlandmm.dll by letting each project link "sharemem" ?
--
Arthur Hoornweg
(In order to reply per e-mail, please just remove the ".net"
from my e-mail address. Leave the rest of the address intact
including the "antispam" part. I had to take this measure to
counteract unsollicited mail.)
 
 

Re:Best way to use FastMM4?

Hi Arthur,
Quote
- Let each module use its own copy by linking Unit fastmm4.pas ?
This way you will have more memory overhead, since every module will have
its own memory manager. The advantage is that when a module is unloaded all
its memory leaks will be freed (if there are any). You will not be able to
pass long strings or dynamic arrays between modules. This option might be
slightly faster if your application is heavily multi-threaded.
Quote
- Use borlandmm.dll by letting each project link "sharemem" ?
Less memory overhead, because you only have one memory manager. If you have
memory leaks then usage will grow as leaky modules are loaded and unloaded
until you run out of address space. You will be able to pass long strings
and dynamic arrays between modules.
Regards,
Pierre