Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DAC crashes WinDBGX on DBG/CHK builds #60321

Closed
AaronRobinsonMSFT opened this issue Oct 13, 2021 · 4 comments · Fixed by #60401
Closed

DAC crashes WinDBGX on DBG/CHK builds #60321

AaronRobinsonMSFT opened this issue Oct 13, 2021 · 4 comments · Fixed by #60401

Comments

@AaronRobinsonMSFT
Copy link
Member

AaronRobinsonMSFT commented Oct 13, 2021

Attempting to debug a DBG build of coreclr causes WinDBGX's debug engine to crash. Attaching VS to EngHost.exe, the following failure is observed.

This appears to be introduced in #59590.

 	mscordaccore.dll!_CxxThrowException(void * pExceptionObject, const _s__ThrowInfo * pThrowInfo) Line 75	C++
>	mscordaccore.dll!DacError(HRESULT err) Line 113	C++
 	mscordaccore.dll!PEImage::GetOrCreateLayout(unsigned long imageLayoutMask) Line 788	C++
 	mscordaccore.dll!PEImage::HasNTHeaders() Line 187	C++
 	mscordaccore.dll!ClrDataAccess::GetMetaDataFileInfoFromPEFile(PEAssembly * pPEAssembly, unsigned long & dwTimeStamp, unsigned long & dwSize, unsigned long & dwDataSize, unsigned long & dwRvaHint, bool & isNGEN, wchar_t * wszFilePath, unsigned long cchFilePath) Line 6499	C++
 	mscordaccore.dll!DacDbiInterfaceImpl::GetMetaDataFileInfoFromPEFile(VMPTR_Base<PEAssembly,__VPtr<PEAssembly>> vmPEAssembly, unsigned long & dwTimeStamp, unsigned long & dwSize, bool & isNGEN, IDacDbiInterface::IStringHolder * pStrFilename) Line 1247	C++
 	mscordbi.dll!CordbModule::InitPublicMetaDataFromFile(const wchar_t * pszFullPathName, unsigned long dwOpenFlags, bool validateFileInfo) Line 893	C++
 	mscordbi.dll!CordbModule::InitPublicMetaDataFromFile() Line 862	C++
 	mscordbi.dll!CordbModule::InitMetaData(TargetBuffer buffer, int allowFileMappingOptimization) Line 697	C++
 	mscordbi.dll!CordbModule::RefreshMetaData() Line 595	C++
 	mscordbi.dll!CordbModule::GetMetaDataImporter() Line 314	C++
 	mscordbi.dll!CordbModule::GetMetaDataInterface(const _GUID & riid, IUnknown * * ppObj) Line 1683	C++
 	CLRComposition.dll!Debugger::TargetComposition::Services::Managed::ClrSymbolSet::RuntimeClassInitialize(Debugger::TargetComposition::Services::Managed::ClrManager * pClrManager, ISvcModule * pSvcModule, ICorDebugModule * pClrModule) Line 4402	C++
 	[Inline Frame] CLRComposition.dll!Microsoft::WRL::Details::MakeAndInitialize(Debugger::TargetComposition::Services::Managed::ClrSymbolSet * *) Line 2532	C++
 	CLRComposition.dll!Microsoft::WRL::Details::MakeAndInitialize<Debugger::TargetComposition::Services::Managed::ClrSymbolSet,Debugger::TargetComposition::Services::Managed::ClrSymbolSet,Debugger::TargetComposition::Services::Managed::ClrManager *,ISvcModule * &,ICorDebugModule *>(Microsoft::WRL::Details::ComPtrRef<Microsoft::WRL::ComPtr<Debugger::TargetComposition::Services::Managed::ClrSymbolSet>> ppvObject, Debugger::TargetComposition::Services::Managed::ClrManager * && <args_0>, ISvcModule * & <args_1>, ICorDebugModule * && <args_2>) Line 2542	C++
 	CLRComposition.dll!Debugger::TargetComposition::Services::Managed::ClrSymbolProvider::LocateSymbolsForImage(ISvcModule * pImage, ISvcSymbolSet * * ppSymbolSet) Line 6911	C++
@ghost
Copy link

ghost commented Oct 13, 2021

Tagging subscribers to this area: @tommcdon
See info in area-owners.md if you want to be subscribed.

Issue Details

Attempting to debug a DBG build of coreclr causes WinDBGX's debug engine to crash. Attaching VS to EngHost.exe, the following failure is observed.

 	mscordaccore.dll!_CxxThrowException(void * pExceptionObject, const _s__ThrowInfo * pThrowInfo) Line 75	C++
>	mscordaccore.dll!DacError(HRESULT err) Line 113	C++
 	mscordaccore.dll!PEImage::GetOrCreateLayout(unsigned long imageLayoutMask) Line 788	C++
 	mscordaccore.dll!PEImage::HasNTHeaders() Line 187	C++
 	mscordaccore.dll!ClrDataAccess::GetMetaDataFileInfoFromPEFile(PEAssembly * pPEAssembly, unsigned long & dwTimeStamp, unsigned long & dwSize, unsigned long & dwDataSize, unsigned long & dwRvaHint, bool & isNGEN, wchar_t * wszFilePath, unsigned long cchFilePath) Line 6499	C++
 	mscordaccore.dll!DacDbiInterfaceImpl::GetMetaDataFileInfoFromPEFile(VMPTR_Base<PEAssembly,__VPtr<PEAssembly>> vmPEAssembly, unsigned long & dwTimeStamp, unsigned long & dwSize, bool & isNGEN, IDacDbiInterface::IStringHolder * pStrFilename) Line 1247	C++
 	mscordbi.dll!CordbModule::InitPublicMetaDataFromFile(const wchar_t * pszFullPathName, unsigned long dwOpenFlags, bool validateFileInfo) Line 893	C++
 	mscordbi.dll!CordbModule::InitPublicMetaDataFromFile() Line 862	C++
 	mscordbi.dll!CordbModule::InitMetaData(TargetBuffer buffer, int allowFileMappingOptimization) Line 697	C++
 	mscordbi.dll!CordbModule::RefreshMetaData() Line 595	C++
 	mscordbi.dll!CordbModule::GetMetaDataImporter() Line 314	C++
 	mscordbi.dll!CordbModule::GetMetaDataInterface(const _GUID & riid, IUnknown * * ppObj) Line 1683	C++
 	CLRComposition.dll!Debugger::TargetComposition::Services::Managed::ClrSymbolSet::RuntimeClassInitialize(Debugger::TargetComposition::Services::Managed::ClrManager * pClrManager, ISvcModule * pSvcModule, ICorDebugModule * pClrModule) Line 4402	C++
 	[Inline Frame] CLRComposition.dll!Microsoft::WRL::Details::MakeAndInitialize(Debugger::TargetComposition::Services::Managed::ClrSymbolSet * *) Line 2532	C++
 	CLRComposition.dll!Microsoft::WRL::Details::MakeAndInitialize<Debugger::TargetComposition::Services::Managed::ClrSymbolSet,Debugger::TargetComposition::Services::Managed::ClrSymbolSet,Debugger::TargetComposition::Services::Managed::ClrManager *,ISvcModule * &,ICorDebugModule *>(Microsoft::WRL::Details::ComPtrRef<Microsoft::WRL::ComPtr<Debugger::TargetComposition::Services::Managed::ClrSymbolSet>> ppvObject, Debugger::TargetComposition::Services::Managed::ClrManager * && <args_0>, ISvcModule * & <args_1>, ICorDebugModule * && <args_2>) Line 2542	C++
 	CLRComposition.dll!Debugger::TargetComposition::Services::Managed::ClrSymbolProvider::LocateSymbolsForImage(ISvcModule * pImage, ISvcSymbolSet * * ppSymbolSet) Line 6911	C++
Author: AaronRobinsonMSFT
Assignees: -
Labels:

area-Diagnostics-coreclr

Milestone: -

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label Oct 13, 2021
@tommcdon
Copy link
Member

@hoyosjs @mikem8361

@tommcdon tommcdon removed the untriaged New issue has not been triaged by the area owner label Oct 13, 2021
@tommcdon tommcdon added this to the 7.0.0 milestone Oct 13, 2021
@AaronRobinsonMSFT
Copy link
Member Author

/cc @VSadov

@hoyosjs
Copy link
Member

hoyosjs commented Oct 13, 2021

I need to check, but looks like fallout of the refactor in #59590

@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Oct 14, 2021
@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label Oct 14, 2021
@ghost ghost locked as resolved and limited conversation to collaborators Nov 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants