import gdb-1999-09-08 snapshot
[deliverable/binutils-gdb.git] / gdb / config / mips / tm-mips.h
index fd0ae23e3e3474405eb7d61f83edf6f4779d1bce..6e7e72c5762cc080d9b432bda3c00b08a98a594e 100644 (file)
 #ifndef TM_MIPS_H
 #define TM_MIPS_H 1
 
-#ifdef __STDC__
 struct frame_info;
 struct symbol;
 struct type;
 struct value;
-#endif
 
 #include <bfd.h>
 #include "coff/sym.h"          /* Needed for PDR below.  */
@@ -109,8 +107,6 @@ extern int in_sigtramp PARAMS ((CORE_ADDR, char *));
 
 #define INNER_THAN(lhs,rhs) ((lhs) < (rhs))
 
-#define BIG_ENDIAN 4321
-
 /* BREAKPOINT_FROM_PC uses the program counter value to determine whether a
    16- or 32-bit breakpoint should be used.  It returns a pointer
    to a string of bytes that encode a breakpoint instruction, stores
@@ -236,10 +232,31 @@ extern void mips_do_registers_info PARAMS ((int, int));
 
 #define REGISTER_BYTE(N) ((N) * MIPS_REGSIZE)
 
-/* Number of bytes of storage in the actual machine representation
-   for register N. */
+/* Number of bytes of storage in the actual machine representation for
+   register N.  NOTE: This indirectly defines the register size
+   transfered by the GDB protocol. */
+
+extern int mips_register_raw_size PARAMS ((int reg_nr));
+#define REGISTER_RAW_SIZE(N) (mips_register_raw_size ((N)))
+
+
+/* Covert between the RAW and VIRTUAL registers.
 
-#define REGISTER_RAW_SIZE(N) REGISTER_VIRTUAL_SIZE(N)
+   Some MIPS (SR, FSR, FIR) have a `raw' size of MIPS_REGSIZE but are
+   really 32 bit registers.  This is a legacy of the 64 bit MIPS GDB
+   protocol which transfers 64 bits for 32 bit registers. */
+
+extern int mips_register_convertible PARAMS ((int reg_nr));
+#define REGISTER_CONVERTIBLE(N) (mips_register_convertible ((N)))
+     
+
+void mips_register_convert_to_virtual PARAMS ((int reg_nr, struct type *virtual_type, char *raw_buf, char *virt_buf));
+#define REGISTER_CONVERT_TO_VIRTUAL(N,VIRTUAL_TYPE,RAW_BUF,VIRT_BUF) \
+  mips_register_convert_to_virtual (N,VIRTUAL_TYPE,RAW_BUF,VIRT_BUF)
+
+void mips_register_convert_to_raw PARAMS ((struct type *virtual_type, int reg_nr, char *virt_buf, char *raw_buf));
+#define REGISTER_CONVERT_TO_RAW(VIRTUAL_TYPE,N,VIRT_BUF,RAW_BUF) \
+  mips_register_convert_to_raw (VIRTUAL_TYPE,N,VIRT_BUF,RAW_BUF)
 
 /* Number of bytes of storage in the program's representation
    for register N. */
@@ -562,3 +579,7 @@ typedef unsigned long t_inst;       /* Integer big enough to hold an instruction */
   (((long) MSYMBOL_INFO (msym) & 0x80000000) != 0)
 #define MSYMBOL_SIZE(msym) \
   ((long) MSYMBOL_INFO (msym) & 0x7fffffff)
+
+
+/* Command to set the processor type. */
+extern void mips_set_processor_type_command (char *, int);
This page took 0.024644 seconds and 4 git commands to generate.