← Back to team overview

ooc-dev team mailing list archive

Re: About garbage collection

 

Hey there - just a quick response, hopefully followe by a more detailed one
later but I'm on the clock here :)

The Boehm GC does have a "parallel collection" mode, I have never tried it
but it's documented here:
http://www.hpl.hp.com/personal/Hans_Boehm/gc/gcdescr.html
(see "Mostly Parallel Garbage Collection")

Apparently it can be enabled with '--enable-parallel-mark' at ./configure
time, see: http://www.hpl.hp.com/personal/Hans_Boehm/gc/simple_example.html

Also, if the Boehm GC appears to be not quite fast enough, you might
consider another approach: http://gamehaxe.com/tag/immix/
This guy has implemented the IMMIX algorithm for garbage collection and it
seems fast enough - also, he explains that he's triggering garbage
collection
once per frame - you might want to try that so you get shorter, less
noticeable pauses.

Also, what is your game about? :) Has anything annoyed you in rock lately?
Are you looking forward to oc? Do you think rock should be released in 1.0?

Amos
---- Original Message ----
From: Damian
To: "Ooc dev"
Sent: Mon, Dec 20, 2010, 3:53 AM
Subject: [Ooc-dev] About garbage collection

Hi,this is not really a question about ooc, but I'm looking for some help,
maybe someone can point me out something.I'm developing an iphone game in
ooc, I'm really happy with what I have now, but I'm having a problem with
garbage collection. I managed to configure and build Boehm GC for the
iphone, and it works well but the collection cycle produces a freeze of
about 120 miliseconds, and it's relly notorious and awful. I tried to
configure it, but all I could achieve is having a collection cycle about
every 10 seconds (instead of the 2 or 3 seconds I was having). I've read in
ooc documentation about writing a custom sdk and do memory management, but
I don't want to let to the garbage collection.Has anyone an idea of what
can I do? Is there another way of garbage collection suitable for a game? I
don't know if there is a garbage collection that does the collection in a
background thread, I think boehm gc does not
Well. Any help will be greatly appreciated.Thanks! Damian.

Follow ups