diff options
author | Zachary Turner <zturner@google.com> | 2014-06-20 21:07:14 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2014-06-20 21:07:14 +0000 |
commit | 91e18f7639c61ca40efe39efbfcba825570a824e (patch) | |
tree | dd4ecf9c26f55bb430daef6c1efb180b3a48cca4 /unittests | |
parent | 5b8e73ef81bdbc3ce4d020f66d875e22827b7626 (diff) | |
download | llvm-91e18f7639c61ca40efe39efbfcba825570a824e.tar.gz llvm-91e18f7639c61ca40efe39efbfcba825570a824e.tar.bz2 llvm-91e18f7639c61ca40efe39efbfcba825570a824e.tar.xz |
Revert "Replace Execution Engine's mutex with std::recursive_mutex."
This reverts commit 1f502bd9d7d2c1f98ad93a09ffe435e11a95aedd, due to
GCC / MinGW's lack of support for C++11 threading.
It's possible this will go back in after we come up with a
reasonable solution.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211401 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests')
-rw-r--r-- | unittests/IR/ValueMapTest.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/unittests/IR/ValueMapTest.cpp b/unittests/IR/ValueMapTest.cpp index ef8258882a..0b7198fc6e 100644 --- a/unittests/IR/ValueMapTest.cpp +++ b/unittests/IR/ValueMapTest.cpp @@ -186,19 +186,19 @@ struct LockMutex : ValueMapConfig<KeyT, MutexT> { }; static void onRAUW(const ExtraData &Data, KeyT Old, KeyT New) { *Data.CalledRAUW = true; - EXPECT_FALSE(Data.M->try_lock()) << "Mutex should already be locked."; + EXPECT_FALSE(Data.M->tryacquire()) << "Mutex should already be locked."; } static void onDelete(const ExtraData &Data, KeyT Old) { *Data.CalledDeleted = true; - EXPECT_FALSE(Data.M->try_lock()) << "Mutex should already be locked."; + EXPECT_FALSE(Data.M->tryacquire()) << "Mutex should already be locked."; } static MutexT *getMutex(const ExtraData &Data) { return Data.M; } }; #if LLVM_ENABLE_THREADS TYPED_TEST(ValueMapTest, LocksMutex) { - std::mutex M; // Not recursive. + sys::Mutex M(false); // Not recursive. bool CalledRAUW = false, CalledDeleted = false; - typedef LockMutex<TypeParam*, std::mutex> ConfigType; + typedef LockMutex<TypeParam*, sys::Mutex> ConfigType; typename ConfigType::ExtraData Data = {&M, &CalledRAUW, &CalledDeleted}; ValueMap<TypeParam*, int, ConfigType> VM(Data); VM[this->BitcastV.get()] = 7; |