GDB (xrefs)

Macros | Functions | Variables
/tmp/gdb-8.1/gdb/ax-general.c File Reference
`#include "defs.h"`
`#include "ax.h"`
`#include "value.h"`
`#include "user-regs.h"`
`#include "ax.def"`

Go to the source code of this file.

## Macros
#define | DEFOP(NAME, SIZE, DATA_SIZE, CONSUMED, PRODUCED, VALUE) , { # NAME, SIZE, DATA_SIZE, CONSUMED, PRODUCED }

## Functions
static void | grow_expr (struct agent_expr *x, int n)
static void | append_const (struct agent_expr *x, LONGEST val, int n)
static LONGEST | read_const (struct agent_expr *x, int o, int n)
static void | generic_ext (struct agent_expr *x, enum agent_op op, int n)
void | ax_raw_byte (struct agent_expr *x, gdb_byte byte)
void | ax_simple (struct agent_expr *x, enum agent_op op)
void | ax_pick (struct agent_expr *x, int depth)
void | ax_ext (struct agent_expr *x, int n)
void | ax_zero_ext (struct agent_expr *x, int n)
void | ax_trace_quick (struct agent_expr *x, int n)
int | ax_goto (struct agent_expr *x, enum agent_op op)
void | ax_label (struct agent_expr *x, int patch, int target)
void | ax_const_l (struct agent_expr *x, LONGEST l)
void | ax_const_d (struct agent_expr *x, LONGEST d)
void | ax_reg (struct agent_expr *x, int reg)
void | ax_tsv (struct agent_expr *x, enum agent_op op, int num)
void | ax_string (struct agent_expr *x, const char *str, int slen)
void | ax_print (struct ui_file *f, struct agent_expr *x)
void | ax_reg_mask (struct agent_expr *ax, int reg)
void | ax_reqs (struct agent_expr *ax)

## Variables
struct aop_map | aop_map []

## Macro Definition Documentation

## ◆ DEFOP

#define DEFOP | ( |  | NAME,
|  |  | SIZE,
|  |  | DATA_SIZE,
|  |  | CONSUMED,
|  |  | PRODUCED,
|  |  | VALUE
| ) |  | , { # NAME, SIZE, DATA_SIZE, CONSUMED, PRODUCED }

## Function Documentation

## ◆ append_const()

static void append_const | ( | struct agent_expr * | x,
|  | LONGEST | val,
|  | int | n
| ) |  |
| static

Definition at line 82 of file ax-general.c.

References agent_expr::buf, grow_expr(), and agent_expr::len.

Referenced by ax_const_l(), and ax_pick().

## ◆ ax_const_d()

void ax_const_d | ( | struct agent_expr * | x,
|  | LONGEST | d
| ) |  |

Definition at line 263 of file ax-general.c.

References _, and error().

## ◆ ax_const_l()

void ax_const_l | ( | struct agent_expr * | x,
|  | LONGEST | l
| ) |  |

Definition at line 229 of file ax-general.c.

References append_const(), ax_ext(), ax_simple(), and size.

Referenced by access_memory(), amd64_gen_return_address(), compile_probe_arg(), dwarf2_compile_expr_to_ax(), gen_expr(), gen_int_literal(), gen_left_shift(), gen_msym_var_ref(), gen_offset(), gen_printf(), gen_scale(), gen_sizeof(), gen_static_field(), gen_trace_static_fields(), gen_traced_pop(), gen_var_ref(), i386_gen_return_address(), mips_ax_pseudo_register_push_stack(), and s390_ax_pseudo_register_push_stack().

## ◆ ax_ext()

void ax_ext | ( | struct agent_expr * | x,
|  | int | n
| ) |  |

Definition at line 164 of file ax-general.c.

References generic_ext().

Referenced by ax_const_l(), dwarf2_compile_expr_to_ax(), gen_bitfield_ref(), gen_extend(), and gen_sign_extend().

## ◆ ax_goto()

int ax_goto | ( | struct agent_expr * | x,
|  | enum agent_op | op
| ) |  |

Definition at line 200 of file ax-general.c.

References agent_expr::buf, grow_expr(), and agent_expr::len.

Referenced by dwarf2_compile_expr_to_ax(), and gen_expr().

## ◆ ax_label()

void ax_label | ( | struct agent_expr * | x,
|  | int | patch,
|  | int | target
| ) |  |

Definition at line 215 of file ax-general.c.

References _, agent_expr::buf, and error().

Referenced by dwarf2_compile_expr_to_ax(), and gen_expr().

## ◆ ax_pick()

void ax_pick | ( | struct agent_expr * | x,
|  | int | depth
| ) |  |

Definition at line 134 of file ax-general.c.

References _, append_const(), ax_simple(), and error().

Referenced by dwarf2_compile_expr_to_ax().

## ◆ ax_print()

void ax_print | ( | struct ui_file * | f,
|  | struct agent_expr * | x
| ) |  |

Definition at line 363 of file ax-general.c.

References _, aop_last, agent_expr::buf, error(), fprintf_filtered(), fputs_filtered(), agent_expr::gdbarch, if(), agent_expr::len, name, aop_map::name, aop_map::op_size, paddress(), print_longest(), read_const(), agent_expr::reg_mask, agent_expr::reg_mask_len, and agent_expr::scope.

Referenced by agent_eval_command_one(), and maint_agent_printf_command().

## ◆ ax_raw_byte()

void ax_raw_byte | ( | struct agent_expr * | x,
|  | gdb_byte | byte
| ) |  |

Definition at line 117 of file ax-general.c.

References agent_expr::buf, grow_expr(), and agent_expr::len.

Referenced by ax_simple(), and gen_printf().

## ◆ ax_reg()

void ax_reg | ( | struct agent_expr * | x,
|  | int | reg
| ) |  |

Definition at line 274 of file ax-general.c.

References _, agent_expr::buf, error(), agent_expr::gdbarch, gdbarch_ax_pseudo_register_push_stack(), gdbarch_ax_pseudo_register_push_stack_p(), gdbarch_num_regs(), gdbarch_remote_register_number(), grow_expr(), agent_expr::len, and user_reg_map_regnum_to_name().

Referenced by amd64_gen_return_address(), dwarf2_compile_expr_to_ax(), gen_frame_args_address(), gen_frame_locals_address(), gen_traced_pop(), gen_var_ref(), i386_gen_return_address(), mips_ax_pseudo_register_push_stack(), require_rvalue(), s390_ax_pseudo_register_push_stack(), and spu_ax_pseudo_register_push_stack().

## ◆ ax_reg_mask()

void ax_reg_mask | ( | struct agent_expr * | ax,
|  | int | reg
| ) |  |

Definition at line 425 of file ax-general.c.

References _, error(), agent_expr::gdbarch, gdbarch_ax_pseudo_register_collect(), gdbarch_ax_pseudo_register_collect_p(), gdbarch_num_regs(), gdbarch_remote_register_number(), memset(), agent_expr::reg_mask, agent_expr::reg_mask_len, user_reg_map_regnum_to_name(), and XRESIZEVEC.

Referenced by amd64_ax_pseudo_register_collect(), ax_reqs(), gen_trace_static_fields(), gen_traced_pop(), i386_ax_pseudo_register_collect(), mips_ax_pseudo_register_collect(), rs6000_ax_pseudo_register_collect(), s390_ax_pseudo_register_collect(), and spu_ax_pseudo_register_collect().

## ◆ ax_reqs()

void ax_reqs | ( | struct agent_expr * | ax | ) |

Definition at line 468 of file ax-general.c.

References agent_flaw_bad_instruction, agent_flaw_bad_jump, agent_flaw_height_mismatch, agent_flaw_hole, agent_flaw_incomplete_instruction, agent_flaw_none, ax_reg_mask(), agent_expr::buf, aop_map::consumed, aop_map::data_size, agent_expr::final_height, agent_expr::flaw, agent_expr::len, agent_expr::max_data_size, agent_expr::max_height, memset(), agent_expr::min_height, aop_map::name, aop_map::op_size, aop_map::produced, and read_const().

Referenced by agent_eval_command_one(), collection_list::collect_symbol(), encode_actions_1(), maint_agent_printf_command(), and validate_actionline().

## ◆ ax_simple()

void ax_simple | ( | struct agent_expr * | x,
|  | enum agent_op | op
| ) |  |

Definition at line 125 of file ax-general.c.

References ax_raw_byte().

Referenced by access_memory(), amd64_gen_return_address(), ax_const_l(), ax_pick(), dwarf2_compile_expr_to_ax(), gen_binop(), gen_bitfield_ref(), gen_complement(), gen_equal(), gen_eval_for_expr(), gen_expr_binop_rest(), gen_fetch(), gen_left_shift(), gen_less(), gen_logical_not(), gen_offset(), gen_printf(), gen_ptradd(), gen_ptrdiff(), gen_ptrsub(), gen_scale(), gen_trace_for_expr(), gen_trace_for_return_address(), gen_trace_for_var(), gen_trace_static_fields(), gen_traced_pop(), gen_usual_arithmetic(), i386_gen_return_address(), mips_ax_pseudo_register_push_stack(), and s390_ax_pseudo_register_push_stack().

## ◆ ax_string()

void ax_string | ( | struct agent_expr * | x,
|  | const char * | str,
|  | int | slen
| ) |  |

Definition at line 328 of file ax-general.c.

References _, agent_expr::buf, grow_expr(), internal_error(), and agent_expr::len.

Referenced by gen_printf().

## ◆ ax_trace_quick()

void ax_trace_quick | ( | struct agent_expr * | x,
|  | int | n
| ) |  |

Definition at line 180 of file ax-general.c.

References _, agent_expr::buf, error(), grow_expr(), and agent_expr::len.

Referenced by access_memory(), gen_bitfield_ref(), and gen_fetch().

## ◆ ax_tsv()

void ax_tsv | ( | struct agent_expr * | x,
|  | enum agent_op | op,
|  | int | num
| ) |  |

Definition at line 307 of file ax-general.c.

References _, agent_expr::buf, grow_expr(), internal_error(), and agent_expr::len.

Referenced by gen_expr().

## ◆ ax_zero_ext()

void ax_zero_ext | ( | struct agent_expr * | x,
|  | int | n
| ) |  |

Definition at line 172 of file ax-general.c.

References generic_ext().

Referenced by access_memory(), dwarf2_compile_expr_to_ax(), gen_bitfield_ref(), gen_extend(), and s390_ax_pseudo_register_push_stack().

## ◆ generic_ext()

static void generic_ext | ( | struct agent_expr * | x,
|  | enum agent_op | op,
|  | int | n
| ) |  |
| static

Definition at line 146 of file ax-general.c.

References _, agent_expr::buf, error(), grow_expr(), and agent_expr::len.

Referenced by ax_ext(), and ax_zero_ext().

## ◆ grow_expr()

static void grow_expr | ( | struct agent_expr * | x,
|  | int | n
| ) |  |
| static

Definition at line 67 of file ax-general.c.

References agent_expr::buf, agent_expr::len, agent_expr::size, and xrealloc().

Referenced by append_const(), ax_goto(), ax_raw_byte(), ax_reg(), ax_string(), ax_trace_quick(), ax_tsv(), and generic_ext().

## ◆ read_const()

static LONGEST read_const | ( | struct agent_expr * | x,
|  | int | o,
|  | int | n
| ) |  |
| static

Definition at line 99 of file ax-general.c.

References _, agent_expr::buf, error(), and agent_expr::len.

Referenced by ax_print(), and ax_reqs().

## Variable Documentation

## ◆ aop_map

struct aop_map aop_map[]

Definition at line 351 of file ax-general.c.