#include "runtimehandles.h"
#include "vars.hpp"
#include "cycletimer.h"
-#include "defaultallocator.h"
#ifdef FEATURE_REMOTING
#include "remoting.h"
#endif
if (s_addrToMDMap == NULL)
{
- s_addrToMDMap = new AddrToMDMap(DefaultAllocator::Singleton());
+ s_addrToMDMap = new AddrToMDMap();
}
return s_addrToMDMap;
}
CORINFO_METHOD_HANDLE dummy;
assert(!map->Lookup(addr, &dummy));
#endif // DEBUG
- map->Set(addr, md);
+ map->AddOrReplace(KeyValuePair<void*,CORINFO_METHOD_HANDLE>(addr, md));
}
MethodDesc* Interpreter::InterpretationStubToMethodInfo(PCODE addr)
if (s_methodHandleToInterpMethInfoPtrMap == NULL)
{
- s_methodHandleToInterpMethInfoPtrMap = new MethodHandleToInterpMethInfoPtrMap(DefaultAllocator::Singleton());
+ s_methodHandleToInterpMethInfoPtrMap = new MethodHandleToInterpMethInfoPtrMap();
}
return s_methodHandleToInterpMethInfoPtrMap;
}
mi.m_thread = GetThread();
#endif
- bool b = map->Set(md, mi);
- _ASSERTE_MSG(!b, "Multiple InterpMethInfos for method desc.");
+ _ASSERTE_MSG(map->LookupPtr(md) == NULL, "Multiple InterpMethInfos for method desc.");
+ map->Add(md, mi);
return methInfo;
}
#include "corinfo.h"
#include "codeman.h"
#include "jitinterface.h"
-#include "simplerhash.h"
#include "stack.h"
#include "crst.h"
#include "callhelpers.h"
#endif
};
- typedef SimplerHashTable<void*, PtrKeyFuncs<void>, CORINFO_METHOD_HANDLE, DefaultSimplerHashBehavior> AddrToMDMap;
+ typedef MapSHash<void*, CORINFO_METHOD_HANDLE> AddrToMDMap;
static AddrToMDMap* s_addrToMDMap;
static AddrToMDMap* GetAddrToMdMap();
Thread* m_thread;
#endif // _DEBUG
};
- typedef SimplerHashTable<CORINFO_METHOD_HANDLE, PtrKeyFuncs<CORINFO_METHOD_STRUCT_>, MethInfo, DefaultSimplerHashBehavior> MethodHandleToInterpMethInfoPtrMap;
+ typedef MapSHash<CORINFO_METHOD_HANDLE, MethInfo> MethodHandleToInterpMethInfoPtrMap;
static MethodHandleToInterpMethInfoPtrMap* s_methodHandleToInterpMethInfoPtrMap;
static MethodHandleToInterpMethInfoPtrMap* GetMethodHandleToInterpMethInfoPtrMap();