GDB (xrefs)

Macros | Functions | Variables
/tmp/gdb-8.1/gdb/sh-linux-tdep.c File Reference
`#include "defs.h"`
`#include "osabi.h"`
`#include "solib-svr4.h"`
`#include "symtab.h"`
`#include "trad-frame.h"`
`#include "tramp-frame.h"`
`#include "glibc-tdep.h"`
`#include "sh-tdep.h"`
`#include "linux-tdep.h"`

Go to the source code of this file.

## Macros
#define | REGSx16(base)
#define | SH_MOVW 0x9305
#define | SH_TRAP 0xc300
#define | SH_OR_R0_R0 0x200b
#define | SH_NR_SIGRETURN 0x0077
#define | SH_NR_RT_SIGRETURN 0x00ad

## Functions
static void | sh_linux_sigtramp_cache (struct frame_info *this_frame, struct trad_frame_cache *this_cache, CORE_ADDR func, int regs_offset)
static void | sh_linux_sigreturn_init (const struct tramp_frame *self, struct frame_info *this_frame, struct trad_frame_cache *this_cache, CORE_ADDR func)
static void | sh_linux_rt_sigreturn_init (const struct tramp_frame *self, struct frame_info *this_frame, struct trad_frame_cache *this_cache, CORE_ADDR func)
static void | sh_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
void | _initialize_sh_linux_tdep (void)

## Variables
static const struct sh_corefile_regmap | gregs_table []
static const struct sh_corefile_regmap | fpregs_table []
static struct tramp_frame | sh_linux_sigreturn_tramp_frame
static struct tramp_frame | sh_linux_rt_sigreturn_tramp_frame

## Macro Definition Documentation

## ◆ REGSx16

#define REGSx16 | ( |  | base | ) |

Value:
{(base), 0}, \
{(base) + 1, 4}, \
{(base) + 2, 8}, \
{(base) + 3, 12}, \
{(base) + 4, 16}, \
{(base) + 5, 20}, \
{(base) + 6, 24}, \
{(base) + 7, 28}, \
{(base) + 8, 32}, \
{(base) + 9, 36}, \
{(base) + 10, 40}, \
{(base) + 11, 44}, \
{(base) + 12, 48}, \
{(base) + 13, 52}, \
{(base) + 14, 56}, \
{(base) + 15, 60}

Definition at line 33 of file sh-linux-tdep.c.

## ◆ SH_MOVW

#define SH_MOVW 0x9305

Definition at line 141 of file sh-linux-tdep.c.

## ◆ SH_NR_RT_SIGRETURN

#define SH_NR_RT_SIGRETURN 0x00ad

Definition at line 147 of file sh-linux-tdep.c.

## ◆ SH_NR_SIGRETURN

#define SH_NR_SIGRETURN 0x0077

Definition at line 146 of file sh-linux-tdep.c.

## ◆ SH_OR_R0_R0

#define SH_OR_R0_R0 0x200b

Definition at line 143 of file sh-linux-tdep.c.

## ◆ SH_TRAP

#define SH_TRAP 0xc300

Definition at line 142 of file sh-linux-tdep.c.

## Function Documentation

## ◆ _initialize_sh_linux_tdep()

void _initialize_sh_linux_tdep | ( | void |  | ) |

Definition at line 216 of file sh-linux-tdep.c.

References GDB_OSABI_LINUX, gdbarch_register_osabi(), and sh_linux_init_abi().

## ◆ sh_linux_init_abi()

static void sh_linux_init_abi | ( | struct gdbarch_info | info,
|  | struct gdbarch * | gdbarch
| ) |  |
| static

Definition at line 184 of file sh-linux-tdep.c.

References gdbarch_info::bfd_arch_info, gdbarch_tdep::core_fpregmap, gdbarch_tdep::core_gregmap, find_solib_trampoline_target(), fpregs_table, gdbarch_tdep(), glibc_skip_solib_resolver(), gregs_table, linux_init_abi(), set_gdbarch_fetch_tls_load_module_address(), set_gdbarch_skip_solib_resolver(), set_gdbarch_skip_trampoline_code(), set_solib_svr4_fetch_link_map_offsets(), sh_linux_rt_sigreturn_tramp_frame, sh_linux_sigreturn_tramp_frame, gdbarch_tdep::sizeof_fpregset, gdbarch_tdep::sizeof_gregset, svr4_fetch_objfile_link_map(), svr4_ilp32_fetch_link_map_offsets(), and tramp_frame_prepend_unwinder().

Referenced by _initialize_sh_linux_tdep().

## ◆ sh_linux_rt_sigreturn_init()

static void sh_linux_rt_sigreturn_init | ( | const struct tramp_frame * | self,
|  | struct frame_info * | this_frame,
|  | struct trad_frame_cache * | this_cache,
|  | CORE_ADDR | func
| ) |  |
| static

Definition at line 126 of file sh-linux-tdep.c.

References func, and sh_linux_sigtramp_cache().

## ◆ sh_linux_sigreturn_init()

static void sh_linux_sigreturn_init | ( | const struct tramp_frame * | self,
|  | struct frame_info * | this_frame,
|  | struct trad_frame_cache * | this_cache,
|  | CORE_ADDR | func
| ) |  |
| static

Definition at line 115 of file sh-linux-tdep.c.

References func, and sh_linux_sigtramp_cache().

## ◆ sh_linux_sigtramp_cache()

static void sh_linux_sigtramp_cache | ( | struct frame_info * | this_frame,
|  | struct trad_frame_cache * | this_cache,
|  | CORE_ADDR | func,
|  | int | regs_offset
| ) |  |
| static

Definition at line 79 of file sh-linux-tdep.c.

References FP_LAST_REGNUM, FPSCR_REGNUM, FPUL_REGNUM, FR0_REGNUM, frame_id_build(), func, GBR_REGNUM, gdbarch_fp0_regnum(), gdbarch_sp_regnum(), get_frame_arch(), get_frame_register_unsigned(), MACH_REGNUM, MACL_REGNUM, SR_REGNUM, trad_frame_set_id(), and trad_frame_set_reg_addr().

Referenced by sh_linux_rt_sigreturn_init(), and sh_linux_sigreturn_init().

## Variable Documentation

## ◆ fpregs_table

const struct sh_corefile_regmap fpregs_table[]
| static

Initial value:
=
{
REGSx16 (FR0_REGNUM),
{FPSCR_REGNUM, 128},
{FPUL_REGNUM, 132},
{-1 , 0}
}
REGSx16
#define REGSx16(base)
Definition: sh-linux-tdep.c:33
FR0_REGNUM
Definition: sh-tdep.h:42
FPSCR_REGNUM
Definition: sh-tdep.h:41
FPUL_REGNUM
Definition: sh-tdep.h:39

Definition at line 67 of file sh-linux-tdep.c.

Referenced by sh_linux_init_abi().

## ◆ gregs_table

const struct sh_corefile_regmap gregs_table[]
| static

Initial value:
=
{
REGSx16 (R0_REGNUM),
{PC_REGNUM, 64},
{PR_REGNUM, 68},
{SR_REGNUM, 72},
{GBR_REGNUM, 76},
{MACH_REGNUM, 80},
{MACL_REGNUM, 84},
{-1 , 0}
}
REGSx16
#define REGSx16(base)
Definition: sh-linux-tdep.c:33
GBR_REGNUM
Definition: sh-tdep.h:34
SR_REGNUM
Definition: sh-tdep.h:38
PR_REGNUM
Definition: sh-tdep.h:33
PC_REGNUM
Definition: sh-tdep.h:32
MACH_REGNUM
Definition: sh-tdep.h:36
R0_REGNUM
Definition: m32r-tdep.h:32
MACL_REGNUM
Definition: sh-tdep.h:37

Definition at line 53 of file sh-linux-tdep.c.

Referenced by sh_linux_init_abi().

## ◆ sh_linux_rt_sigreturn_tramp_frame

struct tramp_frame sh_linux_rt_sigreturn_tramp_frame
| static

Initial value:
= {
SIGTRAMP_FRAME,
2,
{
{ SH_MOVW, 0xffff },
{ SH_TRAP, 0xff00 },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_NR_RT_SIGRETURN, 0xffff },
{ TRAMP_SENTINEL_INSN }
},
sh_linux_rt_sigreturn_init
}
TRAMP_SENTINEL_INSN
#define TRAMP_SENTINEL_INSN
Definition: tramp-frame.h:44
SH_MOVW
#define SH_MOVW
Definition: sh-linux-tdep.c:141
SIGTRAMP_FRAME
Definition: frame.h:255
SH_TRAP
#define SH_TRAP
Definition: sh-linux-tdep.c:142
sh_linux_rt_sigreturn_init
static void sh_linux_rt_sigreturn_init(const struct tramp_frame *self, struct frame_info *this_frame, struct trad_frame_cache *this_cache, CORE_ADDR func)
Definition: sh-linux-tdep.c:126
SH_NR_RT_SIGRETURN
#define SH_NR_RT_SIGRETURN
Definition: sh-linux-tdep.c:147
SH_OR_R0_R0
#define SH_OR_R0_R0
Definition: sh-linux-tdep.c:143

Definition at line 166 of file sh-linux-tdep.c.

Referenced by sh_linux_init_abi().

## ◆ sh_linux_sigreturn_tramp_frame

struct tramp_frame sh_linux_sigreturn_tramp_frame
| static

Initial value:
= {
SIGTRAMP_FRAME,
2,
{
{ SH_MOVW, 0xffff },
{ SH_TRAP, 0xff00 },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_OR_R0_R0, 0xffff },
{ SH_NR_SIGRETURN, 0xffff },
{ TRAMP_SENTINEL_INSN }
},
sh_linux_sigreturn_init
}
SH_NR_SIGRETURN
#define SH_NR_SIGRETURN
Definition: sh-linux-tdep.c:146
TRAMP_SENTINEL_INSN
#define TRAMP_SENTINEL_INSN
Definition: tramp-frame.h:44
SH_MOVW
#define SH_MOVW
Definition: sh-linux-tdep.c:141
SIGTRAMP_FRAME
Definition: frame.h:255
SH_TRAP
#define SH_TRAP
Definition: sh-linux-tdep.c:142
sh_linux_sigreturn_init
static void sh_linux_sigreturn_init(const struct tramp_frame *self, struct frame_info *this_frame, struct trad_frame_cache *this_cache, CORE_ADDR func)
Definition: sh-linux-tdep.c:115
SH_OR_R0_R0
#define SH_OR_R0_R0
Definition: sh-linux-tdep.c:143

Definition at line 149 of file sh-linux-tdep.c.

Referenced by sh_linux_init_abi().