From 04f97c9923156b0c695f5fe441ffd14624de8076 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Fri, 5 Apr 2019 12:52:00 -0700 Subject: Enable return buffers on Windows ARM64 for struct-returning member functions (#23625) * Enable return buffers on Windows ARM64 for struct-returning member functions. Fixes #23577. * Update comment to match new condition. * Enable byref return on all Windows (excluding arm64 HFA. Add more test cases for ThisCall. * On x86, if we have a normalized return value in an instance method, get back the actual type so that we correctly marshal it via a return buffer. * Fix param ordering. * Clean up based on PR feedback. * Fix accidental variable shadowing. --- src/vm/dispatchinfo.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/vm/dispatchinfo.cpp') diff --git a/src/vm/dispatchinfo.cpp b/src/vm/dispatchinfo.cpp index 3683ddd4b9..c59e2c233f 100644 --- a/src/vm/dispatchinfo.cpp +++ b/src/vm/dispatchinfo.cpp @@ -906,7 +906,7 @@ void DispatchMemberInfo::SetUpMethodMarshalerInfo(MethodDesc *pMD, BOOL bReturnV MarshalInfo Info(msig.GetModule(), msig.GetArgProps(), msig.GetSigTypeContext(), paramDef, MarshalInfo::MARSHAL_SCENARIO_COMINTEROP, (CorNativeLinkType)0, (CorNativeLinkFlags)0, - TRUE, iParam, numArgs, BestFit, ThrowOnUnmappableChar, FALSE, pMD, TRUE + TRUE, iParam, numArgs, BestFit, ThrowOnUnmappableChar, FALSE, TRUE, pMD, TRUE #ifdef _DEBUG , pMD->m_pszDebugMethodName, pMD->m_pszDebugClassName, iParam #endif @@ -943,7 +943,7 @@ void DispatchMemberInfo::SetUpMethodMarshalerInfo(MethodDesc *pMD, BOOL bReturnV { MarshalInfo Info(msig.GetModule(), msig.GetReturnProps(), msig.GetSigTypeContext(), returnParamDef, MarshalInfo::MARSHAL_SCENARIO_COMINTEROP, (CorNativeLinkType)0, (CorNativeLinkFlags)0, - FALSE, 0, numArgs, BestFit, ThrowOnUnmappableChar, FALSE, pMD, TRUE + FALSE, 0, numArgs, BestFit, ThrowOnUnmappableChar, FALSE, TRUE, pMD, TRUE #ifdef _DEBUG , pMD->m_pszDebugMethodName, pMD->m_pszDebugClassName, 0 #endif -- cgit v1.2.3