Saturday, November 24, 2007

Minus4: An old friend....

While getting a little bored of doing paths (MAN! I hate doing paths...) I decided to take a break from that and add some basic profiling under Minus4. This was suggested a while back by TNT in his Paradriod blog, so I'd thought I'd take the plung now and see if I can't save some zero page memory; or at least shuffle it around so I get better use out of it. I currently have around 50 bytes of zero page left but I'm fairly sure some of it really doesn't have to be there.

Anyway, while browsing the source I had a look at the last release of Minus4 and what's been added since, and theres actually quite a bit. I'm sure I posted this a while back, but here it is again.

1) Debugger now loads symbols (-p "symbol.sym" on the command line). SNASM format.
2) Source now builds under VS2005
3) Updated Debugger to allow disassembly view movement.
Page up/down, line up/down now moves disassembly view
SHIFT+Page up/down, line up/down now moves memory dump view
4) Dump of most of the hardware registers
5) Added a menu switch for undocumented opcodes. They are now OFF by default....
6) Added a scrollable BAR to the disassembly view to allow the placement of breakpoints and nicer navigation
7) New debugger keys:
Cursor Up/Down Move user bar
Page Up/Down page disassembly up/down
Shift + Cursor Up/Down Move memory dump up/down a line
Shift + Page Up/Down page memory dump up/down
B Set Break point at current user bar address
Shift + B Set Break point at address/symbol
Enter Step a single instruction. If JSR/Branch then follow if need be.
Space Place a breakpoint after current instruction and RUN.
Cursor Right If user bar is on a JSR/JMP, then read address and set window address to that.
Cursor Left If CursorRight has been used, then pop last address off and reset window.
M Set Memory window address
G Set Disassembly window address
8) Basic Profiling

With profiling being added I think its probably time to release this one so others can make use of it. I dont really use Minus4 for running games anymore, Yape has long since taken that crown, but I do use it for debugging as the built in debugger is much nicer to use (although I do now wish I'd opened up a new window for it so I could have a bigger area). Anyway... With the profiling about to be added, I think its now a nice enough release that others may like to use it for development, so once Im done with profiling, you can play with it for yourself.

My assembler (SNasm) outputs the symbol file format needed for Minus4 although I'll try to workout what the format was so you can use others and convert if you need to.

No comments: