A LOCK argument may contain any subscripted or unsubscripted M name including a name without a preceding caret symbol (^). Because they have the appearance of local variable names, resource names with no preceding caret symbol (^) are commonly referred to as "local LOCKs," even though these LOCKs interact with other processes.
The GT.M run-time system records LOCK information in memory associated with the region holding the global of the same name. However, GT.M does not place LOCKs in the database structures that hold the globals. Instead a "LOCK database" is associated with the database. Only the M commands LOCK, ZALLOCATE, and ZDEALLOCATE, and the LKE utility access the information in the "LOCK database."
When a process leaves M, GT.M normally releases any LOCKs or ZALLOCATEs held by that process. If a GT.M process terminates abnormally, or if the system "crashes" while a GT.M process is active, GT.M cannot perform normal clean-up. However, as soon as any other process waits several seconds for a LOCK, GT.M automatically clears the "orphaned" LOCK.