<P> In software engineering, double - checked locking (also known as "double - checked locking optimization") is a software design pattern used to reduce the overhead of acquiring a lock by first testing the locking criterion (the "lock hint") without actually acquiring the lock . Only if the locking criterion check indicates that locking is required does the actual locking logic proceed . </P> <P> The pattern, when implemented in some language / hardware combinations, can be unsafe . At times, it can be considered an anti-pattern . </P>

Double checked locking is not thread safe in java