I think lock, mutex, semaphore are used for synchronized multiple (threads or processes?) to access something simultaneously.Must this something be some shared memory between multiple (threads or processes)?If yes, does that mean lock, mutex, semaphore are only used for multiple threads of a process, not for multiple processes, because multiple processes don't share memory, while multiple threads of the same process do?Thanks.
Are lock, mutex, and semaphore for between threads or between processes?
process;lock;thread