; ; brkpt.sh ; ; Breakpoint handling ; ; © 1994-1998 Straylight ; ;----- Licensing note ------------------------------------------------------- ; ; This file is part of Straylight's Sledgehammer debugger. ; ; Sledgehammer is free software; you can redistribute it and/or modify ; it under the terms of the GNU General Public License as published by ; the Free Software Foundation; either version 2, or (at your option) ; any later version. ; ; Sledgehammer is distributed in the hope that it will be useful, ; but WITHOUT ANY WARRANTY; without even the implied warranty of ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ; GNU General Public License for more details. ; ; You should have received a copy of the GNU General Public License ; along with Sledgehammer. If not, write to the Free Software Foundation, ; 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. ;----- Overview ------------------------------------------------------------- ; ; Functions provided: ; ; brkpt_set ; brkpt_hardBreak ; brkpt_translate ; brkpt_remove ; brkpt_remAll ; brkpt_exist ; --- brkpt_set --- ; ; On entry: R0 == address to set breakpoint ; ; On exit: May return error ; ; Use: Sets a breakpoint at the given location, giving it the ; current handle. The address is assumed to be word-aligned, ; and writable. IMPORT brkpt_set ; --- brkpt_hardBreak --- ; ; On entry: [R13+4] == return address to stomp on ; ; On exit: -- ; ; Use: Sets an immediate break specified by a SWI call. IMPORT brkpt_hardBreak ; --- brkpt_translate --- ; ; On entry: R0 == address to translate ; ; On exit: R0 == the address we are really interested in ; ; Use: Returns the address given, as if there was no breakpoint ; there. IMPORT brkpt_translate ; --- brkpt_remove --- ; ; On entry: R0 == address of breakpoint ; ; On exit: -- ; ; Use: Removes the break point (if any) at the given address IMPORT brkpt_remove ; --- brkpt_remAll --- ; ; On entry: -- ; ; On exit: -- ; ; Use: Removes all the breakpoints currently installed. IMPORT brkpt_remAll ; --- brkpt_exist --- ; ; On entry: R0 == address to test for ; ; On exit: CC if there is no breakpoint here ; CS otherwise ; ; Use: Informs the user if there is a breakpint at the address ; passed. IMPORT brkpt_exist ;----- That's all, folks ---------------------------------------------------- END