Hacker News new | ask | show | jobs
by exDM69 5317 days ago
QEMU is excellent. It makes a very difficult task very easy. Simulating microprocessors, that is.

It's very cool to be able to test some cool feature in the latest Linux kernel easily or tinker with your own mini Linux distro.

QEMU also makes writing hobby operating systems (everyone's gotta have one, right?) nicer, it would be a pain to have to boot your system every time you make a change. It's easy to attach a debugger to QEMU to do debugging at CPU level, no need to implement GDB stubs and a serial driver to your kernel before you can get anything done.

I guess QEMU can be used for real work, too.

Thanks and congrats to the QEMU team for a milestone release!

(/me wonders if they fixed CPU-level debugging on amd64 yet, the last time I tried, I had to revert one commit to get it done. Otherwise I got a "remote 'g' packet is too long" error or something)

1 comments

That's a GDB bug actually. GDB doesn't handle remote targets that change CPU modes. If your guest is in 16 bit mode, you need to do 'set arch i8086'. For 32-bit mode, 'set arch i386', and for 64-bit mode, 'set arch i386:x86-64'.
Thanks for the tip, I will try it out when I get some time my OS development project again.

It may be a bug in GDB, but reverting a change in QEMU made it work for me.