Created
April 30, 2014 02:56
-
-
Save archerslaw/d3ea4188b408742f5127 to your computer and use it in GitHub Desktop.
how to debug the QEMU quit without any backtrace at the breakpoint.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
breakpoints -- Making program stop at certain points | |
1.launch a KVM guest with gdb. | |
# gdb /usr/libexec/qemu-kvm | |
2.set the breakpoint at exit. | |
(gdb) b exit | |
Breakpoint 1 at 0xaaf30 | |
3.start the program. | |
(gdb) r -M pc -cpu host -enable-kvm -m 2048 -smp 2,sockets=2,cores=1,threads=1 -no-kvm-pit-reinjection -usb -device usb-tablet,id=input0 -name sluo -uuid 990ea161-6b67-47b2-b803-19fb01d30d30 -rtc base=localtime,clock=host,driftfix=slew...-monitor stdio | |
(qemu) [Thread 0x7fffeabf7700 (LWP 31736) exited] | |
[New Thread 0x7fffeabf7700 (LWP 31741)] | |
Breakpoint 1, 0x00007ffff2c9a250 in exit () from /lib64/libc.so.6 | |
4.program received signals and got the backtrace. | |
(gdb) bt | |
#0 0x00007ffff2c9a250 in exit () from /lib64/libc.so.6 | |
#1 0x0000555555795fe2 in virtqueue_num_heads (vq=0x55555811db48, idx=0) | |
at /usr/src/debug/qemu-1.5.3/hw/virtio/virtio.c:291 | |
#2 0x0000555555796673 in virtqueue_pop (vq=vq@entry=0x55555811db48, elem=elem@entry=0x55555767ec50) | |
at /usr/src/debug/qemu-1.5.3/hw/virtio/virtio.c:441 | |
...... | |
#27 main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4360 | |
(gdb) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment