OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gdb-7.1/] [gdb/] [sparc64-tdep.h] - Blame information for rev 231

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 227 jeremybenn
/* Target-dependent code for UltraSPARC.
2
 
3
   Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010
4
   Free Software Foundation, Inc.
5
 
6
   This file is part of GDB.
7
 
8
   This program is free software; you can redistribute it and/or modify
9
   it under the terms of the GNU General Public License as published by
10
   the Free Software Foundation; either version 3 of the License, or
11
   (at your option) any later version.
12
 
13
   This program is distributed in the hope that it will be useful,
14
   but WITHOUT ANY WARRANTY; without even the implied warranty of
15
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
   GNU General Public License for more details.
17
 
18
   You should have received a copy of the GNU General Public License
19
   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
20
 
21
#ifndef SPARC64_TDEP_H
22
#define SPARC64_TDEP_H 1
23
 
24
struct frame_info;
25
struct gdbarch;
26
struct regcache;
27
struct sparc_gregset;
28
struct trad_frame_saved_reg;
29
 
30
#include "sparc-tdep.h"
31
 
32
/* The stack pointer is offset from the stack frame by a BIAS of 2047
33
   (0x7ff) for 64-bit code.  BIAS is likely to be defined on SPARC
34
   hosts, so undefine it first.  */
35
#undef BIAS
36
#define BIAS 2047
37
 
38
/* Register offsets for the general-purpose register set.  */
39
 
40
/* UltraSPARC doesn't have %psr.  */
41
#define r_tstate_offset r_psr_offset
42
 
43
/* UltraSPARC doesn't have %wim either.  */
44
#define r_fprs_offset r_wim_offset
45
 
46
/* Register numbers of various important registers.  */
47
 
48
enum sparc64_regnum
49
{
50
  SPARC64_F32_REGNUM            /* %f32 */
51
  = SPARC_F0_REGNUM + 32,
52
  SPARC64_F62_REGNUM            /* %f62 */
53
  = SPARC64_F32_REGNUM + 15,
54
  SPARC64_PC_REGNUM,            /* %pc */
55
  SPARC64_NPC_REGNUM,           /* %npc */
56
  SPARC64_STATE_REGNUM,
57
  SPARC64_FSR_REGNUM,           /* %fsr */
58
  SPARC64_FPRS_REGNUM,          /* %fprs */
59
  SPARC64_Y_REGNUM,             /* %y */
60
 
61
  /* Pseudo registers.  */
62
  SPARC64_CWP_REGNUM,           /* %cwp */
63
  SPARC64_PSTATE_REGNUM,        /* %pstate */
64
  SPARC64_ASI_REGNUM,           /* %asi */
65
  SPARC64_CCR_REGNUM,           /* %ccr */
66
  SPARC64_D0_REGNUM,            /* %d0 */
67
  SPARC64_D10_REGNUM            /* %d10 */
68
  = SPARC64_D0_REGNUM + 5,
69
  SPARC64_D30_REGNUM            /* %d30 */
70
  = SPARC64_D0_REGNUM + 15,
71
  SPARC64_D32_REGNUM            /* %d32 */
72
  = SPARC64_D0_REGNUM + 16,
73
  SPARC64_D62_REGNUM            /* %d62 */
74
  = SPARC64_D0_REGNUM + 31,
75
  SPARC64_Q0_REGNUM,            /* %q0 */
76
  SPARC64_Q8_REGNUM             /* %q8 */
77
  = SPARC64_Q0_REGNUM + 2,
78
  SPARC64_Q28_REGNUM            /* %q28 */
79
  = SPARC64_Q0_REGNUM + 7,
80
  SPARC64_Q32_REGNUM            /* %q32 */
81
  = SPARC64_Q0_REGNUM + 8,
82
  SPARC64_Q60_REGNUM            /* %q60 */
83
  = SPARC64_Q0_REGNUM + 15
84
};
85
 
86
/* Processor state bits.  */
87
#define SPARC64_PSTATE_AG       0x001
88
#define SPARC64_PSTATE_IE       0x002
89
#define SPARC64_PSTATE_PRIV     0x004
90
#define SPARC64_PSTATE_AM       0x008
91
#define SPARC64_PSTATE_PEF      0x010
92
#define SPARC64_PSTATE_RED      0x020
93
#define SPARC64_PSTATE_TLE      0x100
94
#define SPARC64_PSTATE_CLE      0x200
95
#define SPARC64_PSTATE_PID0     0x400
96
#define SPARC64_PSTATE_PID1     0x800
97
 
98
extern void sparc64_init_abi (struct gdbarch_info info,
99
                              struct gdbarch *gdbarch);
100
 
101
extern void sparc64_supply_gregset (const struct sparc_gregset *gregset,
102
                                    struct regcache *regcache,
103
                                    int regnum, const void *gregs);
104
extern void sparc64_collect_gregset (const struct sparc_gregset *gregset,
105
                                     const struct regcache *regcache,
106
                                     int regnum, void *gregs);
107
extern void sparc64_supply_fpregset (struct regcache *regcache,
108
                                     int regnum, const void *fpregs);
109
extern void sparc64_collect_fpregset (const struct regcache *regcache,
110
                                      int regnum, void *fpregs);
111
 
112
/* Functions and variables exported from sparc64-sol2-tdep.c.  */
113
 
114
/* Register offsets for Solaris 2.  */
115
extern const struct sparc_gregset sparc64_sol2_gregset;
116
 
117
extern void sparc64_sol2_init_abi (struct gdbarch_info info,
118
                                   struct gdbarch *gdbarch);
119
 
120
/* Variables exported from sparc64fbsd-tdep.c.  */
121
 
122
/* Register offsets for FreeBSD/sparc64.  */
123
extern const struct sparc_gregset sparc64fbsd_gregset;
124
 
125
/* Functions and variables exported from sparc64nbsd-tdep.c.  */
126
 
127
/* Register offsets for NetBSD/sparc64.  */
128
extern const struct sparc_gregset sparc64nbsd_gregset;
129
 
130
extern struct trad_frame_saved_reg *
131
  sparc64nbsd_sigcontext_saved_regs (CORE_ADDR sigcontext_addr,
132
                                     struct frame_info *next_frame);
133
 
134
#endif /* sparc64-tdep.h */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.