On 7/12/06, Geir Magnusson Jr <[EMAIL PROTECTED]> wrote:
>
> 1) gc_pin() is optional operation, and may be absent in simplest collectors
> 2) gc_pin() is not required to succeed, and the GC may decide to reject
>    object pinning (e.g. based on some memory footprint/performance 
compromise).
>    The success of operation must be checked by using gc_is_object_pinned()

Do you mean gc_pin_object()?  It returns void.  Why not have it return
an indication of success?  I mean, it knows, right?


My understanding is, as a hint to GC, gc_pin_object() leaves GC to
decide when and how to react; so the immediate return value may not be
very informative to indicate the status of an object pinning, since GC
may pin it later in next collection, the API itself doesn't need to
know the result. The gc_is_object_pinned is used to check the pinning
status.

That said, it's still ok to return the current pinning status at the
return time.

Thanks,
xiaofeng

---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to