You need to sign in or sign up before continuing.
clear need_locks in child after fork
the child is single-threaded, but may still need to synchronize with last changes made to memory by another thread in the parent, so set need_locks to -1 whereby the next lock-taker will drop to 0 and prevent further barriers/locking.
Showing
想要评论请 注册 或 登录