You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create hello world using dotnet new + dotnet restore + dotnet build
Try to debug it on OSX/Linux
Result:
There is a good chance that the debugger will fail to stop on entry point. libmscordbi.so!CordbThread::GetActiveFrame is returning CORDBG_E_READVIRTUAL_FAILURE.
I don't yet know if there is something special about entry point, or if this will happen in general. I had trouble debugging this with release bits, so I switched to debug. Using debug bits, I get an assert in the same method which is therefore probably the problem, but I can't say for certain. Here is the assert --
base {...} __TPtrBase
m_addr 0xffffffff TADDR
m_cbBytes 0x63722d312e302e00 const SIZE_T
Which comes from this loop:
for (int i = 0; i < Debugger::kMaxHijackFunctions; i++)
{
InitTargetBufferFromMemoryRange(pDebugger->m_rgHijackFunction[i], &m_pCachedHijackFunction[i] );
i is 2, which I believe is this hijack --
GetMemoryRangeForFunction(RedirectedHandledJITCaseForDbgThreadControl_Stub,
RedirectedHandledJITCaseForDbgThreadControl_StubEnd)
libmscordaccore.so!InitTargetBufferFromMemoryRange(const MemoryRange memoryRange, TargetBuffer * pTargetBuffer) Line 4110 C++
libmscordaccore.so!DacDbiInterfaceImpl::IsRuntimeUnwindableStub(DacDbiInterfaceImpl * this, PCODE targetControlPC) Line 4958 C++
libmscordaccore.so!DacDbiInterfaceImpl::GetStackWalkCurrentFrameInfo(DacDbiInterfaceImpl * this, IDacDbiInterface::StackWalkHandle pSFIHandle, DebuggerIPCE_STRData * pFrameData) Line 383 C++
libmscordaccore.so!non-virtual thunk to DacDbiInterfaceImpl::GetStackWalkCurrentFrameInfo(void**, DebuggerIPCE_STRData*)() Line 405 C++
libmscordbi.so!CordbStackWalk::GetFrameWorker(CordbStackWalk * this, ICorDebugFrame ** ppFrame) Line 582 C++
libmscordbi.so!CordbStackWalk::GetFrame(CordbStackWalk * this, ICorDebugFrame ** ppFrame) Line 523 C++
libmscordbi.so!non-virtual thunk to CordbStackWalk::GetFrame(ICorDebugFrame**)() Line 539 C++
libmscordbi.so!ShimStackWalk::Populate(ShimStackWalk * this) Line 229 C++
libmscordbi.so!ShimStackWalk::ShimStackWalk(ShimStackWalk * this, ShimProcess * pProcess, ICorDebugThread * pThread) Line 34 C++
libmscordbi.so!ShimProcess::LookupOrCreateShimStackWalk(ShimProcess * this, ICorDebugThread * pThread) Line 1636 C++
libmscordbi.so!CordbThread::GetActiveFrame(CordbThread * this, ICorDebugFrame ** ppFrame) Line 1089 C++
libmscordbi.so!non-virtual thunk to CordbThread::GetActiveFrame(ICorDebugFrame**)() Line 1107 C++
libvsdebugeng.impl.so!ManagedDM::CV2InstrBreakpoint::Fire(ManagedDM::CV2InstrBreakpoint * this, Microsoft::VisualStudio::Debugger::DkmThread * pDkmThread, ICorDebugThread * pCorThread) Line 237 C++
libvsdebugeng.impl.so!ManagedDM::CV2DbiCallback::DoBreakpoint(ManagedDM::CV2DbiCallback * this, ICorDebugAppDomain * pCorAppDomain, ICorDebugThread * pCorThread, ICorDebugBreakpoint * pCorBreakpoint) Line 1553 C++
libvsdebugeng.impl.so!ManagedDM::CDbiCallback::DoDebugEvents(ManagedDM::CDbiCallback * this, ATL::CAtlList<CComObjectPtr<ManagedDM::CManagedDebugEvent>, ATL::CElementTraits<CComObjectPtr<ManagedDM::CManagedDebugEvent> > > * pEvents) Line 2247 C++
libvsdebugeng.impl.so!ManagedDM::CV2DbiCallback::ProcessStoppingDebugEvents(ManagedDM::CV2DbiCallback * this) Line 1324 C++
libvsdebugeng.impl.so!ManagedDM::CV2DbiCallback::DoStoppingDebugEvents(ManagedDM::CV2DbiCallback * this) Line 1289 C++
libvsdebugeng.impl.so!ManagedDM::CV2EventThread::MessageLoop(ManagedDM::CV2EventThread * this, ManagedDM::CV2Process * pDMProcess) Line 269 C++
libvsdebugeng.impl.so!ManagedDM::CV2EventThread::ManagedDMEventThreadFunc(void * pvMessage) Line 218 C++
libvsbaseservices.so!CorUnix::CPalThread::ThreadEntry(void * pvParam) Line 1620 C++
The text was updated successfully, but these errors were encountered:
Repro steps:
Result:
There is a good chance that the debugger will fail to stop on entry point. libmscordbi.so!CordbThread::GetActiveFrame is returning CORDBG_E_READVIRTUAL_FAILURE.
I don't yet know if there is something special about entry point, or if this will happen in general. I had trouble debugging this with release bits, so I switched to debug. Using debug bits, I get an assert in the same method which is therefore probably the problem, but I can't say for certain. Here is the assert --
Assert failure(PID 17345 [0x000043c1], Thread: 17517 [0x446d]): memoryRange.Size() <= 0xffffffff
File: /home/greggm/coreclr/src/debug/daccess/dacdbiimpl.cpp Line: 4110
Here is memoryRange:
Which comes from this loop:
for (int i = 0; i < Debugger::kMaxHijackFunctions; i++)
{
InitTargetBufferFromMemoryRange(pDebugger->m_rgHijackFunction[i], &m_pCachedHijackFunction[i] );
i is 2, which I believe is this hijack --
GetMemoryRangeForFunction(RedirectedHandledJITCaseForDbgThreadControl_Stub,
RedirectedHandledJITCaseForDbgThreadControl_StubEnd)
The text was updated successfully, but these errors were encountered: