Revert "Replace Execution Engine's mutex with std::recursive_mutex."

This reverts commit 1f502bd9d7, 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
This commit is contained in:
Zachary Turner
2014-06-20 21:07:14 +00:00
parent 5b8e73ef81
commit 91e18f7639
7 changed files with 71 additions and 69 deletions

View File

@ -22,10 +22,10 @@
#include "llvm/IR/ValueMap.h"
#include "llvm/MC/MCCodeGenInfo.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/Mutex.h"
#include "llvm/Target/TargetMachine.h"
#include "llvm/Target/TargetOptions.h"
#include <map>
#include <mutex>
#include <string>
#include <vector>
@ -42,6 +42,7 @@ class JITEventListener;
class JITMemoryManager;
class MachineCodeInfo;
class Module;
class MutexGuard;
class ObjectCache;
class RTDyldMemoryManager;
class Triple;
@ -58,7 +59,7 @@ class ExecutionEngineState {
public:
struct AddressMapConfig : public ValueMapConfig<const GlobalValue*> {
typedef ExecutionEngineState *ExtraData;
static std::recursive_mutex *getMutex(ExecutionEngineState *EES);
static sys::Mutex *getMutex(ExecutionEngineState *EES);
static void onDelete(ExecutionEngineState *EES, const GlobalValue *Old);
static void onRAUW(ExecutionEngineState *, const GlobalValue *,
const GlobalValue *);
@ -163,7 +164,7 @@ public:
/// lock - This lock protects the ExecutionEngine, MCJIT, JIT, JITResolver and
/// JITEmitter classes. It must be held while changing the internal state of
/// any of those classes.
std::recursive_mutex lock;
sys::Mutex lock;
//===--------------------------------------------------------------------===//
// ExecutionEngine Startup