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

📄 frv.h

📁 linux下的gcc编译器
💻 H
📖 第 1 页 / 共 5 页
字号:
/* Target macros for the FRV port of GCC.   Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.   Contributed by Red Hat Inc.   This file is part of GCC.   GCC is free software; you can redistribute it and/or modify it   under the terms of the GNU General Public License as published   by the Free Software Foundation; either version 2, or (at your   option) any later version.   GCC is distributed in the hope that it will be useful, but WITHOUT   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public   License for more details.   You should have received a copy of the GNU General Public License   along with GCC; see the file COPYING.  If not, write to the Free   Software Foundation, 59 Temple Place - Suite 330, Boston, MA   02111-1307, USA.  */#ifndef __FRV_H__#define __FRV_H__/* Set up System V.4 (aka ELF) defaults.  */#include "svr4.h"/* Frv general purpose macros.  *//* Align an address.  */#define ADDR_ALIGN(addr,align) (((addr) + (align) - 1) & ~((align) - 1))/* Return true if a value is inside a range.  */#define IN_RANGE_P(VALUE, LOW, HIGH)				\  (   (((HOST_WIDE_INT)(VALUE)) >= (HOST_WIDE_INT)(LOW))	\   && (((HOST_WIDE_INT)(VALUE)) <= ((HOST_WIDE_INT)(HIGH))))/* Driver configuration.  *//* A C expression which determines whether the option `-CHAR' takes arguments.   The value should be the number of arguments that option takes-zero, for many   options.   By default, this macro is defined to handle the standard options properly.   You need not define it unless you wish to add additional options which take   arguments.   Defined in svr4.h.  */#undef  SWITCH_TAKES_ARG#define SWITCH_TAKES_ARG(CHAR)                                          \  (DEFAULT_SWITCH_TAKES_ARG (CHAR) || (CHAR) == 'G')/* A C expression which determines whether the option `-NAME' takes arguments.   The value should be the number of arguments that option takes-zero, for many   options.  This macro rather than `SWITCH_TAKES_ARG' is used for   multi-character option names.   By default, this macro is defined as `DEFAULT_WORD_SWITCH_TAKES_ARG', which   handles the standard options properly.  You need not define   `WORD_SWITCH_TAKES_ARG' unless you wish to add additional options which take   arguments.  Any redefinition should call `DEFAULT_WORD_SWITCH_TAKES_ARG' and   then check for additional options.   Defined in svr4.h.  */#undef WORD_SWITCH_TAKES_ARG/* A C string constant that tells the GNU CC driver program options to pass to   the assembler.  It can also specify how to translate options you give to GNU   CC into options for GNU CC to pass to the assembler.  See the file `sun3.h'   for an example of this.   Do not define this macro if it does not need to do anything.   Defined in svr4.h.  */#undef  ASM_SPEC#define ASM_SPEC "\%{G*} %{v} %{n} %{T} %{Ym,*} %{Yd,*} %{Wa,*:%*} \%{mtomcat-stats} \%{!mno-eflags: \    %{mcpu=*} \    %{mgpr-*} %{mfpr-*} \    %{msoft-float} %{mhard-float} \    %{mdword} %{mno-dword} \    %{mdouble} %{mno-double} \    %{mmedia} %{mno-media} \    %{mmuladd} %{mno-muladd} \    %{mpack} %{mno-pack} \    %{fpic: -mpic} %{fPIC: -mPIC} %{mlibrary-pic}}"/* Another C string constant used much like `LINK_SPEC'.  The difference   between the two is that `STARTFILE_SPEC' is used at the very beginning of   the command given to the linker.   If this macro is not defined, a default is provided that loads the standard   C startup file from the usual place.  See `gcc.c'.   Defined in svr4.h.  */#undef  STARTFILE_SPEC#define STARTFILE_SPEC "crt0%O%s frvbegin%O%s"/* Another C string constant used much like `LINK_SPEC'.  The difference   between the two is that `ENDFILE_SPEC' is used at the very end of the   command given to the linker.   Do not define this macro if it does not need to do anything.   Defined in svr4.h.  */#undef  ENDFILE_SPEC#define ENDFILE_SPEC "frvend%O%s"/* A C string constant that tells the GNU CC driver program options to pass to   CPP.  It can also specify how to translate options you give to GNU CC into   options for GNU CC to pass to the CPP.   Do not define this macro if it does not need to do anything.  *//* The idea here is to use the -mcpu option to define macros based on the   processor's features, using the features of the default processor if   no -mcpu option is given.  These macros can then be overridden by   other -m options.  */#define CPP_SPEC "\%{mcpu=frv: %(cpp_frv)} \%{mcpu=fr500: %(cpp_fr500)} \%{mcpu=fr400: %(cpp_fr400)} \%{mcpu=fr300: %(cpp_simple)} \%{mcpu=tomcat: %(cpp_fr500)} \%{mcpu=simple: %(cpp_simple)} \%{!mcpu*: %(cpp_cpu_default)} \%{mno-media: -D__FRV_ACC__=0 %{msoft-float: -D__FRV_FPR__=0}} \%{mhard-float: -D__FRV_HARD_FLOAT__} \%{msoft-float: -U__FRV_HARD_FLOAT__} \%{mgpr-32: -U__FRV_GPR__ -D__FRV_GPR__=32} \%{mgpr-64: -U__FRV_GPR__ -D__FRV_GPR__=64} \%{mfpr-32: -U__FRV_FPR__ -D__FRV_FPR__=32} \%{mfpr-64: -U__FRV_FPR__ -D__FRV_FPR__=64} \%{macc-4: -U__FRV_ACC__ -D__FRV_ACC__=4} \%{macc-8: -U__FRV_ACC__ -D__FRV_ACC__=8} \%{mdword: -D__FRV_DWORD__} \%{mno-dword: -U__FRV_DWORD__} \%{mno-pack: -U__FRV_VLIW__} \%{fleading-underscore: -D__FRV_UNDERSCORE__}"/* CPU defaults.  Each CPU has its own CPP spec that defines the default   macros for that CPU.  Each CPU also has its own default target mask.   CPU		GPRs	FPRs	ACCs	FPU	MulAdd  ldd/std  Issue rate   ---		----    ----    ----    ---	------  -------  ----------   FRV		64	64	8	double	yes	yes      4   FR500	64	64	8	single	no	yes      4   FR400	32	32	4	none	no	yes      2   Simple	32	0	0	none	no	no       1 */#define CPP_FRV_SPEC "\-D__FRV_GPR__=64 \-D__FRV_FPR__=64 \-D__FRV_ACC__=8 \-D__FRV_HARD_FLOAT__ \-D__FRV_DWORD__ \-D__FRV_VLIW__=4"#define CPP_FR500_SPEC "\-D__FRV_GPR__=64 \-D__FRV_FPR__=64 \-D__FRV_ACC__=8 \-D__FRV_HARD_FLOAT__ \-D__FRV_DWORD__ \-D__FRV_VLIW__=4"#define CPP_FR400_SPEC "\-D__FRV_GPR__=32 \-D__FRV_FPR__=32 \-D__FRV_ACC__=4 \-D__FRV_DWORD__ \-D__FRV_VLIW__=2"#define CPP_SIMPLE_SPEC "\-D__FRV_GPR__=32 \-D__FRV_FPR__=0 \-D__FRV_ACC__=0 \%{mmedia: -D__FRV_ACC__=8} \%{mhard-float|mmedia: -D__FRV_FPR__=64}"#define MASK_DEFAULT_FRV	\  (MASK_MEDIA			\   | MASK_DOUBLE		\   | MASK_MULADD		\   | MASK_DWORD			\   | MASK_PACK)#define MASK_DEFAULT_FR500 \  (MASK_MEDIA | MASK_DWORD | MASK_PACK)#define MASK_DEFAULT_FR400	\  (MASK_GPR_32			\   | MASK_FPR_32		\   | MASK_MEDIA			\   | MASK_ACC_4			\   | MASK_SOFT_FLOAT		\   | MASK_DWORD			\   | MASK_PACK)#define MASK_DEFAULT_SIMPLE \  (MASK_GPR_32 | MASK_SOFT_FLOAT)/* A C string constant that tells the GNU CC driver program options to pass to   `cc1'.  It can also specify how to translate options you give to GNU CC into   options for GNU CC to pass to the `cc1'.   Do not define this macro if it does not need to do anything.  *//* For ABI compliance, we need to put bss data into the normal data section.  */#define CC1_SPEC "%{G*}"/* A C string constant that tells the GNU CC driver program options to pass to   the linker.  It can also specify how to translate options you give to GNU CC   into options for GNU CC to pass to the linker.   Do not define this macro if it does not need to do anything.   Defined in svr4.h.  *//* Override the svr4.h version with one that dispenses without the svr4   shared library options, notably -G.  */#undef	LINK_SPEC#define LINK_SPEC "\%{h*} %{v:-V} \%{b} %{Wl,*:%*} \%{static:-dn -Bstatic} \%{shared:-Bdynamic} \%{symbolic:-Bsymbolic} \%{G*} \%{YP,*} \%{Qy:} %{!Qn:-Qy}"/* Another C string constant used much like `LINK_SPEC'.  The difference   between the two is that `LIB_SPEC' is used at the end of the command given   to the linker.   If this macro is not defined, a default is provided that loads the standard   C library from the usual place.  See `gcc.c'.   Defined in svr4.h.  */#undef  LIB_SPEC#define LIB_SPEC "--start-group -lc -lsim --end-group"/* This macro defines names of additional specifications to put in the specs   that can be used in various specifications like CC1_SPEC.  Its definition   is an initializer with a subgrouping for each command option.   Each subgrouping contains a string constant, that defines the   specification name, and a string constant that used by the GNU CC driver   program.   Do not define this macro if it does not need to do anything.  */#ifndef SUBTARGET_EXTRA_SPECS#define SUBTARGET_EXTRA_SPECS#endif#define EXTRA_SPECS							\  { "cpp_frv",		CPP_FRV_SPEC },					\  { "cpp_fr500",	CPP_FR500_SPEC },				\  { "cpp_fr400",	CPP_FR400_SPEC },				\  { "cpp_simple",	CPP_SIMPLE_SPEC },				\  { "cpp_cpu_default",	CPP_CPU_DEFAULT_SPEC },				\  SUBTARGET_EXTRA_SPECS#ifndef CPP_CPU_DEFAULT_SPEC#define CPP_CPU_DEFAULT_SPEC	CPP_FR500_SPEC#define CPU_TYPE		FRV_CPU_FR500#endif/* Allow us to easily change the default for -malloc-cc.  */#ifndef	DEFAULT_NO_ALLOC_CC#define MASK_DEFAULT_ALLOC_CC	MASK_ALLOC_CC#else#define MASK_DEFAULT_ALLOC_CC	0#endif/* Run-time target specifications *//* 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.  */#define CPP_PREDEFINES "-D__frv__ -Amachine(frv)"/* This declaration should be present.  */extern int target_flags;/* This series of macros is to allow compiler command arguments to enable or

⌨️ 快捷键说明

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