place must the only reference to the object to be released, and no other thread can be still accessing the object.
release-object-and-nullify releases the memory and stores
nil in place, so there is no dangling pointer to the object.
The released memory is returned to the operating system for objects that are allocated in their own segment. Currently, these are objects larger than 1 MB in the Mobile GC, larger than 64 MB in the ordinary 64-bit GC. For other objects, the memory will eventually be reclaimed by the GC, except for permanent objects that are not in their own segment, which are never reclaimed.
release-object-and-nullify is mainly intended to be used with references to the large objects that are allocated in their own segment, where it can return the memory to the operating system, and hence reduce the memory usage substantially without waiting for a GC. In particular, it is the only way to release the memory of such objects that were made permanent in the Mobile GC. This is the main purpose of it.
release-object-and-nullify does not release the memory for objects that are not in their own segment, it is not very useful for such objects. However, it may have a useful effect when called on an object that contains pointers and is in a higher generation, because objects in lower generations that are kept alive because of pointers from this object can be GCed earlier, but in most cases it probably does not justify the effort.
release-object-and-nullify can be called with a reference to a permanent object too, and if it is allocated in its own segment then the memory will also be released.
release-object-and-nullify releases only the object that is referenced by place, but not anything that this object points to, which means that you may not get the effect you expect for an object that is complex, such as a
hash-table, a CLOS instance, a
pathname or a non-simple array.
LispWorks User Guide and Reference Manual - 20 Sep 2017