summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2019-06-11 13:18:03 -0700
committerGitHub <noreply@github.com>2019-06-11 13:18:03 -0700
commitbeeae6da7c1f35fa335868521e1de21a2403eff4 (patch)
tree1bfdb63223308e2db827b9263cf77259f07398af /src
parent93675fbf467f54ab0f1f5d183c70750c9822c9ca (diff)
downloadcoreclr-beeae6da7c1f35fa335868521e1de21a2403eff4.tar.gz
coreclr-beeae6da7c1f35fa335868521e1de21a2403eff4.tar.bz2
coreclr-beeae6da7c1f35fa335868521e1de21a2403eff4.zip
Delete dead code (#25066)
Diffstat (limited to 'src')
-rw-r--r--src/ToolBox/superpmi/superpmi-shared/coreclrcommoncallbacks.h1
-rw-r--r--src/ToolBox/superpmi/superpmi-shim-collector/coreclrcallbacks.cpp5
-rw-r--r--src/ToolBox/superpmi/superpmi-shim-collector/superpmi-shim-collector.cpp2
-rw-r--r--src/ToolBox/superpmi/superpmi-shim-counter/coreclrcallbacks.cpp13
-rw-r--r--src/ToolBox/superpmi/superpmi-shim-counter/superpmi-shim-counter.cpp2
-rw-r--r--src/ToolBox/superpmi/superpmi-shim-simple/coreclrcallbacks.cpp5
-rw-r--r--src/ToolBox/superpmi/superpmi-shim-simple/superpmi-shim-simple.cpp2
-rw-r--r--src/ToolBox/superpmi/superpmi/coreclrcallbacks.cpp7
-rw-r--r--src/debug/daccess/daccess.cpp1
-rw-r--r--src/debug/di/rsmain.cpp1
-rw-r--r--src/dlls/mscoree/mscoree.cpp1
-rw-r--r--src/inc/utilcode.h11
-rw-r--r--src/vm/appdomain.cpp13
-rw-r--r--src/vm/ceemain.cpp1
-rw-r--r--src/vm/dllimport.cpp41
-rw-r--r--src/vm/dllimport.h17
-rw-r--r--src/vm/finalizerthread.cpp30
-rw-r--r--src/vm/util.cpp33
-rw-r--r--src/vm/util.hpp2
-rw-r--r--src/vm/vars.hpp5
20 files changed, 4 insertions, 189 deletions
diff --git a/src/ToolBox/superpmi/superpmi-shared/coreclrcommoncallbacks.h b/src/ToolBox/superpmi/superpmi-shared/coreclrcommoncallbacks.h
index 674268d52a..3d5a4dc0b6 100644
--- a/src/ToolBox/superpmi/superpmi-shared/coreclrcommoncallbacks.h
+++ b/src/ToolBox/superpmi/superpmi-shared/coreclrcommoncallbacks.h
@@ -10,6 +10,5 @@
IExecutionEngine* STDMETHODCALLTYPE IEE_t();
HRESULT STDMETHODCALLTYPE GetCORSystemDirectory(LPWSTR pbuffer, DWORD cchBuffer, DWORD* pdwlength);
-void* STDMETHODCALLTYPE GetCLRFunction(LPCSTR functionName);
#endif
diff --git a/src/ToolBox/superpmi/superpmi-shim-collector/coreclrcallbacks.cpp b/src/ToolBox/superpmi/superpmi-shim-collector/coreclrcallbacks.cpp
index 759e6717d4..0d79ce7b26 100644
--- a/src/ToolBox/superpmi/superpmi-shim-collector/coreclrcallbacks.cpp
+++ b/src/ToolBox/superpmi/superpmi-shim-collector/coreclrcallbacks.cpp
@@ -15,8 +15,3 @@ IExecutionEngine* STDMETHODCALLTYPE IEE_t()
iee->original_IEE = original_CoreClrCallbacks->m_pfnIEE();
return iee;
}
-
-void* STDMETHODCALLTYPE GetCLRFunction(LPCSTR functionName)
-{
- return original_CoreClrCallbacks->m_pfnGetCLRFunction(functionName);
-}
diff --git a/src/ToolBox/superpmi/superpmi-shim-collector/superpmi-shim-collector.cpp b/src/ToolBox/superpmi/superpmi-shim-collector/superpmi-shim-collector.cpp
index 71d0e49a2b..cad8ac1cfb 100644
--- a/src/ToolBox/superpmi/superpmi-shim-collector/superpmi-shim-collector.cpp
+++ b/src/ToolBox/superpmi/superpmi-shim-collector/superpmi-shim-collector.cpp
@@ -211,14 +211,12 @@ extern "C" DLLEXPORT void __stdcall sxsJitStartup(CoreClrCallbacks const& origin
original_CoreClrCallbacks->m_hmodCoreCLR = original_cccallbacks.m_hmodCoreCLR;
original_CoreClrCallbacks->m_pfnIEE = original_cccallbacks.m_pfnIEE;
original_CoreClrCallbacks->m_pfnGetCORSystemDirectory = original_cccallbacks.m_pfnGetCORSystemDirectory;
- original_CoreClrCallbacks->m_pfnGetCLRFunction = original_cccallbacks.m_pfnGetCLRFunction;
CoreClrCallbacks* temp = new CoreClrCallbacks();
temp->m_hmodCoreCLR = original_cccallbacks.m_hmodCoreCLR;
temp->m_pfnIEE = IEE_t;
temp->m_pfnGetCORSystemDirectory = original_cccallbacks.m_pfnGetCORSystemDirectory;
- temp->m_pfnGetCLRFunction = GetCLRFunction;
pnsxsJitStartup(*temp);
}
diff --git a/src/ToolBox/superpmi/superpmi-shim-counter/coreclrcallbacks.cpp b/src/ToolBox/superpmi/superpmi-shim-counter/coreclrcallbacks.cpp
index c5ef40227c..0d79ce7b26 100644
--- a/src/ToolBox/superpmi/superpmi-shim-counter/coreclrcallbacks.cpp
+++ b/src/ToolBox/superpmi/superpmi-shim-counter/coreclrcallbacks.cpp
@@ -15,16 +15,3 @@ IExecutionEngine* STDMETHODCALLTYPE IEE_t()
iee->original_IEE = original_CoreClrCallbacks->m_pfnIEE();
return iee;
}
-
-/*#pragma warning( suppress :4996 ) //deprecated
-HRESULT STDMETHODCALLTYPE GetCORSystemDirectory(LPWSTR pbuffer, DWORD cchBuffer, DWORD* pdwlength)
-{
- DebugBreakorAV(131);
- return 0;
-}
-*/
-
-void* STDMETHODCALLTYPE GetCLRFunction(LPCSTR functionName)
-{
- return original_CoreClrCallbacks->m_pfnGetCLRFunction(functionName);
-}
diff --git a/src/ToolBox/superpmi/superpmi-shim-counter/superpmi-shim-counter.cpp b/src/ToolBox/superpmi/superpmi-shim-counter/superpmi-shim-counter.cpp
index 65ec7242e9..37fe7252ac 100644
--- a/src/ToolBox/superpmi/superpmi-shim-counter/superpmi-shim-counter.cpp
+++ b/src/ToolBox/superpmi/superpmi-shim-counter/superpmi-shim-counter.cpp
@@ -207,14 +207,12 @@ extern "C" DLLEXPORT void __stdcall sxsJitStartup(CoreClrCallbacks const& origin
original_CoreClrCallbacks->m_hmodCoreCLR = original_cccallbacks.m_hmodCoreCLR;
original_CoreClrCallbacks->m_pfnIEE = original_cccallbacks.m_pfnIEE;
original_CoreClrCallbacks->m_pfnGetCORSystemDirectory = original_cccallbacks.m_pfnGetCORSystemDirectory;
- original_CoreClrCallbacks->m_pfnGetCLRFunction = original_cccallbacks.m_pfnGetCLRFunction;
CoreClrCallbacks* temp = new CoreClrCallbacks();
temp->m_hmodCoreCLR = original_cccallbacks.m_hmodCoreCLR;
temp->m_pfnIEE = IEE_t;
temp->m_pfnGetCORSystemDirectory = original_cccallbacks.m_pfnGetCORSystemDirectory;
- temp->m_pfnGetCLRFunction = GetCLRFunction;
pnsxsJitStartup(*temp);
}
diff --git a/src/ToolBox/superpmi/superpmi-shim-simple/coreclrcallbacks.cpp b/src/ToolBox/superpmi/superpmi-shim-simple/coreclrcallbacks.cpp
index 759e6717d4..0d79ce7b26 100644
--- a/src/ToolBox/superpmi/superpmi-shim-simple/coreclrcallbacks.cpp
+++ b/src/ToolBox/superpmi/superpmi-shim-simple/coreclrcallbacks.cpp
@@ -15,8 +15,3 @@ IExecutionEngine* STDMETHODCALLTYPE IEE_t()
iee->original_IEE = original_CoreClrCallbacks->m_pfnIEE();
return iee;
}
-
-void* STDMETHODCALLTYPE GetCLRFunction(LPCSTR functionName)
-{
- return original_CoreClrCallbacks->m_pfnGetCLRFunction(functionName);
-}
diff --git a/src/ToolBox/superpmi/superpmi-shim-simple/superpmi-shim-simple.cpp b/src/ToolBox/superpmi/superpmi-shim-simple/superpmi-shim-simple.cpp
index 60fa17dcc6..897880aef7 100644
--- a/src/ToolBox/superpmi/superpmi-shim-simple/superpmi-shim-simple.cpp
+++ b/src/ToolBox/superpmi/superpmi-shim-simple/superpmi-shim-simple.cpp
@@ -182,14 +182,12 @@ extern "C" DLLEXPORT void __stdcall sxsJitStartup(CoreClrCallbacks const& origin
original_CoreClrCallbacks->m_hmodCoreCLR = original_cccallbacks.m_hmodCoreCLR;
original_CoreClrCallbacks->m_pfnIEE = original_cccallbacks.m_pfnIEE;
original_CoreClrCallbacks->m_pfnGetCORSystemDirectory = original_cccallbacks.m_pfnGetCORSystemDirectory;
- original_CoreClrCallbacks->m_pfnGetCLRFunction = original_cccallbacks.m_pfnGetCLRFunction;
CoreClrCallbacks* temp = new CoreClrCallbacks();
temp->m_hmodCoreCLR = original_cccallbacks.m_hmodCoreCLR;
temp->m_pfnIEE = IEE_t;
temp->m_pfnGetCORSystemDirectory = original_cccallbacks.m_pfnGetCORSystemDirectory;
- temp->m_pfnGetCLRFunction = GetCLRFunction;
pnsxsJitStartup(*temp);
}
diff --git a/src/ToolBox/superpmi/superpmi/coreclrcallbacks.cpp b/src/ToolBox/superpmi/superpmi/coreclrcallbacks.cpp
index 15af7c8555..8727bd7fb7 100644
--- a/src/ToolBox/superpmi/superpmi/coreclrcallbacks.cpp
+++ b/src/ToolBox/superpmi/superpmi/coreclrcallbacks.cpp
@@ -24,12 +24,6 @@ HRESULT STDMETHODCALLTYPE GetCORSystemDirectory(LPWSTR pbuffer, DWORD cchBuffer,
HANDLE ourHeap = nullptr;
-void* STDMETHODCALLTYPE GetCLRFunction(LPCSTR functionName)
-{
- DebugBreakorAV(132);
- return nullptr;
-}
-
CoreClrCallbacks* InitCoreClrCallbacks()
{
CoreClrCallbacks* temp = new CoreClrCallbacks();
@@ -38,7 +32,6 @@ CoreClrCallbacks* InitCoreClrCallbacks()
temp->m_hmodCoreCLR = (HINSTANCE)(size_t)0xbadbad01; // any non-null value seems okay...
temp->m_pfnIEE = IEE_t;
temp->m_pfnGetCORSystemDirectory = nullptr; // GetCORSystemDirectory;
- temp->m_pfnGetCLRFunction = GetCLRFunction;
return temp;
}
diff --git a/src/debug/daccess/daccess.cpp b/src/debug/daccess/daccess.cpp
index 3985ed2c98..3b0eb7e81e 100644
--- a/src/debug/daccess/daccess.cpp
+++ b/src/debug/daccess/daccess.cpp
@@ -5617,7 +5617,6 @@ ClrDataAccess::Initialize(void)
cccallbacks.m_hmodCoreCLR = (HINSTANCE)m_globalBase; // Base address of the runtime in the target process
cccallbacks.m_pfnIEE = NULL;
cccallbacks.m_pfnGetCORSystemDirectory = NULL;
- cccallbacks.m_pfnGetCLRFunction = NULL;
InitUtilcode(cccallbacks);
return S_OK;
diff --git a/src/debug/di/rsmain.cpp b/src/debug/di/rsmain.cpp
index 887cc3378b..b48715c0ec 100644
--- a/src/debug/di/rsmain.cpp
+++ b/src/debug/di/rsmain.cpp
@@ -1435,7 +1435,6 @@ HRESULT Cordb::SetTargetCLR(HMODULE hmodTargetCLR)
cccallbacks.m_hmodCoreCLR = hmodTargetCLR;
cccallbacks.m_pfnIEE = NULL;
cccallbacks.m_pfnGetCORSystemDirectory = NULL;
- cccallbacks.m_pfnGetCLRFunction = NULL;
InitUtilcode(cccallbacks);
return S_OK;
diff --git a/src/dlls/mscoree/mscoree.cpp b/src/dlls/mscoree/mscoree.cpp
index 28a3ebe390..a59fc9aa32 100644
--- a/src/dlls/mscoree/mscoree.cpp
+++ b/src/dlls/mscoree/mscoree.cpp
@@ -85,7 +85,6 @@ BOOL WINAPI CoreDllMain(HANDLE hInstance, DWORD dwReason, LPVOID lpReserved)
cccallbacks.m_hmodCoreCLR = (HINSTANCE)hInstance;
cccallbacks.m_pfnIEE = IEE;
cccallbacks.m_pfnGetCORSystemDirectory = GetCORSystemDirectoryInternaL;
- cccallbacks.m_pfnGetCLRFunction = GetCLRFunction;
InitUtilcode(cccallbacks);
if (!(result = _CRT_INIT(hInstance, dwReason, lpReserved)))
diff --git a/src/inc/utilcode.h b/src/inc/utilcode.h
index 8e866a00a7..1021a1d37e 100644
--- a/src/inc/utilcode.h
+++ b/src/inc/utilcode.h
@@ -4914,22 +4914,15 @@ BOOL IsIPInModule(HMODULE_TGT hModule, PCODE ip);
// which in turn calls InitUtilcode.
//
// This structure collects all of the critical callback info passed in InitUtilcode().
-// Note that one of them is GetCLRFunction() which is itself a gofer for many other
-// callbacks. If a callback fetch be safely deferred until we have TLS and stack probe
-// functionality running, it should be added to that function rather than this structure.
-// Things like IEE are here because that callback has to be set up before GetCLRFunction()
-// can be safely called.
//----------------------------------------------------------------------------------------
struct CoreClrCallbacks
{
typedef IExecutionEngine* (* pfnIEE_t)();
typedef HRESULT (* pfnGetCORSystemDirectory_t)(SString& pbuffer);
- typedef void* (* pfnGetCLRFunction_t)(LPCSTR functionName);
HINSTANCE m_hmodCoreCLR;
pfnIEE_t m_pfnIEE;
pfnGetCORSystemDirectory_t m_pfnGetCORSystemDirectory;
- pfnGetCLRFunction_t m_pfnGetCLRFunction;
};
@@ -5317,8 +5310,4 @@ struct SpinConstants
extern SpinConstants g_SpinConstants;
-// ======================================================================================
-
-void* GetCLRFunction(LPCSTR FunctionName);
-
#endif // __UtilCode_h__
diff --git a/src/vm/appdomain.cpp b/src/vm/appdomain.cpp
index aab397e7c0..eb70175f37 100644
--- a/src/vm/appdomain.cpp
+++ b/src/vm/appdomain.cpp
@@ -5492,14 +5492,6 @@ BOOL AppDomain::OnUnhandledException(OBJECTREF *pThrowable, BOOL isTerminating/*
return retVal;
}
-static LONG s_ProcessedExitProcessEventCount = 0;
-
-LONG GetProcessedExitProcessEventCount()
-{
- LIMITED_METHOD_CONTRACT;
- return s_ProcessedExitProcessEventCount;
-}
-
void AppDomain::RaiseExitProcessEvent()
{
if (!g_fEEStarted)
@@ -6236,11 +6228,6 @@ AppDomain::RaiseAssemblyResolveEvent(
RETURN pAssembly;
} // AppDomain::RaiseAssemblyResolveEvent
-
-ULONGLONG g_ObjFinalizeStartTime = 0;
-Volatile<BOOL> g_FinalizerIsRunning = FALSE;
-Volatile<ULONG> g_FinalizerLoopCount = 0;
-
enum WorkType
{
WT_UnloadDomain = 0x1,
diff --git a/src/vm/ceemain.cpp b/src/vm/ceemain.cpp
index e621de7a8f..19f02f1e1b 100644
--- a/src/vm/ceemain.cpp
+++ b/src/vm/ceemain.cpp
@@ -897,7 +897,6 @@ void EEStartupHelper(COINITIEE fFlags)
#endif // FEATURE_COMINTEROP
StubHelpers::Init();
- NDirect::Init();
// Before setting up the execution manager initialize the first part
// of the JIT helpers.
diff --git a/src/vm/dllimport.cpp b/src/vm/dllimport.cpp
index aca871d789..d5a7933968 100644
--- a/src/vm/dllimport.cpp
+++ b/src/vm/dllimport.cpp
@@ -3035,7 +3035,7 @@ BOOL HeuristicDoesThisLookLikeAGetLastErrorCall(LPBYTE pTarget)
if (!pGetLastError)
{
// No need to use a holder here, since no cleanup is necessary.
- HMODULE hMod = CLRGetModuleHandle(WINDOWS_KERNEL32_DLLNAME_W);
+ HMODULE hMod = WszGetModuleHandle(WINDOWS_KERNEL32_DLLNAME_W);
if (hMod)
{
pGetLastError = (LPBYTE)GetProcAddress(hMod, "GetLastError");
@@ -5918,11 +5918,7 @@ static NATIVE_LIBRARY_HANDLE LocalLoadLibraryHelper( LPCWSTR name, DWORD flags,
#ifndef FEATURE_PAL
- if ((flags & 0xFFFFFF00) != 0
-#ifndef FEATURE_CORESYSTEM
- && NDirect::SecureLoadLibrarySupported()
-#endif // !FEATURE_CORESYSTEM
- )
+ if ((flags & 0xFFFFFF00) != 0)
{
hmod = CLRLoadLibraryEx(name, NULL, flags & 0xFFFFFF00);
if (hmod != NULL)
@@ -5952,10 +5948,6 @@ static NATIVE_LIBRARY_HANDLE LocalLoadLibraryHelper( LPCWSTR name, DWORD flags,
return hmod;
}
-#if !defined(FEATURE_PAL)
-bool NDirect::s_fSecureLoadLibrarySupported = false;
-#endif
-
#define TOLOWER(a) (((a) >= W('A') && (a) <= W('Z')) ? (W('a') + (a - W('A'))) : (a))
#define TOHEX(a) ((a)>=10 ? W('a')+(a)-10 : W('0')+(a))
@@ -6766,35 +6758,6 @@ VOID NDirect::NDirectLink(NDirectMethodDesc *pMD)
}
}
-
-//---------------------------------------------------------
-// One-time init
-//---------------------------------------------------------
-/*static*/ void NDirect::Init()
-{
- CONTRACTL
- {
- THROWS;
- GC_TRIGGERS;
- MODE_ANY;
- INJECT_FAULT(COMPlusThrowOM());
- }
- CONTRACTL_END;
-
-#if !defined(FEATURE_PAL)
- // Check if the OS supports the new secure LoadLibraryEx flags introduced in KB2533623
- HMODULE hMod = CLRGetModuleHandle(WINDOWS_KERNEL32_DLLNAME_W);
- _ASSERTE(hMod != NULL);
-
- if (GetProcAddress(hMod, "AddDllDirectory") != NULL)
- {
- // The AddDllDirectory export was added in KB2533623 together with the new flag support
- s_fSecureLoadLibrarySupported = true;
- }
-#endif // !FEATURE_PAL
-}
-
-
//==========================================================================
// This function is reached only via NDirectImportThunk. It's purpose
// is to ensure that the target DLL is fully loaded and ready to run.
diff --git a/src/vm/dllimport.h b/src/vm/dllimport.h
index 4e3b862760..740a5e596e 100644
--- a/src/vm/dllimport.h
+++ b/src/vm/dllimport.h
@@ -60,11 +60,6 @@ class NDirect
public:
//---------------------------------------------------------
- // One-time init
- //---------------------------------------------------------
- static void Init();
-
- //---------------------------------------------------------
// Does a class or method have a NAT_L CustomAttribute?
//
// S_OK = yes
@@ -129,18 +124,6 @@ private:
static NATIVE_LIBRARY_HANDLE LoadLibraryModuleViaCallback(NDirectMethodDesc * pMD, LPCWSTR wszLibName);
static NATIVE_LIBRARY_HANDLE LoadLibraryModuleBySearch(NDirectMethodDesc * pMD, LoadLibErrorTracker * pErrorTracker, LPCWSTR wszLibName);
static NATIVE_LIBRARY_HANDLE LoadLibraryModuleBySearch(Assembly *callingAssembly, BOOL searchAssemblyDirectory, DWORD dllImportSearchPathFlags, LoadLibErrorTracker * pErrorTracker, LPCWSTR wszLibName);
-
-#if !defined(FEATURE_PAL)
- // Indicates if the OS supports the new secure LoadLibraryEx flags introduced in KB2533623
- static bool s_fSecureLoadLibrarySupported;
-
-public:
- static bool SecureLoadLibrarySupported()
- {
- LIMITED_METHOD_CONTRACT;
- return s_fSecureLoadLibrarySupported;
- }
-#endif // !FEATURE_PAL
};
//----------------------------------------------------------------
diff --git a/src/vm/finalizerthread.cpp b/src/vm/finalizerthread.cpp
index 46b4f224cc..259544aef9 100644
--- a/src/vm/finalizerthread.cpp
+++ b/src/vm/finalizerthread.cpp
@@ -105,28 +105,8 @@ void FinalizerThread::DoOneFinalization(Object* fobj, Thread* pThread)
STATIC_CONTRACT_GC_TRIGGERS;
STATIC_CONTRACT_MODE_COOPERATIVE;
- class ResetFinalizerStartTime
- {
- public:
- ResetFinalizerStartTime()
- {
- if (CLRHosted())
- {
- g_ObjFinalizeStartTime = CLRGetTickCount64();
- }
- }
- ~ResetFinalizerStartTime()
- {
- if (g_ObjFinalizeStartTime)
- {
- g_ObjFinalizeStartTime = 0;
- }
- }
- };
- {
- ResetFinalizerStartTime resetTime;
- CallFinalizer(fobj);
- }
+ CallFinalizer(fobj);
+
pThread->InternalReset();
}
@@ -365,22 +345,16 @@ VOID FinalizerThread::FinalizerThreadWorker(void *args)
{
GetFinalizerThread()->EEResetAbort(Thread::TAR_ALL);
}
- FastInterlockExchange ((LONG*)&g_FinalizerIsRunning, TRUE);
FinalizeAllObjects(0);
_ASSERTE(GetFinalizerThread()->GetDomain()->IsDefaultDomain());
- FastInterlockExchange ((LONG*)&g_FinalizerIsRunning, FALSE);
// We may still have the finalizer thread for abort. If so the abort request is for previous finalizer method, not for next one.
if (GetFinalizerThread()->IsAbortRequested())
{
GetFinalizerThread()->EEResetAbort(Thread::TAR_ALL);
}
- // Increment the loop count. This is currently used by the AddMemoryPressure heuristic to see
- // if finalizers have run since the last time it triggered GC.
- FastInterlockIncrement((LONG *)&g_FinalizerLoopCount);
-
// Anyone waiting to drain the Q can now wake up. Note that there is a
// race in that another thread starting a drain, as we leave a drain, may
// consider itself satisfied by the drain that just completed. This is
diff --git a/src/vm/util.cpp b/src/vm/util.cpp
index 2b2bb236b3..ba49458a66 100644
--- a/src/vm/util.cpp
+++ b/src/vm/util.cpp
@@ -1832,39 +1832,6 @@ size_t GetCacheSizePerLogicalCpu(BOOL bTrueSize)
else
return maxSize;
}
-
-//---------------------------------------------------------------------
-
-#ifndef FEATURE_PAL
-HMODULE CLRGetModuleHandle(LPCWSTR lpModuleFileName)
-{
- // Don't use dynamic contract: will override GetLastError value
- STATIC_CONTRACT_NOTHROW;
- STATIC_CONTRACT_GC_NOTRIGGER;
- STATIC_CONTRACT_FORBID_FAULT;
-
- HMODULE hMod = WszGetModuleHandle(lpModuleFileName);
- return hMod;
-}
-#endif // !FEATURE_PAL
-
-void *GetCLRFunction(LPCSTR FunctionName)
-{
-
- void* func = NULL;
- BEGIN_ENTRYPOINT_VOIDRET;
-
- LIMITED_METHOD_CONTRACT;
-
- {
- _ASSERTE ("Unknown function name");
- func = NULL;
- }
- END_ENTRYPOINT_VOIDRET;
-
- return func;
-}
-
#endif // CROSSGEN_COMPILE
LPVOID
diff --git a/src/vm/util.hpp b/src/vm/util.hpp
index 61fe9ab367..4b08b29c40 100644
--- a/src/vm/util.hpp
+++ b/src/vm/util.hpp
@@ -609,8 +609,6 @@ inline BOOL CLRHosted()
}
#ifndef FEATURE_PAL
-HMODULE CLRGetModuleHandle(LPCWSTR lpModuleFileName);
-
HMODULE CLRLoadLibraryEx(LPCWSTR lpLibFileName, HANDLE hFile, DWORD dwFlags);
#endif // !FEATURE_PAL
diff --git a/src/vm/vars.hpp b/src/vm/vars.hpp
index 403e2f6843..c841ca925b 100644
--- a/src/vm/vars.hpp
+++ b/src/vm/vars.hpp
@@ -532,16 +532,11 @@ enum FWStatus
};
EXTERN DWORD g_FinalizerWaiterStatus;
-extern ULONGLONG g_ObjFinalizeStartTime;
-extern Volatile<BOOL> g_FinalizerIsRunning;
-extern Volatile<ULONG> g_FinalizerLoopCount;
#if defined(FEATURE_PAL) && defined(FEATURE_EVENT_TRACE)
extern Volatile<BOOL> g_TriggerHeapDump;
#endif // FEATURE_PAL
-extern LONG GetProcessedExitProcessEventCount();
-
#ifndef DACCESS_COMPILE
//
// Allow use of native images?