摘要 |
Publishing an object. Memory for an object may be reserved so as to lock the memory from being access by garbage collection threads or other user threads. While the lock is in place, type and size information can be installed for the object. If the reservation is being made to allow garbage collection threads to operate on the object, then the type may be a specialized type that indicates that the object has no references. Reservations can also be made to allow the intended type information to be installed for the object. An indication can be made that the object is well formed, thus unlocking the object and allowing garbage collection threads, other user threads, or both to access the object. The locking and unlocking may be performed by accessing an API provided by a system garbage collector.
|