runtime icon indicating copy to clipboard operation
runtime copied to clipboard

ildasm fails to dump metadata from mscorlib.dll

Open AndyAyersMS opened this issue 10 years ago • 1 comments

Repro:

D:\repos\coreclr\bin\Product\Windows_NT.x64.Checked>ildasm /metadata mscorlib.dll

//  Microsoft (R) .NET Framework IL Disassembler.  Version 4.5.22220.0


// ================================= M E T A I N F O ================================================


Assert failure(PID 10504 [0x00002908], Thread: 13988 [0x36a4]): !"Invalid GUID"

CORECLR! Disp::SetOption + 0x299 (0x00007ffe`14c00889)
ILDASM! MDInfo::MDInfo + 0xCF (0x00007ff7`a3e681e7)
ILDASM! DumpMetaInfo + 0x1F5 (0x00007ff7`a3e4ac89)
ILDASM! DumpFile + 0x669 (0x00007ff7`a3e471a5)
ILDASM! main + 0x1FC (0x00007ff7`a3e7dcdc)
ILDASM! _scrt_common_main_seh + 0x124 (0x00007ff7`a3eaf4b4)
KERNEL32! BaseThreadInitThunk + 0x22 (0x00007ffe`49d22d92)
NTDLL! RtlUserThreadStart + 0x34 (0x00007ffe`4bc29f64)
    File: d:\repos\coreclr\src\md\compiler\disp.cpp Line: 838
    Image: D:\repos\coreclr\bin\Product\Windows_NT.x64.Checked\ildasm.exe

AndyAyersMS avatar Jan 21 '16 02:01 AndyAyersMS

The failure is expected under CoreCLR. Basically, in MDInfo constructor, we'd like to set MetaDataImportOption. But handling such option is under FEATURE_METADATA_EMIT_ALL which CoreCLR does not support. See https://github.com/dotnet/coreclr/blob/master/src/md/MD.props#L18-L20

It might be better bailing out such option under CoreCLR in ildasm. So I'm moving milestone out of RTM.

kyulee1 avatar May 06 '16 18:05 kyulee1