Progress
Database Administration
Guide and Reference
Unproductive CPU Processing
Symmetric multi-processing (SMP) systems use a spin lock mechanism to give processes exclusive access to data structures in shared memory. Spin locks ensure that only one process can use the structure at a time, but that all processes can get access to these structures quickly when they have to. However, if tuned incorrectly, SMP CPUs might spend time processing the spin locks unnecessarily instead of performing useful work.
The spin lock algorithm works as follows: When a process requires a shared-memory resource, it attempts to acquire the resource’s latch. When a process acquires the latch, it has exclusive access to the resource. All other attempts to acquire the latch fail until the holding process gives up the latch. When another process requires access to the resource, it attempts to acquire the latch. If it cannot acquire the resource's latch because another process is holding it, the second process continues the attempt. This iterative process is called spinning. If a process fails to acquire a latch after a specified number of spins, the process pauses, or takes a nap, before trying again. If a process repeatedly fails to acquire a latch, the length of its nap is gradually increased. You can set the Spin Lock Tries (-
spin
) parameter to specify how many times to test a lock before napping.To use a system of semaphores and queues to control locking, set
-spin
to zero (0).Use the PROMON R&D “Adjust Latch Options” option under Administrative Functions to change the spin mechanism after start up.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |