Index: llvm/trunk/include/llvm/Support/Parallel.h =================================================================== --- llvm/trunk/include/llvm/Support/Parallel.h +++ llvm/trunk/include/llvm/Support/Parallel.h @@ -56,12 +56,12 @@ ~Latch() { sync(); } void inc() { - std::unique_lock lock(Mutex); + std::lock_guard lock(Mutex); ++Count; } void dec() { - std::unique_lock lock(Mutex); + std::lock_guard lock(Mutex); if (--Count == 0) Cond.notify_all(); }