/* Subroutines used for code generation on IBM RS/6000.
Copyright (C) 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
Contributed by Richard Kenner (kenner@vlsi1.ultra.nyu.edu)
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, 51 Franklin Street, Fifth Floor, Boston,
MA 02110-1301, USA. */
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "rtl.h"
#include "regs.h"
#include "hard-reg-set.h"
#include "real.h"
#include "insn-config.h"
#include "conditions.h"
#include "insn-attr.h"
#include "flags.h"
#include "recog.h"
#include "obstack.h"
#include "tree.h"
#include "expr.h"
#include "optabs.h"
#include "except.h"
#include "function.h"
#include "output.h"
#include "basic-block.h"
#include "integrate.h"
#include "toplev.h"
#include "ggc.h"
#include "hashtab.h"
#include "tm_p.h"
#include "target.h"
#include "target-def.h"
#include "langhooks.h"
#include "reload.h"
#include "cfglayout.h"
#include "sched-int.h"
#include "tree-gimple.h"
#include "intl.h"
#include "params.h"
#include "tm-constrs.h"
#if TARGET_XCOFF
#include "xcoffout.h" /* get declarations of xcoff_*_section_name */
#endif
#if TARGET_MACHO
#include "gstab.h" /* for N_SLINE */
#endif
#ifndef TARGET_NO_PROTOTYPE
#define TARGET_NO_PROTOTYPE 0
#endif
#define min(A,B) ((A) < (B) ? (A) : (B))
#define max(A,B) ((A) > (B) ? (A) : (B))
/* Structure used to define the rs6000 stack */
typedef struct rs6000_stack {
int first_gp_reg_save; /* first callee saved GP register used */
int first_fp_reg_save; /* first callee saved FP register used */
int first_altivec_reg_save; /* first callee saved AltiVec register used */
int lr_save_p; /* true if the link reg needs to be saved */
int cr_save_p; /* true if the CR reg needs to be saved */
unsigned int vrsave_mask; /* mask of vec registers to save */
int push_p; /* true if we need to allocate stack space */
int calls_p; /* true if the function makes any calls */
int world_save_p; /* true if we're saving *everything*:
r13-r31, cr, f14-f31, vrsave, v20-v31 */
enum rs6000_abi abi; /* which ABI to use */
int gp_save_offset; /* offset to save GP regs from initial SP */
int fp_save_offset; /* offset to save FP regs from initial SP */
int altivec_save_offset; /* offset to save AltiVec regs from initial SP */
int lr_save_offset; /* offset to save LR from initial SP */
int cr_save_offset; /* offset to save CR from initial SP */
int vrsave_save_offset; /* offset to save VRSAVE from initial SP */
int spe_gp_save_offset; /* offset to save spe 64-bit gprs */
int varargs_save_offset; /* offset to save the varargs registers */
int ehrd_offset; /* offset to EH return data */
int reg_size; /* register size (4 or 8) */
HOST_WIDE_INT vars_size; /* variable save area size */
int parm_size; /* outgoing parameter size */
int save_size; /* save area size */
int fixed_size; /* fixed size of stack frame */
int gp_size; /* size of saved GP registers */
int fp_size; /* size of saved FP registers */
int altivec_size; /* size of saved AltiVec registers */
int cr_size; /* size to hold CR if not in save_size */
int vrsave_size; /* size to hold VRSAVE if not in save_size */
int altivec_padding_size; /* size of altivec alignment padding if
not in save_size */
int spe_gp_size; /* size of 64-bit GPR save size for SPE */
int spe_padding_size;
HOST_WIDE_INT total_size; /* total bytes allocated for stack */
int spe_64bit_regs_used;
} rs6000_stack_t;
/* A C structure for machine-specific, per-function data.
This is added to the cfun structure. */
typedef struct machine_function GTY(())
{
/* Flags if __builtin_return_address (n) with n >= 1 was used. */
int ra_needs_full_frame;
/* Some local-dynamic symbol. */
const char *some_ld_name;
/* Whether the instruction chain has been scanned already. */
int insn_chain_scanned_p;
/* Flags if __builtin_return_address (0) was used. */
int ra_need_lr;
/* Offset from virtual_stack_vars_rtx to the start of the ABI_V4
varargs save area. */
HOST_WIDE_INT varargs_save_offset;
} machine_function;
/* Target cpu type */
enum processor_type rs6000_cpu;
struct rs6000_cpu_select rs6000_select[3] =
{
/* switch name, tune arch */
{ (const char *)0, "--with-cpu=", 1, 1 },
{ (const char *)0, "-mcpu=", 1, 1 },
{ (const char *)0, "-mtune=", 1, 0 },
};
/* Always emit branch hint bits. */
static GTY(()) bool rs6000_always_hint;
/* Schedule instructions for group formation. */
static GTY(()) bool rs6000_sched_groups;
/* Support for -msched-costly-dep option. */
const char *rs6000_sched_costly_dep_str;
enum rs6000_dependence_cost rs6000_sched_costly_dep;
/* Support for -minsert-sched-nops option. */
const char *rs6000_sched_insert_nops_str;
enum rs6000_nop_insertion rs6000_sched_insert_nops;
/* Support targetm.vectorize.builtin_mask_for_load. */
static GTY(()) tree altivec_builtin_mask_for_load;
/* Size of long double. */
int rs6000_long_double_type_size;
/* IEEE quad extended precision long double. */
int rs6000_ieeequad;
/* Whether -mabi=altivec has appeared. */
int rs6000_altivec_abi;
/* Nonzero if we want SPE ABI extensions. */
int rs6000_spe_abi;
/* Nonzero if floating point operations are done in the GPRs. */
int rs6000_float_gprs = 0;
/* Nonzero if we want Darwin's struct-by-value-in-regs ABI. */
int rs6000_darwin64_abi;
/* Set to nonzero once AIX common-mode calls have been defined. */
static GTY(()) int common_mode_defined;
/* Save information from a "cmpxx" operation until the branch or scc is
emitted. */
rtx rs6000_compare_op0, rs6000_compare_op1;
int rs6000_compare_fp_p;
/* Label number of label created for -mrelocatable, to call to so we can
get the address of the GOT section */
int rs6000_pic_labelno;
#ifdef USING_ELFOS_H
/* Which abi to adhere to */
const char *rs6000_abi_name;
/* Semantics of the small data area */
enum rs6000_sdata_type rs6000_sdata = SDATA_DATA;
/* Which small data model to use */
const char *rs6000_sdata_name = (char *)0;
/* Counter for labels which are to be placed in .fixup. */
int fixuplabelno = 0;
#endif
/* Bit size of immediate TLS offsets and string from which it is decoded. */
int rs6000_tls_size = 32;
const char *rs6000_tls_size_string;
/* ABI enumeration available for subtarget to use. */
enum rs6000_abi rs6000_current_abi;
/* Whether to use variant of AIX ABI for PowerPC64 Linux. */
int dot_symbols;
/* Debug flags */
const char *rs6000_debug_name;
int rs6000_debug_stack; /* debug stack applications */
int rs6000_debug_arg; /* debug argument handling */
/* Value is TRUE if register/mode pair is acceptable. */
bool rs6000_hard_regno_mode_ok_p[NUM_MACHINE_MODES][FIRST_PSEUDO_REGISTER];
/* Built in types. */
tree rs6000_builtin_types[RS6000_BTI_MAX];
tree rs6000_builtin_decls[RS6000_BUILTIN_COUNT];
const char *rs6000_traceback_name;
static enum {
traceback_default = 0,
traceback_none,
traceback_part,
traceback_full
} rs6000_traceback;
/* Flag to say the TOC is initialized */
int toc_initialized;
char toc_label_name[10];
static GTY(()) section *read_only_data_section;
static GTY(()) section *private_data_section;
static GTY(()) section *read_only_private_data_section;
static GTY(()) section
没有合适的资源?快使用搜索试试~ 我知道了~
GCCXML 开源文件,用于提取C、C++语法树信息到xml文件
共2537个文件
h:793个
c:676个
md:160个
需积分: 37 15 下载量 112 浏览量
2017-06-03
16:16:42
上传
评论
收藏 13.42MB ZIP 举报
温馨提示
gccxml源码文件,用来把C/C++文件的语法树信息提取到xml文件中。
资源推荐
资源详情
资源评论
收起资源包目录
GCCXML 开源文件,用于提取C、C++语法树信息到xml文件 (2537个子文件)
abi 7KB
m32c.abi 3KB
ABOUT-GCC-NLS 2KB
configure.ac 109KB
configure.ac 20KB
configure.ac 4KB
configure.ac 2KB
algorithm 2KB
algorithm 159B
lb1sf68.asm 98KB
lib1funcs.asm 82KB
lib1funcs.asm 49KB
crt1.asm 33KB
lib1funcs.asm 29KB
larith.asm 20KB
lb1spc.asm 16KB
lib1funcs.asm 15KB
lib1funcs.asm 14KB
lib1funcs.asm 11KB
crtsavres.asm 10KB
eabi.asm 9KB
lib1.asm 7KB
lib1funcs.asm 7KB
lib1funcs-Os-4-200.asm 7KB
darwin-world.asm 7KB
lib1funcs.asm 6KB
sol2-gc1.asm 5KB
mulsi3.asm 5KB
sol2-c1.asm 5KB
crtbegin.asm 5KB
lib1funcs.asm 5KB
lb1spl.asm 4KB
crti.asm 4KB
darwin-vecsave.asm 4KB
crti.asm 4KB
linux-atomic.asm 4KB
darwin-tramp.asm 4KB
tramp.asm 3KB
eabi-ci.asm 3KB
crti.asm 3KB
sol2-c1.asm 3KB
qrnnd.asm 3KB
darwin-fpsave.asm 3KB
eabi-cn.asm 3KB
crtend.asm 3KB
sol-ci.asm 3KB
crtn.asm 3KB
lib1funcs.asm 3KB
cygwin.asm 3KB
lib2funcs.asm 3KB
crtn.asm 3KB
sol-cn.asm 3KB
crti.asm 2KB
lib1funcs.asm 2KB
vms-dwarf2.asm 2KB
crti.asm 2KB
sol2-ci.asm 2KB
crti.asm 2KB
crti.asm 2KB
crti.asm 2KB
crtn.asm 2KB
crtn.asm 2KB
crti.asm 2KB
crtn.asm 2KB
crtn.asm 2KB
crtn.asm 2KB
crtn.asm 2KB
sol2-cn.asm 2KB
sol2-ci.asm 2KB
sol2-cn.asm 2KB
crti.asm 2KB
crtn.asm 2KB
irix-crti.asm 2KB
crtn.asm 2KB
vms_tramp.asm 2KB
vms-dwarf2eh.asm 2KB
uwin.asm 733B
crti.asm 499B
crtn.asm 466B
irix-crtn.asm 385B
optc-gen.awk 5KB
opth-gen.awk 5KB
opt-functions.awk 5KB
mkmap-symver.awk 3KB
mkmap-flat.awk 2KB
opt-gather.awk 2KB
BASE-VER 6B
testSystemTools.bin 766B
bitset 232B
bitset 155B
config.build 4KB
rs6000.c 606KB
i386.c 575KB
parser.c 574KB
arm.c 440KB
dwarf2out.c 426KB
fold-const.c 424KB
combine.c 409KB
pt.c 396KB
decl.c 359KB
共 2537 条
- 1
- 2
- 3
- 4
- 5
- 6
- 26
资源评论
ty101059
- 粉丝: 5
- 资源: 12
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功