core: Log around process locks