return S_OK;
}
+HRESULT DacDbiInterfaceImpl::EnableGCNotificationEvents(BOOL fEnable)
+{
+ DD_ENTER_MAY_THROW
+
+ HRESULT hr = S_OK;
+ EX_TRY
+ {
+ if (g_pDebugger != NULL)
+ {
+ TADDR addr = PTR_HOST_MEMBER_TADDR(Debugger, g_pDebugger, m_isGarbageCollectionEventsEnabled);
+ SafeWriteStructOrThrow<BOOL>(addr, &fEnable);
+ }
+ }
+ EX_CATCH_HRESULT(hr);
+ return hr;
+}
DacRefWalker::DacRefWalker(ClrDataAccess *dac, BOOL walkStacks, BOOL walkFQ, UINT32 handleMask)
: mDac(dac), mWalkStacks(walkStacks), mWalkFQ(walkFQ), mHandleMask(handleMask), mStackWalker(NULL),
HRESULT GetILCodeVersionNodeData(VMPTR_ILCodeVersionNode vmILCodeVersionNode, DacSharedReJitInfo* pData);
HRESULT GetDefinesBitField(ULONG32 *pDefines);
HRESULT GetMDStructuresVersion(ULONG32* pMDStructuresVersion);
+ HRESULT EnableGCNotificationEvents(BOOL fEnable);
private:
void TypeHandleToExpandedTypeInfoImpl(AreValueTypesBoxed boxed,
return hr;
}
+COM_METHOD CordbProcess::EnableGCNotificationEvents(BOOL fEnable)
+{
+ return this->m_pDacPrimitives->EnableGCNotificationEvents(fEnable);
+}
+
#ifdef FEATURE_LEGACYNETCF_DBG_HOST_CONTROL
COM_METHOD CordbProcess::InvokePauseCallback()
// ICorDebugProcess10
//-----------------------------------------------------------
COM_METHOD GetContainingObject(CORDB_ADDRESS interiorPointer, ICorDebugObjectValue** ppContainingObject);
+ COM_METHOD EnableGCNotificationEvents(BOOL fEnable);
#ifdef FEATURE_LEGACYNETCF_DBG_HOST_CONTROL
// ---------------------------------------------------------------
m_forceNonInterceptable(FALSE),
m_pLazyData(NULL),
m_defines(_defines),
- m_isBlockedOnGarbageCollectionEvent(FALSE)
+ m_isBlockedOnGarbageCollectionEvent(FALSE),
+ m_isGarbageCollectionEventsEnabled(FALSE)
{
CONTRACTL
{
}
CONTRACTL_END;
- if (!CORDebuggerAttached())
+ if (!CORDebuggerAttached() || !this->m_isGarbageCollectionEventsEnabled)
{
return;
}
}
CONTRACTL_END;
- if (!CORDebuggerAttached())
+ if (!CORDebuggerAttached() || !this->m_isGarbageCollectionEventsEnabled)
{
return;
}
virtual void AfterGarbageCollection();
#endif
BOOL m_isBlockedOnGarbageCollectionEvent;
+ BOOL m_isGarbageCollectionEventsEnabled;
private:
HANDLE GetGarbageCollectionBlockerEvent() { return GetLazyData()->m_garbageCollectionBlockerEvent; }
virtual
HRESULT GetILCodeVersionNodeData(VMPTR_ILCodeVersionNode ilCodeVersionNode, DacSharedReJitInfo* pData) = 0;
+ // TODO, andrewau, documentation
+ virtual
+ HRESULT EnableGCNotificationEvents(BOOL fEnable) = 0;
+
// The following tag tells the DD-marshalling tool to stop scanning.
// END_MARSHAL
interface ICorDebugProcess10 : IUnknown
{
HRESULT GetContainingObject([in] CORDB_ADDRESS interiorPointer, [out] ICorDebugObjectValue** ppContainingObject);
+ HRESULT EnableGCNotificationEvents(BOOL fEnable);
}
// Event types MODULE_LOADED and MODULE_UNLOADED implement this interface
/* File created by MIDL compiler version 8.01.0622 */
/* at Mon Jan 18 19:14:07 2038
*/
-/* Compiler settings for C:/Dev/CoreCLR/src/inc/cordebug.idl:
+/* Compiler settings for F:/Dev/coreclr/src/inc/cordebug.idl:
Oicf, W1, Zp8, env=Win32 (32b run), target_arch=X86 8.01.0622
protocol : dce , ms_ext, c_ext, robust
error checks: allocation ref bounds_check enum stub_data
/* [in] */ CORDB_ADDRESS interiorPointer,
/* [out] */ ICorDebugObjectValue **ppContainingObject) = 0;
+ virtual HRESULT STDMETHODCALLTYPE EnableGCNotificationEvents(
+ BOOL fEnable) = 0;
+
};
/* [in] */ CORDB_ADDRESS interiorPointer,
/* [out] */ ICorDebugObjectValue **ppContainingObject);
+ HRESULT ( STDMETHODCALLTYPE *EnableGCNotificationEvents )(
+ ICorDebugProcess10 * This,
+ BOOL fEnable);
+
END_INTERFACE
} ICorDebugProcess10Vtbl;
#define ICorDebugProcess10_GetContainingObject(This,interiorPointer,ppContainingObject) \
( (This)->lpVtbl -> GetContainingObject(This,interiorPointer,ppContainingObject) )
+#define ICorDebugProcess10_EnableGCNotificationEvents(This,fEnable) \
+ ( (This)->lpVtbl -> EnableGCNotificationEvents(This,fEnable) )
+
#endif /* COBJMACROS */