Commit Graph

175 Commits

Author SHA1 Message Date
Andrew Cagney b7432f0f27 Pacify GCC -Wall 1997-10-21 07:41:46 +00:00
Andrew Cagney e2f8ffb736 Delete profile support from MIPS simulator, use sim/common/sim-profile
module instead.
Generate a "gmon.out" (gprof) when profiling the target PC.
Add target PC profiling option --profile-pc-granularity (bucket size)
1997-10-21 03:41:21 +00:00
Andrew Cagney 293a0876f8 Have single bit macros return an unsigned result. Avoids risk (and
need) of sign extending results.
1997-10-20 07:27:55 +00:00
Andrew Cagney 0a0ecb2120 Add 8 bit arithmetic to sim-alu.
Fix flags (Carry, oVerflow) for negate and subtract.
Add ALU*_RESULT macros for accessing final result of ALU op.
1997-10-20 02:03:06 +00:00
Andrew Cagney fd89abc204 Handle core regions which start at a poorly aligned address. 1997-10-14 23:45:52 +00:00
Andrew Cagney 7456a10d9b * sim-alu.h (ALU64_HAD_OVERFLOW): Define.
(ALU64_SUB): Define.
* Make-common.in (all): Build SIM_EXTRA_ALL first.
(.gdbinit): Remove dependencies, generate once per build.
1997-10-14 09:39:05 +00:00
Andrew Cagney 1b217de0f3 Correct type of address argument for sim_core_{read,write} 1997-10-14 09:24:57 +00:00
Andrew Cagney 63fe2cc799 Fix typo, WITH_TARGET_WORD_BITSIZE not WITH_TARGET_BITSIZE. 1997-10-02 23:37:30 +00:00
Stu Grossman 68f92f98ac * sim-break.c (sim_set_breakpoint sim_clear_breakpoint): Use ZALLOC
and zfree instead of xmalloc and free.  Prevents warnings.
1997-09-25 18:22:46 +00:00
Andrew Cagney af51b8d56d Add/use SIM_AC_OPTION_BITSIZE. 1997-09-25 07:19:05 +00:00
Stu Grossman b9d580a4b0 * Make-common.in: New files sim-break.c, sim-break.h.
* sim-base.h:  Add point to breakpoint list to sim_state_base.
	* sim-break.c sim-break.h:  New modules that implement intrinsic
	breakpoint support.
	* sim-module.c:  Add breakpoint module.
1997-09-25 00:51:17 +00:00
Felix Lee 34d07b7867 * sim-events.c (SIM_EVENTS_POLL_RATE): poll more often than once
an hour.
        * sim-n-core.h (WITH_XOR_ENDIAN): MSVC barfs on
        if (0) { 1 % 0; }
        * sim-core.c (sim_core_xor_write_buffer): WITH_XOR_ENDIAN + 1.
        (SIGBUS) define for Windows.
        * sim-trace.c (trace_printf,debug_printf): added ALMOST_STDC.
        * sim-resume.c: define SIGTRAP for windows.
        * sim-xcat.h: use token pasting if ALMOST_STDC.
1997-09-23 18:08:09 +00:00
Andrew Cagney 4141b1c63d * Make-common.in (SIM_SCACHE, SIM_DEFAULT_MODEL): Assign configured values.
(CONFIG_CFLAGS): Add same.
1997-09-23 04:05:50 +00:00
Felix Lee 9f4fd82344 * sim-types.h (SIGNED64): ##i64 when _MSC_VER, not _WIN32.
(SIGNED32): use ##i32.
1997-09-23 03:51:33 +00:00
Andrew Cagney 92f91d1ff0 Remove need to update <targ>/Makefile.in when adding optional options
to <targ>/configure.in.
Simplify logic used to select target [default] endianness.
1997-09-23 01:25:26 +00:00
Andrew Cagney 8d332f9c1a Enable --alignment option, stop sim-options.c hardwiring the alignment. 1997-09-22 09:34:28 +00:00
Andrew Cagney 4ca7d6d25b Fix disabling of model code when simulator does not support modeling.
Stops `-p' crashing simulators.
1997-09-22 09:16:14 +00:00
Andrew Cagney 794e9ac96a Simplify logic behind the generic configuration option --enable-sim-alignment. 1997-09-22 02:49:57 +00:00
Andrew Cagney b45caf050c Add support for --enable-sim-alignment to simulator common aclocal.m4
Add support for --alignment={strict,nonstrict,forced} to simulator common
run-time options.
For v850 use, make the default NONSTRICT_ALIGNMENT.
1997-09-22 00:24:46 +00:00
Andrew Cagney 175c6fd375 * sim-events.c (ETRACE): Use trace_printf not sim_io_printf for
trace output.
* sim-core.c (sim_core_signal): When bad access halt simulator
SIGSEGV / SIGBUS instead of aborting.
(signal.h): Include.
* sim-watch.c (sim_watchpoint_install): Handler for watchpoint
options was missing.
1997-09-17 08:13:07 +00:00
Andrew Cagney dfa5c0ca02 Define MOVED macro, move sub-bitfield from XXX to YYY. 1997-09-17 05:28:32 +00:00
Andrew Cagney b52e58c24f Add/test 8bit bit manipuation macros.
Test LS and MS versions of SEXT macro.
Simplify/test macro returning a single bit.
1997-09-17 03:25:54 +00:00
Andrew Cagney aa5e6a5a78 Add {LS,MS}SEXT and {LS,MS}INSERTED macros. Eliminates bug in SEXT. 1997-09-16 07:04:46 +00:00
Andrew Cagney 08547b1f1d Determine ARCHITECTURE from program if possible.
Rename common's generated config.h to cconfig.h.
1997-09-15 08:11:50 +00:00
Andrew Cagney 4bdab45adb * callback.c (os_write): divert stdout and stderr to their
respective hooks.
1997-09-15 08:02:23 +00:00
Andrew Cagney 93e7a1b5b7 Add profiling support to v850*. 1997-09-12 02:44:03 +00:00
Andrew Cagney cad7297e80 o Wordwrap usage messages from sim-options
o	Clarify how to use alias options
o	use in sim-watch (better usage message)
o	Don't pass something on the stack into the
	watch-point interrupt hander.
1997-09-10 22:47:12 +00:00
Andrew Cagney d0b59aa593 Add option architecture-info to list supported architectures. 1997-09-10 05:16:34 +00:00
Felix Lee 31dda65aff * sim-core.h (sim_cpu_core): [WITH_XOR_ENDIAN + 1], to avoid
illegal zero-sized array.
	* sim-core.c (sim_core_xor_read_buffer): same.
1997-09-10 04:46:37 +00:00
David Edelsohn 7b4aeebabe * nltvals.def: Regenerate. 1997-09-09 18:20:57 +00:00
Andrew Cagney 75b3697d5f Add/use LSEXTRACTED, MSEXTRACTED macros.
Add CPU_CIA macro to extract the PC.
1997-09-08 17:21:13 +00:00
Andrew Cagney 1bba340afe Redo watchpoint code so that it target can specify interrupt names.
Replace v850 interrupt code with this common watchpoint code.
Other minor fixes to core.
1997-09-05 08:16:23 +00:00
Andrew Cagney 1b465b54e1 Add sim_do_commandf - printf version of sim_do_command. 1997-09-05 07:57:27 +00:00
Andrew Cagney 30efae3acd Define SIGNED64 and UNSIGNED64 macros - handle MSC/GCC LL issue. 1997-09-05 00:30:38 +00:00
Andrew Cagney 6dbaff8f60 Finish implementation of sim-memopt.
Use in d30v and tic80.
Make available a generic sim_read, sim_write implementation.
1997-09-04 10:08:44 +00:00
Andrew Cagney a34abff813 o Add modulo argument to sim_core_attach
o	Add sim-memopt module - memory option processing.
1997-09-04 03:47:39 +00:00
David Edelsohn 600d83316c * sim-hload.c (sim_load): Add assert for SIM_MAGIC_NUMBER. 1997-09-04 00:57:21 +00:00
David Edelsohn 88d5f8e854 * gdbinit.in: New file.
* aclocal.m4 (SIM_AC_OUTPUT): Build .gdbinit.
	* Make-common.in (distclean): Delete .gdbinit.
	(.gdbinit): Add rule for.
	* configure: Regenerated to track ../common/aclocal.m4 changes.
1997-09-04 00:49:57 +00:00
Andrew Cagney fdd64f952d Add support for suspending/resumeing the simulator in sim-modules.
Use in sim-events.
1997-09-03 07:26:11 +00:00
Andrew Cagney 80c651f02d Stanify error reporting memory overlaps. 1997-09-03 04:06:27 +00:00
David Edelsohn 645ab3ec42 (TAGS): Add support for "/* TAGS: foo */" marker. 1997-09-02 22:03:41 +00:00
David Edelsohn 74db699d1d * Makefile.in (TAGS): Add support for "/* TAGS: foo */" marker.
* sim-n-bits.h: Add TAGS comments for all functions.
	* sim-n-core.h: Likewise.
	* sim-n-endian.h: Likewise.
1997-09-02 21:58:58 +00:00
Andrew Cagney 4b2a6aed84 Use sim_state_alloc to create common sim object. 1997-09-01 03:26:31 +00:00
Andrew Cagney f90b720ba1 Passify GCC. Convert 0x0LL to something more portable in the FP code. 1997-08-30 00:02:19 +00:00
David Edelsohn 36db8e64ab * sim-options.c (standard_option_handler): Use xstrdup, not strdup. 1997-08-28 17:37:30 +00:00
Andrew Cagney 18c319ae59 Add --target=BFDTARGET and --architecture=MACHINE options. 1997-08-28 09:44:42 +00:00
Andrew Cagney 8811705410 Fix doco on enable-sim-inline. 1997-08-27 22:43:18 +00:00
Andrew Cagney d6fea803dc Add MSBIT* and LSBIT* macro's to sim-bits.h
Add more macro's for extracting sub word quantites to sim-endian.h
1997-08-27 07:56:27 +00:00
Andrew Cagney 230a95ce5a New file - generic implementation of sim_load for hardware only
simulators.
1997-08-27 04:45:59 +00:00
Andrew Cagney fafce69ab1 Add ABFD argument to sim_create_inferior. Document.
Add file sim-hload.c - generic load for hardware only simulators.
Review each simulators sim_open, sim_load, sim_create_inferior so that
they more closely match required behavour.
1997-08-27 04:44:41 +00:00