Commit Graph

3184 Commits

Author SHA1 Message Date
Fred Fish 2dd30c722b * defs.h: Delete extraneous whitespace at end of file.
* symfile.h: Move #include of demangle.h outside conditional.
	* objfiles.h (struct objstats, OBJSTAT, OBJSTATS): New struct
	and macros to hold per-objfile statistics for internal instrumentation.
	(struct objfile): Add OBJSTATS member, which is optional.
	* buildsym.h (next_symbol_text_func): Now takes objfile argument.
	Also update copyright to 1995.
	* dbxread.c (dbx_next_symbol_text): Now takes objfile argument.
	(dbx_symfile_init, coffstab_build_psymtabs, elfstab_build_psymtabs,
	stabsect_build_psymtabs): Accumulate string table size.
	(dbx_next_symbol_text, read_dbx_symtab, read_ofile_symtab):
	Accumulate number of stabs symbols read.
	* dwarfread.c (new_symbol, symthesize_typedef):
	Accumulate number of full symbols created.
	* gdbtypes.c (alloc_type): Accumulate number of types.
	* maint.c (maintenance_print_statistics): New function.
	* mdebugread.c (mdebug_next_symbol_text): Now takes objfile argument.
	* minsyms.c (prim_record_minimal_symbol_and_info): Accumulate
	number of minimal symbols read.
	* os9kread.c (read_os9k_psymtab): next_symbol_text takes objfile arg.
	* partial-stab.h: next_symbol_text takes objfile arg.
	* stabsread.c (error_type, STABS_CONTINUE): Now takes objfile arg and
 	uses it to call next_symbol_text.
	* symfile.c (add_psymbol_to_list, add_psymbol_addr_to_list):
	Accumulate number of partial symbols created.
	* symfile.h (ADD_PSYMBOL_VT_TO_LIST): Accumulate number of partial
	symbols created.
	* symmisc.c (print_objfile_statistics): Print the per-objfile
	internal instrumentation statistics gathered.
	* xcoffread.c (xcoff_next_symbol_text): Now takes objfile argument.
1995-12-21 04:08:27 +00:00
Raymond Jou 1c1a6a1e3d * mpw-make.sed: Add quotes to RIncludes reference. 1995-12-15 20:31:58 +00:00
Rob Savoye 1e11d889d0 * remote-array.c: Remove bogus setting of baudrate to 4800. Their
hardware has real UARTS now.
1995-12-15 20:20:33 +00:00
Stan Shebs c148ab3c6d * configure.in (powerpc-*-macos*): New target configuration.
* configure: Update.
	* config/powerpc/macos.mh, config/powerpc/macos.mt,
 	config/powerpc/nm-macos.h, config/powerpc/tm-macos.h, mac-nat.c:
 	New files, native PowerMac debugging support.
	* Makefile.in (mac-nat.o): Add build rule.
	* mpw-config.in (enable_cflags): Add support.
	(m68k-apple-macos, powerpc-apple-macos): Fix natdepfiles to
	list object file instead of source file.
	* mpw-make.sed (@ENABLE_CFLAGS@): Don't edit out, replace with
	value of variable.
	(install, install-only): Edit MPW-specific installation into
	place of Unix shell code.
	* mac-gdb.r: Fix version resources to use symbolic version strings.
	(cfrg): New resource, code fragment for PowerMac.
1995-12-12 02:35:27 +00:00
Fred Fish 1f43e1dd51 * dbxread.c (process_one_symbol): When looking at the next
minimal symbol, check for end of the minimal symbol array
 	(symbol with NULL pointer for name) before dereferencing it.
Fixes PR 8644
1995-12-12 01:58:31 +00:00
Per Bothner 339038710b * eval.c (evaluate_struct_tuple): Fix thinko.
This fixes PR 8643.
1995-12-12 00:51:21 +00:00
Wilfried Moser 8104c47b5a * ch-typeprint.c (chill_type_print_base): Slightly change of printing
of variant structures.
1995-12-11 14:54:50 +00:00
Per Bothner f6d165855e * valops.c (value_cast): Handle casts to and from TYPE_CODE_CHAR.
* ch-exp.c (match_integer_literal):  Fix long long support.
	* gdbtypes.c (get_discrete_bounds):  Make TYPE_LENGTH (type) ==
	sizeof (LONGEST) case work OK.
1995-12-11 09:02:26 +00:00
Fred Fish f309ad9590 * coffread.c, dbxread.c, dstread.c, objfiles.c, os9kread.c,
symfile.c, symtab.c:  Use "obstack.h" rather than <obstack.h>.
1995-12-09 05:12:46 +00:00
Stu Grossman 4c5bc9f44c * remote-mips.c (mips_receive_header): Allow mips_syn_garbage to be
user-settable (via set syn-garbage-limit).  Setting it to -1 makes
	it unlimited.
1995-12-07 00:21:51 +00:00
Brendan Kehoe e045712fa8 * gdbtypes.c (check_stub_method): Make sure we get back a function
string in the demangled name before we try to use it.

fixes gdb/8306 (Mentor, ser/med)
1995-12-06 02:34:53 +00:00
Stu Grossman 67e218392f * monitor.c (monitor_expect_regexp): Make static, add prototype.
* (monitor_read_memory_single):  Call monitor_expect_regexp with
	pointer to getmem_resp_delim_pattern, not entire struct.
1995-12-06 02:13:00 +00:00
Stan Shebs faa077a592 * c-lang.h (c_op_print_tab): Don't declare, some compilers
consider illegal if structure not defined, and only used
	in c-lang.c anyway.
1995-12-06 01:33:49 +00:00
Per Bothner a56c9325ec * eval.c (evaluate_subexp_standard case): Fix typo. 1995-12-03 20:32:55 +00:00
Jeff Law f9384420ae * ch-exp.c (parse_named_record_element): Avoid aggregrate
initializations for automatic variables.

        * hppa-tdep.c (hppa_alignof): Fix typo in last change.

Fixes minor build problems.
1995-12-03 19:59:21 +00:00
Fred Fish dee7a11cd2 * symfile.c (global_psymbols, static_psymbols): Remove, unused. 1995-12-03 03:34:55 +00:00
Peter Schauer 82a38509d8 * alpha-tdep.c (heuristic_proc_desc): Add heuristic to
determine the return address register, needed for OSF/1-3.2C.
	* config/alpha/tm-alpha.h (T7_REGNUM, T9_REGNUM):  Define.
1995-12-02 11:08:20 +00:00
Michael Meissner 98a2c9d2ea Fix typo; some progress in ppcbug support 1995-12-02 01:14:06 +00:00
Michael Meissner 59c8431852 fix typo 1995-12-01 12:21:03 +00:00
Per Bothner a366d882c0 * language.c (lang_bool_type), language.h: New function.
* language.h (LA_BOOL_TYPE):  New macro.
	* eval.c (evaluate_subexp_standard)  Use LA_BOOL_TYPE instead
	of builtin_type_int where appropriate,
	* valarith.c (value_subscript):  Likewise.
1995-12-01 08:08:41 +00:00
Per Bothner 5f3e7bfcbf * valops.c (value_slice): Implement (value) bitstring slices.
* valprint.c (val_print):  If TYPE_LENGTH is zero, don't automatically
	print "<incomplete type>" - Chill has zero-length (string) types.
1995-12-01 08:06:45 +00:00
Per Bothner c8b2ba5d48 * gdbtypes.c (check_stub_type): Removed; no longes needed.
* ch-exp.c (expect, parse_call):  Tweak error messages.
1995-12-01 08:04:51 +00:00
Per Bothner 5e54886116 * ch-exp.y: Replaced by ...
* 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-11-30 03:26:34 +00:00
Per Bothner dcdba37e2d * scm-valprint.c (scm_isymnames): Remove "#@" prefix.
(scm_scmval_print):  Do not print "#@" prefix.
	* mdebugread.c:  Add check_typedef/CHECK_TYPEDEF as needed.
1995-11-30 03:10:59 +00:00
Per Bothner bcbf388e99 * f-typeprint.c, valarith.c, valprint.c, typeprint.c, eval.c:
Add check_typedef/CHECK_TYPEDEF as needed.
	* f-typeprint.c:  Various cleaning up.
	* valarith.c (value_subscript):  Also subscript bitstrings (for Chill).
	* typeprint.c (print_type_scalar):  Also support TYPE_CODE_RANGE.
	* eval.c (evaluate_subexp_standard case OP_ARRAY):  Implement
	support for labelled array tuples and ranges in powerset tuples.
	(init_array_element):  New function.
1995-11-30 02:32:29 +00:00
Per Bothner 940d596798 * alpha-tdep.c, c-exp.y, h8500-tdep.c, f-exp.y, f-valprint.c,
findvar.c, hppa-tdep.c, infcmd.c, language.c, printcmd.c,
 	rs6000-tdep.c, symmisc.c, symtab.c:
	Add check_typedef/CHECK_TYPEDEF as needed.
1995-11-30 01:43:37 +00:00
Per Bothner d1f4065e64 * gdbtypes.h (enum type_code): Added TYPE_CODE_TYPEDEF.
(check_typedef):  New prototype.
	(CHECK_TYPEDEF):  New macro.
	(TYPE_DUMMY_RANGE):  Removed.
	* gdbtypes.c (get_discrete_bounds):  Fix paren error; make more robust.
	(create_array_type):  Don't force_to_range_type;  users of the
	array are responsible for handling non-range index types.
	(create_set_type):  Likewise.
	(force_to_range_type):  Removed.
	(check_typedef):  New function handles stub types and typedefs.
	(check_stub_type):  Just call check_typedef. (To be removed.)
	(recursive_dump_type):  Handle TYPE_CODE_TYPEDEF.
	* ch-lang.c (type_lower_upper):  Use get_discrete_bounds.
	(evaluate_subexp_chill):  Handle string repetition.
	Re-arrange to handle EVAL_AVOID_SIDE_EFFECTS better.
	* ch-typeprint.c (chill_type_print_base):  Handle TYPE_CODE_TYPEDEF.
	Pass show=0 in recursive calls various places.
	(case TYPE_CODE_ARRAY):  Don't require index type to have
	TYPE_CODE_RANGE.
	(case TYPE_CODE_RANGE):  Don't need to support TYPE_DUMMY_RANGE.
	* gdbtypes.c, ch-lang.c, ch-typeprint.c (numerous places):
	Add check_typedef/CHECK_TYPEDEF as needed.
1995-11-30 01:07:28 +00:00
Per Bothner f2ed3a80bb * top.c (command_line_input): Only strip out an initial #-comment.
Looking for internal comments is language-specific (breaks Scheme).
1995-11-29 23:22:32 +00:00
Per Bothner badefd2800 * expression.h (enum exp_opcode): Add BINOP_RANGE.
* expprint.c (dump_expression):  Support BINOP_RANGE.
	* eval.c (evaluate_subexp_standard):  Handle BINOP_RANGE (as error).
	(case MULTI_SUBSCRIPT):  Fix broken f77 value->int ad hoc conversion.
	* ch-lang.c (chill_op_print_tab):  Support BINOP_RANGE.
	(evaluate_subexp_chill):  Error on BINOP_COMMA.
1995-11-29 22:59:31 +00:00
Per Bothner d9f12910a4 * Makefile.in: Clean up so doc stuff stays in doc sub-dir. 1995-11-29 22:00:41 +00:00
Michael Meissner b9ab37f0a8 Make debugging remote gdb friendlier 1995-11-29 21:41:21 +00:00
David Edelsohn bbc6c9c129 Fix typo. 1995-11-29 03:36:46 +00:00
David Edelsohn 9c0bc1daf9 * Makefile.in (target_subdir): Define.
(CC_FOR_TARGET, CXX_FOR_TARGET): Use it to find target libraries.
	* configure.in (X_CFLAGS): Fix typo.
	(target_subdir): Set to "${target_alias}/" if cross.
	* configure.in: Regenerated.
1995-11-29 03:34:57 +00:00
David Edelsohn 4588619966 * dbxread.c (dbx_symfile_read): Set block_address_function_relative
for `pe' format files.
1995-11-28 23:45:17 +00:00
Fred Fish bfe8f51619 * magic.h: Renamed to gmagic.h to avoid <magic.h> conflict.
* magic.c:  Renamed to gmagic.c in sympathy.
	* eval.c, gmagic.c, config/tm-magic.h:
 	Include "gmagic.h" rather than "magic.h".
1995-11-28 19:33:22 +00:00
Peter Schauer 9b041f69fc * mdebugread.c (handle_psymbol_enumerators, parse_symbol):
Recognize enums from alpha cc -migrate.
	(upgrade_type):  Pass correct fd to parse_symbol when parsing
	the index type of an array.
	(parse_procedure, parse_lines, psymtab_to_symtab_1):  Handle
	unsorted procedure descriptors from Irix 5.x and Alpha OSF/1-3.x
	shared libraries. Use CORE_ADDR instead of `unsigned long' in
	procedure descriptor address computations.

	* symtab.c (decode_line_1):  Prevent accidental strchr match
	of a null character with the terminating null character of
	gdb_completer_quote_characters.
	(cplusplus_hint):  Make sure that only a single quote is printed
	in the hint message.
1995-11-25 11:32:18 +00:00
Jeff Law 05ee0201d1 * top.c (recurse_read_control_structure): Don't make cleanups
here.  Callers handle that correctly.
Fixes 6794.
1995-11-24 23:21:38 +00:00
Fred Fish 255764a946 * config/m68k/xm-hp300hpux.h: Define MMAP_BASE_ADDRESS and MMAP_INCREMENT.
Also force HAVE_MMAP to be defined since autoconf is currently broken
	for detecting a working mmap under hpux.
	* config/pa/xm-hppah.h (MMAP_BASE_ADDRESS): Tweak MMAP_BASE_ADDRESS
	to a better value suggested by Jeffrey A Law (law@cygnus.com).
1995-11-22 04:26:03 +00:00
Fred Fish 9c38648171 * objfiles.c (map_to_address): Have gdb print a warning when it
is compiled with HAVE_MMAP but without both MMAP_BASE_ADDRESS and
 	MMAP_INCREMENT defined (thus making it appear mmap doesn't work).
1995-11-21 18:19:23 +00:00
Stu Grossman 78570d35b6 * infrun.c (wait_for_inferior): Add support for dynamic function
trampolines.  These are pieces of code between the caller and the
	callee that figure out the address of the callee's code at run
	time.  Upon entry, we can't figure out the callee's address, so we
	set a breakpoint within the trampoline where the address will be
	known, and continue the target.  Once we hit the breakpoint, we
	break at the callee's address and proceed as usual.
start-sanitize-gm
	* config/tm-magic.h:  Define DYNAMIC_TRAMPOLINE_NEXTPC.  Turn off
	IN_SOLIB_CALL_TRAMPOLINE and IN_SOLIB_RETURN_TRAMPOLINE.
end-sanitize-gm
1995-11-20 22:40:34 +00:00
Fred Fish e7b6403a67 * objfiles.c (allocate_objfile): Change warning message about mapped
symbol tables so that it is obvious that they are not supported on
	this particular machine rather than implying they are not supported
	at all in this version of gdb.
1995-11-20 19:22:40 +00:00
Peter Schauer e701f52174 * stack.c (print_frame_info): Use minimal symbol only if
fi->pc is in a known section.
1995-11-20 09:01:52 +00:00
Peter Schauer f2ebb24d94 * irix5-nat.c, osfsolib.c (solib_address): Return the name of the
containing solib.
1995-11-19 13:31:52 +00:00
Fred Fish d0e0eca26e * solib.c (solib_address): Return the name of the containing solib.
* solib.h (PC_SOLIB): New macro; define using solib_address.
	* stack.c (print_frame_info) [PC_SOLIB]: If no function name, try
	PC_SOLIB on the PC value.
1995-11-19 07:16:03 +00:00
Stan Shebs 21ef3a298e * utils.c: Don't include sys/ioctl.h etc if MPW is host. 1995-11-16 01:24:25 +00:00
David Edelsohn d7cde714c1 * config/arm/tm-arm.h (ADDITIONAL_REGISTER_NAMES): Fix r5.
(FRAME_SAVED_PC): Minor clean up.
1995-11-15 20:18:00 +00:00
Stu Grossman 5c8ba01776 * monitor.c (monitor_load_srec monitor_make_srec): Move all
S-record download code into srec.c.
	* srec.c srec.h:  New files.  Contain S-record loading routines
	formerly in monitor.c.
	* serial.c serial.h:  New routine just like fprintf, but uses
	serial_t instead of FILE *.
	* sh-tdep.c (frame_find_saved_regs init_extra_frame_info):
	Don't add four to saved pc (makes things match manual).  Also, fix
	bug where we didn't get pc from stack frame correctly.
	* config/sh/tm-sh.h (SAVED_PC_AFTER_CALL):  Don't add four to
	saved pc.  Real hardware does this for you.
	* sh3-rom.c (sh3_load):  New routine.  Sets up for download then
	calls generic S-record loader.
	* config/h8300/h8300.mt, config/h8500/h8500.mt,
	config/m68k/monitor.mt, config/pa/hppapro.mt, config/sh/sh.mt:
	Add srec.o to TDEPFILES.
1995-11-14 23:24:10 +00:00
Michael Meissner 855bfb535f Add preliminary ppcbug support. 1995-11-14 21:17:20 +00:00
Jeff Law 3306c363e3 * partial-stab.h: Remove GDB_TARGET_IS_HPPA kludge.
gcc-2.7.0 and gdb-4.15 have been released, so some old crud can
disappear.  Yippie!
1995-11-13 20:15:42 +00:00
Michael Meissner 3c0bf315f5 Enable powerpc simulator for all powerpc-eabi targets, not just powerpc-eabisim if compiling with GCC. Add --enable-sim-powerpc option to control this. 1995-11-09 22:41:34 +00:00