BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

POLL: Memory Managers
Goto page 1, 2, 3, 4, 5, 6, 7  Next
 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Thirdparty Tools (General)
View previous topic :: View next topic  
Author Message
Jonathan Neve[Microtec]
Guest





PostPosted: Tue Dec 20, 2005 3:50 pm    Post subject: Re: POLL: Memory Managers Reply with quote



Danijel Tkalcec [RTC] wrote:

Quote:
From this, I'd say that BucketMem_ASM is a clear winner, but I
haven't used it before (actually, didn't even know it existed a week
ago)

Neither did I. Where did you find it?

Quote:
So, here are my questions ...

1) Which is your favourite Memory Manager?

I still use the standard MM.

Quote:
2) Why do you preffer this one over the others?

I don't! :)

Quote:
3) How long are you using this Memory Manager?

Hmm, ever since... BCB 1. So I guess that's about 7 or 8 years.

Quote:
4) Did you have any bad experience using it?

Not particularly. I don't usually write memory- nor CPU-intensive
applications, so this has never been a real issue. Besides, I've never
tried any third-party MM (because FastMM doesn't support BCB 5).--
Best regards,
Jonathan Neve
_______________
CopyTiger - advanced database replicator for Interbase/Firebird!
Web : http://www.microtec.fr/copycat/ct
_______________________________________
CopyCat - database replication components for Delphi/C++Builder!
Web : http://www.microtec.fr/copycat/cc

Back to top
Jonathan Neve[Microtec]
Guest





PostPosted: Tue Dec 20, 2005 4:09 pm    Post subject: Re: POLL: Memory Managers Reply with quote



Danijel Tkalcec [RTC] wrote:

Quote:
"Jonathan Neve[Microtec]" wrote:
Danijel Tkalcec [RTC] wrote:

From this, I'd say that BucketMem_ASM is a clear winner, but I
haven't used it before (actually, didn't even know it existed a
week ago)

Neither did I. Where did you find it?

One of my licensed RTC SDK users has told me about it,
after I mentioned doing performance tests using FastMM4.

It is included in the "Validation and Benchmark Tool",
which can be downloaded from this web site:
http://dennishomepage.gugs-cats.dk/memoryManagerChallenge.htm


Thanks, looks interesting.
--
Best regards,
Jonathan Neve
_______________
CopyTiger - advanced database replicator for Interbase/Firebird!
Web : http://www.microtec.fr/copycat/ct
_______________________________________
CopyCat - database replication components for Delphi/C++Builder!
Web : http://www.microtec.fr/copycat/cc

Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 4:40 pm    Post subject: POLL: Memory Managers Reply with quote



I've just done a few tests using the standard Delphi memory manager, FastMM4
and BucketMem_ASM. I was using Delphi 7 to compile my test apps and running
the tests in a 100 MBit LAN with 14 Client PCs and one Server. Here are my
results (requests processed per second when using automatic encryption) ...

580 with the Standard Delphi MemMgr
1.310 with FastMM4 and FastMove
1.990 with BucketMem_ASM and FastMove

Each test was running at least 8 hours under full client and server load.

From this, I'd say that BucketMem_ASM is a clear winner, but I haven't used
it before (actually, didn't even know it existed a week ago), so I'm
wondering if someone has had more extensive experience using BucketMem or
some other third-party Memory manager and would be willing to share his
experiences here.


So, here are my questions ...

1) Which is your favourite Memory Manager?

2) Why do you preffer this one over the others?

3) How long are you using this Memory Manager?

4) Did you have any bad experience using it?


Thank you for sharing :)

Best Regards,
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm


Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 5:10 pm    Post subject: Re: POLL: Memory Managers Reply with quote

"Jonathan Neve[Microtec]" wrote:
Quote:
Danijel Tkalcec [RTC] wrote:

From this, I'd say that BucketMem_ASM is a clear winner, but I
haven't used it before (actually, didn't even know it existed a week
ago)

Neither did I. Where did you find it?

One of my licensed RTC SDK users has told me about it,
after I mentioned doing performance tests using FastMM4.

It is included in the "Validation and Benchmark Tool",
which can be downloaded from this web site:
http://dennishomepage.gugs-cats.dk/memoryManagerChallenge.htm

Best Regards,
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm



Back to top
Erick Hartanto
Guest





PostPosted: Tue Dec 20, 2005 5:11 pm    Post subject: Re: Memory Managers Reply with quote

1) Which is your favourite Memory Manager?

Surely FastMM4

2) Why do you preffer this one over the others?

Well, it fast than default memory manager, you can see already when IDE are
loaded it cut the loading time.
the most useful one is it can detect our memory leak.

3) How long are you using this Memory Manager?

Since it became popular <g>

4) Did you have any bad experience using it?

No, this is very helpful to me at least, and i think others too.

Thanks for Pierre :)


Back to top
Jim McKay
Guest





PostPosted: Tue Dec 20, 2005 5:28 pm    Post subject: Re: Memory Managers Reply with quote

Danijel Tkalcec [RTC] said...

Quote:
I can only guess that higher memory usage with FastMM is resulted to
higer memory fragmentation,

nope.

Quote:
but it could also result from additional debug information used by
FastMM to detect memory leaks.

much closer to truth.

I'd suggest, rather than guess, you search/post in BASM group, as
MM Challenge was ongoing technical discussion there for well over
a year. Issues of performance, fragmentation <etc.> have been
discussed in detail.

I'd point out FMM has been adopted by Borland, and used in D'-06.

--
Regards:
Jim McKay

"If English was good enough for Jesus Christ, it's
good enough for us."

- Miriam Amanda "Ma" Ferguson (1875-1961),
Governor of Texas (1925-1927, 1933-1935)

From speech advocating barring foreign language teaching

Posted with XanaNews: Ver: 1.17.6.6

Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 6:07 pm    Post subject: Re: Memory Managers Reply with quote

I also think that FastMM is an excellent replacement for the standard memory
manager, because it helps finding memory leaks in applications.

But, in my tests in with multithreaded applications (Client and Server using
260 running threads), FastMM4 used up to 3 times the ammount of memory
needed by BucketMem.

I've done this "memory usage test" a number of times, to make sure it wasn't
caused by some random chance. And in all my tests, FastMM4 reserved more
than 240 MB, while BucketMem was comfortable with less than 90 MB.

I can only guess that higher memory usage with FastMM is resulted to higer
memory fragmentation, but it could also result from additional debug
information used by FastMM to detect memory leaks.

From what I've read about BucketMem, it is designed to reduce memory
fragmentation in multithreaded apps, which makes this a perfect candidate
for high-load multithreaded Servers.

In any case, here's what Robert Houdart (author of BucketMem) wrote ...
---------------
BucketMem is a replacement Memory Manager for Delphi 5,6,7,2005 and Kylix
that does not suffer
from fragmentation and delivers much better performance in a
multi-threaded application.

HOW TO USE: Simply add BucketMem as the very first unit in your project
(dpr) file.

The memory management is performed at 3 levels:
1) the V-Block level that allocates OS memory chunks of 256 kB..1024 kB
of committed memory
2) each V-Block is divided into "Sheets" of 16 kB..144 kB
3) each "Sheet" is used to create memory blocks of a given size (16
bytes up to 144 kB)
The sheets are managed by "buckets".
BucketMem uses about 50 buckets that each deliver memory blocks of a given
size.

A Bucket
- manages a number of Sheets in a double-linked list
- has an ActiveSheet out of which memory blocks are served until
exhaustion
- if ActiveSheet has been used up, the Bucket continues with the next
Sheet that has free blocks;
if none is available, a new Sheet is created

A Sheet
- is a 16 kB..144 kB memory zone divided in BlockCount equal blocks with
size BlockSize
- memory blocks are served either linearly or from a single-linked list
of free blocks
- Sheets are allocated from from V-Blocks

A Memory Block
- 4 bytes overhead to store the Sheet to which the memory block belongs
- detects freeing an invalid block or twice the same memory block

A V-Block
- is a 256 kB..1024 kB zone of committed Virtual Memory (Windows)
- will be sub-divided into a number of Sheets
--------------

--
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm


Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 6:41 pm    Post subject: Re: Memory Managers Reply with quote

Can someone please post the "FastMM4Options.inc" file (to attachments) with
options set for best performance and lowest memory usage in multithteaded
applications (no debug and memory leak information required), which one
could use when deploying applications?

I'd like to do more tests with FastMM4.

--
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm


Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 7:15 pm    Post subject: Re: Memory Managers Reply with quote

Here is what I now have defined in the
"FastMM4Options.inc" file for deployment:

------------
{$define ASMVersion}
{$define Align16Bytes}
{$define UseCustomFixedSizeMoveRoutines}
{$define EnableMMX}
{$define AssumeMultiThreaded}
{$define HideMemoryLeakHintMessage}
{$define NoMessageBoxes}
{$define NeverUninstall}
-----------

Btw ... I also use FastMove.

Is there something I should add or remove?

--
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm


Back to top
Srinivasan Iyer
Guest





PostPosted: Tue Dec 20, 2005 7:21 pm    Post subject: Re: Memory Managers Reply with quote

Hi Danijel,
I use memory manager from NexusDb
([url]http://www.nexusdb.com/showpage.asp?Id=9Cool[/url]. I am very happy with it. Their
database product also contains this memory manager and three very well
written transport that might be of interest to you.
Regards.
Srini.
"Danijel Tkalcec [RTC]" <dtkalcec (AT) hotmail (DOT) com> wrote

Quote:
I've just done a few tests using the standard Delphi memory manager,
FastMM4
and BucketMem_ASM. I was using Delphi 7 to compile my test apps and
running
the tests in a 100 MBit LAN with 14 Client PCs and one Server. Here are my
results (requests processed per second when using automatic encryption)
....

580 with the Standard Delphi MemMgr
1.310 with FastMM4 and FastMove
1.990 with BucketMem_ASM and FastMove

Each test was running at least 8 hours under full client and server load.

From this, I'd say that BucketMem_ASM is a clear winner, but I haven't
used
it before (actually, didn't even know it existed a week ago), so I'm
wondering if someone has had more extensive experience using BucketMem or
some other third-party Memory manager and would be willing to share his
experiences here.


So, here are my questions ...

1) Which is your favourite Memory Manager?

2) Why do you preffer this one over the others?

3) How long are you using this Memory Manager?

4) Did you have any bad experience using it?


Thank you for sharing :)

Best Regards,
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm





Back to top
Matthew Jones
Guest





PostPosted: Tue Dec 20, 2005 7:28 pm    Post subject: Re: POLL: Memory Managers Reply with quote

I have used the NexusMM, but I suspect that FastMM will become the default
for most people now. We have had one issue in an app that FastMM surfaced
- a mono bitmap printed inverted, but changing to more colours made it go
away. I didn't investigate it so don't have the details. I do know that
the app created over 2,000,000 objects in a run, so it must be okay
overall!

/Matthew Jones/
Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 7:34 pm    Post subject: Re: Memory Managers Reply with quote

Hi Srini,

What I read in their section about Threaded Memory Allocation sounds like a
dream come true (if they really can do what they are promissing):

"... If you now move your multi-threaded application to a multi-processor
machine, you will find that it might even run slower than on a single-cpu
machine. What you see is that the cpus are mostly running in kernel mode and
trying to get access to the critical code which typically is protected by
something like a critical section. The CPUs spend most of their time waiting
for this access.

Especially for server applications it is essential to maximize threaded
memory allocation. The NexusDB replacement memory manager uses a completely
different way to allocate/deallocate memory and minimizes these problems by
doing so."

Is there a Trial version of the Nexus Memory Manager?

--
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm


Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 7:47 pm    Post subject: Re: POLL: Memory Managers Reply with quote

In my tests, I found that FastMM4 is very stable.

I had all clients and server running a stress-test for 3 days and 9 hours,
in which time they have processed 435,326,400 requests (yes, that's 435
million), without any problems.

I've now modified the options file used by FastMM4 and did a short test on
localhost, to see if there is a change in performance between those and
other options I used.

Well ... the performance using FastMM4 was not the same as with BucketMem.

Now I have to check if memory usage has reduced. But for this, I need to
start the test in my LAN, which will take some time to set up :)

--
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm


Back to top
Danijel Tkalcec [RTC]
Guest





PostPosted: Tue Dec 20, 2005 7:49 pm    Post subject: Re: POLL: Memory Managers Reply with quote

Quote:
Well ... the performance using FastMM4 was not the same as with BucketMem.

The performance using FastMM4 was NOW the same as with BucketMem.

--
Danijel Tkalcec
http://www.deltasoft.hr/rtc/author.htm



Back to top
Joe Bain
Guest





PostPosted: Tue Dec 20, 2005 7:55 pm    Post subject: Re: POLL: Memory Managers Reply with quote

Jonathan Neve[Microtec] wrote:

Quote:
Danijel Tkalcec [RTC] wrote:

From this, I'd say that BucketMem_ASM is a clear winner, but I
haven't used it before (actually, didn't even know it existed a week
ago)

Neither did I. Where did you find it?


It is an entry developed for the FastCode MM challenge. I have tested
it with my apps and it works fine.


--------------
Joe Bain
www.iegsoftware.com

Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Thirdparty Tools (General) All times are GMT
Goto page 1, 2, 3, 4, 5, 6, 7  Next
Page 1 of 7

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.