News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Problem debugging with bochs

Started by bobl, November 14, 2009, 12:07:50 PM

Previous topic - Next topic

bobl

I've downloaded the  Bochs x86 Emulator 2.3.7 package.
When I type 'bochs' from the directory with my app and the following .bochsrc
in i.e.

vgaromimage: file=/usr/share/vgabios/vgabios.bin
megs: 32
floppya: 1_44=fd.img, status=inserted
boot: floppy
cpu: ips=1000000

a window pops up and my app races away like a 'good-un'

The problem is I don't get the chance to invoke the debugger and step through things

At the moment I only see a button invoking the debugger by
1 typing  'bochs' from a directory with no img/.bochsrc &
2 starting a simulation
I then get a panic window up with a button labelled 'debugger ' on it.
(when I press it the cursor just flashes under the 'no bootable device' error message so I don't know if it's enabled or not)

1 How do I test that the debugger is enabled & if it is...
2 Where do I specify the breakpoints @ 7c00 etc

As always any help much appreciated.

sinsi

Have a look in the bochs directory, there should be a file called "bochsdbg.exe" that you should run. Bochs is up to version 2.4.1 now too.
You will need to look at the online help to figure out the debugger commands too, because they are *extremely* untuitive.
Light travels faster than sound, that's why some people seem bright until you hear them.

japheth


> Have a look in the bochs directory, there should be a file called "bochsdbg.exe" that you should run.

also search the bochs docu for "magic_break" ( xchg bx,bx ).

bobl

I'm running on Linux but will look for the equivalent.
Thank you for your responses

bobl

I compiled from source and the app now comes up under debugger control
It was the line to enable magic breakpoints in bochsrc.txt that made bochs tell me it wasn't compiled with debugger support.
There's so many configuration options that I feel lucky that it just works.
Thx once again for your advice
I'll try out the debugger tomorrow