• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Garbage collected and non-garbage collected
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Garbage collected and non-garbage collected


  • Subject: Re: Garbage collected and non-garbage collected
  • From: Joar Wingfors <email@hidden>
  • Date: Wed, 11 Mar 2009 10:30:06 -0700


On Mar 11, 2009, at 10:03 AM, Robert Mullen wrote:

As I have waded into the code a little more I see that this entire struct is allocated using calloc() in an init and freed with free(). How does that work with GC?


The GC only manages memory that's allocated from the managed heap, and this is separate from the standard malloc zone. If you're using regular malloc, you're on the hook for managing that memory completely manually. Note though, that you can also allocate raw buffers of data from the managed heap using NSAllocateCollectable.

j o a r


_______________________________________________

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


References: 
 >Garbage collected and non-garbage collected (From: Robert Mullen <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: "Sean McBride" <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: "I. Savant" <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Robert Mullen <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: "I. Savant" <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Robert Mullen <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: "I. Savant" <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Robert Mullen <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: "I. Savant" <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Bill Bumgarner <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Robert Mullen <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Bill Bumgarner <email@hidden>)
 >Re: Garbage collected and non-garbage collected (From: Robert Mullen <email@hidden>)

  • Prev by Date: Cocoaheads Lake Forest (92630) meeting 3/11/2009 (tonight!) at 7 pm on "Modeling a Game with the Cocoa Frameworks"
  • Next by Date: Re: Background Process?
  • Previous by thread: Re: Garbage collected and non-garbage collected
  • Next by thread: Re: Garbage collected and non-garbage collected
  • Index(es):
    • Date
    • Thread