home *** CD-ROM | disk | FTP | other *** search
- AMIBug for the Amiga
- Copyright © 1987 by W.R.Perkins, PCM Associates
- (Alpha release .01)
- Usage Notes
-
- AMIBug is an MS-DOS Debug like utility written specifically for the
- Commodore Amiga 1000 system. It provides a look into the 68000 microprocessor,
- and (almost) any program you care to run.
-
- AMIBug provides the following features:
-
- o memory display/edit
- o register display/edit
- o user program single-step mode
- o a built-in disassembler
-
-
- To get a list of commands, type ?<return>. This debugger is set up for
- the 68000 microprocessor ONLY! I have not yet implemented a check for the
- 68010, nor the code to handle the different stack frame.
-
- Most commands take the form CMD <start> <end>. Spaces between
- the command and <start> and <end> are required. A few of the commands are of
- the form CMD<b|w> <start> <end> where b specifies byte and w specifies word.
- the b or w is optional, and AMIBug remembers which you were last at.
-
-
- Following is a list and description of the commands currently
- available in AMIBug:
-
- B <address> - sets base address for the program counter. When single-
- stepping or unassembling sections of code, it is often useful to be able to
- view the program counter relative to the user program start address, or to a
- routine's start address, so you can follow a listing from the assembler as you
- debug your code. Register displays (<R>eg command or the <S>tep command,
- see below) will display the program counter relative to the base address you
- enter. The <G>o to breakpoint command will also work in the relative mode.
-
- D<w | b> <start> <end> - display memory in word or byte format:
- Displays a block or a line of memory data in hex and ascii formats, a word or
- a byte at a time.
-
- E<w | b> <address> <data, data,...> - edit memory:
- Allows you to change bytes or words in memory. If you enter hex data after
- the address (absolute 32-bit address, no relative mode here) then AMIBug will
- simply put the data into memory and prompt you for the next command. If you
- type in an address only, AMIBug will display the address and the current data
- at that address, display a '-', and allow you to enter another value. If you
- don't want to change the data, just type <return> and AMIBug will go back to
- the prompt.
-
- G <address> - go from current PC to address:
- Runs the loaded program from the program counter address to the specified
- address. When the user program exits, AMIBug gets control again (hopefully) and
- displays the program exit code.
-
- I - information:
- Displays the AMIBug task structure address, the user stack top, and
- the location of the first instruction of the user program in hex.
-
- L [program name] - load user program:
- Loads the program into system memory (uses the AmigaDOS LoadSeg function) and
- displays the start address of the first program segment. This command Unloads
- any previously <L>oaded program before loading the new one.
-
- P - proceed:
- Used when you come to a jsr or bsr instruction, will automatically set a break-
- point at the next instruction after the current one, and execute the branch or
- jump to subroutine. This is so you won't have to step through a known working
- subroutine, or follow a dbra-type instruction through millions of iterations.
-
- Q - quit AMIBug:
- Unloads the user program (if one is Loaded) and exits back to AmigaDOS.
-
- R - registers:
- R<return> will display the current register set, the current instruction, and
- the current flags. RD0 <hex data> will alter data register 0, RA6 will change
- address register 6, etc. If no data is given, the register is cleared. RA8
- is used to change the program counter.
-
- S - single step:
- Executes the instruction displayed in the current Register set, and displays
- the resulting registers and flags.
-
- U <start> <end> - unassemble:
- Will unassemble memory from <start> to <end>, or a screenfull (24 lines or so)
- of memory. Typing U<return> will unassemble from the current PC (if you just
- Stepped), or from the instruction following the last Unassemble.
-
-
-
- Some notes:
-
- This is a "first time out" onto Compuserve with a program that I myself have
- written from scratch. I am interested in hearing about any problems, comments,
- criticisms, and/or complaints you may have about this program, and I will try
- to fix any bugs that are found. I hope to release bigger and better versions
- of AMIBug in the near future. So far, I have located one Exec function that
- seems to get AMIBug hopelessly lost: ExitIntr (FFE2) in the Exec Library.
- So far, I have found no mention of it in any of the RK manuals, nor in any of
- the books about how to use Amiga functions. It is apparantly used by the Aztec
- C compiler (I found it in Melt) but it seems to serve no useful purpose (I
- changed the program counter when I came to it, and went ahead, the screen
- melted just like it was supposed to) but you cannot Proceed or breakpoint
- around it. To report bugs and such, use EMAIL (I am 72245,710) to reach me. I
- will try to answer any and all correspondance I get. Meanwhile, enjoy.
-