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

📄 ip2k.h

📁 gcc-you can use this code to learn something about gcc, and inquire further into linux,
💻 H
📖 第 1 页 / 共 5 页
字号:
/* Definitions of target machine for GNU compiler,   For Ubicom IP2022 Communications Controller   Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc.   Contributed by Red Hat, Inc and Ubicom, Inc.This file is part of GNU CC.GNU CC is free software; you can redistribute it and/or modifyit under the terms of the GNU General Public License as published bythe Free Software Foundation; either version 2, or (at your option)any later version.GNU CC is distributed in the hope that it will be useful,but WITHOUT ANY WARRANTY; without even the implied warranty ofMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See theGNU General Public License for more details.You should have received a copy of the GNU General Public Licensealong with GNU CC; see the file COPYING.  If not, write tothe Free Software Foundation, 59 Temple Place - Suite 330,Boston, MA 02111-1307, USA.  *//* Set up System V.4 (aka ELF) defaults.  */#include "elfos.h"#undef ASM_SPEC			/* But we have a GAS assembler.  */#define CPP_PREDEFINES \  "-DIP2K -D_DOUBLE_IS_32BITS -D__BUFSIZ__=512 -D__FILENAME_MAX__=128"/* Define this to be a string constant containing `-D' options to   define the predefined macros that identify this machine and system.   These macros will be predefined unless the `-ansi' option is   specified.   In addition, a parallel set of macros are predefined, whose names   are made by appending `__' at the beginning and at the end.  These   `__' macros are permitted by the ANSI standard, so they are   predefined regardless of whether `-ansi' is specified.   For example, on the Sun, one can use the following value:   "-Dmc68000 -Dsun -Dunix"   The result is to define the macros `__mc68000__', `__sun__' and   `__unix__' unconditionally, and the macros `mc68000', `sun' and   `unix' provided `-ansi' is not specified.  *//* This declaration should be present.  */extern int target_flags;/* `TARGET_...'   This series of macros is to allow compiler command arguments to   enable or disable the use of optional features of the target   machine.  For example, one machine description serves both the   68000 and the 68020; a command argument tells the compiler whether   it should use 68020-only instructions or not.  This command   argument works by means of a macro `TARGET_68020' that tests a bit   in `target_flags'.   Define a macro `TARGET_FEATURENAME' for each such option.  Its   definition should test a bit in `target_flags'; for example:   #define TARGET_68020 (target_flags & 1)   One place where these macros are used is in the   condition-expressions of instruction patterns.  Note how   `TARGET_68020' appears frequently in the 68000 machine description   file, `m68k.md'.  Another place they are used is in the   definitions of the other macros in the `MACHINE.h' file.  */#define TARGET_SWITCHES {{"",0, NULL}}/* This macro defines names of command options to set and clear bits   in `target_flags'.  Its definition is an initializer with a   subgrouping for each command option.   Each subgrouping contains a string constant, that defines the   option name, and a number, which contains the bits to set in   `target_flags'.  A negative number says to clear bits instead; the   negative of the number is which bits to clear.  The actual option   name is made by appending `-m' to the specified name.   One of the subgroupings should have a null string.  The number in   this grouping is the default value for `target_flags'.  Any target   options act starting with that value.   Here is an example which defines `-m68000' and `-m68020' with   opposite meanings, and picks the latter as the default:   #define TARGET_SWITCHES \   { { "68020", 1},      \   { "68000", -1},     \   { "", 1}}  *//* This macro is similar to `TARGET_SWITCHES' but defines names of   command options that have values.  Its definition is an   initializer with a subgrouping for each command option.   Each subgrouping contains a string constant, that defines the   fixed part of the option name, and the address of a variable.  The   variable, type `char *', is set to the variable part of the given   option if the fixed part matches.  The actual option name is made   by appending `-m' to the specified name.   Here is an example which defines `-mshort-data-NUMBER'.  If the   given option is `-mshort-data-512', the variable `m88k_short_data'   will be set to the string `"512"'.   extern char *m88k_short_data;   #define TARGET_OPTIONS \   { { "short-data-", &m88k_short_data } }  */#define TARGET_VERSION fprintf (stderr, " (ip2k, GNU assembler syntax)")/* This macro is a C statement to print on `stderr' a string   describing the particular machine description choice.  Every   machine description should define `TARGET_VERSION'. For example:   #ifdef MOTOROLA   #define TARGET_VERSION \   fprintf (stderr, " (68k, Motorola syntax)")   #else   #define TARGET_VERSION \   fprintf (stderr, " (68k, MIT syntax)")   #endif  *//* Caller-saves is not a win for the IP2K.  Pretty much anywhere that   a register is permitted allows SP-relative addresses too.   This machine doesn't have PIC addressing modes, so disable that also.  */#define OVERRIDE_OPTIONS	\    do {			\	flag_caller_saves = 0;	\	flag_pic = 0;		\    } while (0)/* `OVERRIDE_OPTIONS'   Sometimes certain combinations of command options do not make   sense on a particular target machine.  You can define a macro   `OVERRIDE_OPTIONS' to take account of this.  This macro, if   defined, is executed once just after all the command options have   been parsed.   Don't use this macro to turn on various extra optimizations for   `-O'.  That is what `OPTIMIZATION_OPTIONS' is for.  *//* Put each function in its own section so that PAGE-instruction   relaxation can do its best.  */#define OPTIMIZATION_OPTIONS(LEVEL, SIZEFLAG)	\    do {					\	if ((LEVEL) || (SIZEFLAG))		\	    flag_function_sections = 1;	\    } while (0)/* Define this if most significant byte of a word is the lowest numbered.  */#define BITS_BIG_ENDIAN 0/* Define this if most significant byte of a word is the lowest numbered.  */#define BYTES_BIG_ENDIAN 1/* Define this if most significant word of a multiword number is the lowest   numbered.  */#define WORDS_BIG_ENDIAN 1/* Number of bits in an addressable storage unit.  */#define BITS_PER_UNIT 8/* Width in bits of a "word", which is the contents of a machine register.   Note that this is not necessarily the width of data type `int';  */#define BITS_PER_WORD 8/* Width of a word, in units (bytes).  */#define UNITS_PER_WORD (BITS_PER_WORD / BITS_PER_UNIT)/* Width in bits of a pointer.   See also the macro `Pmode' defined below.  */#define POINTER_SIZE 16/* Maximum sized of reasonable data type DImode or Dfmode ...  */#define MAX_FIXED_MODE_SIZE 64/* Allocation boundary (in *bits*) for storing arguments in argument list.  */#define PARM_BOUNDARY 8/* Allocation boundary (in *bits*) for the code of a function.  */#define FUNCTION_BOUNDARY 16/* Alignment of field after `int : 0' in a structure.  */#define EMPTY_FIELD_BOUNDARY 8/* No data type wants to be aligned rounder than this.  */#define BIGGEST_ALIGNMENT 8#define STRICT_ALIGNMENT 0#define PCC_BITFIELD_TYPE_MATTERS 1/* A C expression for the size in bits of the type `int' on the     target machine.  If you don't define this, the default is one word.  */#undef INT_TYPE_SIZE#define INT_TYPE_SIZE 16/* A C expression for the size in bits of the type `short' on the   target machine.  If you don't define this, the default is half a   word.  (If this would be less than one storage unit, it is rounded   up to one unit.)  */#undef SHORT_TYPE_SIZE#define SHORT_TYPE_SIZE 16/* A C expression for the size in bits of the type `long' on the   target machine.  If you don't define this, the default is one word.  */#undef LONG_TYPE_SIZE#define LONG_TYPE_SIZE 32/* Maximum number for the size in bits of the type `long' on the   target machine.  If this is undefined, the default is   `LONG_TYPE_SIZE'.  Otherwise, it is the constant value that is the   largest value that `LONG_TYPE_SIZE' can have at run-time.  This is   used in `cpp'.  */#define MAX_LONG_TYPE_SIZE 32/* A C expression for the size in bits of the type `long long' on the   target machine.  If you don't define this, the default is two   words.  If you want to support GNU Ada on your machine, the value   of macro must be at least 64.  */#undef LONG_LONG_TYPE_SIZE#define LONG_LONG_TYPE_SIZE	64#undef CHAR_TYPE_SIZE#define  CHAR_TYPE_SIZE 8/* A C expression for the size in bits of the type `char' on the   target machine.  If you don't define this, the default is one   quarter of a word.  (If this would be less than one storage unit,   it is rounded up to one unit.)  */#undef FLOAT_TYPE_SIZE#define FLOAT_TYPE_SIZE 32/* A C expression for the size in bits of the type `float' on the   target machine.  If you don't define this, the default is one word.  */#undef DOUBLE_TYPE_SIZE#define DOUBLE_TYPE_SIZE 32/* A C expression for the size in bits of the type `double' on the   target machine.  If you don't define this, the default is two   words.  *//* A C expression for the size in bits of the type `long double' on   the target machine.  If you don't define this, the default is two   words.  */#undef LONG_DOUBLE_TYPE_SIZE#define LONG_DOUBLE_TYPE_SIZE	32#define DEFAULT_SIGNED_CHAR 1/* An expression whose value is 1 or 0, according to whether the type   `char' should be signed or unsigned by default.  The user can   always override this default with the options `-fsigned-char' and   `-funsigned-char'.  *//* #define DEFAULT_SHORT_ENUMS	1   This was the default for the IP2k but gcc has a bug (as of 17th May   2001) in the way that library calls to the memory checker functions   are issues that screws things up if an enum is not equivalent to   an int.  *//* `DEFAULT_SHORT_ENUMS'   A C expression to determine whether to give an `enum' type only as   many bytes as it takes to represent the range of possible values   of that type.  A nonzero value means to do that; a zero value   means all `enum' types should be allocated like `int'.   If you don't define the macro, the default is 0.  */#define SIZE_TYPE "unsigned int"/* A C expression for a string describing the name of the data type   to use for size values.  The typedef name `size_t' is defined   using the contents of the string.      The string can contain more than one keyword.  If so, separate   them with spaces, and write first any length keyword, then   `unsigned' if appropriate, and finally `int'.  The string must   exactly match one of the data type names defined in the function   `init_decl_processing' in the file `c-decl.c'.  You may not omit   `int' or change the order--that would cause the compiler to crash   on startup.      If you don't define this macro, the default is `"long unsigned   int"'.  */#define PTRDIFF_TYPE "int"/* A C expression for a string describing the name of the data type   to use for the result of subtracting two pointers.  The typedef   name `ptrdiff_t' is defined using the contents of the string.  See   `SIZE_TYPE' above for more information.   

⌨️ 快捷键说明

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