⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mips.h.svn-base

📁 PSP用开发必装库GCC4.0.1
💻 SVN-BASE
📖 第 1 页 / 共 5 页
字号:
#define BIGGEST_ALIGNMENT LONG_DOUBLE_TYPE_SIZE/* All accesses must be aligned.  */#define STRICT_ALIGNMENT 1/* Define this if you wish to imitate the way many other C compilers   handle alignment of bitfields and the structures that contain   them.   The behavior is that the type written for a bit-field (`int',   `short', or other integer type) imposes an alignment for the   entire structure, as if the structure really did contain an   ordinary field of that type.  In addition, the bit-field is placed   within the structure so that it would fit within such a field,   not crossing a boundary for it.   Thus, on most machines, a bit-field whose type is written as `int'   would not cross a four-byte boundary, and would force four-byte   alignment for the whole structure.  (The alignment used may not   be four bytes; it is controlled by the other alignment   parameters.)   If the macro is defined, its definition should be a C expression;   a nonzero value for the expression enables this behavior.  */#define PCC_BITFIELD_TYPE_MATTERS 1/* If defined, a C expression to compute the alignment given to a   constant that is being placed in memory.  CONSTANT is the constant   and ALIGN is the alignment that the object would ordinarily have.   The value of this macro is used instead of that alignment to align   the object.   If this macro is not defined, then ALIGN is used.   The typical use of this macro is to increase alignment for string   constants to be word aligned so that `strcpy' calls that copy   constants can be done inline.  */#define CONSTANT_ALIGNMENT(EXP, ALIGN)					\  ((TREE_CODE (EXP) == STRING_CST  || TREE_CODE (EXP) == CONSTRUCTOR)	\   && (ALIGN) < BITS_PER_WORD ? BITS_PER_WORD : (ALIGN))/* If defined, a C expression to compute the alignment for a static   variable.  TYPE is the data type, and ALIGN is the alignment that   the object would ordinarily have.  The value of this macro is used   instead of that alignment to align the object.   If this macro is not defined, then ALIGN is used.   One use of this macro is to increase alignment of medium-size   data to make it all fit in fewer cache lines.  Another is to   cause character arrays to be word-aligned so that `strcpy' calls   that copy constants to character arrays can be done inline.  */#undef DATA_ALIGNMENT#define DATA_ALIGNMENT(TYPE, ALIGN)					\  ((((ALIGN) < BITS_PER_WORD)						\    && (TREE_CODE (TYPE) == ARRAY_TYPE					\	|| TREE_CODE (TYPE) == UNION_TYPE				\	|| TREE_CODE (TYPE) == RECORD_TYPE)) ? BITS_PER_WORD : (ALIGN))#define PAD_VARARGS_DOWN \  (FUNCTION_ARG_PADDING (TYPE_MODE (type), type) == downward)/* Define if operations between registers always perform the operation   on the full register even if a narrower mode is specified.  */#define WORD_REGISTER_OPERATIONS/* When in 64 bit mode, move insns will sign extend SImode and CCmode   moves.  All other references are zero extended.  */#define LOAD_EXTEND_OP(MODE) \  (TARGET_64BIT && ((MODE) == SImode || (MODE) == CCmode) \   ? SIGN_EXTEND : ZERO_EXTEND)/* Define this macro if it is advisable to hold scalars in registers   in a wider mode than that declared by the program.  In such cases,   the value is constrained to be within the bounds of the declared   type, but kept valid in the wider mode.  The signedness of the   extension may differ from that of the type.  */#define PROMOTE_MODE(MODE, UNSIGNEDP, TYPE)	\  if (GET_MODE_CLASS (MODE) == MODE_INT		\      && GET_MODE_SIZE (MODE) < UNITS_PER_WORD) \    {                                           \      if ((MODE) == SImode)                     \        (UNSIGNEDP) = 0;                        \      (MODE) = Pmode;                           \    }/* Define if loading short immediate values into registers sign extends.  */#define SHORT_IMMEDIATES_SIGN_EXTEND/* The [d]clz instructions have the natural values at 0.  */#define CLZ_DEFINED_VALUE_AT_ZERO(MODE, VALUE) \  ((VALUE) = GET_MODE_BITSIZE (MODE), true)/* Standard register usage.  *//* Number of hardware registers.  We have:   - 32 integer registers   - 32 floating point registers   - 8 condition code registers   - 2 accumulator registers (hi and lo)   - 32 registers each for coprocessors 0, 2 and 3   - 3 fake registers:	- ARG_POINTER_REGNUM	- FRAME_POINTER_REGNUM	- FAKE_CALL_REGNO (see the comment above load_callsi for details)   - 3 dummy entries that were used at various times in the past.  */#define FIRST_PSEUDO_REGISTER 176/* By default, fix the kernel registers ($26 and $27), the global   pointer ($28) and the stack pointer ($29).  This can change   depending on the command-line options.   Regarding coprocessor registers: without evidence to the contrary,   it's best to assume that each coprocessor register has a unique   use.  This can be overridden, in, e.g., override_options() or   CONDITIONAL_REGISTER_USAGE should the assumption be inappropriate   for a particular target.  */#define FIXED_REGISTERS							\{									\  1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0,			\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1,			\  /* COP0 registers */							\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  /* COP2 registers */							\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  /* COP3 registers */							\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1			\}/* Set up this array for o32 by default.   Note that we don't mark $31 as a call-clobbered register.  The idea is   that it's really the call instructions themselves which clobber $31.   We don't care what the called function does with it afterwards.   This approach makes it easier to implement sibcalls.  Unlike normal   calls, sibcalls don't clobber $31, so the register reaches the   called function in tact.  EPILOGUE_USES says that $31 is useful   to the called function.  */#define CALL_USED_REGISTERS						\{									\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  /* COP0 registers */							\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  /* COP2 registers */							\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  /* COP3 registers */							\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1			\}/* Define this since $28, though fixed, is call-saved in many ABIs.  */#define CALL_REALLY_USED_REGISTERS                                      \{ /* General registers.  */                                             \  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,                       \  0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 0, 0,                       \  /* Floating-point registers.  */                                      \  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  /* Others.  */                                                        \  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,			\  /* COP0 registers */							\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  /* COP2 registers */							\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  /* COP3 registers */							\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,			\  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0			\}/* Internal macros to classify a register number as to whether it's a   general purpose register, a floating point register, a   multiply/divide register, or a status register.  */#define GP_REG_FIRST 0#define GP_REG_LAST  31#define GP_REG_NUM   (GP_REG_LAST - GP_REG_FIRST + 1)#define GP_DBX_FIRST 0#define FP_REG_FIRST 32#define FP_REG_LAST  63#define FP_REG_NUM   (FP_REG_LAST - FP_REG_FIRST + 1)#define FP_DBX_FIRST ((write_symbols == DBX_DEBUG) ? 38 : 32)#define MD_REG_FIRST 64#define MD_REG_LAST  65#define MD_REG_NUM   (MD_REG_LAST - MD_REG_FIRST + 1)#define MD_DBX_FIRST (FP_DBX_FIRST + FP_REG_NUM)#define ST_REG_FIRST 67#define ST_REG_LAST  74#define ST_REG_NUM   (ST_REG_LAST - ST_REG_FIRST + 1)/* FIXME: renumber.  */#define COP0_REG_FIRST 80#define COP0_REG_LAST 111#define COP0_REG_NUM (COP0_REG_LAST - COP0_REG_FIRST + 1)#define COP2_REG_FIRST 112#define COP2_REG_LAST 143#define COP2_REG_NUM (COP2_REG_LAST - COP2_REG_FIRST + 1)#define COP3_REG_FIRST 144#define COP3_REG_LAST 175#define COP3_REG_NUM (COP3_REG_LAST - COP3_REG_FIRST + 1)/* ALL_COP_REG_NUM assumes that COP0,2,and 3 are numbered consecutively.  */#define ALL_COP_REG_NUM (COP3_REG_LAST - COP0_REG_FIRST + 1)#define AT_REGNUM	(GP_REG_FIRST + 1)#define HI_REGNUM	(MD_REG_FIRST + 0)#define LO_REGNUM	(MD_REG_FIRST + 1)/* FPSW_REGNUM is the single condition code used if !ISA_HAS_8CC.   If ISA_HAS_8CC, it should not be used, and an arbitrary ST_REG   should be used instead.  */#define FPSW_REGNUM	ST_REG_FIRST#define GP_REG_P(REGNO)	\  ((unsigned int) ((int) (REGNO) - GP_REG_FIRST) < GP_REG_NUM)#define M16_REG_P(REGNO) \  (((REGNO) >= 2 && (REGNO) <= 7) || (REGNO) == 16 || (REGNO) == 17)#define FP_REG_P(REGNO)  \  ((unsigned int) ((int) (REGNO) - FP_REG_FIRST) < FP_REG_NUM)#define MD_REG_P(REGNO) \  ((unsigned int) ((int) (REGNO) - MD_REG_FIRST) < MD_REG_NUM)#define ST_REG_P(REGNO) \  ((unsigned int) ((int) (REGNO) - ST_REG_FIRST) < ST_REG_NUM)#define COP0_REG_P(REGNO) \  ((unsigned int) ((int) (REGNO) - COP0_REG_FIRST) < COP0_REG_NUM)#define COP2_REG_P(REGNO) \  ((unsigned int) ((int) (REGNO) - COP2_REG_FIRST) < COP2_REG_NUM)#define COP3_REG_P(REGNO) \  ((unsigned int) ((int) (REGNO) - COP3_REG_FIRST) < COP3_REG_NUM)#define ALL_COP_REG_P(REGNO) \  ((unsigned int) ((int) (REGNO) - COP0_REG_FIRST) < ALL_COP_REG_NUM)#define FP_REG_RTX_P(X) (REG_P (X) && FP_REG_P (REGNO (X)))/* True if X is (const (unspec [(const_int 0)] UNSPEC_GP)).  This is used   to initialize the mips16 gp pseudo register.  */#define CONST_GP_P(X)				\  (GET_CODE (X) == CONST			\   && GET_CODE (XEXP (X, 0)) == UNSPEC		\   && XINT (XEXP (X, 0), 1) == UNSPEC_GP)/* Return coprocessor number from register number.  */#define COPNUM_AS_CHAR_FROM_REGNUM(REGNO) 				\  (COP0_REG_P (REGNO) ? '0' : COP2_REG_P (REGNO) ? '2'			\   : COP3_REG_P (REGNO) ? '3' : '?')#define HARD_REGNO_NREGS(REGNO, MODE) mips_hard_regno_nregs (REGNO, MODE)/* To make the code simpler, HARD_REGNO_MODE_OK just references an   array built in override_options.  Because machmodes.h is not yet   included before this file is processed, the MODE bound can't be   expressed here.  */extern char mips_hard_regno_mode_ok[][FIRST_PSEUDO_REGISTER];#define HARD_REGNO_MODE_OK(REGNO, MODE)					\  mips_hard_regno_mode_ok[ (int)(MODE) ][ (REGNO) ]/* Value is 1 if it is a good idea to tie two pseudo registers   when one has mode MODE1 and one has mode MODE2.   If HARD_REGNO_MODE_OK could produce different values for MODE1 and MODE2,   for any hard reg, then this must be 0 for correct output.  */#define MODES_TIEABLE_P(MODE1, MODE2)					\  ((GET_MODE_CLASS (MODE1) == MODE_FLOAT ||				\    GET_MODE_CLASS (MODE1) == MODE_COMPLEX_FLOAT)			\   == (GET_MODE_CLASS (MODE2) == MODE_FLOAT ||				\       GET_MODE_CLASS (MODE2) == MODE_COMPLEX_FLOAT))/* Register to use for pushing function arguments.  */#define STACK_POINTER_REGNUM (GP_REG_FIRST + 29)/* These two registers don't really exist: they get eliminated to either   the stack or hard frame pointer.  */#define ARG_POINTER_REGNUM 77#define FRAME_POINTER_REGNUM 78/* $30 is not available on the mips16, so we use $17 as the frame   pointer.  */#define HARD_FRAME_POINTER_REGNUM \  (TARGET_MIPS16 ? GP_REG_FIRST + 17 : GP_REG_FIRST + 30)/* Value should be nonzero if functions must have frame pointers.   Zero means the frame pointer need not be set up (and parms   may be accessed via the stack pointer) in functions that seem suitable.   This is computed in `reload', in reload1.c.  */#define FRAME_POINTER_REQUIRED (current_function_calls_alloca)/* Register in which static-chain is passed to a function.  */#define STATIC_CHAIN_REGNUM (GP_REG_FIRST + 2)/* Registers used as temporaries in prologue/epilogue code.  If we're   generating mips16 code, these registers must come from the core set   of 8.  The prologue register mustn't conflict with any incoming   arguments, the static chain pointer, or the frame pointer.  The   epilogue temporary mustn't conflict with the return registers, the   frame pointer, the EH stack adjustment, or the EH data registers.  */#define MIPS_PROLOGUE_TEMP_REGNUM (GP_REG_FIRST + 3)#define MIPS_EPILOGUE_TEMP_REGNUM (GP_REG_FIRST + (TARGET_MIPS16 ? 6 : 8))#define MIPS_PROLOGUE_TEMP(MODE) gen_rtx_REG (MODE, MIPS_PROLOGUE_TEMP_REGNUM)#define MIPS_EPILOGUE_TEMP(MODE) gen_rtx_REG (MODE, MIPS_EPILOGUE_TEMP_REGNUM)/* D

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -