Object Alloc Instrument and releasing question
Object Alloc Instrument and releasing question
- Subject: Object Alloc Instrument and releasing question
- From: Nick Rogers <email@hidden>
- Date: Wed, 14 Oct 2009 02:10:59 +0530
Hi,
I'm running Xcode 3.2 on Snow Leopard.
There is an object of type HDIR which can contains a mutable array of
children objects of type HDIR, so a tree is formed.
I can go back using the Back button and release this HDIR type root
object.
And then again form a new tree.
When a tree is formed the VM according to Activity Monitor reaches a
high value and when I release this tree, it doesn't come any lower,
but when I again form the tree, it starts increasing from that max
value.
Does it mean that VM is not being freed, due to some bug in my
releasing the tree?
Here is some Object Alloc instrument data after the first tree is
formed (1), after releasing that tree (2) and after again making a
tree (3):
Category Live Bytes #Living #Transitory Overall Bytes #Overall
1. HDIR 1.73 MB 10333 10428 3.48 MB 20761
2. HDIR 0 0 20761 3.48 MB 20761
3. HDIR 1.73 MB 10333 31189 6.97 MB 41522
Does the #Living being added to #Transitory means that tree is not
actually freed?
The Instrument docs says about Object Alloc:
This instrument captures the following information:
Category - typically a Core Foundation object, an Objective-C class,
or a raw block of memory.
Net Bytes - the number of bytes of this type currently allocated but
not yet released.
# Net - the number of objects or memory blocks of this type currently
allocated but not yet released.
Overall Bytes - the total number of bytes of this type that have been
allocated, including those that have been released.
# Overall - the total number of objects or memory blocks of this type
that have been allocated, including those that have been released.
# Allocations (Net / Overall) - A histogram of the current and total
counts. The bars are normally shades of blue. They are colored shades
of yellow when the ratio between the total number of objects and the
peak, or the ratio between the peak and the current number, is 1/3 or
less. The bars are shades of red when the ratio is 1/10 or less.
It doesn't list the meaning of #Transitory.
Thanks,
Nick
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden