diff options
author | Mark Kettenis <kettenis@gnu.org> | 2003-10-26 13:08:57 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@gnu.org> | 2003-10-26 13:08:57 +0000 |
commit | e9e2fecb66aa1a0c76fc0d898e4f8a0d1b6ca384 (patch) | |
tree | 1b59ef9b734818dabb5ed34fbeba5b221b959786 /gdb/i386-tdep.h | |
parent | 9f62f94dda8a3e8011ec682e566d8fd935fa32f8 (diff) | |
download | gdb-e9e2fecb66aa1a0c76fc0d898e4f8a0d1b6ca384.tar.gz |
Change register numbers to enumartion values.
* i386-tdep.h (enum i386_regnum): New.
(I386_EAX_REGNUM, I386_EDX_REGNUM, I386_ESP_REGNUM,
I386_EBP_REGNUM, I386_IP_REGNUM, I386_EFLAGS_REGNUM,
I386_ST0_REGNUM): Remove defines.
* i386-tdep.c (I386_EBX_REGNUM, I386_ECX_REGNUM, I386_ESI_REGNUM,
I386_EDI_REGNUM): Remove defines.
Diffstat (limited to 'gdb/i386-tdep.h')
-rw-r--r-- | gdb/i386-tdep.h | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/gdb/i386-tdep.h b/gdb/i386-tdep.h index 59668d6b608..cb42a1b9a76 100644 --- a/gdb/i386-tdep.h +++ b/gdb/i386-tdep.h @@ -160,13 +160,20 @@ extern int i386_fpc_regnum_p (int regnum); /* Register numbers of various important registers. */ -#define I386_EAX_REGNUM 0 /* %eax */ -#define I386_EDX_REGNUM 2 /* %edx */ -#define I386_ESP_REGNUM 4 /* %esp */ -#define I386_EBP_REGNUM 5 /* %ebp */ -#define I386_EIP_REGNUM 8 /* %eip */ -#define I386_EFLAGS_REGNUM 9 /* %eflags */ -#define I386_ST0_REGNUM 16 /* %st(0) */ +enum i386_regnum +{ + I386_EAX_REGNUM, /* %eax */ + I386_ECX_REGNUM, /* %ecx */ + I386_EDX_REGNUM, /* %edx */ + I386_EBX_REGNUM, /* %ebx */ + I386_ESP_REGNUM, /* %esp */ + I386_EBP_REGNUM, /* %ebp */ + I386_ESI_REGNUM, /* %esi */ + I386_EDI_REGNUM, /* %edi */ + I386_EIP_REGNUM, /* %eip */ + I386_EFLAGS_REGNUM, /* %eflags */ + I386_ST0_REGNUM = 16, /* %st(0) */ +}; #define I386_NUM_GREGS 16 #define I386_NUM_FREGS 16 |