Commit Graph

23 Commits

Author SHA1 Message Date
Stephane Carrez 7c070881e4 Fix memory leak in sim_parse_args 2000-11-25 09:16:22 +00:00
Jason Molenda c4093a6ab3 import gdb-1999-12-13 snapshot 1999-12-14 01:06:04 +00:00
Jason Molenda 43e526b9b4 import gdb-1999-07-12 snapshot 1999-07-12 11:15:22 +00:00
Stan Shebs c906108c21 Initial creation of sourceware repository 1999-04-16 01:35:26 +00:00
Stan Shebs 071ea11e85 Initial creation of sourceware repository 1999-04-16 01:34:07 +00:00
Ron Unrau aac9328044 (find_match): recheck argv[argi] in multi-word match. Fixes crash when
subset words are alone on the command line.
1998-03-01 14:49:50 +00:00
Andrew Cagney baf8377df8 Pacify GCC: const char * passed to asprintf; int function returning
void; unused variable.
1998-02-28 03:01:51 +00:00
Doug Evans 966df5804d * sim-base.h (sim_cpu_base): New members name, options.
(sim_cpu_lookup): Add prototype.
	* sim-module.c (sim_pre_argv_init): Provide default names for cpus.
	* sim-options.h (DECLARE_OPTION_HANDLER): New argument `cpu'.
	(sim_add_option_table): Update prototype.
	* sim-options.c (sim_add_option_table): New argument `cpu'.
	(standard_option_handler,standard_install): Update.
	(sim_parse_args): Handle cpu specific options.
	(print_help): New static function.
	(sim_print_help): Call it.  Print cpu specific options.
	(find_match): New static function.
	(sim_args_command): Call it.  Handle cpu specific options.
	* sim-utils.c (sim_cpu_lookup): New function.
	* sim-memopt.c (memory_option_handler): Update.
	(sim_memopt_install): Update.
	* sim-model.c (model_option_handler): Update.
	(model_install): Update.
	* sim-profile.c (profile_option_handler): Update.
	(profile_install): Update.
	* sim-trace.c (trace_option_handler): Update.
	(trace_install): Update.
	* sim-watch.c (watchpoint_option_handler): Update.
	(sim_watchpoint_install): Update.
	* cgen-scache.c (scache_option_handler): Update.
	(scache_install): Update.
1998-02-27 18:39:22 +00:00
Doug Evans 22469a10e8 * Make-common.in (SIM_ENVIRONMENT): New variable.
(CONFIG_CFLAGS): Add it.
	* aclocal.m4 (SIM_AC_OPTION_ENVIRONMENT): Handle
	--enable-sim-environment option.
	* configure: Regenerated.
	* sim-config.h (environment support): Rewrite.
	* sim-config.c (current_environment): Define as enum, unconditionally.
	(current_alignment): Define unconditionally.
	(config_environment_to_a): Update.
	(config_alignment_to_a): Fix type of argument.  Define unconditionally.
	(sim_config): Handle environment and alignment determination
	unconditionally.  Delete sanity checks of current_environment,
	unnecessary.
	(print_sim_config): Update.
	* sim-options.c (STANDARD_OPTIONS enum): Add OPTION_ENVIRONMENT.
	(standard_options): Add --environment.
	(standard_option_handler): Likewise.
1997-12-04 02:04:42 +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 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
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 d07dddd2b2 Save a copy of argv, not just a pointer. 1997-08-27 00:35:34 +00:00
Andrew Cagney 2f2e6c5d5b Extend xor-endian and per-cpu support in core module.
Allow negated test when watching value within core.
1997-05-27 06:48:20 +00:00
Andrew Cagney 50a2a69182 Watchpoint interface. 1997-05-21 06:54:13 +00:00
Andrew Cagney 43c53e07db Add function sim_args_command() which takes a `(gdb) sim <command>' and
parses it using rules found in the simulator command-line-options
databse.
1997-05-08 05:28:20 +00:00
David Edelsohn c967f1874a * Makefile.in (sim-options_h): Define.
(sim-{module,options,trace,profile,utils}.o): Clean up dependencies.
	(sim-model.o): Add new rule.
	(cgen-{scache,trace,utils}.o): Add new rules.
	* aclocal.m4 (SIM_AC_OPTION_{SCACHE,DEFAULT_MODEL}): Add.
	* cgen-scache.c (scache_print_profile): Change `sd' arg to `cpu'.
	Indent output by 2 spaces.
	* cgen-scache.h (scache_print_profile): Update.
	* cgen-trace.c (trace_insn_fini): Indent output by 2 spaces.
	Use trace_printf, not fprintf.
	(trace_extract): Use trace_printf, not cgen_trace_printf.
	* genmloop.sh (!FAST case): Increment `insn_count'.
	* sim-base.h (sim_state_base): Only include scache_size if WITH_SCACHE.
	(sim_cpu_base): Rename member `sd' to `state' to be consistent with
	access macro's name.
	* sim-core.c (sim_core_init): Use EXTERN_SIM_CORE to define it.
	Change return type to SIM_RC.
	(sim_core_{install,uninstall}): New functions.
	* sim-core.h (sim_core_{install,uninstall}): Declare.
	(sim_core_init): Use EXTERN_SIM_CORE to define it.
	Change return type to SIM_RC.
	* sim-model.h (models,machs,model_install): Declare.
	* sim-module.c (modules): Add scache_install, model_install.
	(sim_post_argv_init): Set cpu->state backlinks.
	* sim-options.c (standard_options): Delete --simcache-size,--max-insns.
	(standard_option_handler): Likewise.
	* sim-profile.c (PROFILE_{HISTOGRAM,LABEL}_WIDTH): Move to
	sim-profile.h.
	(*): Assume ANSI C.
	(profile_options): Delete --profile-simcache.
	(profile_option_handler): Likewise.
	(profile_print_insn): Change `sd' arg to `cpu'.  Indent output 2
	spaces.
	(profile_print_{memory,model}): Likewise.
	(profile_print_simcache): Delete.
	(profile_print_speed): New function.
	(profile_print): Rewrite.
	* sim-profile.h (PROFILE_scache): Renamed from PROFILE_simcache.
	(WITH_PROFILE_SCACHE_P): Renamed from WITH_PROFILE_SIMCACHE_P.
	(PROFILE_DATA): Delete members simcache_{hits,misses}.
	(PROFILE_COUNT_SIMCACHE_{HIT,MISS}): Delete.
	(PROFILE_{CALLBACK,CPU_CALLBACK}): New types.
	(profile_print): Update prototype.
1997-05-01 18:05:37 +00:00
David Edelsohn e65bd1d843 * sim-options.c (standard_options): Add --endian.
(standard_option_handler): Likewise.
1997-04-18 21:32:07 +00:00
David Edelsohn 8786d42627 (standard_option_handler): Tweak some error messages.
(sim_parse_args): Record orig_val as unsigned char.
1997-04-17 14:07:19 +00:00
David Edelsohn 4ede3a832b * sim-options.c, sim-options.h: New files. 1997-04-17 12:39:29 +00:00