Does using a lock have better performance than using a local (single application) semaphore? [closed]
问题 Closed . This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing this post. Closed 8 months ago . Does using a lock have better performance than using a local (single application) semaphore? I read this blog from msdn : Producer consumer solution on msdn and I didn't like their solution to the problem because there are always 20 elements left in the queue. So instead, I