[libcxx] r204078 - Implement N3891: A proposal to rename shared_mutex to shared_timed_mutex
David Majnemer
david.majnemer at gmail.com
Mon Mar 17 13:19:44 PDT 2014
Author: majnemer
Date: Mon Mar 17 15:19:44 2014
New Revision: 204078
URL: http://llvm.org/viewvc/llvm-project?rev=204078&view=rev
Log:
Implement N3891: A proposal to rename shared_mutex to shared_timed_mutex
This is as straightforward as it sounds, a renamed from shared_mutex to
shared_timed_mutex.
Note that libcxx .dylib and .so files built with c++14 support need to
be rebuilt.
Added:
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/nothing_to_do.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/assign.fail.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/copy.fail.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/default.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock_shared.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_for.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_for.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_until.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_until.pass.cpp
- copied, changed from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp
Removed:
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp
Modified:
libcxx/trunk/include/shared_mutex
libcxx/trunk/src/shared_mutex.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_assign.fail.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_ctor.fail.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/default.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_assign.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_ctor.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_adopt_lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_defer_lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_duration.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_time_point.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_try_to_lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/mutex.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/op_bool.pass.cpp
libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/owns_lock.pass.cpp
libcxx/trunk/www/cxx1y_status.html
Modified: libcxx/trunk/include/shared_mutex
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/shared_mutex?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/include/shared_mutex (original)
+++ libcxx/trunk/include/shared_mutex Mon Mar 17 15:19:44 2014
@@ -19,14 +19,14 @@
namespace std
{
-class shared_mutex
+class shared_timed_mutex
{
public:
- shared_mutex();
- ~shared_mutex();
+ shared_timed_mutex();
+ ~shared_timed_mutex();
- shared_mutex(const shared_mutex&) = delete;
- shared_mutex& operator=(const shared_mutex&) = delete;
+ shared_timed_mutex(const shared_timed_mutex&) = delete;
+ shared_timed_mutex& operator=(const shared_timed_mutex&) = delete;
// Exclusive ownership
void lock(); // blocking
@@ -114,7 +114,7 @@ template <class Mutex>
_LIBCPP_BEGIN_NAMESPACE_STD
-class _LIBCPP_TYPE_VIS shared_mutex
+class _LIBCPP_TYPE_VIS shared_timed_mutex
{
mutex __mut_;
condition_variable __gate1_;
@@ -124,11 +124,11 @@ class _LIBCPP_TYPE_VIS shared_mutex
static const unsigned __write_entered_ = 1U << (sizeof(unsigned)*__CHAR_BIT__ - 1);
static const unsigned __n_readers_ = ~__write_entered_;
public:
- shared_mutex();
- _LIBCPP_INLINE_VISIBILITY ~shared_mutex() = default;
+ shared_timed_mutex();
+ _LIBCPP_INLINE_VISIBILITY ~shared_timed_mutex() = default;
- shared_mutex(const shared_mutex&) = delete;
- shared_mutex& operator=(const shared_mutex&) = delete;
+ shared_timed_mutex(const shared_timed_mutex&) = delete;
+ shared_timed_mutex& operator=(const shared_timed_mutex&) = delete;
// Exclusive ownership
void lock();
@@ -163,7 +163,7 @@ public:
template <class _Clock, class _Duration>
bool
-shared_mutex::try_lock_until(
+shared_timed_mutex::try_lock_until(
const chrono::time_point<_Clock, _Duration>& __abs_time)
{
unique_lock<mutex> __lk(__mut_);
@@ -198,7 +198,7 @@ shared_mutex::try_lock_until(
template <class _Clock, class _Duration>
bool
-shared_mutex::try_lock_shared_until(
+shared_timed_mutex::try_lock_shared_until(
const chrono::time_point<_Clock, _Duration>& __abs_time)
{
unique_lock<mutex> __lk(__mut_);
Modified: libcxx/trunk/src/shared_mutex.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/shared_mutex.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/src/shared_mutex.cpp (original)
+++ libcxx/trunk/src/shared_mutex.cpp Mon Mar 17 15:19:44 2014
@@ -12,7 +12,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
-shared_mutex::shared_mutex()
+shared_timed_mutex::shared_timed_mutex()
: __state_(0)
{
}
@@ -20,7 +20,7 @@ shared_mutex::shared_mutex()
// Exclusive ownership
void
-shared_mutex::lock()
+shared_timed_mutex::lock()
{
unique_lock<mutex> lk(__mut_);
while (__state_ & __write_entered_)
@@ -31,7 +31,7 @@ shared_mutex::lock()
}
bool
-shared_mutex::try_lock()
+shared_timed_mutex::try_lock()
{
unique_lock<mutex> lk(__mut_);
if (__state_ == 0)
@@ -43,7 +43,7 @@ shared_mutex::try_lock()
}
void
-shared_mutex::unlock()
+shared_timed_mutex::unlock()
{
lock_guard<mutex> _(__mut_);
__state_ = 0;
@@ -53,7 +53,7 @@ shared_mutex::unlock()
// Shared ownership
void
-shared_mutex::lock_shared()
+shared_timed_mutex::lock_shared()
{
unique_lock<mutex> lk(__mut_);
while ((__state_ & __write_entered_) || (__state_ & __n_readers_) == __n_readers_)
@@ -64,7 +64,7 @@ shared_mutex::lock_shared()
}
bool
-shared_mutex::try_lock_shared()
+shared_timed_mutex::try_lock_shared()
{
unique_lock<mutex> lk(__mut_);
unsigned num_readers = __state_ & __n_readers_;
@@ -79,7 +79,7 @@ shared_mutex::try_lock_shared()
}
void
-shared_mutex::unlock_shared()
+shared_timed_mutex::unlock_shared()
{
lock_guard<mutex> _(__mut_);
unsigned num_readers = (__state_ & __n_readers_) - 1;
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_assign.fail.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_assign.fail.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_assign.fail.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_assign.fail.cpp Mon Mar 17 15:19:44 2014
@@ -17,16 +17,16 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m0;
-std::shared_mutex m1;
+std::shared_timed_mutex m0;
+std::shared_timed_mutex m1;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0(m0);
- std::shared_lock<std::shared_mutex> lk1(m1);
+ std::shared_lock<std::shared_timed_mutex> lk0(m0);
+ std::shared_lock<std::shared_timed_mutex> lk1(m1);
lk1 = lk0;
#else
# error
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_ctor.fail.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_ctor.fail.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_ctor.fail.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/copy_ctor.fail.cpp Mon Mar 17 15:19:44 2014
@@ -16,14 +16,14 @@
#include <shared_mutex>
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0(m);
- std::shared_lock<std::shared_mutex> lk = lk0;
+ std::shared_lock<std::shared_timed_mutex> lk0(m);
+ std::shared_lock<std::shared_timed_mutex> lk = lk0;
#else
# error
#endif // _LIBCPP_STD_VER > 11
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/default.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/default.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/default.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/default.pass.cpp Mon Mar 17 15:19:44 2014
@@ -19,7 +19,7 @@
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> ul;
+ std::shared_lock<std::shared_timed_mutex> ul;
assert(!ul.owns_lock());
assert(ul.mutex() == nullptr);
#endif // _LIBCPP_STD_VER > 11
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_assign.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_assign.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_assign.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_assign.pass.cpp Mon Mar 17 15:19:44 2014
@@ -18,16 +18,16 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m0;
-std::shared_mutex m1;
+std::shared_timed_mutex m0;
+std::shared_timed_mutex m1;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0(m0);
- std::shared_lock<std::shared_mutex> lk1(m1);
+ std::shared_lock<std::shared_timed_mutex> lk0(m0);
+ std::shared_lock<std::shared_timed_mutex> lk1(m1);
lk1 = std::move(lk0);
assert(lk1.mutex() == &m0);
assert(lk1.owns_lock() == true);
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_ctor.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_ctor.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_ctor.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/move_ctor.pass.cpp Mon Mar 17 15:19:44 2014
@@ -17,14 +17,14 @@
#include <cassert>
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0(m);
- std::shared_lock<std::shared_mutex> lk = std::move(lk0);
+ std::shared_lock<std::shared_timed_mutex> lk0(m);
+ std::shared_lock<std::shared_timed_mutex> lk = std::move(lk0);
assert(lk.mutex() == &m);
assert(lk.owns_lock() == true);
assert(lk0.mutex() == nullptr);
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp Mon Mar 17 15:19:44 2014
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
@@ -34,7 +34,7 @@ void f()
time_point t0 = Clock::now();
time_point t1;
{
- std::shared_lock<std::shared_mutex> ul(m);
+ std::shared_lock<std::shared_timed_mutex> ul(m);
t1 = Clock::now();
}
ns d = t1 - t0 - ms(250);
@@ -46,7 +46,7 @@ void g()
time_point t0 = Clock::now();
time_point t1;
{
- std::shared_lock<std::shared_mutex> ul(m);
+ std::shared_lock<std::shared_timed_mutex> ul(m);
t1 = Clock::now();
}
ns d = t1 - t0;
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_adopt_lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_adopt_lock.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_adopt_lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_adopt_lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -19,9 +19,9 @@
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_mutex m;
+ std::shared_timed_mutex m;
m.lock();
- std::shared_lock<std::shared_mutex> lk(m, std::adopt_lock);
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::adopt_lock);
assert(lk.mutex() == &m);
assert(lk.owns_lock() == true);
#endif // _LIBCPP_STD_VER > 11
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_defer_lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_defer_lock.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_defer_lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_defer_lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -19,8 +19,8 @@
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_mutex m;
- std::shared_lock<std::shared_mutex> lk(m, std::defer_lock);
+ std::shared_timed_mutex m;
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::defer_lock);
assert(lk.mutex() == &m);
assert(lk.owns_lock() == false);
#endif // _LIBCPP_STD_VER > 11
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_duration.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_duration.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_duration.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_duration.pass.cpp Mon Mar 17 15:19:44 2014
@@ -22,7 +22,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::steady_clock Clock;
typedef Clock::time_point time_point;
@@ -33,7 +33,7 @@ typedef std::chrono::nanoseconds ns;
void f1()
{
time_point t0 = Clock::now();
- std::shared_lock<std::shared_mutex> lk(m, ms(300));
+ std::shared_lock<std::shared_timed_mutex> lk(m, ms(300));
assert(lk.owns_lock() == true);
time_point t1 = Clock::now();
ns d = t1 - t0 - ms(250);
@@ -43,7 +43,7 @@ void f1()
void f2()
{
time_point t0 = Clock::now();
- std::shared_lock<std::shared_mutex> lk(m, ms(250));
+ std::shared_lock<std::shared_timed_mutex> lk(m, ms(250));
assert(lk.owns_lock() == false);
time_point t1 = Clock::now();
ns d = t1 - t0 - ms(250);
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_time_point.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_time_point.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_time_point.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_time_point.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// template <class Clock, class Duration>
// shared_lock(mutex_type& m, const chrono::time_point<Clock, Duration>& abs_time);
@@ -22,7 +22,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::steady_clock Clock;
typedef Clock::time_point time_point;
@@ -33,7 +33,7 @@ typedef std::chrono::nanoseconds ns;
void f1()
{
time_point t0 = Clock::now();
- std::shared_lock<std::shared_mutex> lk(m, Clock::now() + ms(300));
+ std::shared_lock<std::shared_timed_mutex> lk(m, Clock::now() + ms(300));
assert(lk.owns_lock() == true);
time_point t1 = Clock::now();
ns d = t1 - t0 - ms(250);
@@ -43,7 +43,7 @@ void f1()
void f2()
{
time_point t0 = Clock::now();
- std::shared_lock<std::shared_mutex> lk(m, Clock::now() + ms(250));
+ std::shared_lock<std::shared_timed_mutex> lk(m, Clock::now() + ms(250));
assert(lk.owns_lock() == false);
time_point t1 = Clock::now();
ns d = t1 - t0 - ms(250);
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_try_to_lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_try_to_lock.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_try_to_lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex_try_to_lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
@@ -33,20 +33,20 @@ void f()
{
time_point t0 = Clock::now();
{
- std::shared_lock<std::shared_mutex> lk(m, std::try_to_lock);
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::try_to_lock);
assert(lk.owns_lock() == false);
}
{
- std::shared_lock<std::shared_mutex> lk(m, std::try_to_lock);
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::try_to_lock);
assert(lk.owns_lock() == false);
}
{
- std::shared_lock<std::shared_mutex> lk(m, std::try_to_lock);
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::try_to_lock);
assert(lk.owns_lock() == false);
}
while (true)
{
- std::shared_lock<std::shared_mutex> lk(m, std::try_to_lock);
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::try_to_lock);
if (lk.owns_lock())
break;
}
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
@@ -31,7 +31,7 @@ typedef std::chrono::nanoseconds ns;
void f()
{
- std::shared_lock<std::shared_mutex> lk(m, std::defer_lock);
+ std::shared_lock<std::shared_timed_mutex> lk(m, std::defer_lock);
time_point t0 = Clock::now();
lk.lock();
time_point t1 = Clock::now();
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/mutex.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/mutex.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/mutex.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/mutex.pass.cpp Mon Mar 17 15:19:44 2014
@@ -18,16 +18,16 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0;
+ std::shared_lock<std::shared_timed_mutex> lk0;
assert(lk0.mutex() == nullptr);
- std::shared_lock<std::shared_mutex> lk1(m);
+ std::shared_lock<std::shared_timed_mutex> lk1(m);
assert(lk1.mutex() == &m);
lk1.unlock();
assert(lk1.mutex() == &m);
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/op_bool.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/op_bool.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/op_bool.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/op_bool.pass.cpp Mon Mar 17 15:19:44 2014
@@ -18,16 +18,16 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0;
+ std::shared_lock<std::shared_timed_mutex> lk0;
assert(static_cast<bool>(lk0) == false);
- std::shared_lock<std::shared_mutex> lk1(m);
+ std::shared_lock<std::shared_timed_mutex> lk1(m);
assert(static_cast<bool>(lk1) == true);
lk1.unlock();
assert(static_cast<bool>(lk1) == false);
Modified: libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/owns_lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/owns_lock.pass.cpp?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/owns_lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.obs/owns_lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -18,16 +18,16 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
#endif // _LIBCPP_STD_VER > 11
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_lock<std::shared_mutex> lk0;
+ std::shared_lock<std::shared_timed_mutex> lk0;
assert(lk0.owns_lock() == false);
- std::shared_lock<std::shared_mutex> lk1(m);
+ std::shared_lock<std::shared_timed_mutex> lk1(m);
assert(lk1.owns_lock() == true);
lk1.unlock();
assert(lk1.owns_lock() == false);
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp (removed)
@@ -1,12 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-int main()
-{
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp (removed)
@@ -1,27 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// shared_mutex& operator=(const shared_mutex&) = delete;
-
-#include <shared_mutex>
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- std::shared_mutex m0;
- std::shared_mutex m1;
- m1 = m0;
-#else
-# error
-#endif
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp (removed)
@@ -1,26 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// shared_mutex(const shared_mutex&) = delete;
-
-#include <shared_mutex>
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- std::shared_mutex m0;
- std::shared_mutex m1(m0);
-#else
-# error
-#endif
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp (removed)
@@ -1,23 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// shared_mutex();
-
-#include <shared_mutex>
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- std::shared_mutex m;
-#endif
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp (removed)
@@ -1,52 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// void lock();
-
-#include <shared_mutex>
-#include <thread>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::system_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f()
-{
- time_point t0 = Clock::now();
- m.lock();
- time_point t1 = Clock::now();
- m.unlock();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- m.lock();
- std::thread t(f);
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- t.join();
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp (removed)
@@ -1,75 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// void lock_shared();
-
-#include <shared_mutex>
-#include <thread>
-#include <vector>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::system_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f()
-{
- time_point t0 = Clock::now();
- m.lock_shared();
- time_point t1 = Clock::now();
- m.unlock_shared();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-void g()
-{
- time_point t0 = Clock::now();
- m.lock_shared();
- time_point t1 = Clock::now();
- m.unlock_shared();
- ns d = t1 - t0;
- assert(d < ms(50)); // within 50ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- m.lock();
- std::vector<std::thread> v;
- for (int i = 0; i < 5; ++i)
- v.push_back(std::thread(f));
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- for (auto& t : v)
- t.join();
- m.lock_shared();
- for (auto& t : v)
- t = std::thread(g);
- std::thread q(f);
- std::this_thread::sleep_for(ms(250));
- m.unlock_shared();
- for (auto& t : v)
- t.join();
- q.join();
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp (removed)
@@ -1,56 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// bool try_lock();
-
-#include <shared_mutex>
-#include <thread>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::system_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f()
-{
- time_point t0 = Clock::now();
- assert(!m.try_lock());
- assert(!m.try_lock());
- assert(!m.try_lock());
- while(!m.try_lock())
- ;
- time_point t1 = Clock::now();
- m.unlock();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(200)); // within 200ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- m.lock();
- std::thread t(f);
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- t.join();
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp (removed)
@@ -1,71 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// template <class Rep, class Period>
-// bool try_lock_for(const chrono::duration<Rep, Period>& rel_time);
-
-#include <shared_mutex>
-#include <thread>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::steady_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f1()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_for(ms(300)) == true);
- time_point t1 = Clock::now();
- m.unlock();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-void f2()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_for(ms(250)) == false);
- time_point t1 = Clock::now();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- {
- m.lock();
- std::thread t(f1);
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- t.join();
- }
- {
- m.lock();
- std::thread t(f2);
- std::this_thread::sleep_for(ms(300));
- m.unlock();
- t.join();
- }
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp (removed)
@@ -1,60 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// bool try_lock_shared();
-
-#include <shared_mutex>
-#include <thread>
-#include <vector>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::system_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f()
-{
- time_point t0 = Clock::now();
- assert(!m.try_lock_shared());
- assert(!m.try_lock_shared());
- assert(!m.try_lock_shared());
- while(!m.try_lock_shared())
- ;
- time_point t1 = Clock::now();
- m.unlock_shared();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(200)); // within 200ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- m.lock();
- std::vector<std::thread> v;
- for (int i = 0; i < 5; ++i)
- v.push_back(std::thread(f));
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- for (auto& t : v)
- t.join();
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp (removed)
@@ -1,78 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// template <class Rep, class Period>
-// bool try_lock_shared_for(const chrono::duration<Rep, Period>& rel_time);
-
-#include <shared_mutex>
-#include <thread>
-#include <vector>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::steady_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f1()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_shared_for(ms(300)) == true);
- time_point t1 = Clock::now();
- m.unlock_shared();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-void f2()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_shared_for(ms(250)) == false);
- time_point t1 = Clock::now();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- {
- m.lock();
- std::vector<std::thread> v;
- for (int i = 0; i < 5; ++i)
- v.push_back(std::thread(f1));
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- for (auto& t : v)
- t.join();
- }
- {
- m.lock();
- std::vector<std::thread> v;
- for (int i = 0; i < 5; ++i)
- v.push_back(std::thread(f2));
- std::this_thread::sleep_for(ms(300));
- m.unlock();
- for (auto& t : v)
- t.join();
- }
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp (removed)
@@ -1,78 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// template <class Clock, class Duration>
-// bool try_lock_shared_until(const chrono::time_point<Clock, Duration>& abs_time);
-
-#include <shared_mutex>
-#include <thread>
-#include <vector>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::steady_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f1()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_shared_until(Clock::now() + ms(300)) == true);
- time_point t1 = Clock::now();
- m.unlock_shared();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-void f2()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_shared_until(Clock::now() + ms(250)) == false);
- time_point t1 = Clock::now();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- {
- m.lock();
- std::vector<std::thread> v;
- for (int i = 0; i < 5; ++i)
- v.push_back(std::thread(f1));
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- for (auto& t : v)
- t.join();
- }
- {
- m.lock();
- std::vector<std::thread> v;
- for (int i = 0; i < 5; ++i)
- v.push_back(std::thread(f2));
- std::this_thread::sleep_for(ms(300));
- m.unlock();
- for (auto& t : v)
- t.join();
- }
-#endif // _LIBCPP_STD_VER > 11
-}
Removed: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp?rev=204077&view=auto
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp (removed)
@@ -1,71 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is dual licensed under the MIT and the University of Illinois Open
-// Source Licenses. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-// <shared_mutex>
-
-// class shared_mutex;
-
-// template <class Clock, class Duration>
-// bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time);
-
-#include <shared_mutex>
-#include <thread>
-#include <cstdlib>
-#include <cassert>
-
-#if _LIBCPP_STD_VER > 11
-
-std::shared_mutex m;
-
-typedef std::chrono::steady_clock Clock;
-typedef Clock::time_point time_point;
-typedef Clock::duration duration;
-typedef std::chrono::milliseconds ms;
-typedef std::chrono::nanoseconds ns;
-
-void f1()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_until(Clock::now() + ms(300)) == true);
- time_point t1 = Clock::now();
- m.unlock();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-void f2()
-{
- time_point t0 = Clock::now();
- assert(m.try_lock_until(Clock::now() + ms(250)) == false);
- time_point t1 = Clock::now();
- ns d = t1 - t0 - ms(250);
- assert(d < ms(50)); // within 50ms
-}
-
-#endif // _LIBCPP_STD_VER > 11
-
-int main()
-{
-#if _LIBCPP_STD_VER > 11
- {
- m.lock();
- std::thread t(f1);
- std::this_thread::sleep_for(ms(250));
- m.unlock();
- t.join();
- }
- {
- m.lock();
- std::thread t(f2);
- std::this_thread::sleep_for(ms(300));
- m.unlock();
- t.join();
- }
-#endif // _LIBCPP_STD_VER > 11
-}
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/nothing_to_do.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/nothing_to_do.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/nothing_to_do.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/nothing_to_do.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
(empty)
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/assign.fail.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/assign.fail.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/assign.fail.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/assign.fail.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/assign.fail.cpp Mon Mar 17 15:19:44 2014
@@ -9,17 +9,17 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
-// shared_mutex& operator=(const shared_mutex&) = delete;
+// shared_timed_mutex& operator=(const shared_timed_mutex&) = delete;
#include <shared_mutex>
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_mutex m0;
- std::shared_mutex m1;
+ std::shared_timed_mutex m0;
+ std::shared_timed_mutex m1;
m1 = m0;
#else
# error
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/copy.fail.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/copy.fail.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/copy.fail.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/copy.fail.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/copy.fail.cpp Mon Mar 17 15:19:44 2014
@@ -9,17 +9,17 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
-// shared_mutex(const shared_mutex&) = delete;
+// shared_timed_mutex(const shared_timed_mutex&) = delete;
#include <shared_mutex>
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_mutex m0;
- std::shared_mutex m1(m0);
+ std::shared_timed_mutex m0;
+ std::shared_timed_mutex m1(m0);
#else
# error
#endif
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/default.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/default.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/default.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/default.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/default.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,15 +9,15 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
-// shared_mutex();
+// shared_timed_mutex();
#include <shared_mutex>
int main()
{
#if _LIBCPP_STD_VER > 11
- std::shared_mutex m;
+ std::shared_timed_mutex m;
#endif
}
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// void lock();
@@ -20,7 +20,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock_shared.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock_shared.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock_shared.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/lock_shared.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/lock_shared.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// void lock_shared();
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// bool try_lock();
@@ -20,7 +20,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_for.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_for.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_for.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_for.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_for.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// template <class Rep, class Period>
// bool try_lock_for(const chrono::duration<Rep, Period>& rel_time);
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::steady_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// bool try_lock_shared();
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::system_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_for.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_for.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_for.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_for.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_for.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// template <class Rep, class Period>
// bool try_lock_shared_for(const chrono::duration<Rep, Period>& rel_time);
@@ -22,7 +22,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::steady_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_until.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_until.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_until.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_shared_until.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_shared_until.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// template <class Clock, class Duration>
// bool try_lock_shared_until(const chrono::time_point<Clock, Duration>& abs_time);
@@ -22,7 +22,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::steady_clock Clock;
typedef Clock::time_point time_point;
Copied: libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_until.pass.cpp (from r204077, libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp)
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_until.pass.cpp?p2=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_until.pass.cpp&p1=libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp&r1=204077&r2=204078&rev=204078&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedmutex.requirements/thread.sharedmutex.class/try_lock_until.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.mutex/thread.mutex.requirements/thread.sharedtimedmutex.requirements/thread.sharedtimedmutex.class/try_lock_until.pass.cpp Mon Mar 17 15:19:44 2014
@@ -9,7 +9,7 @@
// <shared_mutex>
-// class shared_mutex;
+// class shared_timed_mutex;
// template <class Clock, class Duration>
// bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time);
@@ -21,7 +21,7 @@
#if _LIBCPP_STD_VER > 11
-std::shared_mutex m;
+std::shared_timed_mutex m;
typedef std::chrono::steady_clock Clock;
typedef Clock::time_point time_point;
Modified: libcxx/trunk/www/cxx1y_status.html
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/www/cxx1y_status.html?rev=204078&r1=204077&r2=204078&view=diff
==============================================================================
--- libcxx/trunk/www/cxx1y_status.html (original)
+++ libcxx/trunk/www/cxx1y_status.html Mon Mar 17 15:19:44 2014
@@ -101,7 +101,7 @@
<tr><td><a href="http://isocpp.org/files/papers/N3924.pdf">3924</a></td><td>LWG</td><td>Discouraging rand() in C++14</td><td>Issaquah</td><td>Complete</td><td>3.5</td></tr>
<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n3887">3887</a></td><td>LWG</td><td>Consistent Metafunction Aliases</td><td>Issaquah</td><td>Complete</td><td>3.5</td></tr>
- <tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n3891">3891</a></td><td>SG1</td><td>A proposal to rename shared_mutex to shared_timed_mutex</td><td>Issaquah</td><td></td><td></td></tr>
+ <tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n3891">3891</a></td><td>SG1</td><td>A proposal to rename shared_mutex to shared_timed_mutex</td><td>Issaquah</td><td>Complete</td><td>3.5</td></tr>
<!-- <tr><td></td><td></td><td></td><td></td><td></td><td></td></tr> -->
</table>
More information about the cfe-commits
mailing list