Commit Graph

1854 Commits

Author SHA1 Message Date
Frank Ch. Eigler
8127139143 * gxtool silence tweak 1998-12-05 11:46:32 +00:00
Frank Ch. Eigler
3e99af1bae * gx prototype: simulator I/O bug fix
1998-12-05  Frank Ch. Eigler  <fche@elastic.org>
	* gx-translate.c (m32r_emit_short_insn): Correct ABI result
	handling for TRAP insn.
1998-12-05 10:32:12 +00:00
Doug Evans
1932239a58 (profile_print_addr_range): Pretty up output a little. 1998-12-05 08:47:32 +00:00
Doug Evans
0a18a6b8ad * configure.in: Call SIM_AC_OPTION_INLINE.
* configure: Regenerate.
	* sim-main.h: Protect against multiple inclusion.
	Don't include cgen-scache.h,cgen-cpu.h,cgen-trace.h,cpuall.h.
	Done by cgen-sim.h now.
	* tconfig.in (SIM_HAVE_MODEL): Delete, moved to cgen-types.h.
	* cpuall.h: Regenerate.
	* cpu.h,decode.c,sem-switch.c,sem.c: Regenerate.
	* mloop.in (extract16): Make static inline again.
	Simplify with call to @cpu@_fill_argbuf,@cpu@_fill_argbuf_tp.
	(extract32): Ditto.
	Simplify with call to @cpu@_fill_argbuf,@cpu@_fill_argbuf_tp.
	(execute): Test ARGBUF_PROFILE_P before profiling.
	Update calls to TRACE_INSN_INIT,TRACE_INSN_FINI.
	* cpux.h,decodex.c,modelx.c,semx-switch.c: Regenerate.
	* mloopx.in: Rewrite.
1998-12-05 08:09:18 +00:00
Doug Evans
b61e2e146a * cgen-defs.h: New file, old cgen-sim.h.
* cgen-sim.h: Simple header that includes others.
	* sim-arange.c: New file.
	* sim-arange.h: New file.
	* sim-basics.h: Include it.
	* Make-common.in (SIM_NEW_COMMON_OBJS): Add sim-arange.o.
	(sim-arange.o): Add rule for.
	* sim-cpu.h (sim_cpu_msg_prefix): Add prototype.
	(sim_io_eprintf_cpu): Add prototype.
	* sim-inline.h (HAVE_INLINE): Define if GNUC.
	(INLINE2): New macro.
	(EXTERN_INLINE): New macro.
	* sim-module.c (sim_post_argv_init): Initialize cpu backlink
	before calling module init fns.
	* sim-profile.h (OPTION_PROFILE_*): Move into enum.
	(profile_init): New function.
	(profile_options): New option --profile-range.
	(profile_option_handler): Handle --profile-range.
	(profile_print_insn): Qualify address range specific section titles.
	(profile_print_addr_ranges): New function.
	(profile_info): Print address ranges if specified.
	(profile_install): Set profile_init init fn.
	* sim-profile.h (PROFILE_DATA): New member `range'.
	* sim-trace.c (trace_init): New function.
	(trace_options): New option --trace-range.
	(trace_option_handler): Handle --trace-range.
	(trace_install): Set trace_init init fn.
	* sim-trace.h (TRACE_DATA): New member `range'.
	* sim-utils.c (sim_cpu_msg_prefix): New function.
	(sim_io_eprintf_cpu): New function.
	* cgen-engine.h (PC_IN_TRACE_RANGE_P): New macro.
	(PC_IN_PROFILE_RANGE_P): New macro.
	* cgen-trace.c (trace_insn_init): Set current_insn to NULL.
	(trace_insn_fini): New arg abuf.  All callers updated.
	Exit early if trace_insn not called.  Check ARGBUF_PROFILE_P before
	printing cycle counts.
	* cgen-trace.h (trace_insn_fini): Update prototype.
	(TRACE_RESULT_P): New macro.
	(TRACE_INSN_INIT,TRACE_INSN_FINI): New arg abuf.  All callers updated.
	(TRACE_INSN): Check ARGBUF_TRACE_P.
	(TRACE_EXTRACT,TRACE_RESULT): New arg abuf.  All callers updated.
	* cgen-types.h (SIM_INLINE): Delete.
	(SIM_HAVE_MODEL,SIM_HAVE_ADDR_RANGE): Define.
	* cgen-utils.c: Don't include cgen-engine.h
	* genmloop.sh (@cpu@_fill_argbuf): New function.
	(@cpu@_fill_argbuf_tp): New function.
	(@cpu@_emit_before,@cpu@_emit_after): New functions.
	(@cpu@_pbb_begin): Prefix cti_sc,insn_count with '_'.
	(SET_CTI_VPC,SET_INSN_COUNT): Update.
	(@cpu@_pbb_before): Check ARGBUF_PROFILE_P before calling
	doing profiling.  Update call to TRACE_INSN_INIT,TRACE_INSN_FINI.
	(@cpu@_pbb_after): Check ARGBUF_PROFILE_P before calling
	doing profiling. Update call to TRACE_INSN_FINI.
1998-12-05 07:56:13 +00:00
Doug Evans
e8116eca81 * sim-memopt.c (sim_memory_uninstall): Result type is `void'. 1998-12-05 02:33:31 +00:00
Doug Evans
17f07639b4 address range support 1998-12-05 02:19:39 +00:00
Doug Evans
99c53aa9f6 * cpu.h,decode.c,sem-switch.c,sem.c: Regenerate.
* cpux.h,decodex.c,modelx.c,semx-switch.c: Regenerate.
1998-12-04 08:22:27 +00:00
Andrew Cagney
33ccdb1b97 * gen-engine.c (print_run_body): Prefix instruction_address. 1998-12-04 04:45:05 +00:00
Frank Ch. Eigler
beef5e777c * Test case for PR 18364, over from d30v branch.
1998-12-04  Frank Ch. Eigler  <fche@cygnus.com>
	* do-shifts.S: Update an older test case.
1998-12-04 04:17:08 +00:00
Dave Brolley
2cf8f53cc9 Thu Dec 3 14:20:03 1998 Dave Brolley <brolley@cygnus.com>
* sim/fr30/ld.cgs: Implement more loads.
	* sim/fr30/call.cgs: New testcase.
	* sim/fr30/testutils.inc (testr_h_dr): New macro.
	(set_s_user,set_s_system): New macros.
1998-12-03 22:38:13 +00:00
Dave Brolley
3bf9790595 Thu Dec 3 14:20:03 1998 Dave Brolley <brolley@cygnus.com>
* sim/fr30: New Directory.
1998-12-03 19:22:56 +00:00
Frank Ch. Eigler
3d7075f5f5 * A few more improvements to gx jit prototype.
[common/ChangeLog]
1998-12-01  Frank Ch. Eigler  <fche@elastic.org>
	* sim-gx-run.c (sim_engine_run): Use new tgx_info struct to
	collect run-time arguments to gx block.
	* sim-gx.h (sim_gx_function): Corresponding signature change.
	* sim-gx.c (sim_gx_compiled_block_f): Remove nonfunctional code to
	again compile a gx block source file.
	(sim_gx_compiled_block_dispose): Uninstall obsoleted gx block
	shared libraries.
	(sim_gx_block_translate): Always emit new "gx_label_NNNN" labels,
	for basic block entry points, even if !__GNUC__.
[m32r-gx/ChangeLog]
1998-12-01  Frank Ch. Eigler  <fche@elastic.org>
	* Makefile.in (SIM_OBJS): Don't build sim-core.o.
	* configure.in:	Added --enable-sim-inline support.
	Look for "getenv()" function.
	* configure: Rebuilt.
	* config.in: Rebuilt.
	* gx-translate.c: Include "sim-inline.c" for sim-core inlining.
	(m32r_gx_{load,store}*): Update signature.
	(tgx_emit_pre_function): Emit new "tgx_info" struct, update
	callback function signatures.
	(m32r_emit_*_insn): Use new callback signatures.  For all short
	branches in optimized mode, emit direct "goto gx_label_NNNN".
	(tgx_optimize_test): If the GX_OPTIMIZE environment variable is
	set, allow its integer value to override the optimization heuristic.
	* m32r-sim.h: New empty placeholder file.
	* sim-main.c: New empty placeholder file.
	* sim-if.c (sim_create_inferior): Use NULL instead of &abort
	for unimplemented register fondling functions.
	* sim-main.h: Add multiple inclusion guard.  Update callback
	function signatures.
	(tgx_info): New struct for collecting gx block invocation
	arguments.
1998-12-01 13:28:53 +00:00
Doug Evans
3c034beb5b * cgen-utils.c (cgen_virtual_opcode_table): Update. 1998-11-30 23:43:58 +00:00
Andrew Cagney
a6a5d34927 Fix --enable-build-warnings=-Werror failures.
v850/simops.c, d10v/simops.c, v850/Makefile.in, d10v/Makefile.in:
Include targ-vals.h instead of syscall.h. Replace SYS_* with
TARGET_SYS_*.  Add dependency.
z8k/support.c: Include <errno.h>
v850/simops.c: Replace long with portable signed32.
mips/interp.c: Make sim_monitor global - needed by sky.
1998-11-25 09:58:04 +00:00
Andrew Cagney
baa1a48801 Explicitly tag vr41/mips16 instructions.
Update configure.in/configure.
1998-11-25 06:50:48 +00:00
Andrew Cagney
fbf1f3f1f6 Add d10v and v850 to gennltvals.sh and regenerate.
Add a howto.
1998-11-24 07:59:01 +00:00
Dave Brolley
7259fc9491 Mon Nov 23 17:02:47 1998 Dave Brolley <brolley@cygnus.com>
* Directory created.
1998-11-23 23:25:28 +00:00
Andrew Cagney
554eb429e4 gencode.c: Kill, Kill, Kill....
Remove last remenats of old gencode simulator.
1998-11-23 11:37:56 +00:00
Andrew Cagney
57791952b6 Configure mips64vr4100-elf nee mips64vr41* as a 64 bit mips16 igen simulator.
Fix problems: All vr.igen instructions are 64 bit.
1998-11-23 07:16:03 +00:00
Andrew Cagney
67f7d50d5e Pacify GCC. 1998-11-23 06:18:32 +00:00
Andrew Cagney
5a581ea612 Pacify GCC. 1998-11-23 06:10:01 +00:00
Andrew Cagney
ee562da4c4 Reconize target mips-tx19-elf 1998-11-23 06:06:12 +00:00
Andrew Cagney
a83d7d870f Switch mips-lsi-elf mips16 simulator to igen (from gencode). 1998-11-23 05:50:21 +00:00
Doug Evans
9935b2e7f3 * genmloop.sh (${cpu}_pbb_chain): Watch for Ctrl-C's.
(${cpu}_pbb_cti_chain): Ditto.
1998-11-22 19:21:51 +00:00
Frank Ch. Eigler
74cc43debc * fix for minor sanitization lossage 1998-11-22 11:50:48 +00:00
Frank Ch. Eigler
42647d5b8c * mild gx prototype tweak
start-sanitize-gxsim
1998-11-21  Frank Ch. Eigler  <fche@elastic.org>
	* sim-gx.c (sim_gx_block_translate): Generate computed
	goto for __GNUC__ instead of plain switch() for gx block
	entry.  Lose "-g" compile option for gx block.
end-sanitize-gxsim
1998-11-21 19:05:09 +00:00
Andrew Cagney
821b702f92 * r5900.igen (CVT.W.S): Always round towards zero.
Update testsuite.
1998-11-21 03:31:30 +00:00
Michael Meissner
86908c4014 Fix problem where qnan was treated like an infinity 1998-11-20 00:44:03 +00:00
Doug Evans
8406c876c5 * Makefile.in (M32R_OBJS): Delete extract.o.
(extract.o): Delete.
	(stamp-arch): Depend on $(CGEN_ARCH_SCM).
	(stamp-cpu): Don't build extract.c.
	* cpu.c,cpu.h,decode.c,decode.h,sem-switch.c,sem.c: Rebuild.
	* mloop.in (extract16): Update type of `insn' arg.
	Delete call to d->extract.
	(extract32): Ditto.

	* Makefile.in (M32RX_OBJS): Delete extractx.o.
	(extractx.o): Delete.
	(stamp-xcpu): Don't build extractx.c.
	* cpux.c,cpux.h,decodex.c,decodex.h,semx-switch.c: Rebuild.
	* mloopx.in (extractx16): Update type of `insn' arg.
	Delete call to d->extract.  Delete arg pbb_p.  All callers updated.
	(extract-simple,full-exec-simple,fast-exec-simple): Delete.
	(extractx32): Ditto.
1998-11-19 00:12:00 +00:00
Doug Evans
916b11527e * Make-common.in (cgen-utils.o): Depend on cgen-engine.h.
(CGEN_ARCH_SCM): New variable.
	* cgen-engine.h (EXTRACT_[ML]SB0_{INT,UINT}): New macros.
	(EXTRACT_INT,EXTRACT_UINT): New macros.
	(SEM_SEM_ARG): New macro.
	(SEM_NEXT_VPC): New arg `pc'.
	* cgen-sim.h (EXTRACT_SIGNED,EXTRACT_UNSIGNED): Delete.
	(sim_disassemble_insn): Update prototype.
	* cgen-trace.c (current_insn,insn_fields): New static locals.
	(trace_insn): Set them.
	* cgen-utils.scm: #include cgen-engine.h.
	(sim_disassemble_insn): New arg insn_fields.
	Handle variable length insns.
	* genmloop.sh: Only emit pbb decls if -pbb.
	(${cpu}_scache_lookup): New arg `vpc'.
	(scache support): Fetch pc before entering loop.
1998-11-18 23:45:32 +00:00
Doug Evans
2c05443851 * gennltvals.sh: Add fr30 support.
* nltvals.def: Rebuild.
1998-11-18 22:41:50 +00:00
Andrew Cagney
78dee4ee05 Re-do type system so that GCC's explicit attribute/mode types are used
(when available).
Update sim-bits and sim-alu tests in sim/testsuite/common.
1998-11-17 23:59:30 +00:00
Frank Ch. Eigler
ca0669a326 * sun build fix for thinko (?) 1998-11-16 08:52:06 +00:00
Frank Ch. Eigler
92fa45795d * Personal prototype "gx" translation-based JIT engine for M32R.
[ChangeLog]
start-sanitize-gxsim
1998-11-13  Frank Ch. Eigler  <fche@elastic.org>
	* configure.in: Added "--enable-sim-gx" option.
	* configure: Regenerated.
end-sanitize-gxsim
[common/ChangeLog]
1998-11-13  Frank Ch. Eigler  <fche@elastic.org>
start-sanitize-gxsim
	* Make-common.im: Build sim-gx.o and sim-gx-run.o.
	* sim-gx.c: New file: target-independent gx routines.
	* sim-gx.h: Declarations for gx structs and routines.
	* sim-gx-run.c: New file: target-independent gx driver.
	* sim-base.h: Add gx block vector to state struct.
end-sanitize-gxsim
	* aclocal.m4: Add tests for dlopen family.
1998-11-14 04:35:47 +00:00
Frank Ch. Eigler
fca5abc13a * sanitize fix for do-shifts.S 1998-11-14 04:32:00 +00:00
Frank Ch. Eigler
78cec885d7 * test case for PR 18230, over from d30v branch
1998-11-12  Frank Ch. Eigler  <fche@cygnus.com>
        * br-djsr.S: New test for new R62-update timing.
1998-11-12 11:39:05 +00:00
Andrew Cagney
d1cbd70abb Add configury for mips-lsi-elf target (32 bit MIPS16).
Fix numerous problems with PENDING_* code.
In old gencode simulator, don't double tick each cycle.
Add BREAK instruction to MIPS16 gencode simulator.
1998-11-12 06:42:34 +00:00
Doug Evans
847b31bdab * sim-hload.c (sim_load): Pass `prog_name' to sim_load_file, not NULL. 1998-11-11 22:02:57 +00:00
Andrew Cagney
7d88afe63e div(-0) sets both I/SI and D/SD (PR16522) 1998-11-11 08:18:55 +00:00
Doug Evans
ca40ecdcec remove cgen support from Makefile.in, moved to cgen dir 1998-11-07 02:47:22 +00:00
Frank Ch. Eigler
edba5926c8 * Patch for PR 18196, brought over from d30v branch.
[d30v/ChangeLog]
1998-11-06  Frank Ch. Eigler  <fche@cygnus.com>
	* d30v-insns (do_mvfacc): Use loop to limit shift count to 63 .. 0.
[testsuite/d30v-elf/ChangeLog]
1998-11-06  Frank Ch. Eigler  <fche@cygnus.com>
	* do-shifts.S: Add test for large mvfacc shifts.
1998-11-06 08:45:57 +00:00
Doug Evans
47a2144503 lose fr30 for now 1998-11-06 00:17:34 +00:00
Dave Brolley
168c5ef4ef Wed Nov 4 19:11:43 1998 Dave Brolley <brolley@cygnus.com>
* configure.in: Added case for fr30-*-*.
	* configure: Regenerated.
1998-11-05 20:25:22 +00:00
Frank Ch. Eigler
1995094e7f * r5900 sim test case fix
Thu Nov  5 10:37:40 EST 1998  Frank Ch. Eigler <fche@cygnus.com>

	* t-prot3w.s: Correct test of prot3w insn.
1998-11-05 15:42:02 +00:00
Frank Ch. Eigler
210a903baf * build fix
Thu Nov  5 10:29:42 EST 1998  Frank Ch. Eigler  <fche@cygnus.com>
	* r5900.igen (r59fp_opdiv): Correct erroneous FGR[FD] reference.
1998-11-05 09:42:06 +00:00
Andrew Cagney
dd0f610960 PR 16522
Fix RSQRT.S instruction, add test case.
1998-11-05 09:42:05 +00:00
Doug Evans
8de434bf89 * sim-main.h: Delete inclusion of config.h, include sim-basics.h
before cgen-types.h.
	* tconfig.in: Guard against multiple inclusion.
	* cpu.h: Delete decls moved to genmloop.sh.
	* cpux.h: Ditto.
1998-11-05 07:56:02 +00:00
Doug Evans
8c7dc9ffc8 * genmloop.sh (eng.hin): Rename HAVE_PARALLEL_EXEC to
HAVE_PARALLEL_INSNS, define as 0 or 1.  Emit decls of fns in mloop.cin.
	* cgen-engine.h: Typedefs of IADDR,CIA,SEM_ARG,SEM_PC moved ...
	* cgen-sim.h: ... to here.
1998-11-05 07:53:37 +00:00
Doug Evans
d4df1e3023 add some comments 1998-11-04 19:27:20 +00:00