Commit Graph

7338 Commits

Author SHA1 Message Date
Jim Kingdon 40b92220c5 * remote-sim.h: New file.
* remote-sim.c: Add remote debug feature.  Rename stuff to distinguish
	interface to simulator from gdb-specific stuff.  Other changes.
start-sanitize-v9
	* remote-sp64sim.c: Renamed to remote-sim.c.
	Use sr_get_debug instead of our own sim_verbose/simif_snoop.
	Use gnutarget in call to bfd_openr.
	Rename simif_* to gdbsim_*.
	* config/sparc/sp64sim.mt: Change remote-sp64sim.c to remote-sim.c.
end-sanitize-v9
1993-09-17 17:27:43 +00:00
Peter Schauer 26a08d1529 * gdb.stabs/ecoff.mt: Remove STABSCC hack.
* gdb.stabs/weird.exp:  Handle the case where weird.o is compiled
	by mips cc and contains no stabs entries.
1993-09-17 11:51:28 +00:00
Peter Schauer 3c6c7e4456 * alpha-dis.c (print_insn_alpha), alpha-opc.h: Fix bugs, use
info->fprintf_func for printing and info->print_address_func for
	address output.
1993-09-17 11:47:59 +00:00
Peter Schauer 30d20d1545 * findvar.c (extract_signed_integer): Cast *p to LONGEST before doing
the xor and subtract.  Otherwise it will not sign extend if the type
	of LONGEST is larger than int.
	* cp-valprint.c (cp_print_class_method):  Inhibit core dump if
	domain is an undefined cross reference.
	* valops.c (call_function_by_hand):  Set real_pc to correct
1993-09-17 11:46:50 +00:00
John Gilmore 9d6323bace * hosts/{alphaosf.h, amix.h, apollo68.h, apollov68.h,
decstation.h, delta88.h, dgux.h, dose.h, go32.h, harris.h,
hp300.h, hp300bsd.h, hppabsd.h, hppahpux.h, i386aix.h, i386bsd.h,
i386linux.h, i386lynx.h, i386v.h, i386v4.h, irix3.h, irix4.h,
mipsbsd.h, ncr3000.h, rs6000.h, rtbsd.h, solaris2.h, sparc-ll.h,
std-host.h, stratus.h, sun3.h, sysv4.h, tahoe.h, ultra3.h,
vaxult.h, vaxult2.h, we32k.h}:  Make sure that "offsetof" is
defined on all hosts, now that archive.c uses it.
1993-09-17 09:14:31 +00:00
John Gilmore c5652bffcb Make sure that "offsetof" is defined on all hosts, now that archive.c uses it. 1993-09-17 09:08:00 +00:00
Jim Kingdon f8efbf2296 * config/a29k/tm-a29k.h (FRAME_CHAIN): If rsize is zero, return zero. 1993-09-17 04:54:52 +00:00
Jim Kingdon e8b114f7f4 * sym.h, symconst.h: Add comment stating these files are not part
of GDB, GAS, etc.  In 1991, when we asked rms whether we could
	include these files in GDB (although they are copyrighted by
	someone besides the FSF), he said it was OK if they were not
	considered part of GDB.
1993-09-17 03:32:10 +00:00
Jim Kingdon 23afb447a2 * stabs.texinfo (Negative Type Numbers): Re-write discussions of
names, sizes, and formats to suggest how not to lose.
1993-09-17 00:50:09 +00:00
Jim Kingdon ca0622e7e0 * remote-udi.c, remote-adapt.c, remote-mm.c: Move processor_type
to tm-a29k.h and a29k-tdep.c and make it an enum.
	* a29k-tdep.c (a29k_get_processor_type): New function.  Fix many
	aspects of how we detected the processor type.
	* remote-udi.c, remote-adapt.c, remote-mm.c (*_open): Call it
	rather than figuring out the type ourselves.
1993-09-16 23:45:46 +00:00
Rob Savoye de8c35cfdb * config/vx-gdb.exp: Use fake device to load files rather than
NFS.
	* lib/gdb.exp: New proc to do "file" command.
	* config/unix-gdb.exp: Use new "file" proc.
1993-09-16 23:27:10 +00:00
Rob Savoye 954f33cfc0 Use new proc for "file" command to load symbol tables. 1993-09-16 23:21:56 +00:00
Ian Lance Taylor e621c5cc37 * elfcode.h (elf_map_symbols): Create section symbols for all
sections, not just allocated sections; debugging sections can have
	relocs.
	(elf_symbol_from_bfd_symbol): If there is an output section, use
	the section index from that rather than the input section.
1993-09-16 22:24:33 +00:00
Stu Grossman c9de302ba5 * infrun.c (wait_for_inferior): Allow user to single step within
a stack dummy.
1993-09-16 20:18:26 +00:00
Jim Kingdon 2670a1dd47 * dbxread.c (copy_pending): Deal with END NULL.
(process_one_symbol): Add comments about what common_block NULL means.
1993-09-16 19:54:47 +00:00
Stu Grossman f2e21136eb * sparc-stub.c (_trap_low): Do restore/save sequence after
setting sp to ensure that we load the previous window from the
right place on the stack.
1993-09-16 19:16:19 +00:00
Ian Lance Taylor 1399802122 * tc.h: Declare tc_gen_reloc differently depending upong
RELOC_EXPANSION_POSSIBLE.
	* config/obj-elf.c (obj_elf_section): Only set flags when first
	creating the section.
1993-09-16 18:26:36 +00:00
Ian Lance Taylor 48d10a2545 * config/mips-gdb.exp (gdb_load): Increase timeout to 2400.
Rework board rebooting slightly.
	(gdb_exit): Don't exit from the remote shell; there isn't one.
	* gdb.stabs/weird.exp: If a program is being debugged already,
	kill it.
	* gdb.t04/setvar.exp: Stop and restart gdb.
	* gdb.t05/expr.exp: Likewise.
	* gdb.t07/watchpoint.exp: If target is mips-idt-*, stop and
	restart gdb and reload the program.
	* gdb.t08/opaque.exp: Likewise.
	* gdb.t12/scope.exp: Likewise.
	* gdb.t13/bitfields.exp: Likewise.
	* gdb.t15/funcargs.exp: Likewise.
	* gdb.t20/classes.exp: Likewise.
	* gdb.t03/ptype.exp: Increase timeout.
	* gdb.t16/printcmds.exp (test_print_string_constants,
	test_print_array_constants): Likewise.
	* gdb.t17/callfuncs.exp (do_function_calls): Likewise.
	* gdb.t20/classes.exp (do_tests): Likewise.
	* gdb.t22/virtfunc.exp (test_virtual_calls): Likewise.
1993-09-16 17:57:19 +00:00
Peter Schauer 8b15c4801a * config/mips/tm-mips.h (ECOFF_REG_TO_REGNUM): Define. 1993-09-16 07:39:41 +00:00
Peter Schauer 85999c054b * mipsread.c: Many changes for alpha ecoff format:
Correct sizeof(int) == sizeof(long) assumptions.
	Replace stParsed hack by putting the parsed types on the pending chain.
	Replace mips specific ecoff mapping by ECOFF_REG_TO_REGNUM macro,
	provide default for cross debugging.
	Swapping the symbol back is no longer needed as the symbol is not
	modified anymore.
	Add new alpha basic types, handle btTypedef, handle stStaticProc
	external symbols .
	Update and clean up cross_ref for alpha cc cross ref variations.
	Allocate types on the type_obstack to inhibit storage leaks.
	* config/mips/tm-mips.h (ECOFF_REG_TO_REGNUM):  Define.
	* gdbtypes.c (recursive_dump_type):  Dump TYPE_TAG_NAME if it is set.
1993-09-16 07:38:42 +00:00
Ian Lance Taylor 8cced93dd7 Change wierd to weird 1993-09-15 22:17:29 +00:00
Ian Lance Taylor 0542a638d7 * libbfd.h (COERCExx): Cast x to bfd_signed_vma before doing the
xor and subtract.  Otherwise it will not sign extend if the type
	of bfd_vma is larger than int.
1993-09-15 20:57:47 +00:00
Jim Kingdon 3283eab366 * remote-utils.[ch]: new files of functions collected from several
different remote targets.
1993-09-15 20:20:23 +00:00
Jim Kingdon f424845a95 * gdb.t13/bitfields.exp: Test for bad output rather than waiting
for timeout.  Add "known gcc 2.4.5 bug" to failure message.
1993-09-15 17:39:33 +00:00
Jim Kingdon ddf5d7e82e * paread.c, coffread.c, elfread.c, dwarfread.c:
Include <time.h> and <sys/types.h> before libbfd.h.
1993-09-15 16:45:44 +00:00
Ian Lance Taylor 2fbb0a713c * ecoffswap.h (ecoff_swap_pdr_in): Get regoffset, iopt, fregoffset
and frameoffset as signed numbers.  From Peter Schauer.
1993-09-15 15:58:11 +00:00
David D. Zuhn 03abfb2cbc fix replacement of multiline values for CC and CXX 1993-09-15 02:11:35 +00:00
Jim Kingdon 06f63f95db * gdb.stabs/wierd.exp (print_wierd_var): Test size, not type name.
(do_tests): Remove xfail for whatis on one_var and two_var.
1993-09-15 00:47:45 +00:00
Jim Kingdon 5ed0ccafca * stabsread.c (read_type): Process "s" (size) type attribute.
If type is defined to another type, copy the type.
1993-09-15 00:46:55 +00:00
Jim Kingdon 791e451394 * paread.c, coffread.c, elfread.c, dwarfread.c:
Include <time.h> before libbfd.h.
1993-09-14 23:26:43 +00:00
Ian Lance Taylor aa8fe9070c * config/i386/i386v4.mh (NATDEPFILES): Move exec.o from here...
* config/i386/i386v4.mt (TDEPFILES): ...to here.
1993-09-14 22:41:49 +00:00
Ian Lance Taylor 207f85b54b * elf32-i386.c (elf_howto_table): Add bfd_elf_generic_reloc
special function for all reloc entries.
	* elf32-target.h (TARGET_LITTLE_SYM): Add SEC_CODE to
	section_flags.
	* libelf.h (elf_symbol_type): Remove desc, type and other fields.
	* Makefile.in (elf32-*.o): These depend upon elf32-target.h.
1993-09-14 22:29:26 +00:00
Ian Lance Taylor 90397ff823 * config/obj-elf.c (obj_elf_data, obj_elf_text): New functions;
set previous_section and previous_subsection and then call s_data
	and s_text, respectively.
	(obj_pseudo_table): Add data and text.
	(obj_elf_section): Add SEC_LOAD to default initialization of
	flags.  Treat .rodata1 like .rodata.  Set SEC_LOAD as well as
	SEC_ALLOC for "alloc" string.  Don't bother trying to find the
	section; just use subseg_new.
1993-09-14 22:28:22 +00:00
Steve Chamberlain a6f5fcd8c2 Tue Sep 14 14:34:45 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
* libbfd-in.h (struct artdata):  Add armap_timestamp and
 	armap_datepos here too.
1993-09-14 21:39:33 +00:00
K. Richard Pixley b70b042d02 fix serial.h inclusion 1993-09-14 20:08:23 +00:00
K. Richard Pixley a94abe5bb7 use remote-utils facilities for baud_rate 1993-09-14 19:34:15 +00:00
Jim Kingdon fc77365385 * paread.c, coffread.c, elfread.c: Include <time.h> before libbfd.h. 1993-09-14 18:10:42 +00:00
Ian Lance Taylor 4f0bccc7d8 Some more gcc lint, and:
* read.c (change_to_section): Removed.  This is now done by
	subseg_new.
	(get_stab_string_offset): Rearranged somewhat.  Create the section
	using subseg_new.  Store the string index in seg_info, rather than
	in a static variable.  Force the first string to be empty.  Use
	frag_more rather than FRAG_APPEND_1_CHAR.
	(s_stab_generic): Rewrote.
	* subsegs.h (segment_info_type): Added stabu union.
	* subsegs.c (subseg_new): Initialize stab_string_size to 0.
	* config/obj-aout.c: Don't include aout/stab_gnu.h.
	(obj_aout_stab, obj_aout_desc): Removed.
	(obj_pseudo_table): Removed desc and stabX entries.
	* config/obj-bout.c: Same changes as config/obj-aout.c.
	* config/obj-bout.h (S_SET_TYPE): Define.
	(tc_bout_fix_to_chars): Declare.
	* config/obj-coff.c (obj_coff_stab): Removed.
	(obj_pseudo_table): Removed desc and stabX entries.
	* config/obj-coff.h (SEPARATE_STAB_SECTIONS): Define.
	* config/obj-coffbfd.c (current_stab_symbol): Removed.
	* config/obj-coffbfd.h (obj_symbol_type): Removed n_strx, n_type,
	n_other, n_desc and n_value fields.
	(S_{S,G}ET_{OFFSET,OTHER,TYPE,DESC}): Removed.
	(MAKE_STAB_SYMBOL): Removed.
	* config/obj-ecoff.c (obj_ecoff_stab): Renamed to ecoff_stab.
	Changed arguments and removed parsing code.
	(obj_pseudo_table): Removed stabX entries.
	* config/obj-ecoff.h (ecoff_stab): Declare.
	(OBJ_PROCESS_STAB): Define.
	* config/obj-elf.c: Don't include aout/stab_gnu.h.
	(obj_elf_stab, obj_elf_xstab, obj_elf_desc,
	elf_stab_symbol_string, elf_stab_symbol, obj_elf_stab_generic):
	Removed.
	(obj_pseudo_table): Removed desc, stabX and xstabs entries.
	(obj_elf_version): Use subseg_new, not bfd_make_section.  Don't
	set SEC_LOAD for .note section.
	(adjust_stab_sections): Get frag pointer from seg_info, rather
	than looking through frags.
	* config/obj-elf.h (S_{S,G}ET_{OTHER,TYPE,DESC}): Removed.
	(SEPARATE_STAB_SECTIONS, INIT_STAB_SECTION, OBJ_PROCESS_STAB):
	Define.
	* config/obj-vms.c (obj_aout_stab): Removed.
	(obj_pseudo_table): Removed stabX entries.
	* config/obj-vms.h (S_SET_TYPE): Define.
1993-09-14 17:58:35 +00:00
Jim Kingdon 1225fcbd24 * paread.c: Include <time.h> before libbfd.h.
* paread.c: Define BYTES_IN_WORD before including aout/aout64.h.
1993-09-14 17:32:45 +00:00
Jim Kingdon 899931b638 * Makefile.in (a29k-tdep.o): Depend on $(defs_h).
* config/a29k/tm-a29k.h (SAVED_PC_AFTER_CALL): Use gr122 not lr0
	if this	is a transparent procedure.
1993-09-14 16:22:07 +00:00
Jim Kingdon f8f6b2c755 * remote-udi.c (udi_wait): Return inferior_pid not 0. 1993-09-14 16:19:30 +00:00
John Gilmore cb4acadb8c Avoid minor warning in archive.c change. 1993-09-14 04:19:40 +00:00
John Gilmore f26a0e9bcf * hosts/std-host.h (offsetof): Define, if not already, for archive.c. 1993-09-14 04:15:23 +00:00
John Gilmore b5b4294e65 Improve timestamp support in BSD archive files to avoid linker
warnings.

* libbfd.h (struct artdata):  Add armap_timestamp and armap_datepos.
(bfd_flush, bfd_stat):  Add prototypes.
* libbfd.c (bfd_flush):  Add, does fflush on a BFD.
(bfd_stat):  Add, does fstat on a BFD.

* archive.c (_bfd_write_archive_contents): At end of file writing,
verify and possibly update the timestamp in the armap, if a BSD
archive.  FIXME!  Kludge recognizes BSD archive, rather than
vectoring properly.  Should add to xvec.
(compute_and_write_armap):  Move prototype to top, avoid PROTO.
(bsd_write_armap): Save timestamp and file location thereof, when
writing the armap in a BSD file.
(bsd_update_armap_timestamp):  New function to check and
rewrite the timestamp.
1993-09-14 04:13:43 +00:00
Jim Kingdon 55fea07b55 * remote.c: Define remote_debug to 0 and #if 0 baud_rate. Temporary
hack so this file compiles again.

	* remote-utils.c (gr_multi_scan): Cast return value from alloca.
	(gr_multi_scan): #if 0 never-reached return(-1).
1993-09-14 01:08:22 +00:00
Jim Kingdon 02ff0cd370 add comment 1993-09-13 23:06:17 +00:00
Jim Kingdon 66eca5ee10 add som.c and som.h 1993-09-13 22:51:51 +00:00
K. Richard Pixley c6f494e8be collect some remote things into remote-utils 1993-09-13 22:12:16 +00:00
Ian Lance Taylor 604633aeca * subsegs.c: Renamed non-BFD_ASSEMBLER subseg_new to subseg_set.
Wrote non-BFD_ASSEMBLER subseg_new.  Now subseg_new always takes a
	section name, and subseg_set always takes a segT.  Changed all
	callers as appropriate.
	* config/obj-coffbfd.c 	(change_to_section): Renamed to
	obj_coff_add_segment.  Corrected.  Made callers use subseg_new.
	* config/obj-coffbfd.h (obj_segment_name, obj_add_segment):
	Define.

Also some more gcc warning removal.
1993-09-13 21:32:07 +00:00
Jim Kingdon 37c99ddb4e * inferior.h, infrun.c, thread.c, infcmd.c: Remove all uses of
pc_changed.  If it was ever set to a non-zero value, it was before
	GDB 2.8.  It doesn't seem to have any useful function.
1993-09-13 20:54:00 +00:00