aboutsummaryrefslogtreecommitdiff
path: root/gdb/findvar.c
AgeCommit message (Collapse)AuthorFilesLines
2002-05-15* regcache.c (register_valid): Revise comments refering to "NotAndrew Cagney1-0/+7
available" and "unavailable". * frame.c (frame_register_read): Ditto. * findvar.c (value_of_register): Ditto.
2002-05-12* arch-utils.h (legacy_register_to_value): Declare.Andrew Cagney1-4/+4
(legacy_value_to_register): Declare. (legacy_convert_register_p): Declare. * arch-utils.c (legacy_register_to_value): New function. (legacy_value_to_register): New function. (legacy_convert_register_p): New function. * gdbarch.sh (REGISTER_TO_VALUE): Define. (VALUE_TO_REGISTER): Define. (CONVERT_REGISTER_P): Define. * gdbarch.h, gdbarch.c: Regenerate. * valops.c (value_assign): Use CONVERT_REGISTER_P and VALUE_TO_REGISTER. * findvar.c (value_from_register): Use REGISTER_TO_VALUE and CONVERT_REGISTER_P. * gdbint.texinfo (Target Architecture Definition): Document REGISTER_TO_VALUE and VALUE_TO_REGISTER and CONVERT_REGISTER_P. (Target Architecture Definition): Revise section `Using Different Register and Memory Data Representations'. Add section `Raw and Virtual Register Representations'.
2002-04-23* findvar.c (extract_signed_integer): Cast printf argumentJason Thorpe1-2/+2
to suppress format warning. (extract_unsigned_integer): Likewise. * infcmd.c (registers_info): Likewise. * top.c (get_prompt_1): Likewise. * valops.c (value_assign): Likewise. * valprint.c (print_decimal): Likewise.
2002-04-09* findvar.c: Include "builtin-regs.h".Andrew Cagney1-0/+6
(value_of_register): Call value_of_builtin_reg when applicable. * parse.c: Include "builtin-regs.h" and "gdb_assert.h". (target_map_name_to_register): Call builtin_reg_map_name_to_regnum. * Makefile.in (SFILES): Add builtin-regs.c and std-regs.c. (COMMON_OBS): Add builtin-regs.o and std-regs.o. (builtin_regs_h): Define. (builtin-regs.o): New target. (findvar.o): Add $(builtin_regs_h). * builtin-regs.c, builtin-regs.h: New files. * std-regs.c: New file. Partial fix for PR gdb/251.
2002-04-05gdb/ChangeLog:Jim Blandy1-1/+1
* stack.c (get_selected_block): Add new argument `addr_in_block', used to return the exact code address we used to select the block, not just the block. * blockframe.c (get_frame_block, get_current_block): Same. * frame.h (get_frame_block, get_current_block, get_selected_block): Update declarations. * linespec.c, stack.c, blockframe.c, breakpoint.c, findvar.c, linespec.c, varobj.c, printcmd.c, symtab.c: Callers changed. gdb/mi/ChangeLog: * mi-cmd-stack.c (list_args_or_locals): Pass new arg to get_frame_block. (See entry in gdb/ChangeLog.)
2002-03-16* eval.c (evaluate_subexp_standard): Pass ``selected_frame'' toAndrew Cagney1-7/+7
value_of_register. * findvar.c (value_of_register): Add ``frame'' parameter. Pass to get_saved_register. * value.h (value_of_register): Update.
2002-02-10* gdbarch.sh (TARGET_LONG_DOUBLE_FORMAT): Default toAndrew Cagney1-6/+0
default_double_format. * gdbarch.h, gdbarch.c: Re-generate. * findvar.c (floatformat_unknown): Delete variable definition. * doublest.h (floatformat_unknown): Delete variable declaration.
2002-01-05s/BIG_ENDIAN/BFD_ENDIAN_BIG/Andrew Cagney1-6/+6
2001-12-032001-11-30 Pierre Muller <muller@ics.u-strasbg.fr>Pierre Muller1-2/+15
* findvar.c (locate_var_value): Specify in which register a register variable is stored.
2001-11-10s/value_ptr/struct value */Andrew Cagney1-11/+11
2001-10-16* value.h (value_as_address): Rename value_as_pointer.Andrew Cagney1-4/+4
* eval.c, findvar.c, gnu-v2-abi.c, gnu-v3-abi.c, jv-lang.c, jv-valprint.c, printcmd.c, stack.c, top.c, valarith.c, valops.c, values.c: Update.
2001-09-24* findvar.c (read_var_value): For LOC_INDIRECT and LOC_REF_ARGAndrew Cagney1-18/+25
convert the pointer into a CORE_ADDRs.
2001-08-01* defs.h (HOST_FLOAT_FORMAT, HOST_DOUBLE_FORMAT)Andrew Cagney1-96/+0
(HOST_FLOAT_FORMAT, HOST_DOUBLE_FORMAT) (HOST_LONG_DOUBLE_FORMAT, DOUBLEST) (floatformat_to_doublest, floatformat_from_doublest) (floatformat_is_negative, floatformat_is_nan) (floatformat_mantissa, store_floating) (extract_floating): Move declaration from here. * doublest.h: To here. New file. * utils.c (get_field, floatformat_to_doublest, put_field) (ldfrexp, floatformat_from_doublest, floatformat_is_negative) (floatformat_is_nan, floatformat_mantissa) (FLOATFORMAT_CHAR_BIT): Move from here. * doublest.c: To here. New file. * findvar.c (store_floating, extract_floating): Move from here. * doublest.c: To here. * Makefile.in (SFILES): Add doublest.c. (COMMON_OBS): Add doublest.o. (doublest.o): Specify dependencies. (doublest_h): Define. * config/m88k/tm-m88k.h: Include "doublest.h". * config/i960/tm-i960.h: Ditto. * config/i386/tm-symmetry.h: Ditto. * rs6000-tdep.c, valarith.c: Ditto. * valprint.c, stabsread.c, sh-tdep.c: Ditto. * ia64-tdep.c, i387-tdep.c, i386-tdep.c: Ditto. * values.c, arm-tdep.c, arm-linux-tdep.c: Ditto. * alpha-tdep.c, ax.h, expression.h: Ditto. * sh-tdep.c, parse.c, top.c, value.h: Ditto. * Makefile.in (arm-tdep.o): Add $(doublest_h). (i386-tdep.o, i387-tdep.o, ia64-tdep.o): Ditto. (rs6000-tdep.o, stabsread.o, valarith.o): Ditto. (values.o, valprint.o, arm-linux-tdep.o): Ditto. (alpha-tdep.o, ax_h, parse.o, top.o, value_h): Ditto. (parser_defs_h): Ditto. (expression_h): Add $(doublest_h) and $(symtab_h).
2001-07-16 * findvar.c (read_var_value): Apply value_as_pointer() toNicholas Duffek1-13/+6
addresses retrieved from the target for LOC_BASEREG and LOC_BASEREG_ARG variables.
2001-07-10Clean up the D10V port so that GDB and the target program noJim Blandy1-23/+0
longer disagree on how big pointers are. * findvar.c (value_from_register): Remove special case code for D10V. * printcmd.c (print_frame_args): Same. * valops.c (value_at, value_fetch_lazy): Same. * values.c (unpack_long): Same. * gdbarch.sh: Changes to effect the following: * gdbarch.h (GDB_TARGET_IS_D10V, D10V_MAKE_DADDR, gdbarch_d10v_make_daddr_ftype, gdbarch_d10v_make_daddr, set_gdbarch_d10v_make_daddr, D10V_MAKE_IADDR, gdbarch_d10v_make_iaddr_ftype, gdbarch_d10v_make_iaddr, set_gdbarch_d10v_make_iaddr, D10V_DADDR_P, gdbarch_d10v_daddr_p_ftype, gdbarch_d10v_daddr_p, set_gdbarch_d10v_daddr_p, D10V_IADDR_P, gdbarch_d10v_iaddr_p_ftype, gdbarch_d10v_iaddr_p, set_gdbarch_d10v_iaddr_p, D10V_CONVERT_DADDR_TO_RAW, gdbarch_d10v_convert_daddr_to_raw_ftype, gdbarch_d10v_convert_daddr_to_raw, set_gdbarch_d10v_convert_daddr_to_raw, D10V_CONVERT_IADDR_TO_RAW, gdbarch_d10v_convert_iaddr_to_raw_ftype, gdbarch_d10v_convert_iaddr_to_raw, set_gdbarch_d10v_convert_iaddr_to_raw): Delete declarations. * gdbarch.c: Delete the corresponding definitions. (struct gdbarch): Delete members d10v_make_daddr, d10v_make_iaddr, d10v_daddr_p, d10v_iaddr_p, d10v_convert_daddr_to_raw, and d10v_convert_iaddr_to_raw. (startup_gdbarch): Remove initializers for the above. (verify_gdbarch, gdbarch_dump): Don't verify or dump them any more. * d10v-tdep.c (d10v_register_virtual_type): Rather that claiming the stack pointer and PC are 32 bits long (which they aren't), say that the stack pointer is an int16_t, and the program counter is a function pointer. This allows the rest of GDB to make the appropriate conversions between the code pointer format and real addresses. (d10v_register_convertible, d10v_register_convert_to_virtual, d10v_register_convert_to_raw): Delete function; no registers are convertible now, so we use generic_register_convertible_not instead. (d10v_address_to_pointer, d10v_pointer_to_address): New gdbarch methods. (d10v_push_arguments, d10v_extract_return_value): Remove special cases for code and data pointers. (d10v_gdbarch_init): Set gdbarch_ptr_bit to 16, so that GDB and the target agree on how large pointers are. Say that addresses are 32 bits long. Register the address_to_pointer and pointer_to_address conversion functions. Since no registers are convertible now, register generic_register_convertible_not as the gdbarch_register_convertible method instead of d10v_register_convertible. Remove registrations for d10v_register_convert_to_virtual, d10v_register_convert_to_raw, gdbarch_d10v_make_daddr, gdbarch_d10v_make_iaddr, gdbarch_d10v_daddr_p, gdbarch_d10v_iaddr_p, gdbarch_d10v_convert_daddr_to_raw, and gdbarch_d10v_convert_iaddr_to_raw.
2001-03-06Update/correct copyright notices.Kevin Buettner1-1/+2
2001-03-01Create new file regcache.h. Update all uses.Andrew Cagney1-0/+1
2001-02-08Add __FILE__ and __LINE__ parameter to internal_error() /Andrew Cagney1-5/+9
internal_verror().
2001-02-062001-02-06 Michael Snyder <msnyder@makita.cygnus.com>Michael Snyder1-4/+4
Submitted by Paul Hilfinger (hilfingr@gnat.com) and Andrei Petrov (and@genesyslab.com). * findvar.c: Buffers of size MAX_REGISTER_RAW_SIZE or REGISTER_BYTES must be allocated dynamically, since these are no longer constants. * infcmd.c: Ditto. * regcache.c: Ditto. * remote.c: Ditto. * sol-thread.c: Ditto. * valops.c: Ditto. * config/sparc/sun4sol2.mh (MH_CFLAGS): Add -I/usr/include/v9, as a work-around for a missing Sun header file in solaris for sparc64.
2000-07-30Protoization.Kevin Buettner1-14/+5
2000-07-102000-07-07 Michael Snyder <msnyder@cleaver.cygnus.com>Michael Snyder1-810/+5
* findvar.c (_initialize_findvar, build_findvar, write_fp, read_fp, generic_target_write_fp, generic_target_read_fp, write_sp, read_sp, generic_target_write_sp, generic_target_read_sp, write_pc, read_pc, generic_target_write_pc, generic_target_read_pc, write_pc_pid, read_pc_pid, supply_register, write_register_pid, write_register, read_register_pid, read_register, write_register_bytes, read_register_bytes, write_register_gen, read_register_gen, registers_fetched, registers_changed, find_saved_register, read_relative_register_raw_bytes, default_get_saved_register, read_relative_register_raw_bytes_for_frame, get_saved_register): Move from this file into new file regcache.c. (register_valid, registers_pid, registers): Ditto. * regcache.c: New file to hold the register cache. (register_cached): New function to read register_valid array. * value.h (register_cached): Declare. * defs.h (default_get_saved_register): Delete decl of static function. * Makefile.in: Add regcache module.
2000-06-04Add host_pointer_to_address() and address_to_host_pointer(). AddAndrew Cagney1-2/+12
signed_pointer_to_address() etc. Rename generic_pointer_to_address() to unsigned_pointer_to_address() etc.
2000-05-28PARAMS removal.Kevin Buettner1-7/+7
2000-05-242000-05-24 Michael Snyder <msnyder@seadog.cygnus.com>Michael Snyder1-18/+14
* findvar.c (value_from_register): Factor code, simplify logic.
2000-05-02Multi-arch NPC_REGNUM NNPC_REGNUM.Andrew Cagney1-4/+0
2000-04-272000-04-27 Michael Snyder <msnyder@seadog.cygnus.com>Michael Snyder1-3/+6
* jv-valprint.c (java_val_print): Add arg declaration, fix compiler warning. * corelow.c (core_open): Call set_gdbarch_from_file so that gdbarch becomes aware of the architecture encoded in the corefile. * findvar.c (write_register_gen): Export this useful interface. * value.h (write_register_gen): Declare.
2000-04-17* remote.c (REMOTE_TRANSLATE_XFER_ADDRESS), mem-break.cAndrew Cagney1-8/+0
(MEMORY_INSERT_BREAKPOINT, MEMORY_REMOVE_BREAKPOINT), target.h (BREAKPOINT_FROM_PC), valops.c (COERCE_FLOAT_TO_DOUBLE), gdbarch.sh (D10V_MAKE_DADDR, D10V_MAKE_IADDR, FRAMELESS_FUNCTION_INVOCATION, REGISTER_CONVERTIBLE, REGISTER_CONVERT_TO_VIRTUAL, REGISTER_CONVERT_TO_RAW, REGISTER_NAME), findvar.c (POINTER_TO_ADDRESS, ADDRESS_TO_POINTER): Delete default definition. Handled by gdbarch. * gdbarch.sh: Make multi-arch defaults, defaults for non- multi-arch targets. (REGISTER_NAME, COERCE_FLOAT_TO_DOUBLE, REGISTER_CONVERTIBLE, REGISTER_CONVERT_TO_VIRTUAL, REGISTER_CONVERT_TO_RAW, D10V_MAKE_DADDR, D10V_MAKE_IADDR, BREAKPOINT_FROM_PC, MEMORY_INSERT_BREAKPOINT, MEMORY_REMOVE_BREAKPOINT, REMOTE_TRANSLATE_XFER_ADDRESS, FRAMELESS_FUNCTION_INVOCATION): Provide default/legacy implementation. (REGISTER_NAMES, CALL_DUMMY): Allow legacy definition. * gdbarch.h, gdbarch.c: Re-generate.
2000-04-16* findvar.c (store_typed_address, extract_typed_address): FixJim Blandy1-2/+2
function names in error messages.
2000-04-14* gdbarch.sh (POINTER_TO_ADDRESS, ADDRESS_TO_POINTER): Two newJim Blandy1-12/+98
functions which architectures can redefine, defaulting to generic_pointer_to_address and generic_address_to_pointer. * findvar.c (extract_typed_address, store_typed_address, generic_pointer_to_address, generic_address_to_pointer): New functions. (POINTER_TO_ADDRESS, ADDRESS_TO_POINTER): Provide default definitions. (extract_address, store_address): Doc fixes. * values.c (value_as_pointer): Doc fix. (value_from_pointer): New function. * defs.h (extract_typed_address, store_typed_address): New declarations. * inferior.h (generic_address_to_pointer, generic_pointer_to_address): New declarations. * value.h (value_from_pointer): New declaration. * ax-gdb.c (const_var_ref): Use value_from_pointer, not value_from_longest. * blockframe.c (generic_push_dummy_frame): Use read_pc and read_sp, not read_register. * c-valprint.c (c_val_print): Use extract_typed_address instead of extract_address to extract vtable entries and references. * cp-valprint.c (cp_print_value_fields): Use value_from_pointer instead of value_from_longest to extract the vtable's address. * eval.c (evaluate_subexp_standard): Use value_from_pointer instead of value_from_longest to compute `this', and for doing pointer-to-member dereferencing. * findvar.c (read_register): Use extract_unsigned_integer, not extract_address. (read_var_value): Use store_typed_address instead of store_address for building label values. (locate_var_value): Use value_from_pointer instead of value_from_longest. * hppa-tdep.c (find_stub_with_shl_get): Use value_from_pointer, instead of value_from_longest, to build arguments to __d_shl_get. * printcmd.c (set_next_address): Use value_from_pointer, not value_from_longest. (x_command): Use value_from_pointer, not value_from_longest. * tracepoint.c (set_traceframe_context): Use value_from_pointer, not value_from_longest. * valarith.c (value_add, value_sub): Use value_from_pointer, not value_from_longest. * valops.c (find_function_in_inferior, value_coerce_array, value_coerce_function, value_addr, hand_function_call): Same. * value.h (COERCE_REF): Use unpack_pointer, not unpack_long. * values.c (unpack_long): Use extract_typed_address to produce addresses from pointers and references, not extract_address. (value_from_longest): Use store_typed_address instead of store_address to produce pointer and reference values.
2000-03-312000-03-29 Mark Kettenis <kettenis@gnu.org>Mark Kettenis1-8/+0
* findvar.c (extract_floating): Remove reference to TARGET_EXTRACT_FLOATING. (store_floating): Remove reference to TARGET_STORE_FLOATING.
2000-03-04Convert extract/store functions to ISO-C.Andrew Cagney1-26/+8
2000-03-02Fixes for extract_floating() and store_floating().Kevin Buettner1-13/+8
2000-02-08 Clean up compiler warnings:Jim Kingdon1-1/+1
* bcache.h, bcache.c, c-valprint.c, coffread.c, stabsread.c, stack.c, valprint.c: Change variables to unsigned. * bcache.c: Rearrange to avoid warnings about variables not being set. * c-lang.c, ch-lang.c, f-lang.c, m2-lang.c: Include valprint.h rather than declaring print_max and repeat_count_threashold ourselves (incorrectly). * valprint.h: Do declare repeat_count_threashold. * ch-exp.c: Use default case for internal error. * findvar.c: Don't omit argument type. * symtab.c: Remove unused variable.
2000-02-01import gdb-2000-01-31 snapshotJason Molenda1-0/+27
1999-12-07import gdb-1999-12-06 snapshotJason Molenda1-62/+42
1999-09-09import gdb-1999-09-08 snapshotStan Shebs1-0/+8
1999-08-09import gdb-1999-08-09 snapshotJason Molenda1-10/+12
1999-07-07import gdb-1999-07-07 post reformatJason Molenda1-104/+112
1999-06-14import gdb-1999-06-14 snapshotJason Molenda1-28/+118
1999-05-25import gdb-1999-05-25 snapshotJason Molenda1-11/+6
1999-04-26import gdb-19990422 snapshotStan Shebs1-30/+48
1999-04-16Initial creation of sourceware repositorygdb-4_18-branchpointStan Shebs1-0/+1630
1999-04-16Initial creation of sourceware repositoryStan Shebs1-1553/+0
1998-12-10CARP:Andrew Cagney1-2/+2
Rename REGISTER_NAMES{} -> REGISTER_NAME().
1998-12-091998-12-08 Philippe De Muyter <phdm@macqel.be>Jason Molenda1-80/+152
* config/xm-aix4.h (SIGWINCH_HANDLER): Function `aix_resize_window' must accept a signal number as parameter. * config/rs6000/xm-rs6000.h (SIGWINCH_HANDLER): Ditto. * utils.c (initialize_utils): Give a parameter to `SIGWINCH_HANDLER'. * inferior.h (register_valid): Variable's type is `SIGNED char', not `char'. * findvar.c (register_valid): Ditto. * defs.h (make_cleanup_func): Protect parameter list by `PARAMS'. * gdbthread.h (unbind_target_thread_vector): Likewise.
1996-04-12 * defs.h: Define TARGET_{FLOAT DOUBLE LONG_DOUBLE}_FORMATStu Grossman1-22/+6
defaults for bi-endian targets. Replace function pointers for floatformat routines with macros. No need for these to be runtime selectable. * findvar.c: Get rid of floatformat function pointers. Use macros in extract_floating and store_floating. * remote-nindy.c (nindy_fetch_registers nindy_store_registers): Use floatformat macros.
1996-04-11 * dcache.c: Add prototypes. Make many functions static.Stu Grossman1-20/+73
* (dcache_peek dcache_fetch dcache_poke): Make dcache_fetch and dcache_poke call dcache_xfer_memory directly in order to fix problems with turning off dcache. dcache_peek is now unnecessary, so it goes away. * defs.h: Define new macros HOST_{FLOAT DOUBLE LONG_DOUBLE}_FORMAT and TARGET_{FLOAT DOUBLE LONG_DOUBLE}_FORMAT to specify a pointer to a struct floatformat. This allows for better handling of targets whose floating point formats differ from the host by more than just byte order. * (floatformat_to_long_double floatformat_from_long_double): Prototypes for new functions in utils.c. * (floatformat_to_doublest floatformat_from_doublest): Prototypes for pointers to floating point conversion functions. The actual function uses either double or long double if the host supports it. * findvar.c (floatformat_to_doublest floatformat_from_doublest): Initialize to point at correct function depending on HAVE_LONG_DOUBLE. * (extract_floating store_floating): Rewrite. Now, if host fp format is the same as the target, we just do a copy. Otherwise, we call floatformat_{to from}_doublest. * remote-nindy.c (nindy_xfer_inferior_memory): Change param `write' to `should_write'. * utils.c (floatformat_to_long_double floatformat_from_long_double): New routines that implement long double versions of functions in libiberty/floatformat.c. * config/i960/tm-i960.h (TARGET_LONG_DOUBLE_FORMAT): Define this for i960 extended real (80 bit) numbers. * nindy-share/nindy.c (ninMemGet ninMemPut): Return number of bytes actually read or written.
1996-03-30 * core-aout.c (fetch_core_registers): Cast core_reg_size to intFred Fish1-6/+58
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-4/+33
* 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.
1995-08-01* configure.in: Check for working mmap, ansi headers, string.h,J.T. Conklin1-30/+144
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.