[libcxx-commits] [PATCH] D116712: [libc++] [test] Remove `UNSUPPORTED: stdlib=msvc` from lock.pass.cpp

Arthur O'Dwyer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sat Jan 8 13:03:57 PST 2022


This revision was not accepted when it landed; it landed in state "Needs Review".
This revision was automatically updated to reflect the committed changes.
Closed by commit rG8a21e0c10cc8: [libc++] [test] Remove `UNSUPPORTED: stdlib=msvc` from lock.pass.cpp. (authored by arthur.j.odwyer).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D116712/new/

https://reviews.llvm.org/D116712

Files:
  libcxx/test/std/thread/thread.mutex/thread.lock.algorithm/lock.pass.cpp


Index: libcxx/test/std/thread/thread.mutex/thread.lock.algorithm/lock.pass.cpp
===================================================================
--- libcxx/test/std/thread/thread.mutex/thread.lock.algorithm/lock.pass.cpp
+++ libcxx/test/std/thread/thread.mutex/thread.lock.algorithm/lock.pass.cpp
@@ -8,10 +8,14 @@
 //
 // UNSUPPORTED: libcpp-has-no-threads
 
-// This test hangs forever when built against libstdc++ and MSVC. In order to allow
-// validation of the test suite against other STLs we have to mark it
-// unsupported.
-// UNSUPPORTED: stdlib=libstdc++, stdlib=msvc
+// This test hangs forever when built against libstdc++ (Oct 2016).
+// UNSUPPORTED: stdlib=libstdc++
+
+// This test isn't quite standards-conforming: it's testing our specific
+// algorithm, where when lx.try_lock() fails we start the next attempt
+// with an unconditional lx.lock(). Thus our algorithm can handle a list
+// of mutexes where at-most-one of them is of the evil type `class L1`,
+// but will loop forever if two or more of them are `class L1`.
 
 // <mutex>
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D116712.398368.patch
Type: text/x-patch
Size: 1061 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20220108/dae56676/attachment.bin>


More information about the libcxx-commits mailing list