[PATCHES] remove last uses of naked mutexes

Dylan Noblesmith nobled at dreamwidth.org
Sat Aug 23 12:47:38 PDT 2014


There are a few places in LLVM that have weird conditional unlocking
and a ScopedLock simply doesn't fit.

So this adds a minimal variation of std::unique_lock to accommodate
those use cases. I just named it llvm::unique_lock since it copied the
STL-- should it still use CamelCase instead?

I also noticed that MutexGuard predates SmartScopedLock, but offers a
subset of its features aside from a method 'holds()' that has no
users, so it's basically duplicated code. But which name should be
kept as the canonical typedef, ScopedLock or MutexGuard?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-Support-Unix-use-ScopedLock-wherever-possible.patch
Type: text/x-patch
Size: 3572 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140823/752cb8b8/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0004b-Support-make-LLVM-Mutexes-STL-compatible.patch
Type: text/x-patch
Size: 10593 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140823/752cb8b8/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0005-Support-add-llvm-unique_lock.patch
Type: text/x-patch
Size: 7976 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140823/752cb8b8/attachment-0002.bin>


More information about the llvm-commits mailing list