Bug 382978

Summary: valgrind: LOAD_PDB_DEBUGINFO: \032 header character not found. possible invalid/unsupported pdb file format
Product: [Developer tools] valgrind Reporter: Austin English <austinenglish>
Component: generalAssignee: Julian Seward <jseward>
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version First Reported In: 3.14 SVN   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: mscorlib.pdb
makecert.pdb

Description Austin English 2017-08-01 04:25:42 UTC
Created attachment 106998 [details]
mscorlib.pdb

Microsoft's C# compiler (Rosylyn, also used by Mono, https://github.com/dotnet/roslyn/) generates PDBs that are of a different format than those generated by Visual Studio for C/C++.

This revealed itself because wine-mono accidentally shipped .pdb files, and running wine's dlls/mscoree/tests/mscoree.c tests crashed valgrind (bug 382515).

Now, it ignores those pdb files instead. It would be nice if these files were supported, but at least for Wine, it's probably not worth the effort, as only a tiny part of the code uses it. But if valgrind becomes popular for C#, it may be more important.

==1193== Warning: Missing or un-stat-able /home/austin/.wine/drive_c/windows/mono/mono-2.0/bin/libmono-2.0-x86.pdb
==1193== LOAD_PDB_DEBUGINFO: \032 header character not found.  possible invalid/unsupported pdb file format?
==1193== LOAD_PDB_DEBUGINFO: find_pdb_header found no hdr.  possible invalid/unsupported pdb file format?
==1193== LOAD_PDB_DEBUGINFO: failed loading info from /home/austin/.wine/drive_c/windows/mono/mono-2.0/lib/mono/4.5/mscorlib.pdb
Comment 1 Austin English 2017-08-01 04:27:10 UTC
Created attachment 106999 [details]
makecert.pdb

I'm also attaching a small pdb file that may be easier to analyze.
Comment 2 Austin English 2017-08-01 04:28:57 UTC
Forgot to mention in first comment; the PDB format is now publicly documented, at https://github.com/Microsoft/microsoft-pdb