windows-devel.rst
changeset 1527 2e7183c46848
parent 1526 1e5c611f8ab3
child 1528 80dc24a59e2f
equal deleted inserted replaced
1526:1e5c611f8ab3 1527:2e7183c46848
    52   http://www.microsoft.com/whdc/devtools/debugging/install64bit.mspx
    52   http://www.microsoft.com/whdc/devtools/debugging/install64bit.mspx
    53                 Debugging Tools for Windows 64-bit Version
    53                 Debugging Tools for Windows 64-bit Version
    54                 download page
    54                 download page
    55 
    55 
    56 Break on dll load/unload.
    56 Break on dll load/unload.
    57 =========================
    57 -------------------------
    58 ::
    58 ::
    59 
    59 
    60   sxe ld <module>
    60   sxe ld <module>
    61   sxe ud <module>
    61   sxe ud <module>
    62 
    62 
    63 Set breakpoint by pattern and/or on specific module.
    63 Set breakpoint by pattern and/or on specific module.
    64 ====================================================
    64 ----------------------------------------------------
    65 ::
    65 ::
    66 
    66 
    67   bm <module>!<name>    # set breakpoints on 'module' with name 'name'
    67   bm <module>!<name>    # set breakpoints on 'module' with name 'name'
    68   bm *!<prefix>*        # set breakpoints on all names with prefix 'prefix'
    68   bm *!<prefix>*        # set breakpoints on all names with prefix 'prefix'
    69   bm <module>!*         # set breakpoints on all names in module 'module'
    69   bm <module>!*         # set breakpoints on all names in module 'module'
    70 
    70 
    71 ``bp``, ``bm`` commands sets software breakpoints, debugger replaces the processor
    71 ``bp``, ``bm`` commands sets software breakpoints, debugger replaces the processor
    72 instruction with a break instruction.
    72 instruction with a break instruction.
    73 
    73 
    74 Clear breakpoints.
    74 Clear breakpoints.
    75 ==================
    75 ------------------
    76 ::
    76 ::
    77 
    77 
    78   bc *
    78   bc *
    79 
    79 
    80 How to set WinDbg as a Default Windows Postmortem Debugger.
    80 How to set WinDbg as a Default Windows Postmortem Debugger.
    81 ===========================================================
    81 -----------------------------------------------------------
    82 ::
    82 ::
    83 
    83 
    84   cmd> WinDbg -I
    84   cmd> WinDbg -I
    85 
    85 
    86 How analyse crash.
    86 How analyse crash.
    87 ==================
    87 ------------------
    88 
    88 
    89 When program crash and use enter in WinDbg execute::
    89 When program crash and use enter in WinDbg execute::
    90 
    90 
    91   !analyze -v
    91   !analyze -v
    92 
    92 
    93 Adding symbols from Symbol Server.
    93 Adding symbols from Symbol Server.
    94 ==================================
    94 ----------------------------------
    95 
    95 
    96 Execute in WinDbg::
    96 Execute in WinDbg::
    97 
    97 
    98   .sympath SRV*D:\srv\symcache*http://msdl.microsoft.com/download/symbols
    98   .sympath SRV*D:\srv\symcache*http://msdl.microsoft.com/download/symbols
    99 
    99 
   105 
   105 
   106   http://support.microsoft.com/kb/311503
   106   http://support.microsoft.com/kb/311503
   107                 Use the Microsoft Symbol Server to obtain debug symbol files
   107                 Use the Microsoft Symbol Server to obtain debug symbol files
   108 
   108 
   109 Using the SymChk.exe utility to download symbols.
   109 Using the SymChk.exe utility to download symbols.
   110 =================================================
   110 -------------------------------------------------
   111 ::
   111 ::
   112 
   112 
   113   symchk /r c:\windows\system32 /s SRV*c:\symbols\*http://msdl.microsoft.com/download/symbols
   113   symchk /r c:\windows\system32 /s SRV*c:\symbols\*http://msdl.microsoft.com/download/symbols
   114 
   114 
   115 Debugging child process.
   115 Debugging child process.
   116 ========================
   116 ------------------------
   117 ::
   117 ::
   118 
   118 
   119   .childdbg 1
   119   .childdbg 1
   120 
   120 
   121 Running at startup.
   121 Running at startup.