1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00

Remove the Win32 implementation, since it doesn't compile pre-Vista.

llvm-svn: 73550
This commit is contained in:
Owen Anderson 2009-06-16 20:49:20 +00:00
parent c52c99f111
commit 208c38b522

View File

@ -18,36 +18,31 @@
#include "Win32.h"
// FIXME: THIS IS NOT THREAD-SAFE!!
// Windows does not have reader-writer locks pre-Vista. If you want to have
// thread-safe LLVM on Windows, for now at least, you need to use a pthreads
// replacement library.
namespace llvm {
using namespace sys;
RWMutex::RWMutex() {
data_ = new PSRWLOCK;
InitializeSRWLock((PSRWLOCK*)data_);
}
RWMutex::RWMutex() { }
RWMutex::~RWMutex() {
delete (PSRWLOCK*)data_;
data_ = 0;
}
RWMutex::~RWMutex() { }
bool RWMutex::reader_acquire() {
AcquireSRWLockShared((PSRWLOCK*)data_);
return true;
}
bool RWMutex::reader_release() {
ReleaseSRWLockShared((PSRWLOCK*)data_);
return true;
}
bool RWMutex::writer_acquire() {
AcquireSRWLockExclusive((PSRWLOCK*)data_);
return true;
}
bool RWMutex::writer_release() {
ReleaseSRWLockExclusive((PSRWLOCK*)data_);
return true;
}