首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法加载符号表并使用Simics执行符号调试

无法加载符号表并使用Simics执行符号调试
EN

Stack Overflow用户
提问于 2022-01-25 19:32:38
回答 1查看 167关注 0票数 2

我试图在Simics预览6.0.43下调试我的自定义内核。

我能够引导内核,在内存地址上设置一个断点,并使执行命中断点。无论如何,我无法加载符号进行符号调试。

我就是这样做的:

代码语言:javascript
复制
simics> $disk0_image="/home/peppe/Scrivania/gpt.img"
simics> 
simics> run-command-file /opt/simics/simics-qsp-x86-6.0.43/targets/qsp-x86/qsp-h
dd-boot.simics

simics> enable-debugger
Debugger enabled.
simics> 
simics> add-symbol-file /home/peppe/Scrivania/g-os-grub2/g-os/kernel.bin
Context query * currently matches 6 contexts.
Symbol file added with id '1'.

simics> bp.source_location.break 0xc0000812
2: 0x2 (planted)
simics> bp.source_location.break kmain
3: 0x3 (not planted)
simics> list kamin.c
**At col 7: Cannot read symbol data. Invalid abbreviation table offset. Error reading DWARF data**

simics> run
running> 
[tcf] Breakpoint 2 on execution in context mb.cpu0.core[0][0]
Now debugging the x86QSP1 board.mb.cpu0.core[0][0]
??()
                                                  push ebp
simics> board.mb.cpu0.core[0][0].pregs

rip = 0x00000000c0000812

我编译了我的资料来源如下:

代码语言:javascript
复制
CFLAGS         = -O0 -g -c -fno-builtin -m32
gcc version 11.2.1 20211203 (Red Hat 11.2.1-7) (GCC)

我的问题:为什么错误信息

代码语言:javascript
复制
At col 7: Cannot read symbol data. Invalid abbreviation table offset. Error reading DWARF data

这似乎妨碍了正确访问符号?

EN

回答 1

Stack Overflow用户

发布于 2022-03-21 10:35:30

Simics应该支持Dwarf 5,但是您需要升级到至少6.0.116,而6.0.126是在3月9日发布的。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/70854614

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档