GDB (xrefs)
Loading...
Searching...
No Matches
gdb
frv-tdep.h
Go to the documentation of this file.
1
/* Architecture-dependent code for the Fujitsu FR-V, for GDB, the GNU Debugger.
2
Copyright (C) 2004-2023 Free Software Foundation, Inc.
3
4
This file is part of GDB.
5
6
This program is free software; you can redistribute it and/or modify
7
it under the terms of the GNU General Public License as published by
8
the Free Software Foundation; either version 3 of the License, or
9
(at your option) any later version.
10
11
This program is distributed in the hope that it will be useful,
12
but WITHOUT ANY WARRANTY; without even the implied warranty of
13
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
GNU General Public License for more details.
15
16
You should have received a copy of the GNU General Public License
17
along with this program. If not, see <http://www.gnu.org/licenses/>. */
18
19
#ifndef FRV_TDEP_H
20
#define FRV_TDEP_H
21
22
/* Enumerate the possible ABIs for FR-V. */
23
enum
frv_abi
24
{
25
FRV_ABI_EABI
,
26
FRV_ABI_FDPIC
27
};
28
29
/* Register numbers. The order in which these appear define the
30
remote protocol, so take care in changing them. */
31
enum
{
32
/* Register numbers 0 -- 63 are always reserved for general-purpose
33
registers. The chip at hand may have less. */
34
first_gpr_regnum
= 0,
35
sp_regnum
= 1,
36
fp_regnum
= 2,
37
struct_return_regnum
= 3,
38
last_gpr_regnum
= 63,
39
40
/* Register numbers 64 -- 127 are always reserved for floating-point
41
registers. The chip at hand may have less. */
42
first_fpr_regnum
= 64,
43
last_fpr_regnum
= 127,
44
45
/* The PC register. */
46
pc_regnum
= 128,
47
48
/* Register numbers 129 on up are always reserved for special-purpose
49
registers. */
50
first_spr_regnum
= 129,
51
psr_regnum
= 129,
52
ccr_regnum
= 130,
53
cccr_regnum
= 131,
54
fdpic_loadmap_exec_regnum
= 132,
55
fdpic_loadmap_interp_regnum
= 133,
56
tbr_regnum
= 135,
57
brr_regnum
= 136,
58
dbar0_regnum
= 137,
59
dbar1_regnum
= 138,
60
dbar2_regnum
= 139,
61
dbar3_regnum
= 140,
62
scr0_regnum
= 141,
63
scr1_regnum
= 142,
64
scr2_regnum
= 143,
65
scr3_regnum
= 144,
66
lr_regnum
= 145,
67
lcr_regnum
= 146,
68
iacc0h_regnum
= 147,
69
iacc0l_regnum
= 148,
70
fsr0_regnum
= 149,
71
acc0_regnum
= 150,
72
acc7_regnum
= 157,
73
accg0123_regnum
= 158,
74
accg4567_regnum
= 159,
75
msr0_regnum
= 160,
76
msr1_regnum
= 161,
77
gner0_regnum
= 162,
78
gner1_regnum
= 163,
79
fner0_regnum
= 164,
80
fner1_regnum
= 165,
81
last_spr_regnum
= 165,
82
83
/* The total number of registers we know exist. */
84
frv_num_regs
=
last_spr_regnum
+ 1,
85
86
/* Pseudo registers */
87
first_pseudo_regnum
=
frv_num_regs
,
88
89
/* iacc0 - the 64-bit concatenation of iacc0h and iacc0l. */
90
iacc0_regnum
=
first_pseudo_regnum
+ 0,
91
accg0_regnum
=
first_pseudo_regnum
+ 1,
92
accg7_regnum
=
accg0_regnum
+ 7,
93
94
last_pseudo_regnum
=
accg7_regnum
,
95
frv_num_pseudo_regs
=
last_pseudo_regnum
-
first_pseudo_regnum
+ 1,
96
};
97
98
/* Return the FR-V ABI associated with GDBARCH. */
99
enum
frv_abi
frv_abi
(
struct
gdbarch
*
gdbarch
);
100
101
/* Fetch the interpreter and executable loadmap addresses (for shared
102
library support) for the FDPIC ABI. Return 0 if successful, -1 if
103
not. (E.g, -1 will be returned if the ABI isn't the FDPIC ABI.) */
104
int
frv_fdpic_loadmap_addresses
(
struct
gdbarch
*
gdbarch
,
105
CORE_ADDR *interp_addr, CORE_ADDR *exec_addr);
106
107
/* Given a function entry point, find and return the GOT address for the
108
containing load module. */
109
CORE_ADDR
frv_fdpic_find_global_pointer
(CORE_ADDR addr);
110
111
/* Given a function entry point, find and return the canonical descriptor
112
for that function, if one exists. If no canonical descriptor could
113
be found, return 0. */
114
CORE_ADDR
frv_fdpic_find_canonical_descriptor
(CORE_ADDR entry_point);
115
116
117
/* Given an objfile, return the address of its link map. This value is
118
needed for TLS support. */
119
CORE_ADDR
frv_fetch_objfile_link_map
(
struct
objfile
*
objfile
);
120
121
struct
target_so_ops
;
122
extern
const
struct
target_so_ops
frv_so_ops
;
123
124
#endif
/* FRV_TDEP_H */
frv_fetch_objfile_link_map
CORE_ADDR frv_fetch_objfile_link_map(struct objfile *objfile)
Definition
solib-frv.c:1066
frv_fdpic_loadmap_addresses
int frv_fdpic_loadmap_addresses(struct gdbarch *gdbarch, CORE_ADDR *interp_addr, CORE_ADDR *exec_addr)
Definition
frv-tdep.c:110
frv_fdpic_find_global_pointer
CORE_ADDR frv_fdpic_find_global_pointer(CORE_ADDR addr)
Definition
solib-frv.c:867
frv_fdpic_find_canonical_descriptor
CORE_ADDR frv_fdpic_find_canonical_descriptor(CORE_ADDR entry_point)
Definition
solib-frv.c:897
scr0_regnum
@ scr0_regnum
Definition
frv-tdep.h:62
last_spr_regnum
@ last_spr_regnum
Definition
frv-tdep.h:81
frv_num_regs
@ frv_num_regs
Definition
frv-tdep.h:84
accg0_regnum
@ accg0_regnum
Definition
frv-tdep.h:91
fp_regnum
@ fp_regnum
Definition
frv-tdep.h:36
msr1_regnum
@ msr1_regnum
Definition
frv-tdep.h:76
accg4567_regnum
@ accg4567_regnum
Definition
frv-tdep.h:74
first_fpr_regnum
@ first_fpr_regnum
Definition
frv-tdep.h:42
acc0_regnum
@ acc0_regnum
Definition
frv-tdep.h:71
dbar2_regnum
@ dbar2_regnum
Definition
frv-tdep.h:60
acc7_regnum
@ acc7_regnum
Definition
frv-tdep.h:72
fner0_regnum
@ fner0_regnum
Definition
frv-tdep.h:79
fsr0_regnum
@ fsr0_regnum
Definition
frv-tdep.h:70
iacc0l_regnum
@ iacc0l_regnum
Definition
frv-tdep.h:69
iacc0_regnum
@ iacc0_regnum
Definition
frv-tdep.h:90
lr_regnum
@ lr_regnum
Definition
frv-tdep.h:66
fdpic_loadmap_interp_regnum
@ fdpic_loadmap_interp_regnum
Definition
frv-tdep.h:55
cccr_regnum
@ cccr_regnum
Definition
frv-tdep.h:53
gner1_regnum
@ gner1_regnum
Definition
frv-tdep.h:78
last_gpr_regnum
@ last_gpr_regnum
Definition
frv-tdep.h:38
psr_regnum
@ psr_regnum
Definition
frv-tdep.h:51
scr1_regnum
@ scr1_regnum
Definition
frv-tdep.h:63
fner1_regnum
@ fner1_regnum
Definition
frv-tdep.h:80
scr2_regnum
@ scr2_regnum
Definition
frv-tdep.h:64
dbar0_regnum
@ dbar0_regnum
Definition
frv-tdep.h:58
lcr_regnum
@ lcr_regnum
Definition
frv-tdep.h:67
ccr_regnum
@ ccr_regnum
Definition
frv-tdep.h:52
accg7_regnum
@ accg7_regnum
Definition
frv-tdep.h:92
msr0_regnum
@ msr0_regnum
Definition
frv-tdep.h:75
tbr_regnum
@ tbr_regnum
Definition
frv-tdep.h:56
first_gpr_regnum
@ first_gpr_regnum
Definition
frv-tdep.h:34
dbar1_regnum
@ dbar1_regnum
Definition
frv-tdep.h:59
sp_regnum
@ sp_regnum
Definition
frv-tdep.h:35
scr3_regnum
@ scr3_regnum
Definition
frv-tdep.h:65
accg0123_regnum
@ accg0123_regnum
Definition
frv-tdep.h:73
pc_regnum
@ pc_regnum
Definition
frv-tdep.h:46
first_spr_regnum
@ first_spr_regnum
Definition
frv-tdep.h:50
dbar3_regnum
@ dbar3_regnum
Definition
frv-tdep.h:61
first_pseudo_regnum
@ first_pseudo_regnum
Definition
frv-tdep.h:87
last_pseudo_regnum
@ last_pseudo_regnum
Definition
frv-tdep.h:94
last_fpr_regnum
@ last_fpr_regnum
Definition
frv-tdep.h:43
fdpic_loadmap_exec_regnum
@ fdpic_loadmap_exec_regnum
Definition
frv-tdep.h:54
struct_return_regnum
@ struct_return_regnum
Definition
frv-tdep.h:37
gner0_regnum
@ gner0_regnum
Definition
frv-tdep.h:77
frv_num_pseudo_regs
@ frv_num_pseudo_regs
Definition
frv-tdep.h:95
brr_regnum
@ brr_regnum
Definition
frv-tdep.h:57
iacc0h_regnum
@ iacc0h_regnum
Definition
frv-tdep.h:68
frv_so_ops
const struct target_so_ops frv_so_ops
Definition
solib-frv.c:1090
frv_abi
frv_abi
Definition
frv-tdep.h:24
FRV_ABI_FDPIC
@ FRV_ABI_FDPIC
Definition
frv-tdep.h:26
FRV_ABI_EABI
@ FRV_ABI_EABI
Definition
frv-tdep.h:25
gdbarch
Definition
gdbarch.py:1
objfile
Definition
objfiles.h:422
target_so_ops
Definition
solist.h:84
Generated by
1.10.0