diff options
author | Eli Zaretskii <eliz@gnu.org> | 2001-07-29 08:03:36 +0000 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2001-07-29 08:03:36 +0000 |
commit | 6c56c06965e54986e5e5ad75f399a914b4b1becd (patch) | |
tree | d3cd023b127b794b76fd4679a060339666e673a1 /gdb/config/i386/tm-go32.h | |
parent | 2f83960e2ca6a38b4a68d3c394fb2b5c0db2e2af (diff) | |
download | gdb-6c56c06965e54986e5e5ad75f399a914b4b1becd.zip gdb-6c56c06965e54986e5e5ad75f399a914b4b1becd.tar.gz gdb-6c56c06965e54986e5e5ad75f399a914b4b1becd.tar.bz2 |
Support for stepping through longjmp in DJGPP programs:
* config/i386/tm-go32.h (JB_ELEMENT_SIZE, JB_PC): New macros.
(GET_LONGJMP_TARGET): Define to call get_longjmp_target.
(get_longjmp_target): Add prototype.
Diffstat (limited to 'gdb/config/i386/tm-go32.h')
-rw-r--r-- | gdb/config/i386/tm-go32.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gdb/config/i386/tm-go32.h b/gdb/config/i386/tm-go32.h index f416396..024f4fb 100644 --- a/gdb/config/i386/tm-go32.h +++ b/gdb/config/i386/tm-go32.h @@ -48,4 +48,20 @@ #undef FRAME_SAVED_PC #define FRAME_SAVED_PC(FRAME) (read_memory_integer ((FRAME)->frame + 4, 4)) +/* Support for longjmp. */ + +/* Details about jmp_buf. It's supposed to be an array of integers. */ + +#define JB_ELEMENT_SIZE 4 /* Size of elements in jmp_buf. */ +#define JB_PC 8 /* Array index of saved PC inside jmp_buf. */ + +/* Figure out where the longjmp will land. Slurp the args out of the + stack. We expect the first arg to be a pointer to the jmp_buf + structure from which we extract the pc (JB_PC) that we will land + at. The pc is copied into ADDR. This routine returns true on + success. */ + +#define GET_LONGJMP_TARGET(addr) get_longjmp_target (addr) +extern int get_longjmp_target (CORE_ADDR *addr); + #endif /* TM_GO32_H */ |