[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: JoCaml rewritten ...



Hi,

If I remember correctly, the gc does not need to track dates, it just
need to tell the local part of the dgc that it finished a gc cycle. But
I'm not sure and should definitely look it up (or ask Fabrice, which
would be faster ;-)

About the usefulness of a dgc, well ... it's useful only if there is
some notion of ditribution, with remotely accessible things, and if you
don't want to leak memory. The join calculus part does not need a
dgc, it's mostly a programmation paradigm used to express
synchronization and short lived threads (which is useful to express
protocols). The dgc comes into play when you add the feature that
channel may be sent on the network and still accessed transparently. So
it's the modile code bit that requires a dgc.

The solution you propose about having heartbeat messages is fine as long
as you consider the network as reliable. I guess the dgc was designed to
tolerate network delays and some network partitionning. I do believe
that a dgc is essential when adding distribution to a system that relies
on a gc. I'm still pretty much convinced that it's not that expensive
anyway, because the tradeoff between quickly reclaiming memory and not
using much bandwidth leans toward the low bandwidth (thus slower
reclaiming of memory) solution.

Alan

* Christopher Quinn (cq@htec.demon.co.uk) wrote:
> Hi,
> 
> I took a look at the dgc paper. Phew! A paper of only 8 pages screwing 
> up my head!!
>  From my limited understanding of it, it seems the maintenance of cyclic 
> garbage is burdening the gc with extra work ie. tracking dates. This can 
> only hurt performance on all code, even code which deals only minimally 
> with communications matters.
> Why is dgc necessary to the join-calculus / mobile code?
> Why not deal with communicating entites at a higher level and not 
> sacrifice performance at a fundamental level (gc)?  Say a server spawns 
> a thread to handle a request - it lives as long as it still receives 
> valid comms messages, and dies and releases resources otherwise.
> That works, no? What does dgc buy you?
> 
> It would be nice if Ocaml 3.04 were augmented by just a join-calc 
> library for comms, perhaps with a dash of camlp4.
> Is it possible? Is dgc essential to mobile code?
> 
> Cheers,
> Chris


--
The hacker: someone who figured things out and made something cool happen.