|
GDB (xrefs)
|
#include "defs.h"#include "symtab.h"#include "gdbtypes.h"#include "value.h"#include "gdbcore.h"#include "gdbcmd.h"#include "target.h"#include "language.h"#include "annotate.h"#include "valprint.h"#include "target-float.h"#include "extension.h"#include "ada-lang.h"#include "gdb_obstack.h"#include "charset.h"#include "typeprint.h"#include <ctype.h>#include <algorithm>#include "common/byte-vector.h"Go to the source code of this file.
Classes | |
| struct | converted_character |
Macros | |
| #define | MAX_WCHARS 4 |
| #define | WCHAR_BUFLEN(X) ((X) * sizeof (gdb_wchar_t)) |
| #define | WCHAR_BUFLEN_MAX WCHAR_BUFLEN (MAX_WCHARS) |
| #define | PRINT_MAX_DEFAULT 200 /* Start print_max off at this value. */ |
| #define | BITS_IN_OCTAL 3 |
| #define | HIGH_ZERO 0340 |
| #define | LOW_ZERO 0034 |
| #define | CARRY_ZERO 0003 |
| #define | HIGH_ONE 0200 |
| #define | MID_ONE 0160 |
| #define | LOW_ONE 0016 |
| #define | CARRY_ONE 0001 |
| #define | HIGH_TWO 0300 |
| #define | MID_TWO 0070 |
| #define | LOW_TWO 0007 |
| #define | TEN 10 |
| #define | CARRY_OUT( x) ((x) / TEN) /* extend char to int */ |
| #define | CARRY_LEFT(x) ((x) % TEN) |
| #define | SHIFT(x) ((x) << 4) |
| #define | LOW_NIBBLE( x) ( (x) & 0x00F) |
| #define | HIGH_NIBBLE(x) (((x) & 0x0F0) >> 4) |
Typedefs | |
| typedef struct converted_character | converted_character_d |
Functions | |
| DEF_VEC_O (converted_character_d) | |
| static int | partial_memory_read (CORE_ADDR memaddr, gdb_byte *myaddr, int len, int *errptr) |
| static void | set_input_radix_1 (int, unsigned) |
| static void | set_output_radix_1 (int, unsigned) |
| static void | val_print_type_code_flags (struct type *type, const gdb_byte *valaddr, struct ui_file *stream) |
| void | get_user_print_options (struct value_print_options *opts) |
| void | get_no_prettyformat_print_options (struct value_print_options *opts) |
| void | get_formatted_print_options (struct value_print_options *opts, char format) |
| static void | show_print_max (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_input_radix (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_output_radix (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_print_array_indexes (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_repeat_count_threshold (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_stop_print_at_null (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_prettyformat_structs (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_prettyformat_arrays (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_unionprint (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_addressprint (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static void | show_symbol_print (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| int | val_print_scalar_type_p (struct type *type) |
| int | valprint_check_validity (struct ui_file *stream, struct type *type, LONGEST embedded_offset, const struct value *val) |
| void | val_print_optimized_out (const struct value *val, struct ui_file *stream) |
| void | val_print_not_saved (struct ui_file *stream) |
| void | val_print_unavailable (struct ui_file *stream) |
| void | val_print_invalid_address (struct ui_file *stream) |
| static void | print_unpacked_pointer (struct type *type, struct type *elttype, CORE_ADDR address, struct ui_file *stream, const struct value_print_options *options) |
| static void | generic_val_print_array (struct type *type, int embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, struct value *original_value, const struct value_print_options *options, const struct generic_val_print_decorations *decorations) |
| static void | generic_val_print_ptr (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_memberptr (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | print_ref_address (struct type *type, const gdb_byte *address_buffer, int embedded_offset, struct ui_file *stream) |
| static const gdb_byte * | get_value_addr_contents (struct value *deref_val) |
| static void | generic_val_print_ref (struct type *type, int embedded_offset, struct ui_file *stream, int recurse, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_enum_1 (struct type *type, LONGEST val, struct ui_file *stream) |
| static void | generic_val_print_enum (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_flags (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_func (struct type *type, int embedded_offset, CORE_ADDR address, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_bool (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options, const struct generic_val_print_decorations *decorations) |
| static void | generic_val_print_int (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_char (struct type *type, struct type *unresolved_type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_float (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options) |
| static void | generic_val_print_complex (struct type *type, int embedded_offset, struct ui_file *stream, struct value *original_value, const struct value_print_options *options, const struct generic_val_print_decorations *decorations) |
| void | generic_val_print (struct type *type, int embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, struct value *original_value, const struct value_print_options *options, const struct generic_val_print_decorations *decorations) |
| void | val_print (struct type *type, LONGEST embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, struct value *val, const struct value_print_options *options, const struct language_defn *language) |
| static int | value_check_printable (struct value *val, struct ui_file *stream, const struct value_print_options *options) |
| void | common_val_print (struct value *val, struct ui_file *stream, int recurse, const struct value_print_options *options, const struct language_defn *language) |
| void | value_print (struct value *val, struct ui_file *stream, const struct value_print_options *options) |
| void | val_print_scalar_formatted (struct type *type, LONGEST embedded_offset, struct value *val, const struct value_print_options *options, int size, struct ui_file *stream) |
| void | print_longest (struct ui_file *stream, int format, int use_c_format, LONGEST val_long) |
| int | longest_to_int (LONGEST arg) |
| void | print_floating (const gdb_byte *valaddr, struct type *type, struct ui_file *stream) |
| void | print_binary_chars (struct ui_file *stream, const gdb_byte *valaddr, unsigned len, enum bfd_endian byte_order, bool zero_pad) |
| static void | emit_octal_digit (struct ui_file *stream, bool *seen_a_one, int digit) |
| void | print_octal_chars (struct ui_file *stream, const gdb_byte *valaddr, unsigned len, enum bfd_endian byte_order) |
| static bool | maybe_negate_by_bytes (const gdb_byte *bytes, unsigned len, enum bfd_endian byte_order, gdb::byte_vector *out_vec) |
| void | print_decimal_chars (struct ui_file *stream, const gdb_byte *valaddr, unsigned len, bool is_signed, enum bfd_endian byte_order) |
| void | print_hex_chars (struct ui_file *stream, const gdb_byte *valaddr, unsigned len, enum bfd_endian byte_order, bool zero_pad) |
| void | print_char_chars (struct ui_file *stream, struct type *type, const gdb_byte *valaddr, unsigned len, enum bfd_endian byte_order) |
| void | print_function_pointer_address (const struct value_print_options *options, struct gdbarch *gdbarch, CORE_ADDR address, struct ui_file *stream) |
| void | maybe_print_array_index (struct type *index_type, LONGEST index, struct ui_file *stream, const struct value_print_options *options) |
| void | val_print_array_elements (struct type *type, LONGEST embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, struct value *val, const struct value_print_options *options, unsigned int i) |
| int | read_string (CORE_ADDR addr, int len, int width, unsigned int fetchlimit, enum bfd_endian byte_order, gdb_byte **buffer, int *bytes_read) |
| static int | wchar_printable (gdb_wchar_t w) |
| static void | append_string_as_wide (const char *string, struct obstack *output) |
| static void | print_wchar (gdb_wint_t w, const gdb_byte *orig, int orig_len, int width, enum bfd_endian byte_order, struct obstack *output, int quoter, int *need_escapep) |
| void | generic_emit_char (int c, struct type *type, struct ui_file *stream, int quoter, const char *encoding) |
| static int | count_next_character (wchar_iterator *iter, VEC(converted_character_d) **vec) |
| static void | print_converted_chars_to_obstack (struct obstack *obstack, VEC(converted_character_d) *chars, int quote_char, int width, enum bfd_endian byte_order, const struct value_print_options *options) |
| void | generic_printstr (struct ui_file *stream, struct type *type, const gdb_byte *string, unsigned int length, const char *encoding, int force_ellipses, int quote_char, int c_style_terminator, const struct value_print_options *options) |
| int | val_print_string (struct type *elttype, const char *encoding, CORE_ADDR addr, int len, struct ui_file *stream, const struct value_print_options *options) |
| static void | set_input_radix (const char *args, int from_tty, struct cmd_list_element *c) |
| static void | set_output_radix (const char *args, int from_tty, struct cmd_list_element *c) |
| static void | set_radix (const char *arg, int from_tty) |
| static void | show_radix (const char *arg, int from_tty) |
| static void | set_print (const char *arg, int from_tty) |
| static void | show_print (const char *args, int from_tty) |
| static void | set_print_raw (const char *arg, int from_tty) |
| static void | show_print_raw (const char *args, int from_tty) |
| void | _initialize_valprint (void) |
Variables | |
| struct cmd_list_element * | setprintrawlist |
| struct cmd_list_element * | showprintrawlist |
| struct value_print_options | user_print_options |
| unsigned | input_radix = 10 |
| unsigned | output_radix = 10 |
| static unsigned | input_radix_1 = 10 |
| static unsigned | output_radix_1 = 10 |
| #define BITS_IN_OCTAL 3 |
Referenced by print_octal_chars().
| #define CARRY_LEFT | ( | x | ) | ((x) % TEN) |
Referenced by print_decimal_chars().
| #define CARRY_ONE 0001 |
Referenced by print_octal_chars().
| #define CARRY_OUT | ( | x | ) | ((x) / TEN) /* extend char to int */ |
Referenced by print_decimal_chars().
| #define CARRY_ZERO 0003 |
Referenced by print_octal_chars().
| #define HIGH_NIBBLE | ( | x | ) | (((x) & 0x0F0) >> 4) |
Referenced by print_decimal_chars().
| #define HIGH_ONE 0200 |
Referenced by print_octal_chars().
| #define HIGH_TWO 0300 |
Referenced by print_octal_chars().
| #define HIGH_ZERO 0340 |
Referenced by print_octal_chars().
| #define LOW_NIBBLE | ( | x | ) | ( (x) & 0x00F) |
Referenced by print_decimal_chars().
| #define LOW_ONE 0016 |
Referenced by print_octal_chars().
| #define LOW_TWO 0007 |
Referenced by print_octal_chars().
| #define LOW_ZERO 0034 |
Referenced by print_octal_chars().
| #define MAX_WCHARS 4 |
Definition at line 41 of file valprint.c.
Referenced by count_next_character().
| #define MID_ONE 0160 |
Referenced by print_octal_chars().
| #define MID_TWO 0070 |
Referenced by print_octal_chars().
| #define PRINT_MAX_DEFAULT 200 /* Start print_max off at this value. */ |
Definition at line 93 of file valprint.c.
| #define SHIFT | ( | x | ) | ((x) << 4) |
Referenced by print_decimal_chars().
| #define TEN 10 |
| #define WCHAR_BUFLEN | ( | X | ) | ((X) * sizeof (gdb_wchar_t)) |
Definition at line 45 of file valprint.c.
Referenced by count_next_character().
| #define WCHAR_BUFLEN_MAX WCHAR_BUFLEN (MAX_WCHARS) |
Definition at line 48 of file valprint.c.
| typedef struct converted_character converted_character_d |
Definition at line 73 of file valprint.c.
| void _initialize_valprint | ( | void | ) |
Definition at line 3048 of file valprint.c.
References _, add_alias_cmd(), add_cmd(), add_prefix_cmd(), add_setshow_boolean_cmd(), add_setshow_uinteger_cmd(), add_setshow_zuinteger_cmd(), value_print_options::addressprint, class_support, input_radix_1, no_class, output_radix_1, value_print_options::prettyformat_arrays, value_print_options::prettyformat_structs, value_print_options::print_array_indexes, value_print_options::print_max, value_print_options::repeat_count_threshold, set_input_radix(), set_output_radix(), set_print(), set_print_raw(), set_radix(), setlist, setprintlist, setprintrawlist, show_addressprint(), show_input_radix(), show_output_radix(), show_prettyformat_arrays(), show_prettyformat_structs(), show_print(), show_print_array_indexes(), show_print_max(), show_print_raw(), show_radix(), show_repeat_count_threshold(), show_stop_print_at_null(), show_symbol_print(), show_unionprint(), showlist, showprintlist, showprintrawlist, value_print_options::stop_print_at_null, value_print_options::symbol_print, value_print_options::unionprint, and user_print_options.
|
static |
Definition at line 2254 of file valprint.c.
References gdb_btowc, and string.
Referenced by print_wchar().
| void common_val_print | ( | struct value * | val, |
| struct ui_file * | stream, | ||
| int | recurse, | ||
| const struct value_print_options * | options, | ||
| const struct language_defn * | language | ||
| ) |
Definition at line 1136 of file valprint.c.
References ada_to_fixed_value(), language_ada, val_print(), value_address(), value_check_printable(), value_embedded_offset(), value_fetch_lazy(), value_lazy(), and value_type().
Referenced by ada_val_print_ref(), ada_varobj_get_value_image(), cp_print_value_fields(), gdbscm_value_print(), generic_val_print_ref(), list_arg_or_local(), mi_cmd_data_evaluate_expression(), pascal_object_print_static_field(), pascal_object_print_value_fields(), pascal_val_print(), pascal_value_print(), ppscm_print_children(), ppscm_print_string_repr(), print_children(), print_frame_arg(), print_string_repr(), print_unpacked_pointer(), print_variable_and_value(), print_variable_at_address(), print_variable_or_computed(), py_print_value(), valpy_str(), varobj_value_get_print_value(), and vlscm_print_value_smob().
|
static |
Definition at line 2440 of file valprint.c.
References converted_character::buf, converted_character::buflen, converted_character::chars, gdb_assert, wchar_iterator::iterate(), MAX_WCHARS, converted_character::num_chars, converted_character::repeat_count, converted_character::result, VEC_empty, VEC_last, VEC_safe_push, and WCHAR_BUFLEN.
Referenced by generic_printstr().
| DEF_VEC_O | ( | converted_character_d | ) |
|
static |
Definition at line 1436 of file valprint.c.
References fprintf_filtered().
Referenced by print_octal_chars().
| void generic_emit_char | ( | int | c, |
| struct type * | type, | ||
| struct ui_file * | stream, | ||
| int | quoter, | ||
| const char * | encoding | ||
| ) |
Definition at line 2364 of file valprint.c.
References convert_between_encodings(), fputs_filtered(), gdb_WEOF, gdbarch_byte_order(), get_type_arch(), host_charset(), INTERMEDIATE_ENCODING, wchar_iterator::iterate(), pack_long(), print_wchar(), translit_char, TYPE_LENGTH, and wchar_printable().
Referenced by c_emit_char(), f_emit_char(), and rust_emitchar().
| void generic_printstr | ( | struct ui_file * | stream, |
| struct type * | type, | ||
| const gdb_byte * | string, | ||
| unsigned int | length, | ||
| const char * | encoding, | ||
| int | force_ellipses, | ||
| int | quote_char, | ||
| int | c_style_terminator, | ||
| const struct value_print_options * | options | ||
| ) |
Definition at line 2683 of file valprint.c.
References convert_between_encodings(), count_next_character(), do_cleanups(), extract_unsigned_integer(), fputs_filtered(), gdbarch_byte_order(), get_type_arch(), host_charset(), INTERMEDIATE_ENCODING, LCST, make_cleanup(), obstack_grow_wstr, print_converted_chars_to_obstack(), QUIT, converted_character::result, translit_char, TYPE_LENGTH, VEC, VEC_cleanup, VEC_last, and wchar_iterate_eof.
Referenced by c_printstr(), f_printstr(), and rust_printstr().
| void generic_val_print | ( | struct type * | type, |
| int | embedded_offset, | ||
| CORE_ADDR | address, | ||
| struct ui_file * | stream, | ||
| int | recurse, | ||
| struct value * | original_value, | ||
| const struct value_print_options * | options, | ||
| const struct generic_val_print_decorations * | decorations | ||
| ) |
Definition at line 884 of file valprint.c.
References _, check_typedef(), error(), fprintf_filtered(), fputs_filtered(), gdb_flush(), generic_val_print_array(), generic_val_print_bool(), generic_val_print_char(), generic_val_print_complex(), generic_val_print_enum(), generic_val_print_flags(), generic_val_print_float(), generic_val_print_func(), generic_val_print_int(), generic_val_print_memberptr(), generic_val_print_ptr(), generic_val_print_ref(), type, TYPE_CODE, TYPE_CODE_ARRAY, TYPE_CODE_BOOL, TYPE_CODE_CHAR, TYPE_CODE_COMPLEX, TYPE_CODE_DECFLOAT, TYPE_CODE_ENUM, TYPE_CODE_ERROR, TYPE_CODE_FLAGS, TYPE_CODE_FLT, TYPE_CODE_FUNC, TYPE_CODE_INT, TYPE_CODE_MEMBERPTR, TYPE_CODE_METHOD, TYPE_CODE_METHODPTR, TYPE_CODE_PTR, TYPE_CODE_RANGE, TYPE_CODE_REF, TYPE_CODE_RVALUE_REF, TYPE_CODE_STRUCT, TYPE_CODE_UNDEF, TYPE_CODE_UNION, TYPE_CODE_VOID, TYPE_ERROR_NAME, and generic_val_print_decorations::void_name.
Referenced by c_val_print(), c_val_print_memberptr(), f_val_print(), m2_val_print(), pascal_val_print(), and rust_val_print().
|
static |
Definition at line 409 of file valprint.c.
References _, generic_val_print_decorations::array_end, generic_val_print_decorations::array_start, check_typedef(), error(), fputs_filtered(), get_array_bounds(), value_print_options::prettyformat_arrays, print_spaces_filtered(), print_unpacked_pointer(), TYPE_LENGTH, TYPE_TARGET_TYPE, and val_print_array_elements().
Referenced by generic_val_print().
|
static |
Definition at line 729 of file valprint.c.
References generic_val_print_decorations::false_name, value_print_options::format, fputs_filtered(), gdbarch_addressable_memory_unit_size(), get_type_arch(), value_print_options::output_format, print_longest(), generic_val_print_decorations::true_name, unpack_long(), val_print_scalar_formatted(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 780 of file valprint.c.
References value_print_options::format, fprintf_filtered(), fputs_filtered(), gdbarch_addressable_memory_unit_size(), get_type_arch(), LA_PRINT_CHAR, value_print_options::output_format, TYPE_UNSIGNED, unpack_long(), val_print_scalar_formatted(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 840 of file valprint.c.
References generic_val_print_decorations::complex_infix, generic_val_print_decorations::complex_prefix, generic_val_print_decorations::complex_suffix, value_print_options::format, fprintf_filtered(), gdbarch_addressable_memory_unit_size(), get_type_arch(), print_floating(), TYPE_LENGTH, type_length_units(), TYPE_TARGET_TYPE, val_print_scalar_formatted(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 653 of file valprint.c.
References value_print_options::format, gdbarch_addressable_memory_unit_size(), generic_val_print_enum_1(), get_type_arch(), unpack_long(), val_print_scalar_formatted(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 594 of file valprint.c.
References fputs_filtered(), print_longest(), QUIT, TYPE_FIELD_ENUMVAL, TYPE_FIELD_NAME, TYPE_FLAG_ENUM, and TYPE_NFIELDS.
Referenced by generic_val_print_enum(), and val_print_type_code_flags().
|
static |
Definition at line 680 of file valprint.c.
References value_print_options::format, val_print_scalar_formatted(), val_print_type_code_flags(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 816 of file valprint.c.
References value_print_options::format, gdbarch_addressable_memory_unit_size(), get_type_arch(), print_floating(), val_print_scalar_formatted(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 700 of file valprint.c.
References demangle, value_print_options::format, fprintf_filtered(), get_type_arch(), print_address_demangle(), type_print(), and val_print_scalar_formatted().
Referenced by generic_val_print().
|
static |
Definition at line 764 of file valprint.c.
References value_print_options::format, value_print_options::output_format, and val_print_scalar_formatted().
Referenced by generic_val_print().
|
static |
Definition at line 479 of file valprint.c.
References val_print_scalar_formatted().
Referenced by generic_val_print().
|
static |
Definition at line 450 of file valprint.c.
References check_typedef(), value_print_options::format, gdbarch_addressable_memory_unit_size(), get_type_arch(), print_unpacked_pointer(), TYPE_TARGET_TYPE, unpack_pointer(), val_print_scalar_formatted(), and value_contents_for_printing().
Referenced by generic_val_print().
|
static |
Definition at line 527 of file valprint.c.
References value::address, value_print_options::addressprint, check_typedef(), coerce_ref_if_computed(), common_val_print(), current_language, value_print_options::deref_ref, value::embedded_offset, fputs_filtered(), gdb_assert, get_value_addr_contents(), print_ref_address(), TARGET_CHAR_BIT, TYPE_CODE, TYPE_CODE_UNDEF, TYPE_LENGTH, TYPE_TARGET_TYPE, unpack_pointer(), value_at(), value_bits_synthetic_pointer(), and value_contents_for_printing().
Referenced by generic_val_print().
| void get_formatted_print_options | ( | struct value_print_options * | opts, |
| char | format | ||
| ) |
Definition at line 137 of file valprint.c.
References value_print_options::format, and user_print_options.
Referenced by default_print_one_register_info(), do_examine(), do_one_display(), dwarf2_compute_name(), mi_cmd_data_read_memory(), mips_print_fp_register(), mips_print_register(), output_command_const(), output_register(), print_value(), sh64_do_register(), and varobj_formatted_print_options().
| void get_no_prettyformat_print_options | ( | struct value_print_options * | opts | ) |
Definition at line 128 of file valprint.c.
References value_print_options::prettyformat, user_print_options, and Val_no_prettyformat.
Referenced by list_arg_or_local(), mt_registers_info(), print_frame_arg(), print_return_value_1(), print_subexp_standard(), print_variable_or_computed(), and rust_get_disr_info().
| void get_user_print_options | ( | struct value_print_options * | opts | ) |
Definition at line 120 of file valprint.c.
References user_print_options.
Referenced by breakpoint_1(), cplus_describe_child(), cplus_number_of_children(), decode_agent_options(), default_print_one_register_info(), enumerate_args(), enumerate_locals(), evaluate_subexp_standard(), fprint_auxv_entry(), gdbscm_value_print(), gnuv3_print_method_ptr(), gnuv3_print_vtable(), info_common_command_for_block(), info_skip_command(), mi_cmd_data_evaluate_expression(), print_frame(), print_frame_info(), print_one_breakpoint_location(), print_one_catch_exec(), print_one_catch_fork(), print_one_catch_solib(), print_one_catch_syscall(), print_one_catch_vfork(), print_one_exception(), print_one_exception_catchpoint(), print_one_ranged_breakpoint(), print_subexp_standard(), print_variable_and_value(), py_print_frame(), say_where(), show_convenience(), show_values(), signal_catchpoint_print_one(), unwind_infopy_str(), update_type_if_necessary(), valpy_str(), value_actual_type(), vlscm_print_value_smob(), watchpoint_value_print(), and whatis_exp().
Definition at line 511 of file valprint.c.
References gdb_assert, lval_memory, value_addr(), value_contents_for_printing_const(), and value_lval_const().
Referenced by generic_val_print_ref().
| int longest_to_int | ( | LONGEST | ) |
Convert a LONGEST to an int. This is used in contexts (e.g. number of arguments to a function, number in a value history, register number, etc.) where the value must not be larger than can fit in an int.
Definition at line 1341 of file valprint.c.
Referenced by ada_dump_subexp_body(), ada_evaluate_subexp(), ada_forward_operator_length(), ada_operator_length(), ada_type_of_array(), aggregate_assign_from_choices(), aggregate_assign_positional(), dump_subexp_body_standard(), dwarf2_evaluate_loc_desc_full(), evaluate_funcall(), evaluate_subexp_c(), evaluate_subexp_for_address(), evaluate_subexp_opencl(), evaluate_subexp_standard(), extract_field_op(), gen_expr(), ignore_command(), operator_length_standard(), print_subexp_standard(), resolve_subexp(), rust_dump_subexp_body(), rust_evaluate_subexp(), rust_operator_length(), rust_print_subexp(), rust_range(), value_concat(), value_equal(), value_f90_subarray(), and value_less().
|
static |
Definition at line 1605 of file valprint.c.
Referenced by print_decimal_chars().
| void maybe_print_array_index | ( | struct type * | index_type, |
| LONGEST | index, | ||
| struct ui_file * | stream, | ||
| const struct value_print_options * | options | ||
| ) |
Definition at line 1909 of file valprint.c.
References LA_PRINT_ARRAY_INDEX, value_print_options::print_array_indexes, and value_from_longest().
Referenced by val_print_array_elements(), and val_print_packed_array_elements().
|
static |
Definition at line 2069 of file valprint.c.
References target_read_memory().
Referenced by read_string().
| void print_binary_chars | ( | struct ui_file * | stream, |
| const gdb_byte * | valaddr, | ||
| unsigned | len, | ||
| enum bfd_endian | byte_order, | ||
| bool | zero_pad | ||
| ) |
Definition at line 1369 of file valprint.c.
References fputc_filtered(), and HOST_CHAR_BIT.
Referenced by print_scalar_formatted().
| void print_char_chars | ( | struct ui_file * | stream, |
| struct type * | type, | ||
| const gdb_byte * | valaddr, | ||
| unsigned | len, | ||
| enum bfd_endian | byte_order | ||
| ) |
Definition at line 1848 of file valprint.c.
References LA_EMIT_CHAR.
|
static |
Definition at line 2525 of file valprint.c.
References _, converted_character::buf, converted_character::buflen, converted_character::chars, gdb_btowc, gdb_WEOF, LCST, obstack_grow_wstr, print_wchar(), converted_character::repeat_count, value_print_options::repeat_count_threshold, converted_character::result, VEC_index, wchar_iterate_eof, wchar_iterate_incomplete, wchar_iterate_invalid, wchar_iterate_ok, xfree(), and xstrprintf().
Referenced by generic_printstr().
| void print_decimal_chars | ( | struct ui_file * | stream, |
| const gdb_byte * | valaddr, | ||
| unsigned | len, | ||
| bool | is_signed, | ||
| enum bfd_endian | byte_order | ||
| ) |
Definition at line 1648 of file valprint.c.
References CARRY_LEFT, CARRY_OUT, dummy, fprintf_filtered(), fputs_filtered(), HIGH_NIBBLE, LOW_NIBBLE, maybe_negate_by_bytes(), and SHIFT.
Referenced by print_scalar_formatted().
Definition at line 1361 of file valprint.c.
References fputs_filtered(), string, and target_float_to_string().
Referenced by ada_print_floating(), dump_subexp_body_standard(), generic_val_print_complex(), generic_val_print_float(), and print_scalar_formatted().
| void print_function_pointer_address | ( | const struct value_print_options * | options, |
| struct gdbarch * | gdbarch, | ||
| CORE_ADDR | address, | ||
| struct ui_file * | stream | ||
| ) |
Definition at line 1884 of file valprint.c.
References value_print_options::addressprint, current_target, demangle, fputs_filtered(), gdbarch_convert_from_func_ptr_addr(), paddress(), and print_address_demangle().
Referenced by c_val_print_ptr(), c_val_print_struct(), cp_print_value_fields(), f_val_print(), print_one_vtable(), and print_unpacked_pointer().
| void print_hex_chars | ( | struct ui_file * | stream, |
| const gdb_byte * | valaddr, | ||
| unsigned | len, | ||
| enum bfd_endian | byte_order, | ||
| bool | zero_pad | ||
| ) |
Definition at line 1784 of file valprint.c.
References fprintf_filtered(), and fputs_filtered().
Referenced by default_print_one_register_info(), regcache::dump(), print_scalar_formatted(), and sh64_do_fp_register().
Definition at line 1303 of file valprint.c.
References _, value_print_options::format, fputs_filtered(), int_string(), and internal_error().
Referenced by ada_print_scalar(), ada_val_print_enum(), ax_print(), dump_raw_expression(), generic_val_print_bool(), generic_val_print_enum_1(), gnuv3_print_method_ptr(), h8300_print_register(), m68hc11_print_register(), mt_registers_info(), print_type_scalar(), and val_print_type_code_flags().
| void print_octal_chars | ( | struct ui_file * | stream, |
| const gdb_byte * | valaddr, | ||
| unsigned | len, | ||
| enum bfd_endian | byte_order | ||
| ) |
Definition at line 1448 of file valprint.c.
References _, BITS_IN_OCTAL, CARRY_ONE, CARRY_ZERO, emit_octal_digit(), error(), fputs_filtered(), HIGH_ONE, HIGH_TWO, HIGH_ZERO, HOST_CHAR_BIT, LOW_ONE, LOW_TWO, LOW_ZERO, MID_ONE, and MID_TWO.
Referenced by print_scalar_formatted().
|
static |
Definition at line 491 of file valprint.c.
References extract_typed_address(), fprintf_filtered(), fputs_filtered(), get_type_arch(), and paddress().
Referenced by generic_val_print_ref().
|
static |
Definition at line 387 of file valprint.c.
References value_print_options::addressprint, demangle, fputs_filtered(), get_type_arch(), paddress(), print_address_demangle(), print_function_pointer_address(), value_print_options::symbol_print, TYPE_CODE, and TYPE_CODE_FUNC.
Referenced by generic_val_print_array(), and generic_val_print_ptr().
|
static |
Definition at line 2274 of file valprint.c.
References append_string_as_wide(), extract_unsigned_integer(), gdb_btowc, gdb_iswdigit, LCST, obstack_grow_wstr, wchar_printable(), and xsnprintf().
Referenced by generic_emit_char(), and print_converted_chars_to_obstack().
| int read_string | ( | CORE_ADDR | addr, |
| int | len, | ||
| int | width, | ||
| unsigned int | fetchlimit, | ||
| enum bfd_endian | byte_order, | ||
| gdb_byte ** | buffer, | ||
| int * | bytes_read | ||
| ) |
Definition at line 2127 of file valprint.c.
References discard_cleanups(), extract_unsigned_integer(), free_current_contents(), make_cleanup(), partial_memory_read(), QUIT, xmalloc(), and xrealloc().
Referenced by c_get_string(), and val_print_string().
|
static |
Definition at line 2895 of file valprint.c.
References input_radix_1, and set_input_radix_1().
Referenced by _initialize_valprint().
|
static |
Definition at line 2901 of file valprint.c.
References _, error(), input_radix, input_radix_1, and printf_filtered().
Referenced by set_input_radix(), and set_radix().
|
static |
Definition at line 2932 of file valprint.c.
References output_radix_1, and set_output_radix_1().
Referenced by _initialize_valprint().
|
static |
Definition at line 2938 of file valprint.c.
References _, error(), value_print_options::output_format, output_radix, output_radix_1, printf_filtered(), and user_print_options.
Referenced by set_output_radix(), and set_radix().
|
static |
Definition at line 3019 of file valprint.c.
References all_commands, gdb_stdout, help_list(), printf_unfiltered(), and setprintlist.
Referenced by _initialize_valprint().
|
static |
Definition at line 3033 of file valprint.c.
References all_commands, gdb_stdout, help_list(), printf_unfiltered(), and setprintrawlist.
Referenced by _initialize_valprint().
|
static |
Definition at line 2977 of file valprint.c.
References _, parse_and_eval_long(), printf_filtered(), set_input_radix_1(), and set_output_radix_1().
Referenced by _initialize_valprint().
|
static |
Definition at line 244 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 159 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 169 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 223 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 214 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 3027 of file valprint.c.
References cmd_show_list(), and showprintlist.
Referenced by _initialize_valprint().
|
static |
Definition at line 181 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 145 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 3041 of file valprint.c.
References cmd_show_list(), and showprintrawlist.
Referenced by _initialize_valprint().
|
static |
Definition at line 2995 of file valprint.c.
References _, input_radix, output_radix, and printf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 192 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 202 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 251 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
|
static |
Definition at line 233 of file valprint.c.
References _, and fprintf_filtered().
Referenced by _initialize_valprint().
| void val_print | ( | struct type * | type, |
| LONGEST | embedded_offset, | ||
| CORE_ADDR | address, | ||
| struct ui_file * | stream, | ||
| int | recurse, | ||
| struct value * | val, | ||
| const struct value_print_options * | options, | ||
| const struct language_defn * | language | ||
| ) |
Definition at line 1015 of file valprint.c.
References _, apply_ext_lang_val_pretty_printer(), CATCH, check_typedef(), END_CATCH, fprintf_filtered(), gdb_flush(), value_print_options::prettyformat, value_print_options::prettyformat_structs, QUIT, value_print_options::raw, RETURN_MASK_ERROR, value_print_options::summary, TRY, TYPE_STUB, Val_no_prettyformat, Val_prettyformat, Val_prettyformat_default, val_print_scalar_type_p(), and valprint_check_validity().
Referenced by ada_val_print_1(), ada_val_print_flt(), ada_val_print_gnat_array(), ada_val_print_num(), ada_val_print_ptr(), ada_val_print_ref(), ada_value_print(), c_value_print(), common_val_print(), cp_print_static_field(), cp_print_value_fields(), default_print_one_register_info(), f77_print_array_1(), f_val_print(), mt_registers_info(), output_register(), pascal_object_print_value_fields(), print_field_values(), rust_val_print(), sh64_do_register(), val_print_array_elements(), val_print_packed_array_elements(), val_print_scalar_formatted(), and val_print_struct().
| void val_print_array_elements | ( | struct type * | type, |
| LONGEST | embedded_offset, | ||
| CORE_ADDR | address, | ||
| struct ui_file * | stream, | ||
| int | recurse, | ||
| struct value * | val, | ||
| const struct value_print_options * | options, | ||
| unsigned int | i | ||
| ) |
Definition at line 1932 of file valprint.c.
References _, annotate_array_section_begin(), annotate_array_section_end(), annotate_elt(), annotate_elt_rep(), annotate_elt_rep_end(), check_typedef(), current_language, discrete_position(), fprintf_filtered(), get_array_bounds(), maybe_print_array_index(), n_spaces(), value_print_options::prettyformat_arrays, value_print_options::print_max, print_spaces_filtered(), value_print_options::repeat_count_threshold, TYPE_CODE, TYPE_CODE_RANGE, TYPE_INDEX_TYPE, type_length_units(), TYPE_TARGET_TYPE, UINT_MAX, val_print(), value_contents_eq(), warning(), and wrap_here().
Referenced by ada_val_print_array(), c_val_print_array(), generic_val_print_array(), m2_print_array_contents(), m2_val_print(), and pascal_val_print().
| void val_print_invalid_address | ( | struct ui_file * | stream | ) |
Definition at line 374 of file valprint.c.
References _, and fprintf_filtered().
Referenced by cp_print_value(), and pascal_object_print_value().
| void val_print_not_saved | ( | struct ui_file * | stream | ) |
Definition at line 362 of file valprint.c.
References _, and fprintf_filtered().
Referenced by fprint_frame(), info_frame_command(), and val_print_optimized_out().
Definition at line 353 of file valprint.c.
References _, fprintf_filtered(), lval_register, val_print_not_saved(), and value_lval_const().
Referenced by cp_print_static_field(), frame_unwind_register_value(), pascal_object_print_static_field(), pascal_object_print_value_fields(), val_print_scalar_formatted(), valprint_check_validity(), value_check_printable(), and value_fetch_lazy().
| void val_print_scalar_formatted | ( | struct type * | type, |
| LONGEST | embedded_offset, | ||
| struct value * | val, | ||
| const struct value_print_options * | options, | ||
| int | size, | ||
| struct ui_file * | stream | ||
| ) |
Definition at line 1240 of file valprint.c.
References current_language, value_print_options::deref_ref, value_print_options::format, gdb_assert, gdbarch_addressable_memory_unit_size(), get_type_arch(), print_scalar_formatted(), size, TARGET_CHAR_BIT, TYPE_LENGTH, val_print(), val_print_optimized_out(), val_print_unavailable(), value_bits_any_optimized_out(), value_bytes_available(), and value_contents_for_printing().
Referenced by ada_val_print_enum(), ada_val_print_num(), c_val_print_int(), c_val_print_ptr(), f_val_print(), generic_val_print_bool(), generic_val_print_char(), generic_val_print_complex(), generic_val_print_enum(), generic_val_print_flags(), generic_val_print_float(), generic_val_print_func(), generic_val_print_int(), generic_val_print_memberptr(), generic_val_print_ptr(), m2_val_print(), mips_print_register(), pascal_val_print(), and print_formatted().
| int val_print_scalar_type_p | ( | struct type * | type | ) |
Definition at line 266 of file valprint.c.
References check_typedef(), TYPE_CODE, TYPE_CODE_ARRAY, TYPE_CODE_SET, TYPE_CODE_STRING, TYPE_CODE_STRUCT, TYPE_CODE_UNION, TYPE_IS_REFERENCE, and TYPE_TARGET_TYPE.
Referenced by list_arg_or_local(), val_print(), and value_check_printable().
| int val_print_string | ( | struct type * | elttype, |
| const char * | encoding, | ||
| CORE_ADDR | addr, | ||
| int | len, | ||
| struct ui_file * | stream, | ||
| const struct value_print_options * | options | ||
| ) |
Definition at line 2795 of file valprint.c.
References gdbarch::byte_order, do_cleanups(), err, extract_unsigned_integer(), fprintf_filtered(), fputs_filtered(), gdb_flush(), gdbarch_byte_order(), get_type_arch(), LA_PRINT_STRING, make_cleanup(), memory_error_message(), value_print_options::print_max, read_string(), string, target_read_memory(), TARGET_XFER_E_IO, TYPE_LENGTH, and xfree().
Referenced by f_val_print(), fprint_auxv_entry(), lsscm_val_print_lazy_string(), m2_print_array_contents(), pascal_val_print(), print_children(), print_formatted(), print_go_string(), print_string_repr(), print_unpacked_pointer(), rust_val_print(), rust_val_print_str(), and varobj_value_get_print_value().
|
static |
Definition at line 1186 of file valprint.c.
References builtin_type::builtin_bool, builtin_type(), fprintf_filtered(), fputs_filtered(), generic_val_print_enum_1(), get_type_arch(), print_longest(), TARGET_CHAR_BIT, TYPE_CODE, TYPE_CODE_ENUM, TYPE_FIELD_BITPOS, TYPE_FIELD_BITSIZE, TYPE_FIELD_NAME, TYPE_FIELD_TYPE, TYPE_NFIELDS, and unpack_long().
Referenced by generic_val_print_flags().
| void val_print_unavailable | ( | struct ui_file * | stream | ) |
Definition at line 368 of file valprint.c.
References _, and fprintf_filtered().
Referenced by cp_print_value(), fprint_frame(), info_frame_command(), pascal_object_print_value(), val_print_scalar_formatted(), valprint_check_validity(), and value_check_printable().
| int valprint_check_validity | ( | struct ui_file * | stream, |
| struct type * | type, | ||
| LONGEST | embedded_offset, | ||
| const struct value * | val | ||
| ) |
Definition at line 290 of file valprint.c.
References _, check_typedef(), coerce_ref_if_computed(), value::embedded_offset, fputs_filtered(), lval_memory, TARGET_CHAR_BIT, TYPE_CODE, TYPE_CODE_ARRAY, TYPE_CODE_REF, TYPE_CODE_STRUCT, TYPE_CODE_UNION, TYPE_LENGTH, type_not_allocated(), type_not_associated(), val_print_not_allocated(), val_print_not_associated(), val_print_optimized_out(), val_print_unavailable(), value_bits_any_optimized_out(), value_bits_synthetic_pointer(), value_bytes_available(), and value_lval_const().
Referenced by cp_print_value_fields(), and val_print().
|
static |
Definition at line 1080 of file valprint.c.
References _, fprintf_filtered(), value_print_options::summary, TYPE_CODE, TYPE_CODE_INTERNAL_FUNCTION, type_not_allocated(), type_not_associated(), val_print_not_allocated(), val_print_not_associated(), val_print_optimized_out(), val_print_scalar_type_p(), val_print_unavailable(), value_entirely_optimized_out(), value_entirely_unavailable(), value_internal_function_name(), and value_type().
Referenced by common_val_print(), and value_print().
| void value_print | ( | struct value * | val, |
| struct ui_file * | stream, | ||
| const struct value_print_options * | options | ||
| ) |
Definition at line 1163 of file valprint.c.
References apply_ext_lang_val_pretty_printer(), current_language, LA_VALUE_PRINT, value_print_options::raw, value_address(), value_check_printable(), value_embedded_offset(), and value_type().
Referenced by dwarf2_compute_name(), info_common_command_for_block(), print_formatted(), print_return_value_1(), print_scalar_formatted(), print_subexp_standard(), show_convenience(), show_values(), unwind_infopy_str(), and watchpoint_value_print().
|
static |
Definition at line 2241 of file valprint.c.
References gdb_iswprint, and LCST.
Referenced by generic_emit_char(), and print_wchar().
| unsigned input_radix = 10 |
Default radixes for input and output. Only some values supported.
Definition at line 157 of file valprint.c.
Referenced by breakpoint_re_set(), breakpoint_re_set_one(), classify_name(), init_raw_breakpoint_without_location(), lex_one_token(), parse_number(), set_input_radix_1(), show_radix(), varobj_set_value(), VEC(), and yylex().
|
static |
Definition at line 2888 of file valprint.c.
Referenced by _initialize_valprint(), set_input_radix(), and set_input_radix_1().
| unsigned output_radix = 10 |
Definition at line 167 of file valprint.c.
Referenced by set_output_radix_1(), and show_radix().
|
static |
Definition at line 2929 of file valprint.c.
Referenced by _initialize_valprint(), set_output_radix(), and set_output_radix_1().
| struct cmd_list_element* setprintrawlist |
Definition at line 77 of file valprint.c.
Referenced by _initialize_stack(), _initialize_valprint(), and set_print_raw().
| struct cmd_list_element* showprintrawlist |
Definition at line 78 of file valprint.c.
Referenced by _initialize_stack(), _initialize_valprint(), and show_print_raw().
| struct value_print_options user_print_options |
Definition at line 95 of file valprint.c.
Referenced by _initialize_cp_valprint(), _initialize_pascal_valprint(), _initialize_valprint(), get_formatted_print_options(), get_no_prettyformat_print_options(), get_user_print_options(), and set_output_radix_1().
1.8.14