安装bochs
sudo apt-get install bochs
sudo apt-get install bochs-x
配置bochs
- 新建文件夹
rsheng@ubuntu:~/github$ mkdir x86_assembly rsheng@ubuntu:~/github$ cd x86_assembl
- 生成配置文件
rsheng@ubuntu:~/github/x86_assembly$ bochs
- 修改配置文件,打开GUI-dabug
display_library: x, options="gui_debug"
配置硬盘
rsheng@ubuntu:~/github/x86_assembly$ bximage
ata0-master: type=disk, path=”master.img”, mode=flat
打开magic_break
magic_break: enabled=1
xchg bx, bx ;在bx处自动打断点
启动
rsheng@ubuntu:~/github/x86_assembly$ bochs -q
安装qemu
rsheng@ubuntu:~$ sudo apt-get install qemu