aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sim/ChangeLog7
-rw-r--r--sim/Makefile.in1
-rw-r--r--sim/bfin/ChangeLog7
-rw-r--r--sim/bfin/aclocal.m41
-rwxr-xr-xsim/bfin/configure29
-rw-r--r--sim/bfin/configure.ac2
-rw-r--r--sim/bfin/interp.c1
-rw-r--r--sim/bpf/ChangeLog7
-rw-r--r--sim/bpf/aclocal.m41
-rwxr-xr-xsim/bpf/configure21
-rw-r--r--sim/bpf/configure.ac1
-rw-r--r--sim/bpf/sim-if.c1
-rw-r--r--sim/common/ChangeLog11
-rw-r--r--sim/common/Make-common.in2
-rw-r--r--sim/common/sim-base.h4
-rw-r--r--sim/common/sim-model.c13
-rw-r--r--sim/common/sim-model.h7
-rwxr-xr-xsim/configure6
-rw-r--r--sim/configure.ac1
-rw-r--r--sim/cris/ChangeLog7
-rw-r--r--sim/cris/aclocal.m41
-rwxr-xr-xsim/cris/configure25
-rw-r--r--sim/cris/configure.ac3
-rw-r--r--sim/cris/sim-if.c1
-rw-r--r--sim/frv/ChangeLog7
-rw-r--r--sim/frv/aclocal.m41
-rwxr-xr-xsim/frv/configure23
-rw-r--r--sim/frv/configure.ac1
-rw-r--r--sim/frv/sim-if.c1
-rw-r--r--sim/iq2000/ChangeLog7
-rw-r--r--sim/iq2000/aclocal.m41
-rwxr-xr-xsim/iq2000/configure23
-rw-r--r--sim/iq2000/configure.ac1
-rw-r--r--sim/iq2000/sim-if.c1
-rw-r--r--sim/lm32/ChangeLog7
-rw-r--r--sim/lm32/aclocal.m41
-rwxr-xr-xsim/lm32/configure23
-rw-r--r--sim/lm32/configure.ac1
-rw-r--r--sim/lm32/sim-if.c1
-rw-r--r--sim/m32r/ChangeLog7
-rw-r--r--sim/m32r/aclocal.m41
-rwxr-xr-xsim/m32r/configure23
-rw-r--r--sim/m32r/configure.ac1
-rw-r--r--sim/m32r/sim-if.c1
-rw-r--r--sim/m4/sim_ac_option_default_model.m431
-rw-r--r--sim/m4/sim_ac_output.m41
-rw-r--r--sim/mips/ChangeLog4
-rwxr-xr-xsim/mips/configure2
-rw-r--r--sim/mn10300/ChangeLog4
-rwxr-xr-xsim/mn10300/configure2
-rw-r--r--sim/or1k/ChangeLog7
-rw-r--r--sim/or1k/aclocal.m41
-rwxr-xr-xsim/or1k/configure21
-rw-r--r--sim/or1k/configure.ac1
-rw-r--r--sim/or1k/sim-if.c1
-rw-r--r--sim/riscv/ChangeLog7
-rw-r--r--sim/riscv/aclocal.m41
-rwxr-xr-xsim/riscv/configure28
-rw-r--r--sim/riscv/configure.ac8
-rw-r--r--sim/riscv/interp.c1
-rw-r--r--sim/v850/ChangeLog4
-rwxr-xr-xsim/v850/configure2
62 files changed, 120 insertions, 298 deletions
diff --git a/sim/ChangeLog b/sim/ChangeLog
index 59c123d..91edb5e 100644
--- a/sim/ChangeLog
+++ b/sim/ChangeLog
@@ -1,3 +1,10 @@
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
+ * configure.ac (sim_default_model): Delete.
+ * m4/sim_ac_output.m4 (sim_default_model): Likewise.
+ * configure, Makefile.in: Regenerate.
+ * m4/sim_ac_option_default_model.m4: Removed.
+
2021-06-29 Mike Frysinger <vapier@gentoo.org>
* m4/sim_ac_option_warnings.m4: Add -Wunused-but-set-parameter.
diff --git a/sim/Makefile.in b/sim/Makefile.in
index 047d548..1d9e855 100644
--- a/sim/Makefile.in
+++ b/sim/Makefile.in
@@ -781,7 +781,6 @@ psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
sim_bitsize = @sim_bitsize@
-sim_default_model = @sim_default_model@
sim_float = @sim_float@
sim_hw_cflags = @sim_hw_cflags@
sim_hw_sockser = @sim_hw_sockser@
diff --git a/sim/bfin/ChangeLog b/sim/bfin/ChangeLog
index 6b0000a..c1397bd 100644
--- a/sim/bfin/ChangeLog
+++ b/sim/bfin/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * interp.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* interp.c (sim_open): Set STATE_MACHS.
* machs.c (sim_machs): Rename to ...
(bfin_sim_machs): ... this.
diff --git a/sim/bfin/aclocal.m4 b/sim/bfin/aclocal.m4
index bdbe880..c9414d4 100644
--- a/sim/bfin/aclocal.m4
+++ b/sim/bfin/aclocal.m4
@@ -12,5 +12,4 @@
# PARTICULAR PURPOSE.
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/bfin/configure b/sim/bfin/configure
index bed0a3d..9b8c7fc 100755
--- a/sim/bfin/configure
+++ b/sim/bfin/configure
@@ -628,12 +628,10 @@ PACKAGE_VERSION
PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
-SHELL
-sim_default_model'
+SHELL'
ac_subst_files=''
ac_user_opts='
enable_option_checking
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1241,13 +1239,6 @@ if test -n "$ac_init_help"; then
cat <<\_ACEOF
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-sim-default-model=model
- Specify default model to simulate
-
Report bugs to the package provider.
_ACEOF
ac_status=$?
@@ -1678,23 +1669,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-default_sim_default_model="bf537"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
cgen_breaks=""
if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then
cgen_breaks="break cgen_rtx_error";
@@ -1716,7 +1690,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/bfin/configure.ac b/sim/bfin/configure.ac
index 6cf5c48..99370b3 100644
--- a/sim/bfin/configure.ac
+++ b/sim/bfin/configure.ac
@@ -2,6 +2,4 @@ dnl Process this file with autoconf to produce a configure script.
AC_INIT(Makefile.in)
AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
-SIM_AC_OPTION_DEFAULT_MODEL(bf537)
-
SIM_AC_OUTPUT
diff --git a/sim/bfin/interp.c b/sim/bfin/interp.c
index dcc7a13..b99f20d 100644
--- a/sim/bfin/interp.c
+++ b/sim/bfin/interp.c
@@ -704,6 +704,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = bfin_sim_machs;
+ STATE_MODEL_NAME (sd) = "bf537";
current_alignment = STRICT_ALIGNMENT;
current_target_byte_order = BFD_ENDIAN_LITTLE;
diff --git a/sim/bpf/ChangeLog b/sim/bpf/ChangeLog
index 959c63f..63037fd 100644
--- a/sim/bpf/ChangeLog
+++ b/sim/bpf/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(bpf_sim_machs): ... this.
* sim-if.c (bpf_sim_machs): New decl.
diff --git a/sim/bpf/aclocal.m4 b/sim/bpf/aclocal.m4
index d0f761f..90a839c 100644
--- a/sim/bpf/aclocal.m4
+++ b/sim/bpf/aclocal.m4
@@ -13,6 +13,5 @@
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
m4_include([../m4/sim_ac_option_bitsize.m4])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/bpf/configure b/sim/bpf/configure
index 2dc2ee2..de2798c 100755
--- a/sim/bpf/configure
+++ b/sim/bpf/configure
@@ -628,14 +628,12 @@ PACKAGE_NAME
PATH_SEPARATOR
SHELL
sim_scache
-sim_default_model
sim_bitsize'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_bitsize
enable_sim_scache
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1250,8 +1248,6 @@ Optional Features:
--enable-sim-bitsize=N Specify target bitsize (32 or 64)
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
Report bugs to the package provider.
_ACEOF
@@ -1762,22 +1758,6 @@ fi
-default_sim_default_model="bpf-def"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
cgen_breaks=""
if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then
cgen_breaks="break cgen_rtx_error";
@@ -1799,7 +1779,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/bpf/configure.ac b/sim/bpf/configure.ac
index 3272937..9cbd202 100644
--- a/sim/bpf/configure.ac
+++ b/sim/bpf/configure.ac
@@ -4,6 +4,5 @@ AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_BITSIZE([64])
SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL([bpf-def])
SIM_AC_OUTPUT
diff --git a/sim/bpf/sim-if.c b/sim/bpf/sim-if.c
index 150f5cd..aba191d 100644
--- a/sim/bpf/sim-if.c
+++ b/sim/bpf/sim-if.c
@@ -129,6 +129,7 @@ sim_open (SIM_OPEN_KIND kind,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = bpf_sim_machs;
+ STATE_MODEL_NAME (sd) = "bpf-def";
if (sim_cpu_alloc_all (sd, 1) != SIM_RC_OK)
goto error;
diff --git a/sim/common/ChangeLog b/sim/common/ChangeLog
index 63e7f3b..5b86431 100644
--- a/sim/common/ChangeLog
+++ b/sim/common/ChangeLog
@@ -1,5 +1,16 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * Make-common.in (SIM_DEFAULT_MODEL): Delete.
+ * sim-base.h (struct sim_state): Add model_name.
+ (STATE_MODEL_NAME): Define.
+ * sim-model.c (model_option_handler): Set STATE_MODEL_NAME.
+ (sim_model_init): Delete WITH_MODEL_P check. Change
+ WITH_DEFAULT_MODEL to STATE_MODEL_NAME.
+ * sim-model.h (WITH_DEFAULT_MODEL): Delete.
+ (WITH_MODEL_P): Delete.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* cgen-defs.h (cgen_cpu_max_extra_bytes): Add SIM_DESC arg.
* cgen-utils.c (cgen_cpu_max_extra_bytes): Likewise. Change sim_machs
to STATE_MACHS.
diff --git a/sim/common/Make-common.in b/sim/common/Make-common.in
index 723bda5..992fd7f 100644
--- a/sim/common/Make-common.in
+++ b/sim/common/Make-common.in
@@ -73,7 +73,6 @@ top_builddir = ..
SHELL = @SHELL@
SIM_BITSIZE = @sim_bitsize@
-SIM_DEFAULT_MODEL = @sim_default_model@
SIM_FLOAT = @sim_float@
SIM_RESERVED_BITS = @sim_reserved_bits@
SIM_SCACHE = @sim_scache@
@@ -195,7 +194,6 @@ CGEN_INCLUDE_DEPS = \
CONFIG_CFLAGS = \
-DHAVE_CONFIG_H \
- $(SIM_DEFAULT_MODEL) \
$(SIM_BITSIZE) \
$(SIM_FLOAT) \
$(SIM_HW_CFLAGS) \
diff --git a/sim/common/sim-base.h b/sim/common/sim-base.h
index 8eae988..674b2d4 100644
--- a/sim/common/sim-base.h
+++ b/sim/common/sim-base.h
@@ -147,6 +147,10 @@ struct sim_state {
const SIM_MACH * const *machs;
#define STATE_MACHS(sd) ((sd)->machs)
+ /* If non-NULL, the model to select for CPUs. */
+ const char *model_name;
+#define STATE_MODEL_NAME(sd) ((sd)->model_name)
+
/* In standalone simulator, this is the program's arguments passed
on the command line. */
char **prog_argv;
diff --git a/sim/common/sim-model.c b/sim/common/sim-model.c
index 4c5e463..98dcbea 100644
--- a/sim/common/sim-model.c
+++ b/sim/common/sim-model.c
@@ -68,6 +68,7 @@ model_option_handler (SIM_DESC sd, sim_cpu *cpu, int opt,
sim_io_eprintf (sd, "unknown model `%s'\n", arg);
return SIM_RC_FAIL;
}
+ STATE_MODEL_NAME (sd) = arg;
sim_model_set (sd, cpu, model);
break;
}
@@ -209,9 +210,6 @@ sim_model_init (SIM_DESC sd)
{
SIM_CPU *cpu;
- if (!WITH_MODEL_P)
- return SIM_RC_OK;
-
/* If both cpu model and state architecture are set, ensure they're
compatible. If only one is set, set the other. If neither are set,
use the default model. STATE_ARCHITECTURE is the bfd_arch_info data
@@ -222,10 +220,11 @@ sim_model_init (SIM_DESC sd)
cpu = STATE_CPU (sd, 0);
if (! STATE_ARCHITECTURE (sd)
- && ! CPU_MACH (cpu))
+ && ! CPU_MACH (cpu)
+ && STATE_MODEL_NAME (sd))
{
/* Set the default model. */
- const SIM_MODEL *model = sim_model_lookup (sd, WITH_DEFAULT_MODEL);
+ const SIM_MODEL *model = sim_model_lookup (sd, STATE_MODEL_NAME (sd));
SIM_ASSERT (model != NULL);
sim_model_set (sd, NULL, model);
}
@@ -242,7 +241,7 @@ sim_model_init (SIM_DESC sd)
return SIM_RC_FAIL;
}
}
- else if (STATE_ARCHITECTURE (sd))
+ else if (STATE_ARCHITECTURE (sd) && STATE_MACHS (sd))
{
/* Use the default model for the selected machine.
The default model is the first one in the list. */
@@ -257,7 +256,7 @@ sim_model_init (SIM_DESC sd)
}
sim_model_set (sd, NULL, MACH_MODELS (mach));
}
- else
+ else if (CPU_MACH (cpu))
{
STATE_ARCHITECTURE (sd) = bfd_scan_arch (MACH_BFD_NAME (CPU_MACH (cpu)));
}
diff --git a/sim/common/sim-model.h b/sim/common/sim-model.h
index e735feb..ecef257 100644
--- a/sim/common/sim-model.h
+++ b/sim/common/sim-model.h
@@ -47,13 +47,6 @@ typedef struct {
#define MAX_UNITS 1
#endif
-#ifndef WITH_DEFAULT_MODEL
-# define WITH_DEFAULT_MODEL NULL
-# define WITH_MODEL_P 0
-#else
-# define WITH_MODEL_P 1
-#endif
-
typedef int (MODEL_FN) (sim_cpu *, void *);
typedef struct {
diff --git a/sim/configure b/sim/configure
index 94b45fd..909f8e6 100755
--- a/sim/configure
+++ b/sim/configure
@@ -640,7 +640,6 @@ am__EXEEXT_TRUE
LTLIBOBJS
SIM_RX_CYCLE_ACCURATE_FLAGS
sim_reserved_bits
-sim_default_model
sim_scache
sim_float
sim_bitsize
@@ -12180,7 +12179,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 12183 "configure"
+#line 12182 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -12286,7 +12285,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 12289 "configure"
+#line 12288 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -14674,7 +14673,6 @@ fi
-
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sim rx should be cycle accurate" >&5
$as_echo_n "checking whether sim rx should be cycle accurate... " >&6; }
# Check whether --enable-sim-rx-cycle-accurate was given.
diff --git a/sim/configure.ac b/sim/configure.ac
index 15b2b65..0b31d2c 100644
--- a/sim/configure.ac
+++ b/sim/configure.ac
@@ -172,7 +172,6 @@ dnl respective SIM_AC_OPTION_xxx call above, we can drop these.
AC_SUBST(sim_bitsize)
AC_SUBST(sim_float)
AC_SUBST(sim_scache)
-AC_SUBST(sim_default_model)
AC_SUBST(sim_reserved_bits)
dnl Some arches have unique configure flags.
diff --git a/sim/cris/ChangeLog b/sim/cris/ChangeLog
index 2920850..9cdc488 100644
--- a/sim/cris/ChangeLog
+++ b/sim/cris/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(cris_sim_machs): ... this.
* sim-if.c (cris_sim_machs): New decl.
diff --git a/sim/cris/aclocal.m4 b/sim/cris/aclocal.m4
index 212a399..ca624a7 100644
--- a/sim/cris/aclocal.m4
+++ b/sim/cris/aclocal.m4
@@ -12,6 +12,5 @@
# PARTICULAR PURPOSE.
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/cris/configure b/sim/cris/configure
index a0bfa60..1f18282 100755
--- a/sim/cris/configure
+++ b/sim/cris/configure
@@ -628,13 +628,11 @@ PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL
-sim_scache
-sim_default_model'
+sim_scache'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_scache
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1248,8 +1246,6 @@ Optional Features:
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
Report bugs to the package provider.
_ACEOF
@@ -1701,24 +1697,6 @@ fi
-# The default model shouldn't matter as long as there's a BFD.
-
-default_sim_default_model="crisv32"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
cgen_breaks=""
if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then
cgen_breaks="break cgen_rtx_error";
@@ -1740,7 +1718,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/cris/configure.ac b/sim/cris/configure.ac
index 57a2d5f..d203722 100644
--- a/sim/cris/configure.ac
+++ b/sim/cris/configure.ac
@@ -4,7 +4,4 @@ AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_SCACHE(16384)
-# The default model shouldn't matter as long as there's a BFD.
-SIM_AC_OPTION_DEFAULT_MODEL(crisv32)
-
SIM_AC_OUTPUT
diff --git a/sim/cris/sim-if.c b/sim/cris/sim-if.c
index 37a1d5b..2d7e922 100644
--- a/sim/cris/sim-if.c
+++ b/sim/cris/sim-if.c
@@ -659,6 +659,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = cris_sim_machs;
+ STATE_MODEL_NAME (sd) = "crisv32";
current_target_byte_order = BFD_ENDIAN_LITTLE;
/* The cpu data is kept in a separately allocated chunk of memory. */
diff --git a/sim/frv/ChangeLog b/sim/frv/ChangeLog
index 7cc35c5..6db6b66 100644
--- a/sim/frv/ChangeLog
+++ b/sim/frv/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(frv_sim_machs): ... this.
* sim-if.c (frv_sim_machs): New decl.
diff --git a/sim/frv/aclocal.m4 b/sim/frv/aclocal.m4
index 212a399..ca624a7 100644
--- a/sim/frv/aclocal.m4
+++ b/sim/frv/aclocal.m4
@@ -12,6 +12,5 @@
# PARTICULAR PURPOSE.
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/frv/configure b/sim/frv/configure
index d3d21e2..dcd1a87 100755
--- a/sim/frv/configure
+++ b/sim/frv/configure
@@ -629,13 +629,11 @@ PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL
-sim_scache
-sim_default_model'
+sim_scache'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_scache
-enable_sim_default_model
enable_sim_trapdump
'
ac_precious_vars='build_alias
@@ -1250,8 +1248,6 @@ Optional Features:
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
--enable-sim-trapdump Make unknown traps dump the registers
Report bugs to the package provider.
@@ -1704,22 +1700,6 @@ fi
-default_sim_default_model="fr500"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
#
# Enable making unknown traps dump out registers
#
@@ -1759,7 +1739,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/frv/configure.ac b/sim/frv/configure.ac
index 83ad011..785a3bc 100644
--- a/sim/frv/configure.ac
+++ b/sim/frv/configure.ac
@@ -3,7 +3,6 @@ AC_INIT(Makefile.in)
AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL(fr500)
#
# Enable making unknown traps dump out registers
diff --git a/sim/frv/sim-if.c b/sim/frv/sim-if.c
index 82f4bd8..6d22aad 100644
--- a/sim/frv/sim-if.c
+++ b/sim/frv/sim-if.c
@@ -57,6 +57,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, bfd *abfd,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = frv_sim_machs;
+ STATE_MODEL_NAME (sd) = "fr500";
current_alignment = STRICT_ALIGNMENT;
current_target_byte_order = BFD_ENDIAN_BIG;
diff --git a/sim/iq2000/ChangeLog b/sim/iq2000/ChangeLog
index 130c6bf..60aa966 100644
--- a/sim/iq2000/ChangeLog
+++ b/sim/iq2000/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(iq2000_sim_machs): ... this.
* sim-if.c (iq2000_sim_machs): New decl.
diff --git a/sim/iq2000/aclocal.m4 b/sim/iq2000/aclocal.m4
index 212a399..ca624a7 100644
--- a/sim/iq2000/aclocal.m4
+++ b/sim/iq2000/aclocal.m4
@@ -12,6 +12,5 @@
# PARTICULAR PURPOSE.
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/iq2000/configure b/sim/iq2000/configure
index 8ed98a5..1f18282 100755
--- a/sim/iq2000/configure
+++ b/sim/iq2000/configure
@@ -628,13 +628,11 @@ PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL
-sim_scache
-sim_default_model'
+sim_scache'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_scache
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1248,8 +1246,6 @@ Optional Features:
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
Report bugs to the package provider.
_ACEOF
@@ -1701,22 +1697,6 @@ fi
-default_sim_default_model="iq2000"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
cgen_breaks=""
if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then
cgen_breaks="break cgen_rtx_error";
@@ -1738,7 +1718,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/iq2000/configure.ac b/sim/iq2000/configure.ac
index e35068f..d203722 100644
--- a/sim/iq2000/configure.ac
+++ b/sim/iq2000/configure.ac
@@ -3,6 +3,5 @@ AC_INIT(Makefile.in)
AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL(iq2000)
SIM_AC_OUTPUT
diff --git a/sim/iq2000/sim-if.c b/sim/iq2000/sim-if.c
index 6df4b94..9728882 100644
--- a/sim/iq2000/sim-if.c
+++ b/sim/iq2000/sim-if.c
@@ -64,6 +64,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = iq2000_sim_machs;
+ STATE_MODEL_NAME (sd) = "iq2000";
current_alignment = STRICT_ALIGNMENT;
current_target_byte_order = BFD_ENDIAN_BIG;
diff --git a/sim/lm32/ChangeLog b/sim/lm32/ChangeLog
index 6d2d238..f9092a9 100644
--- a/sim/lm32/ChangeLog
+++ b/sim/lm32/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(lm32_sim_machs): ... this.
* sim-if.c (lm32_sim_machs): New decl.
diff --git a/sim/lm32/aclocal.m4 b/sim/lm32/aclocal.m4
index 212a399..ca624a7 100644
--- a/sim/lm32/aclocal.m4
+++ b/sim/lm32/aclocal.m4
@@ -12,6 +12,5 @@
# PARTICULAR PURPOSE.
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/lm32/configure b/sim/lm32/configure
index 2fa956b..1f18282 100755
--- a/sim/lm32/configure
+++ b/sim/lm32/configure
@@ -628,13 +628,11 @@ PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL
-sim_scache
-sim_default_model'
+sim_scache'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_scache
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1248,8 +1246,6 @@ Optional Features:
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
Report bugs to the package provider.
_ACEOF
@@ -1701,22 +1697,6 @@ fi
-default_sim_default_model="lm32"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
cgen_breaks=""
if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then
cgen_breaks="break cgen_rtx_error";
@@ -1738,7 +1718,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/lm32/configure.ac b/sim/lm32/configure.ac
index 96b6f0e..d203722 100644
--- a/sim/lm32/configure.ac
+++ b/sim/lm32/configure.ac
@@ -3,6 +3,5 @@ AC_INIT(Makefile.in)
AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL(lm32)
SIM_AC_OUTPUT
diff --git a/sim/lm32/sim-if.c b/sim/lm32/sim-if.c
index abb9ad7..f9143ea 100644
--- a/sim/lm32/sim-if.c
+++ b/sim/lm32/sim-if.c
@@ -95,6 +95,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = lm32_sim_machs;
+ STATE_MODEL_NAME (sd) = "lm32";
current_alignment = STRICT_ALIGNMENT;
current_target_byte_order = BFD_ENDIAN_BIG;
diff --git a/sim/m32r/ChangeLog b/sim/m32r/ChangeLog
index d2abefc..d738f5d 100644
--- a/sim/m32r/ChangeLog
+++ b/sim/m32r/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(m32r_sim_machs): ... this.
* sim-if.c (m32r_sim_machs): New decl.
diff --git a/sim/m32r/aclocal.m4 b/sim/m32r/aclocal.m4
index 212a399..ca624a7 100644
--- a/sim/m32r/aclocal.m4
+++ b/sim/m32r/aclocal.m4
@@ -12,6 +12,5 @@
# PARTICULAR PURPOSE.
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/m32r/configure b/sim/m32r/configure
index e9b4b76..25077dd 100755
--- a/sim/m32r/configure
+++ b/sim/m32r/configure
@@ -630,13 +630,11 @@ PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL
-sim_scache
-sim_default_model'
+sim_scache'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_scache
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1250,8 +1248,6 @@ Optional Features:
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
Report bugs to the package provider.
_ACEOF
@@ -1703,22 +1699,6 @@ fi
-default_sim_default_model="m32r/d"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
case "${target_alias}" in
m32r*-linux*)
traps_obj=traps-linux.o
@@ -1753,7 +1733,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/m32r/configure.ac b/sim/m32r/configure.ac
index f98adb2..eed2e91 100644
--- a/sim/m32r/configure.ac
+++ b/sim/m32r/configure.ac
@@ -3,7 +3,6 @@ AC_INIT(Makefile.in)
AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL(m32r/d)
case "${target_alias}" in
m32r*-linux*)
diff --git a/sim/m32r/sim-if.c b/sim/m32r/sim-if.c
index 33ae7c1..8957e83 100644
--- a/sim/m32r/sim-if.c
+++ b/sim/m32r/sim-if.c
@@ -58,6 +58,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = m32r_sim_machs;
+ STATE_MODEL_NAME (sd) = "m32r/d";
current_alignment = STRICT_ALIGNMENT;
current_target_byte_order = BFD_ENDIAN_BIG;
diff --git a/sim/m4/sim_ac_option_default_model.m4 b/sim/m4/sim_ac_option_default_model.m4
deleted file mode 100644
index 1150937..0000000
--- a/sim/m4/sim_ac_option_default_model.m4
+++ /dev/null
@@ -1,31 +0,0 @@
-dnl Copyright (C) 1997-2021 Free Software Foundation, Inc.
-dnl
-dnl This program is free software; you can redistribute it and/or modify
-dnl it under the terms of the GNU General Public License as published by
-dnl the Free Software Foundation; either version 3 of the License, or
-dnl (at your option) any later version.
-dnl
-dnl This program is distributed in the hope that it will be useful,
-dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
-dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-dnl GNU General Public License for more details.
-dnl
-dnl You should have received a copy of the GNU General Public License
-dnl along with this program. If not, see <http://www.gnu.org/licenses/>.
-dnl
-dnl The argument is the default model if none is specified.
-AC_DEFUN([SIM_AC_OPTION_DEFAULT_MODEL],
-[
-default_sim_default_model="ifelse([$1],,0,[$1])"
-AC_ARG_ENABLE(sim-default-model,
-[AS_HELP_STRING([--enable-sim-default-model=model],
- [Specify default model to simulate])],
-[case "${enableval}" in
- yes|no) AC_MSG_ERROR("Missing argument to --enable-sim-default-model");;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi],[sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"])
-])
-AC_SUBST(sim_default_model)
diff --git a/sim/m4/sim_ac_output.m4 b/sim/m4/sim_ac_output.m4
index f9f7016..100e2f9 100644
--- a/sim/m4/sim_ac_output.m4
+++ b/sim/m4/sim_ac_output.m4
@@ -48,7 +48,6 @@ dnl when the rest of the code is in the respective macros.
AC_SUBST(sim_bitsize)
AC_SUBST(sim_float)
AC_SUBST(sim_scache)
-AC_SUBST(sim_default_model)
AC_SUBST(sim_reserved_bits)
dnl Used by common/Make-common.in to see which configure script created it.
diff --git a/sim/mips/ChangeLog b/sim/mips/ChangeLog
index a84059d..2db73e5 100644
--- a/sim/mips/ChangeLog
+++ b/sim/mips/ChangeLog
@@ -1,3 +1,7 @@
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
+ * configure: Regenerate.
+
2021-06-22 Mike Frysinger <vapier@gentoo.org>
* configure: Regenerate.
diff --git a/sim/mips/configure b/sim/mips/configure
index 89c16a7..2cc8d31 100755
--- a/sim/mips/configure
+++ b/sim/mips/configure
@@ -586,7 +586,6 @@ ac_subst_vars='LTLIBOBJS
LIBOBJS
SIM_COMMON_BUILD_FALSE
SIM_COMMON_BUILD_TRUE
-sim_default_model
sim_scache
cgen_breaks
sim_multi_obj
@@ -2212,7 +2211,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/mn10300/ChangeLog b/sim/mn10300/ChangeLog
index 48e8415..b983278 100644
--- a/sim/mn10300/ChangeLog
+++ b/sim/mn10300/ChangeLog
@@ -1,3 +1,7 @@
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
+ * configure: Regenerate.
+
2021-06-22 Mike Frysinger <vapier@gentoo.org>
* configure: Regenerate.
diff --git a/sim/mn10300/configure b/sim/mn10300/configure
index 14257c4..91c58e5 100755
--- a/sim/mn10300/configure
+++ b/sim/mn10300/configure
@@ -586,7 +586,6 @@ ac_subst_vars='LTLIBOBJS
LIBOBJS
SIM_COMMON_BUILD_FALSE
SIM_COMMON_BUILD_TRUE
-sim_default_model
sim_scache
sim_float
cgen_breaks
@@ -1778,7 +1777,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/or1k/ChangeLog b/sim/or1k/ChangeLog
index 94e7e0e..9cd2f22 100644
--- a/sim/or1k/ChangeLog
+++ b/sim/or1k/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * sim-if.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* arch.c (sim_machs): Rename to ...
(or1k_sim_machs): ... this.
* sim-if.c (or1k_sim_machs): New decl.
diff --git a/sim/or1k/aclocal.m4 b/sim/or1k/aclocal.m4
index d0f761f..90a839c 100644
--- a/sim/or1k/aclocal.m4
+++ b/sim/or1k/aclocal.m4
@@ -13,6 +13,5 @@
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
m4_include([../m4/sim_ac_option_bitsize.m4])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_option_scache.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/or1k/configure b/sim/or1k/configure
index adf13d0..3677607 100755
--- a/sim/or1k/configure
+++ b/sim/or1k/configure
@@ -628,14 +628,12 @@ PACKAGE_NAME
PATH_SEPARATOR
SHELL
sim_scache
-sim_default_model
sim_bitsize'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_sim_bitsize
enable_sim_scache
-enable_sim_default_model
'
ac_precious_vars='build_alias
host_alias
@@ -1250,8 +1248,6 @@ Optional Features:
--enable-sim-bitsize=N Specify target bitsize (32 or 64)
--enable-sim-scache=size
Specify simulator execution cache size
- --enable-sim-default-model=model
- Specify default model to simulate
Report bugs to the package provider.
_ACEOF
@@ -1762,22 +1758,6 @@ fi
-default_sim_default_model="or1200"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
cgen_breaks=""
if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then
cgen_breaks="break cgen_rtx_error";
@@ -1799,7 +1779,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/or1k/configure.ac b/sim/or1k/configure.ac
index c72c80c..aaeb121 100644
--- a/sim/or1k/configure.ac
+++ b/sim/or1k/configure.ac
@@ -4,6 +4,5 @@ AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
SIM_AC_OPTION_BITSIZE([32], [31], [32])
SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL([or1200])
SIM_AC_OUTPUT
diff --git a/sim/or1k/sim-if.c b/sim/or1k/sim-if.c
index e835388..3f47ce5 100644
--- a/sim/or1k/sim-if.c
+++ b/sim/or1k/sim-if.c
@@ -164,6 +164,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = or1k_sim_machs;
+ STATE_MODEL_NAME (sd) = "or1200";
current_target_byte_order = BFD_ENDIAN_BIG;
/* The cpu data is kept in a separately allocated chunk of memory. */
diff --git a/sim/riscv/ChangeLog b/sim/riscv/ChangeLog
index 1c98ed5..ec4f69a 100644
--- a/sim/riscv/ChangeLog
+++ b/sim/riscv/ChangeLog
@@ -1,5 +1,12 @@
2021-06-30 Mike Frysinger <vapier@gentoo.org>
+ * configure.ac: Delete SIM_AC_OPTION_DEFAULT_MODEL call.
+ * interp.c (sim_open): Set STATE_MODEL_NAME.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
* interp.c (sim_open): Set STATE_MACHS.
(riscv_sim_machs): New decl.
* machs.c (sim_machs): Rename to ...
diff --git a/sim/riscv/aclocal.m4 b/sim/riscv/aclocal.m4
index 39198e5..3b7f0c1 100644
--- a/sim/riscv/aclocal.m4
+++ b/sim/riscv/aclocal.m4
@@ -13,5 +13,4 @@
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
m4_include([../m4/sim_ac_option_bitsize.m4])
-m4_include([../m4/sim_ac_option_default_model.m4])
m4_include([../m4/sim_ac_output.m4])
diff --git a/sim/riscv/configure b/sim/riscv/configure
index b8b789a..c2e53cc 100755
--- a/sim/riscv/configure
+++ b/sim/riscv/configure
@@ -628,12 +628,10 @@ PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL
-sim_default_model
sim_bitsize'
ac_subst_files=''
ac_user_opts='
enable_option_checking
-enable_sim_default_model
enable_sim_bitsize
'
ac_precious_vars='build_alias
@@ -1246,8 +1244,6 @@ Optional Features:
--disable-option-checking ignore unrecognized --enable/--with options
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-sim-default-model=model
- Specify default model to simulate
--enable-sim-bitsize=N Specify target bitsize (32 or 64)
Report bugs to the package provider.
@@ -1680,29 +1676,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
-# Select the default model for the target.
-riscv_model=
-case "${target}" in
-riscv32*) riscv_model="RV32G" ;;
-riscv*) riscv_model="RV64G" ;;
-esac
-
-default_sim_default_model="${riscv_model}"
-# Check whether --enable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then :
- enableval=$enable_sim_default_model; case "${enableval}" in
- yes|no) as_fn_error $? "\"Missing argument to --enable-sim-default-model\"" "$LINENO" 5;;
- *) sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
- echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
- sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
# Select the bitsize of the target.
riscv_addr_bitsize=
case "${target}" in
@@ -1790,7 +1763,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=
diff --git a/sim/riscv/configure.ac b/sim/riscv/configure.ac
index 01afe51..6edb28c 100644
--- a/sim/riscv/configure.ac
+++ b/sim/riscv/configure.ac
@@ -2,14 +2,6 @@ dnl Process this file with autoconf to produce a configure script.
AC_INIT(Makefile.in)
AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
-# Select the default model for the target.
-riscv_model=
-case "${target}" in
-riscv32*) riscv_model="RV32G" ;;
-riscv*) riscv_model="RV64G" ;;
-esac
-SIM_AC_OPTION_DEFAULT_MODEL(${riscv_model})
-
# Select the bitsize of the target.
riscv_addr_bitsize=
case "${target}" in
diff --git a/sim/riscv/interp.c b/sim/riscv/interp.c
index 8908ed1..202412a 100644
--- a/sim/riscv/interp.c
+++ b/sim/riscv/interp.c
@@ -66,6 +66,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback,
/* Set default options before parsing user options. */
STATE_MACHS (sd) = riscv_sim_machs;
+ STATE_MODEL_NAME (sd) = WITH_TARGET_WORD_BITSIZE == 32 ? "RV32G" : "RV64G";
current_target_byte_order = BFD_ENDIAN_LITTLE;
/* The cpu data is kept in a separately allocated chunk of memory. */
diff --git a/sim/v850/ChangeLog b/sim/v850/ChangeLog
index f14ab0f..b68aff0 100644
--- a/sim/v850/ChangeLog
+++ b/sim/v850/ChangeLog
@@ -1,3 +1,7 @@
+2021-06-30 Mike Frysinger <vapier@gentoo.org>
+
+ * configure: Regenerate.
+
2021-06-22 Mike Frysinger <vapier@gentoo.org>
* configure: Regenerate.
diff --git a/sim/v850/configure b/sim/v850/configure
index 14257c4..91c58e5 100755
--- a/sim/v850/configure
+++ b/sim/v850/configure
@@ -586,7 +586,6 @@ ac_subst_vars='LTLIBOBJS
LIBOBJS
SIM_COMMON_BUILD_FALSE
SIM_COMMON_BUILD_TRUE
-sim_default_model
sim_scache
sim_float
cgen_breaks
@@ -1778,7 +1777,6 @@ ac_config_commands="$ac_config_commands stamp-h"
-
SIM_COMMON_BUILD_TRUE='#'
SIM_COMMON_BUILD_FALSE=