LIBRARY CACHE:
- Library cache latch:- The library cache latch must be acquired in order to add a new statement to the library cache. -
Ensure that the application is reusing as much as possible SQL statement.
If the application is already tuned, increase the SHARED_POOL_SIZE.
- Library cache pin latch:- This latch is acquired when a statement in the library cache is reexecuted.
SHARED POOL RELATED LATCHES
- Shared pool latch: While the library cache latch protects operations withing the library cache, the shared pool latch is used to protect critical operations when allocating and freeing memory in the shared pool.
Ways to reduce the shared pool latch are, avoid hard parses when possible.
Row cache objects latch:- This latch comes into play when user processes are attempting to access the cached data dictionary values.
Reduce contention for this latch is by increasing the size of the shared pool (SHARED_POOL_SIZE)