From: Acosta, Mark W [Magic Earth LLC] (acostmw++at++texaco.com)
Date: 02/10/2000 16:50:16
Hello,
I've got some unusual memory behavior going on here and I hope someone can
explain to me what's going on. I have a performer application that will,
under certain conditions, allocate and free memory from the shared arena on
every frame. I noticed a couple of times if I left it running for a while,
it would just terminate with an "unable to allocate <n> bytes from arena".
So, I decided to run the application again and print the info from
"amallinfo" on the Performer shared arena. The behavior I see is the shared
arena gradually gets bigger and bigger but the space used stays fairly
constant and the space in free blocks gets bigger as the arena gets bigger.
Here's a snapshot of the last amallinfo I got just before it blew up.
Total space in arena: 535920608
Number of ordinary blocks: 22762
Number of small blocks: 43100
Space in holding block headers: 20688
Number of holding blocks: 431
Space in small blocks in use: 1332736
Space in free small blocks: 4864
Space in ordinary blocks in use: 18257728
Space in free ordinary blocks: 516304592
Space penalty if keep option is used: 294432
As you can see, there's an awful lot of free space here. There seems to be
very little or no reuse of free blocks going on. I guess one question is,
is Performer setting up the arena in some way that might cause this
behavior?
I also had a hunch that the app was blowing up when it hit the end of the
arena and, sure enough, I had a 512MB arena and it blew up just about the
time the arena grew to 512MB. I guess fragmentation could cause it to fail
but the chunks of memory I'm getting are fairly consistant in size so I
wouldn't expect it to be that bad.
Does anyone know if the M_DEBUG option in amallopt works? I've tried turning
it on and as far as I can tell, it's not doing anything. It's not even clear
from the man page what it suppose to do if it finds a problem.
By the way, I'm running this on a dual 12000 Octane, 2GB memory, IRIX 6.5.5.
Thanks
Mark Acosta
Magic Earth LLC
This archive was generated by hypermail 2b29 : Thu Feb 10 2000 - 16:50:54 PST