From dbe16c169ad9c10a48acee89d424852458cb5ca0 Mon Sep 17 00:00:00 2001 From: Jan Kotas Date: Sun, 24 Jan 2016 21:43:42 -0800 Subject: Revert "Generate P/Invoke transitions for CoreRT." --- src/zap/zapinfo.cpp | 13 ++++++------- src/zap/zapinfo.h | 4 ++-- 2 files changed, 8 insertions(+), 9 deletions(-) (limited to 'src/zap') diff --git a/src/zap/zapinfo.cpp b/src/zap/zapinfo.cpp index 5258dfef24..e3c2759e82 100644 --- a/src/zap/zapinfo.cpp +++ b/src/zap/zapinfo.cpp @@ -2731,9 +2731,9 @@ void * ZapInfo::getPInvokeUnmanagedTarget(CORINFO_METHOD_HANDLE method, void **p return NULL; } -void ZapInfo::getAddressOfPInvokeFixup(CORINFO_METHOD_HANDLE method, CORINFO_CONST_LOOKUP *pLookup) +void * ZapInfo::getAddressOfPInvokeFixup(CORINFO_METHOD_HANDLE method,void **ppIndirection) { - _ASSERTE(pLookup != NULL); + _ASSERTE(ppIndirection != NULL); m_pImage->m_pPreloader->AddMethodToTransitiveClosureOfInstantiations(method); @@ -2741,9 +2741,8 @@ void ZapInfo::getAddressOfPInvokeFixup(CORINFO_METHOD_HANDLE method, CORINFO_CON if (moduleHandle == m_pImage->m_hModule && m_pImage->m_pPreloader->CanEmbedMethodHandle(method, m_currentMethodHandle)) { - pLookup->accessType = IAT_PVALUE; - pLookup->addr = PVOID(m_pImage->GetWrappers()->GetAddrOfPInvokeFixup(method)); - return; + *ppIndirection = NULL; + return PVOID(m_pImage->GetWrappers()->GetAddrOfPInvokeFixup(method)); } // @@ -2756,8 +2755,8 @@ void ZapInfo::getAddressOfPInvokeFixup(CORINFO_METHOD_HANDLE method, CORINFO_CON ZapImport * pImport = m_pImage->GetImportTable()->GetIndirectPInvokeTargetImport(method); AppendConditionalImport(pImport); - pLookup->accessType = IAT_PPVALUE; - pLookup->addr = pImport; + *ppIndirection = pImport; + return NULL; } CORINFO_JUST_MY_CODE_HANDLE ZapInfo::getJustMyCodeHandle( diff --git a/src/zap/zapinfo.h b/src/zap/zapinfo.h index e32d2068d5..1d16c9b760 100644 --- a/src/zap/zapinfo.h +++ b/src/zap/zapinfo.h @@ -430,8 +430,8 @@ public: void **ppIndirection); void * getPInvokeUnmanagedTarget(CORINFO_METHOD_HANDLE method, void **ppIndirection); - void getAddressOfPInvokeFixup(CORINFO_METHOD_HANDLE method, - CORINFO_CONST_LOOKUP *pLookup); + void * getAddressOfPInvokeFixup(CORINFO_METHOD_HANDLE method, + void **ppIndirection); CORINFO_JUST_MY_CODE_HANDLE getJustMyCodeHandle( CORINFO_METHOD_HANDLE method, CORINFO_JUST_MY_CODE_HANDLE **ppIndirection); -- cgit v1.2.3