home *** CD-ROM | disk | FTP | other *** search
- #ifndef debugger_H
- #define debugger_H
-
- /* C header file for Debugger
- * written by DefMod (Sep 7 1994) on Wed Sep 7 21:25:04 1994
- * Copyright © Acorn Computers Ltd, 1994
- */
-
- /*************************************************************************
- * This source file was written by Acorn Computers Limited. It is part *
- * of the OSLib library for writing applications for RISC OS. It may be *
- * used freely in the creation of programs for RISC OS. *
- *************************************************************************/
-
- #ifndef types_H
- #include "types.h"
- #endif
-
- #ifndef os_H
- #include "os.h"
- #endif
-
- /**********************************
- * SWI names and SWI reason codes *
- **********************************/
- #undef Debugger_Disassemble
- #define Debugger_Disassemble 0x40380
- #undef XDebugger_Disassemble
- #define XDebugger_Disassemble 0x60380
-
- /************************
- * Constant definitions *
- ************************/
- #define error_DEBUG_BREAK_NOT_FOUND 0x800u
- #define error_DEBUG_INVALID_VALUE 0x801u
- #define error_DEBUG_RESETTING 0x802u
- #define error_DEBUG_NO_ROOM 0x803u
- #define error_DEBUG_NO_BREAKPOINTS 0x804u
- #define error_DEBUG_BAD_BREAKPOINT 0x805u
- #define error_DEBUG_UNDEFINED 0x806u
- #define error_DEBUG_NON_ALIGNED 0x807u
- #define error_DEBUG_NO_WORKSPACE 0x808u
-
- /*************************
- * Function declarations *
- *************************/
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- /*************************************************************
- * NOTE: The following functions provide direct access to *
- * the SWI's noted in the function description. *
- * Please read the relevant PRM section for more *
- * information on their input/output parameters. *
- *************************************************************/
-
- /* ------------------------------------------------------------------------
- * Function: debugger_disassemble()
- *
- * Description: Disassembles an instruction
- *
- * Input: instruction - value of R0 on entry
- * address - value of R1 on entry
- *
- * Output: disassembly - value of R1 on exit
- * used - value of R2 on exit
- *
- * Other notes: Calls SWI 0x40380.
- */
-
- extern os_error *xdebugger_disassemble (int instruction,
- int *address,
- char **disassembly,
- int *used);
- extern void debugger_disassemble (int instruction,
- int *address,
- char **disassembly,
- int *used);
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif
-