Kevin raised the point that a problem with cycle locking is that records
recovered during low memory handling are not available until the next
cycle. This is true, but there is a simple workaround. As soon as a
low memory condition is recognized, do a manual wake-up of the cycle
manager thread. It will still have to wait for other threads with a
cycle lock to finish, but none of these threads are going to block
holding cycle locks except, perhaps, the thread that invoked the low
memory operation. Given the very few places that record memory is
allocated, a careful analysis might reveal that there is no danger of
releasing the cycle lock at the point of memory allocation. The
situations that the cycle manager primarily addresses is traversing
record chains, which is generally unassociated with allocating new
record objects.