aboutsummaryrefslogtreecommitdiff
path: root/gdb/values.c
AgeCommit message (Collapse)AuthorFilesLines
1999-07-07import gdb-1999-07-07 post reformatJason Molenda1-184/+186
1999-06-14import gdb-1999-06-14 snapshotJason Molenda1-0/+26
1999-06-01import gdb-1999-06-01 snapshotJason Molenda1-8/+8
1999-04-26import gdb-19990422 snapshotStan Shebs1-5/+4
1999-04-16Initial creation of sourceware repositorygdb-4_18-branchpointStan Shebs1-0/+1623
1999-04-16Initial creation of sourceware repositoryStan Shebs1-1623/+0
1999-01-18 * values.c (value_virtual_fn_field): Clear the pointed-toMark Alexander1-1/+3
offset when casting to the base class.
1998-12-31 * value.c (value_virtual_fn_field): Handle the situation whereMark Alexander1-9/+25
vtbl is a pointer to a structure instead of a pointer to an array.
1998-12-28hp merge changes -- too numerous to mention here; see ChangeLog andDavid Taylor1-73/+204
ChangeLog-gdbtk for details.
1998-12-28revert change 1.104 --> 1.105. sigh. this reversal breaks 18470. doubleDavid Taylor1-25/+9
sigh. this is to 'fix' a conflict with hp merge changes that are about to go in.
1998-12-21Fix for PR 18470:Mark Alexander1-9/+25
* value.c (value_virtual_fn_field): Handle the situation where vtbl is a pointer to a structure instead of a pointer to an array.
1998-11-23CARP: Convert macro definitions of USE_STRUCT_CONVENTION into targetAndrew Cagney1-8/+15
specific functions.
1998-10-141998-10-14 Jason Molenda (jsm@bugshack.cygnus.com)Jason Molenda1-2/+6
* defs.h: Move _initialize_printcmd, _initialize_stack, _initialize_blockframe out of here and in to their respective .c files. * blockframe.c: Move _initialize_blockframe prototype to here. * printcmd.c: Move _initialize_printcmd prototype to here. * stack.c: Move _initialize_stack prototype to here. * source.c, symtab.h: Move _initialize_source prototype to the .c file. * values.c, value.h: Move _initialize_values prototype to the .c file. * gdbthread.h, thread.c: Move _initialize_thread prototype to the .c file. * breakpoint.c, breakpoint.h: Move _initialize_breakpoint prototype to the .c file. * abug-rom.c alpha-nat.c alpha-tdep.c annotate.c ax-gdb.c bcache.c: Standardize comments for the prototype section of these files. * configure.in: Look in libc for wctype before looking for it in libc. The last one is to fix the GNU ld (~2.9.1) + Solaris 2.6 interaction problem where an empty stub library (libw) causes a core dump when we call vasprintf (e.g. `info br') in the final linked gdb.
1998-10-02 * target.c (target_xfer_memory): Handle requests with zeroPeter Schauer1-3/+6
transfer length right away. * values.c (unpack_double): Set up code, length and signedness of type _after_ checking for typedef.
1998-06-16* PR 15693 fix.Frank Ch. Eigler1-1/+4
Wed Jun 10 18:04:35 1998 Frank Ch. Eigler <fche@cygnus.com> * gdbtypes.c (get_discrete_bounds): Assign unsigned type flag for all-positive enum. (create_set_type): Ditto for all-positive set values. * values.c (unpack_field_as_long): Check for typedef in struct field unpacking.
1998-04-20Mon Apr 20 15:35:03 1998 Philippe De Muyter <phdm@macqel.be>Jason Molenda1-1/+1
* coffread.c (decode_base_type): Treat a long field with size greater than TARGET_LONG_BIT as long long. * values.c (value_from_longest): Print code value in error message.
1998-01-23 * config/d10v/tm-d10v.h (CALL_DUMMY): Define as "{ 0 }".Fred Fish1-0/+4
(TARGET_READ_FP): Define to d10v_read_fp rather than d10v_read_sp. (TARGET_WRITE_FP): Define to d10v_write_fp rather than d10v_write_sp. (d10v_write_fp, d10v_read_fp): Add prototypes. * symtab.c (decode_line_1): Remove assignment of sals[0].pc field. * symfile.c (simple_overlay_update, simple_overlay_update_1): Ignore the size of overlay sections. This check is redundant anyway. * printcmd.c (print_frame_args): Ditto. * valops.c (value_fetch_lazy): Ditto. * values.c (unpack_long): Ditto. * d10v-tdep.c (d10v_frame_chain, d10v_frame_find_saved_regs, d10v_init_extra_frame_info): Fix some minor bugs so the finish command works properly. (show_regs): Change num1 and num2 types from "long long" to "LONGEST". (d10v_read_fp, d10v_write_fp): New functions. (d10v_push_arguments): Remove unneeded assigns to "val" and "contents". (d10v_push_arguments): Fix for pointers and structs. (d10v_extract_return_value): Fix for pointers and chars.
1997-08-09 * values.c (value_primitive_field): Account for offset whenPeter Schauer1-7/+10
extracting the value of a bitfield. From Paul Hilfinger <hilfingr@CS.Berkeley.EDU>.
1997-08-05 * gdbtypes.h: Re-interpret struct field. Suppport address of static.Per Bothner1-8/+31
Add a bunch of macros. * coffread.c, dwarf2read.c, dwarfread.c, mdebugread.c, stabsread.c: Update to use new macros. * coffread.c, hpread.c, stabsread.c: Remove bugus TYPE_FIELD_VALUE. * value.h, values.c (value_static_field): New function. * cp-valprint.c, valops.c: Modify to use value_static_field.
1997-01-04 * Makefile.in configure configure.in: Remove ENABLE_CLIBS,Stu Grossman1-6/+4
ENABLE_OBS, and THREAD_DB_OBS. These are consolidated into LIBS and CONFIG_OBS. * configure configure.in: Clean up test cases around thread support. start-sanitize-v850 * configure.tgt (v850-*-*): Include v850ice.o and v850.lib if host is Windows. end-sanitize-v850 * c-valprint.c ch-valprint.c cp-valprint.c eval.c expprint.c printcmd.c valops.c value.h values.c: Add bfd_section arg to value_at and value_at_lazy. * coffread.c dbxread.c elfread.c mdebugread.c minsyms.c symtab.h: Add bfd_section arg to prim_record_minimal_symbol_and_info. * corefile.c gdbcore.h printcmd.c valops.c: Use read_memory_section instead of read_memory. It takes a bfd_section arg. * coffread.c dbxread.c elfread.c gdb-stabs.h objfiles.h: Remove unnecessary cast for assignment of struct dbx_symfile_info. Struct objfile now uses a real pointer instead of PTR for this element. * dbxread.c (dbx_symfile_init): Stash bfd section pointers for text, data and bss into dbx_symfile_info. * exec.c (xfer_memory): Handle transfers for user-specified sections. * findvar.c (read_var_value locate_var_value): Copy bfd section from the symbol to the value. * gdb-stabs.h: Add section pointers for text, data and bss sections. * maint.c (translate address command): Add test code for overlay address translation. * printcmd.c (do_examine do_one_display): Now takes a bfd section arg. * (print_formatted x_command): Record current section along with current address for repeated commands. * sparc-nat.c (fetch_inferior_registers): Change target_xfer_memory to target_{read write}_memory to allow changes to target_xfer_memory interface for section info. * symmisc.c (dump_msymbols print_symbol): Print section assocaited with symbol. * symtab.c (fixup_symbol_section): New routine to add section info to symbols returned by lookup_symbol. * symtab.h (struct general_symbol_info): Add bfd section to symbols. * target.c target.h (target_xfer_memory): Add bfd section to args. * (target_read_memory_section): New routine to read data from a specific section. * (target_memory_bfd_section): New global variable to pass bfd section in to targets. * valarith.c (value_add value_addr value_array): Preserve bfd section when computing new value. * value.h (struct value): Add bfd section to values. * values.c (allocate_value value_copy): Initialize/preserve bfd section. * (unpack_double): Clean up _MSC_VER conditionals to remove duplicate code. start-sanitize-v850 * v850ice.c: New module to support communication with NEC's PC-based ICE. * config/v850/tm-v850.h (REGISTER_NAMES): Replace sp, gp, fp, and ep names with rxx names. sp and fp are renamed via a different mechanism. end-sanitize-v850
1996-12-19 * values.c (unpack_double): Make it compile with MSVC++ 2.x.Mark Alexander1-1/+1
* remote-mips.c (S_IROTH): Define if not defined by stat.h, e.g. when using MSVC++. (common_open): Fix help string.
1996-11-22Fri Nov 22 15:55:22 1996 Martin M. Hunt <hunt@pizza.cygnus.com>Martin Hunt1-9/+1
* valops.c (value_at, value_fetch_lazy): Put in D10V call to fix up address pointers. * values.c (value_from_longest): Removed previous d10v changes. * config/d10v/tm-d10v.h (TARGET_PTR_BIT): Change to 4 bytes.
1996-11-21Wed Nov 20 19:09:16 1996 Martin M. Hunt <hunt@pizza.cygnus.com>Martin Hunt1-0/+8
* infcmd.c (do_registers_info): Call val_print with the virtual buf instead of the raw buf. Needed for REGISTER_CONVERT to work with non-floating point regs. start-sanitize-d10v * d10v-tdep.c (d10v_skip_prologue): If we have line debugging information, then the end of the prologue should the first assembly instruction of the first source line. * values.c (value_from_longest): Put in D10V call to fix up address pointers. * config/d10v/tm-d10v.h (REGISTER_VIRTUAL_SIZE): Modified. (REGISTER_VIRTUAL_TYPE): Modified for PC_REGNUM and SP_REGNUM. (REGISTER_CONVERTIBLE): Make PC and SP convertible. (REGISTER_CONVERT_TO_VIRTUAL): Define. (REGISTER_CONVERT_TO_RAW): Define. (D10V_MAKE_DADDR): Define. (D10V_MAKE_IADDR): Define. end-sanitize-d10v
1996-11-12Patches to add Irix6 host support.Jim Wilson1-7/+7
1996-11-11 * mips-tdep.c, remote-mips.c, values.c, mdebugread.c,Dawn Perchik1-0/+9
config/mips/tm-mips.h: Add/fix bugs for 64-bit mips support. * defs.h: Cleanup; add prototypess * corefile.c: Change FIXME #ifdef * win32-nat.c: Include windefs instead of windows.h. * utils.c: Add routines for printing addresses and registers based on type size.
1996-07-26See gdb ChangeLog entry with header:Fred Fish1-0/+2
Thu Jul 25 19:41:31 1996 Fred Fish <fnf@cygnus.com> for a rather huge set of changes. I was going to put them here, but it made cvs dump core. :-(
1996-03-30 * core-aout.c (fetch_core_registers): Cast core_reg_size to intFred Fish1-5/+5
before testing against reg_ptr. * eval.c (evaluate_subexp_standard): Cast type of TYPE_FN_FIELD_VOFFSET to int. * findvar.c (extract_signed_integer, extract_unsigned_integer, extract_long_unsigned_integer): Cast type of sizeof to int. * values.c (unpack_field_as_long, modify_field): Ditto. * valops.c (value_assign, call_function_by_hand): Ditto. * infcmd.c (do_registers_info): Ditto. * ser-tcp.c (tcp_open): Ditto * remote.c (putpkt): Ditto. * dcache.c (dcache_peek): Ditto. * dcache.c (dcache_poke): Ditto. * m2-exp.y (yylex): Ditto. * gnu-regex.c (re_match_2): Ditto. * f-lang.c (ADD_BF_SYMNUM, saved_bf_list_end, tmp_bf_ptr): Ifdef out unused macro definition and variables. * inftarg.c (proc_wait): Move from main.c to here, and make static. * valprint.c (val_print_string): Change bufsize from int to unsigned. * main.c (wait.h): Include * top.c (command_line_input): Remove unused variable "c". * f-typeprint.c (f_type_print_varspec_prefix): Add missing enum value TYPE_CODE_TYPEDEF to switch statement. (f_type_print_varspec_suffix): Add missing enum value TYPE_CODE_TYPEDEF to switch statement. * ch-exp.c (parse_primval): Add remaining enumeration values to switch statement, with no specific action. (ch_lex): Add LOC_UNRESOLVED in switch statement. (pushback_token): Ifdef out, since code using it is ifdef'd out. * stabsread.c (cleanup_undefined_types): Remove unused label "badtype". * objfiles.h (print_symbol_bcache_statistics): Add prototype. * maint.c (objfiles.h): Include. (maintenance_print_statistics): Remove unused variable "temp". * minsyms.c (lookup_minimal_symbol_solib_trampoline): Remove unused variable "found_file_symbol". * m2-exp.y (yylex): Add LOC_UNRESOLVED case to switch. * language.c (lang_bool_type): Use existing function local type variable rather than create block local variables. * solib.c (disable_break): Enclose in ifndef SVR4_SHARED_LIBS. * infptrace.c (wait.h, command.h): Include. * ser-tcp.c (gdb_string.h): Include * i386-tdep.c (codestream_seek): Change "place" to CORE_ADDR. (i386_get_frame_setup): Change "pc" from int to CORE_ADDR. * command.c (complete_on_enum): Make assignment used as truth value explictly check against NULL. (wait.h): Include. * infrun.c (wait_for_inferior): Ifdef out prologue_pc since code that uses it is ifdef'd out. * parser-defs.h: Add prototype for write_dollar_variable. * infrun.c: Add prototype for write_pc_pid. * breakpoint.h: Add prototype for re_enable_breakpoints_in_shlibs. * symmisc.c (bcache.h): Include. * bcache.h: Add prototype for print_bcache_statistics. * symfile.c: Include <time.h>. * printcmd.c (print_scalar_formatted): Change len to unsigned int. * valarith.c (value_equal): Cast result of TYPE_LENGTH to int. * valarith.c (value_binop): Change result_len, promoted_len1, and promoted_len2 to unsigned int. * valarith.c (value_subscripted_rvalue): Change elt_offs and elt_size to unsigned int. * valops.c (value_array): Change typelength to unsigned int. (destructor_name_p): Change len to unsigned int. * scm-lang.h (scm_parse): Add prototype for scm_unpack. * symfile.c (decrement_reading_symtab): Change return type to void. * valarith.c (value_subscript): Remove unused variable "word". (value_subscript): Remove unused variable "tint". * valops.c (auto_abandon): Ifdef out, since code using it is also ifdef'd out. * eval.c (init_array_element): Remove unused variable "val". * Makefile.in (values.o): Depends on scm-lang.h. (command.o): Depends upon wait_h. (ser-tcp.o): Depends upon gdb_string.h. (infptrace.o): Depends upon wait_h and command_h. (maint.o): Depends on objfiles.h and symfile.h. * values.c (allocate_repeat_value): Remove unused variable "element_type". (scm-lang.h): Include. * breakpoint.c (create_longjmp_breakpoint): Enclose in GET_LONGJMP_TARGET define, unused otherwise. * config/i386/nm-linux.h: Add prototypes for i386_insert_watchpoint, i386_remove_watchpoint and i386_stopped_by_watchpoint.
1996-02-17 * Add native support for long double data type.Stu Grossman1-15/+16
* c-exp.y (%union): Change dval to typed_val_float. Use DOUBLEST to store actual data. Change types of INT and FLOAT tokens to typed_val_int and typed_val_float respectively. Create new token DOUBLE_KEYWORD to specify the string `double'. Make production for FLOAT use type determined by parse_number. Add production for "long double" data type. * (parse_number): Use sscanf to parse numbers as float, double or long double depending upon the type of typed_val_float.dval. Also allow user to specify `f' or `l' suffix to explicitly specify float or long double constants. Change typed_val to typed_val_int. * (yylex): Change typed_val to typed_val_int. Also, scan for "double" keyword. * coffread.c (decode_base_type): Add support for T_LNGDBL basic type. * configure, configure.in: Add check for long double support in the host compiler. * defs.h: Define DOUBLEST appropriatly depending on whether HAVE_LONG_DOUBLE (from autoconf) is defined. Also, fix prototypes for functions that handle this type. * expression.h (union exp_element): doubleconst is now type DOUBLEST. * m2-exp.y f-exp.y (%union): dval becomes type DOUBLEST. * findvar.c (extract_floating): Make return value be DOUBLEST. Also, add support for numbers with size of long double. * (store_floating): Arg `val' is now type DOUBLEST. Handle all floating types. * parser-defs.h parse.c (write_exp_elt_dblcst): Arg expelt is now DOUBLEST. * valarith.c (value_binop): Change temp variables v1, v2 and v to type DOUBLEST. Coerce type of result to long double if either op was of that type. * valops.c (value_arg_coerce): If argument type is bigger than double, coerce to long double. * (call_function_by_hand): If REG_STRUCT_HAS_ADDR is defined, and arg type is float and > 8 bytes, then use pointer-to-object calling conventions. * valprint.c (print_floating): Arg doub is now type DOUBLEST. Use appropriate format and precision to print out floating point values. * value.h: Fixup prototypes for value_as_double, value_from_double, and unpack_double to use DOUBLEST. * values.c (record_latest_value): Remove check for invalid floats. Allow history to store them so that people may examine them in hex if they want. * (value_as_double unpack_double): Change return value to DOUBLEST. * (value_from_double): Arg `num' is now DOUBLEST. * (using_struct_return): Use RETURN_VALUE_ON_STACK macro (target specific) to expect certain types to always be returned on the stack.
1996-02-16 * demangle.c (is_cplus_marker): New function, checks if aFred Fish1-2/+2
character is one of the commonly used C++ marker characters. * defs.h (is_cplus_marker): Add prototype. * c-typeprint.c (c_type_print_base), ch-lang.c (chill_demangle), cp-valprint.c (cp_print_class_method), mdebugread.c (parse_symbol), stabsread.c (define_symbol, read_member_functions, read_struct_fields), symtab.h (OPNAME_PREFIX_P, VTBL_PREFIX_P, DESTRUCTOR_PREFIX_P), values.c (vb_match): Use is_cplus_marker instead of comparison with CPLUS_MARKER.
1996-01-24 * value.h (COERCE_ARRAY): Don't coerce enums.Per Bothner1-2/+1
(COERCE_ENUM): Don't COERCE_REF. (COERCE_NUMBER): New macro (same as COERCE_ARRAY then COERCE_ENUM). * valops.c (value_assign): Only do COERCE_ARRAY if internalvar (let value_cast handle it otherwise); do *not* COERCE_ENUM either way. * valarith.c: Use COERCE_NUMBER instead od COEREC_ARRAY. Add COERCE_REF before COERCE_ENUM. * values.c (value_as_long): Simplify. This fixes PR chill/8869. * valops.c (value_array): Create internalvar if !c_style_arrays.
1995-11-30 * ch-exp.y: Replaced by ...Per Bothner1-121/+43
* ch-exp.c: New file. Use recursive-descent. Recognize labelled array tuples and powerset ranges. * Makefile.in: Update for no longer using yacc for ch-exp. * c-lang.c: Make various functions non-static. * c-lang.h: Add bunches of prototypes. * cp-valprint.c (cp_print_value_fields): Also take address. (cp_print_value): Likewise. Use baselcass_offset. * stabsread.c (current_symbol): New static variable. (type_synonym_name): Remove. (read_type): If copying, make copy be a TYPE_CODE_TYPEDEF. (read_array_type): Don't need to handle undefined element type here. (cleanup_undefined_types): Ditto. (read_range_type): Look for Chill ranges. * valops.c (value_assign): Fix case lval_internalvar - don't try to assign into old value (which might be too small!). (value_coerce_array): No longer need special VALUE_REPEATED handling. (value_arg_coerce): Cleaner array->pointer decay mechanism. (search_struct_field): Use baseclass_offset rather than baseclass_addr. (value_slice): Use get_discrete_bounds. * value.h (COERCE_VARYING_ARRAY): Take type argumnt as well. * values.c (baseclass_offset): Change parameter interface. (baseclass_addr): Removed. * c-typeprint.c, c-valprint.c, ch-valprint.c, values.c, valops.c: Add check_typedef/CHECK_TYPEDEF as needed.
1995-10-06 * values.c allocate_repeat_value): Allocate an array type, andPer Bothner1-29/+14
a value of that type; use that instead of setting VALUE_REPEATED. * value.h (struct value): Remove fields repetitions and repeated. (VALUE_REPEATED, VALUE_REPETITIONS): Removed, no longer used. * c-valprint.c, ch-valprint.c, eval.c, printcmd.c, valops.c, value.h, values.c: Simplify, since now VALUE_REPEATED is never used. * valprint.c (value_print_array_elemen): Removed never-used function.
1995-10-05 * expression.h (enum exp_code): Added OP_NAME.Per Bothner1-0/+4
* expprint.c (print_subexp): Add OP_NAME support. * parse.c (length_of_subexp, prefixify_subexp): Likewise. * scm-lang.c (scm_unpack, in_eval_c, scm_lookup_name): new function. * scm-lang.h: Declare builtin_type_scm; other minor tweaks. * values.c (unpack_long): If type is SCM, call scm_unpack. * scm-valprint.c (scm_val_print): Use extract_signed_integer, instead unpack_long * scm-lang.c: More Scheme expression parsing from here ... * scm-exp.c: ... to here. New file. Also, provide for gdb to evaluate simple constants and names.. * Makefile.in: Note new scm-exp.{c,o}.
1995-09-02 * configure.in: Explicitly `exit 0' for broken shells.Peter Schauer1-0/+2
* configure: Rebuilt. * symtab.c (list_symbols): Add missing blank after `<function, no debug info>' output. * valops.c (value_assign): Handle truncation when assigning to bitfields. Use value_copy to construct the return value from toval. * values.c (value_copy): Copy VALUE_FRAME and VALUE_OPTIMIZED_OUT.
1995-08-26 * mdebugread.c (parse_symbol): Handle sh.value of zero for enums.Peter Schauer1-4/+12
Determine signedness of enum type from enumerators. (parse_type): Handle btIndirect types, handle fBitfield for some non-member types. (upgrade_type): Use TYPE_FLAG_TARGET_STUB for arrays with unknown length. (cross_ref): Handle stIndirect forward reference to btTypedef. * stabsread.c (read_enum_type): Determine signedness of enum type from enumerators. * top.c (execute_command): Remove trailing whitespace from command arguments, except for `set' and `complete' commands. (validate_comname): Allow underscores in user defined command names. * values.c (modify_field): Change `Value does not fit in %d bits' error to a warning. Exclude sign extension bits of negative field values from fit check.
1995-08-02Update FSF address.Fred Fish1-1/+1
1995-08-01* configure.in: Check for working mmap, ansi headers, string.h,J.T. Conklin1-1/+1
strings.h, and memory.h. * configure: Regenerated. * gdb_stat.h: New file, "portable" <sys/stat.h>. * gdb_string.h: New file, "portable" <string.h>. * altos-xdep.c, arm-tdep.c, arm-xdep.c, convex-tdep.c, convex-xdep.c, coredep.c, cxux-nat.c, dbxread.c, exec.c, gould-xdep.c, hppa-tdep.c, i386aix-nat.c, i386b-nat.c, i386mach-nat.c, i386v-nat.c, infptrace.c, m88k-nat.c, main.c, mdebugread.c, objfiles.c, os9kread.c, procfs.c, pyr-xdep.c, rs6000-nat.c, source.c, standalone.c, stuff.c, sun386-nat.c, symfile.c, symm-nat.c, symm-tdep.c, symtab.c, top.c, ultra3-nat.c, ultra3-xdep.c, umax-xdep.c, xcoffread.c: Include "gdb_stat.h" instead of <sys/stat.h>. * alpha-tdep.c, breakpoint.c, buildsym.c, c-typeprint.c, ch-typeprint.c, coffread.c, command.c, core-sol2.c, core-svr4.c, core.c, corelow.c, cp-valprint.c, dbxread.c, dcache.c, demangle.c, dpx2-nat.c, dstread.c, dwarfread.c, elfread.c, environ.c, eval.c, exec.c, f-lang.c, f-typeprint.c, f-valprint.c, findvar.c, fork-child.c, gdbtypes.c, hpread.c, i386-tdep.c, infcmd.c, inflow.c, infptrace.c, infrun.c, irix5-nat.c, language.c, m2-typeprint.c, main.c, mdebugread.c, minsyms.c, mipsread.c, monitor.c, nlmread.c, objfiles.c, os9kread.c, osfsolib.c, parse.c, printcmd.c, procfs.c, regex.c, remote-adapt.c, remote-arc.c, remote-array.c, remote-bug.c, remote-e7000.c, remote-eb.c, remote-es.c, remote-hms.c, remote-mm.c, remote-os9k.c, remote-pa.c, remote-sim.c, remote-st.c, remote-udi.c, remote-utils.c, remote-vx.c, remote-vx29k.c, remote-vx68.c, remote-vx960.c, remote-vxmips.c, remote-vxsparc.c, remote.c, solib.c, somread.c, source.c, stabsread.c, stack.c, symfile.c, symmisc.c, symtab.c, target.c, top.c, typeprint.c, utils.c, valarith.c, valops.c, valprint.c, values.c, xcoffread.c: Include "gdb_string.h" instead of <string.h>. * gdbtk.c: Likewise. * config/xm-sysv4.h, i386/xm-ptx.h, m68k/xm-sun3os4.h, sparc/xm-sun4os4.h (HAVE_MMAP): Removed. * config/xm-lynx.h, config/i386/xm-ptx.h, config/m68k/nm-apollo68b.h, config/m68k/xm-hp300hpux.h, config/mips/xm-irix3.h, config/mips/xm-mips.h, config/mips/xm-news-mips.h, config/mips/xm-riscos.h, config/pa/hppah.h, config/rs6000/xm-rs6000.h, config/sparc/xm-sun4os4.h, config/sparc/xm-sun4sol2.h, config/vax/xm-vaxbsd.h, config/vax/xm-vaxult.h, config/vax/xm-vaxult2.h (MEM_FNS_DECLARED): Removed. * config/mips/xm-irix3.h, config/mips/xm-mips.h, config/pa/xm-hppah.h (memcpy, memset): Removed declarations.
1995-04-13* values.c (set_internalvar): Set modifiable flag of newval.Jim Kingdon1-0/+1
1995-01-26 * language.h (struct language_defn): New field c_style_arrays.Per Bothner1-0/+1
* language.c (unknown_language_defn, auto_language_defn, local_language_defn), c-lang.c (c_language_defn, cplus_language_defn, asm_language_defn): Set c_style_arrays to true. * m2-lang.c (m2_language_defn), ch-lang.c (chill_language_defn), f-lang.c (f_language_defn): Set c_style_arrays to false. * valops.c (value_string): If c_style_array is not set, allocate string in gdb (not inferior) using allocate_value. * value.h (COERCE_ARRAY), valops.c (value_addr, value_arg_coerce): Only call value_coerce_array if current_language->c_style_arrays. * values.c: Add #include "language.h". (Needed for COERCE_ARRAY.) * valops.c (chill_varying_type): New predicate. * valops.c (value_cast): Support assigning a fixed string or array to a variable string/array structure. * valarith.c (value_subscripted_rvalue): Extra parameter lowerbound. Check index>=lowerbound, and then add lowerbound to index here, instead of in caller. Generalize to arbitrary lval_types. (value_subscript): Use enhanced value_subscripted_rvalue if c_style_arrays is false (and index is in range).
1994-10-15 * eval.c (evaluate_subexp): Make fnptr a LONGEST insteadPeter Schauer1-15/+1
of using longest_to_int. * infcmd.c (run_stack_dummy): Reinstate set_current_frame call, mips and alpha targets need the real breakpoint pc for creating the breakpoint frame. * stack.c (return_command): Cast return value to the return type of the function from which we return. * values.c (set_return_value): Pass VALUE_CONTENTS unmodified to STORE_RETURN_VALUE. * symtab.c (lookup_symbol): Remove search for `static mangled symbols', the search for `static symbols' already looks for mangled and demangled symbols via lookup_block_symbol. * valarith.c (value_binop): Use ANSI C arithmetic conversions when performing integral evaluations, implement BINOP_EQUAL and BINOP_LESS. (value_equal, value_less): Use value_binop to perform the comparison if both operands have TYPE_CODE_INT. * rs6000-tdep.c (pop_frame): Make sure all registers are valid, as they are written back later. Handle sp restore for frameless functions. Use fdata.nosavedpc instead of fdata.frameless to determine if the pc has been saved. (function_frame_info): Handle `mr r31,r1', which is generated by gcc-2.6, as a synonym for `oril r31,r1,0'. (skip_trampoline_code): Handle shared library trampolines. * xcoffread.c (read_xcoff_symtabs): Record XMC_GL symbols with their real name. Enables setting of breakpoints in shared libraries before the executable is run.
1994-10-06 * defs.h: If TARGET_BYTE_ORDER_SELECTABLE is defined by tm.h,Ian Lance Taylor1-8/+6
define TARGET_BYTE_ORDER as target_byte_order, and declare target_byte_order as an extern int, and define BITS_BIG_ENDIAN as a test of TARGET_BYTE_ORDER. * top.c: Several additions if TARGET_BYTE_ORDER_SELECTABLE is defined: (endianlist, target_byte_order): New variables. (set_endian, set_endian_big, set_endian_little): New functions. (show_endian): New function. (init_cmd_lists): Initialize endianlist. (init_main): Add commands ``set endian big'', ``set endian little'', and ``show endian''. * a29k-pinsn.c: Rewrite uses of TARGET_BYTE_ORDER and BITS_BIG_ENDIAN to switch at run time rather than at compile time. * coffread.c, dwarfread.c, findvar.c, mips-tdep.c: Likewise. * remote-os9k.c, stabsread.c, valarith.c, valprint.c: Likewise. * values.c: Likewise. * mips-tdep.c: Rewrite uses of GDB_TARGET_IS_MIPS64 to switch at run time rather than at compile time.
1994-09-25 * infcmd.c (do_registers_info) [INVALID_FLOAT]: Only use ifStan Shebs1-0/+2
defined. * values.c (unpack_double) [INVALID_FLOAT]: Ditto. * mips-tdep.c (mips_print_register): Don't test float validity. * config/a29k/tm-a29k.h, config/alpha/tm-alpha.h, config/arm/tm-arm.h, config/convex/tm-convex.h, config/h8300/tm-h8300.h, config/h8500/tm-h8500.h, config/i386/tm-i386v.h, config/i386/tm-sun386.h, config/i960/tm-i960.h, config/m68k/tm-m68k.h, config/m88k/tm-m88k.h, config/mips/tm-mips.h, config/ns32k/tm-merlin.h, config/ns32k/tm-nbsd.h, config/ns32k/tm-ns32km3.h, config/ns32k/tm-umax.h, config/pa/tm-hppa.h, config/pyr/tm-pyr.h, config/rs6000/tm-rs6000.h, config/sh/tm-sh.h, config/sparc/tm-sparc.h, config/z8k/tm-z8k.h (INVALID_FLOAT): Remove definition.
1994-09-10 * Update copyright message to include 1993, 1994.Peter Schauer1-1/+2
1994-09-10 * corelow.c (add_solib_stub): Copy to_sections changes fromPeter Schauer1-12/+12
core_ops to current_target after adding the shared libraries. * partial-stab.h (N_EXCL), dbxread.c (add_old_header_file, find_corresponding_bincl_psymtab): Change `repeated header not seen' error to a complaint, simplify complaint. * procfs.c (signalname, errnoname): Make `name' const. * symfile.c (reread_symbols): Use filename from old BFD to reopen the objfile. * values.c (record_latest_value): Don't record value in the history chain until we are sure there won't be an error.
1994-05-05 Add partial support for g++ code compiled with -fvtable-thunks.Per Bothner1-9/+20
* c-valprint.c (c_val_print): Add vtblprint support when using thunks. * cp-valprint.c (cp_is_vtbl_member): A vtable can be an array of pointers (if using thunks) as well as array of structs (otherwise). * cp-valprint.c (vtbl_ptr_name_old, vtbl_ptr_name): Move to global level, and make the latter non-static (so define_symbol can use it). * stabsread.c (define_symbol): If the type being defined is a pointer type named "__vtbl_ptr_type", set the TYPE_NAME to that name. * symtab.h (VTBL_PREFIX_P): Allow "_VT" as well as "_vt". * values.c (value_virtual_fn_field): Handle thunks. * values.c (value_headof): Minor efficiency hack. * values.c (value_headof): Incomplete thunk support. FIXME.
1994-04-13 * breakpoint.h (enum bptype): Add bp_hardware_watchpoint andJeff Law1-0/+18
bp_watchpoint_scope breakpoints. (struct breakpoint): Add val_chain and related_breakpoint fields for use by watchpoints. * breakpoint.c (within_scope): Delete. No longer used. (TARGET_CAN_USE_HARDWARE_WATCHPOINT): Provide default definition. (target_{remove,insert}_watchpoint): Likewise. (can_use_hardware_watchpoint): New function. (remove_breakpoint): New function to remove a single breakpoint or hardware watchpoint. (insert_breakpoints): Handle insertion of hardware watchpoints. Store a copy of the value chain derived from the watchpoint expression. (remove_breakpoints): Simplify by using remove_breakpoint. (delete_breakpoint): Likewise. (watchpoint_check): Delete the watchpoint and watchpoint scope breakpoints when the watchpoint goes out of scope. Save & restore the current frame after checking watchpoints. (breakpoint_init_inferior): Likewise (restarting the program makes all local watchpoints go out of scope). (bpstat_stop_status): Handle hardware watchpoints much like normal watchpoints. Delete the watchpoint and watchpoint scope breakpoint when the watchpoint goes out of scope. Remove and reinsert all breakpoints before returning if we stopped when a hardware watchpoint fired. (watch_command): Use a hardware watchpoint when possible. If watching a local expression, build a scope breakpoint too. (map_breakpoint_numbers): Also call given function for any related breakpoints. (disable_breakpoint): Never disable a scope breakpoint. (enable_breakpoint): Handle hardware breakpoints much like normal breakpoints, but recompute the watchpoint_scope breakpoint's frame and address (if we have an associated scope breakpoint). (read_memory_nobpt): Handle hardware watchpoints like normal watchpoints. When necessary handle watchpoint_scope breakpoints. (print_it_normal, bpstat_what, breakpoint_1, mention): Likewise. (clear_command, breakpoint_re_set_one, enable_command): Likewise. (disable_command): Likewise. * blockframe.c (find_frame_addr_in_frame_chain): New function. Extern prototype added to frame.h * infrun.c (wait_for_inferior): Set current_frame and select a frame before checking if we stopped due to a hardare watchpoint firing. Handle stepping over hardware watchpoints. (normal_stop): Remove unnecessary call to select_frame. * value.h (value_release_to_mark): Declare. * values.c (value_release_to_mark): New function. * procfs.c (procfs_wait): Add cases for hardware watchpoints. (procfs_set_watchpoint, procfs_stopped_by_watchpoint): New functions. * hppab-nat.c (hppa_set_watchpoint): New function. * config/pa/nm-hppab.h (STOPPED_BY_WATCHPOINT): Define. (HAVE_STEPPABLE_WATCHPOINT): Define. (TARGET_CAN_USE_HARDWARE_WATCHPOINT): Define. (target_{insert,delete}_watchpoint): Define.
1994-04-08 * values.c (unpack_long): Remove obsolete comment about using aJim Kingdon1-3/+0
switch statement.
1994-04-05 * values.c (unpack_long, value_from_longest),Per Bothner1-0/+2
valarith.c (value_binop): Allow TYPE_CODE_RANGE.
1994-03-23 * values.c (set_internalvar): Don't set var->value until we areJim Kingdon1-5/+17
sure there won't be an error().
1994-03-05Fix typo, value has not been changed to value_ptr in all places.Peter Schauer1-1/+2