Reapply my less-lock-contention-in-leak-detector patch, now with new files

actually added.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79429 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson
2009-08-19 17:07:46 +00:00
parent de95c1b88b
commit c34ebf65af
4 changed files with 122 additions and 93 deletions

View File

@@ -16,6 +16,7 @@
#define LLVM_LLVMCONTEXT_IMPL_H
#include "ConstantsContext.h"
#include "LeaksContext.h"
#include "TypesContext.h"
#include "llvm/LLVMContext.h"
#include "llvm/Constants.h"
@@ -134,6 +135,10 @@ public:
ConstantInt *TheTrueVal;
ConstantInt *TheFalseVal;
// Lock used for guarding access to the leak detector
sys::SmartMutex<true> LLVMObjectsLock;
LeakDetectorImpl<Value> LLVMObjects;
// Lock used for guarding access to the type maps.
sys::SmartMutex<true> TypeMapLock;