应用调试基础
时间:2020-04-15 20:10:53
收藏:0
阅读:66
**Windbg 符号表环境变量**
```shell
# _NT_SYMBOL_PATH
# C:\Symbols 路径自行设置
srv*C:\Symbols*https://msdl.microsoft.com/download/symbols
```

上面是.NET Core本地符号表
**SOS安装**
```shell
dotnet tool install -g dotnet-sos
dotnet-sos install
```

记住图中红框的加载指令
**Windbg基本用法**
```shell
# 运行
windbgx dotnet .\ConsoleApp1.dll
# 加载coreclr
sxe ld coreclr
# 继续
g
# 加载SOS
.load C:\Users\Zilor\.dotnet\sos\sos.dll
# 查看插件
.chain
# 函数断点
!bpmd ConsoleApp1.dll ConsoleApp1.Program.Main
```
原文:https://www.cnblogs.com/qingyunye/p/12707377.html
评论(0)