dia-sdk

How can I get the GUID from a PDB file?

青春壹個敷衍的年華 提交于 2019-12-23 17:42:47
问题 Does anyone know how to get the GUID from a PDB file? I'm using Microsoft's Debug Interface Access SDK http://msdn.microsoft.com/en-us/library/f0756hat.aspx and getting E_PDB_INVALID_SIG when passing in the GUID i expect when trying to load the PDB. I'd just like to know the GUID of the PDB so I can be certain that it's mismatching and not just a PDB that's perhaps corrupted somehow. Is there a tool that can do this? I've tried dia2dump and dumpbin, but with no joy... Many thanks, thoughton.

How do I use the MS DIA SDK from C#?

佐手、 提交于 2019-12-18 01:03:59
问题 I'm trying to use the Microsoft Debug Interface Access SDK from C#. This is installed with Visual Studio, but the docs don't seem to mention how you use this from C#. I've found example code on interweb but no information on how to link to the DIA SDK. I.e. I can't import it as an assembly. I don't think I have to include it into a managed C++ application and use it as COM (that would be hell). There is an IDL file, is this the correct way? If so, how? Edit: The following will create the type

How do I get the line number and path of a method from a pdb using .Net?

左心房为你撑大大i 提交于 2019-12-11 17:31:47
问题 Given an assembly and its pdb, how do I get the line number and path to a method using .Net? 回答1: You will need to use the DIA SDK. Microsoft does not have a managed interface for it, but using DIA in C# has been asked on StackOverflow before. If you are going to try it out in native first you can get the information in question by getting the IDiaSymbol instance for the PDB in question, this is called the 'global scope'. Once you have that you will call findChildren() passing it the

Why does IDiaEnumSymbolsByAddr::Next crash?

时光总嘲笑我的痴心妄想 提交于 2019-12-11 10:08:26
问题 I wanted to enumerate symbols by address but it seems IDiaEnumSymbolsByAddr::Next crash when I call it. The documentation doesn't say anything extra about it. Minimal code to reproduce: int main() { IDiaDataSource *ds; IDiaSession *session; IDiaEnumSymbolsByAddr *symbolEnum; IDiaSymbol *symbol; HRESULT hr; ULONG fetched; CoInitialize(NULL); hr = makeDiaDataSource(&ds); assert(SUCCEEDED(hr)); hr = ds->loadDataForExe(L"readpdb.exe", NULL, NULL); assert(SUCCEEDED(hr)); hr = ds->openSession(

Is it possible to infer which line in source has the problem according to disassembly?

拜拜、爱过 提交于 2019-12-11 08:46:49
问题 The problem exists at 017D0B5F call eax : 017D0B56 mov esi,esp 017D0B58 mov edx,dword ptr [ebp-20h] 017D0B5B push edx 017D0B5C mov eax,dword ptr [ecx+8] 017D0B5F call eax 017D0B61 cmp esi,esp 017D0B63 call @ILT+2525(__RTC_CheckEsp) (17C49E2h) 017D0B68 cmp dword ptr [ebp-2Ch],0 017D0B6C je CSourceStream::DoBufferProcessingLoop+10Ah (17D0B8Ah) 017D0B6E mov eax,dword ptr [ebp-2Ch] 017D0B71 push eax 017D0B72 push offset string "Deliver() returned %08x; stoppin"... (17F7278h) Here's the

Getting a List of Symbols Used by My VC++ Code

只愿长相守 提交于 2019-12-01 13:17:56
I am building a tool that process my VC++ source codes. For this, I need to obtain a list of symbols including local variable names and their types used by my codes. I know Visual C++ 2010 already provides a .bsc file that allows the object browser to locate symbols quickly. But this is an interactive tool. I need to obtain a list of the symbols in a file. Is there any tools allowing us to programmatically obtain the list of symbols used in our own VC++ source codes? I tried the Debug Interface Access SDK provided by Microsoft. It allows us to read the .pdb file for the names of the local

Getting a List of Symbols Used by My VC++ Code

醉酒当歌 提交于 2019-12-01 11:15:17
问题 I am building a tool that process my VC++ source codes. For this, I need to obtain a list of symbols including local variable names and their types used by my codes. I know Visual C++ 2010 already provides a .bsc file that allows the object browser to locate symbols quickly. But this is an interactive tool. I need to obtain a list of the symbols in a file. Is there any tools allowing us to programmatically obtain the list of symbols used in our own VC++ source codes? I tried the Debug

How do I use the MS DIA SDK from C#?

穿精又带淫゛_ 提交于 2019-11-28 21:57:50
I'm trying to use the Microsoft Debug Interface Access SDK from C#. This is installed with Visual Studio, but the docs don't seem to mention how you use this from C#. I've found example code on interweb but no information on how to link to the DIA SDK. I.e. I can't import it as an assembly. I don't think I have to include it into a managed C++ application and use it as COM (that would be hell). There is an IDL file, is this the correct way? If so, how? Edit: The following will create the type library for use as a referenced assembly. Paste into a batch file. call "%VS80COMNTOOLS%\vsvars32.bat"