-dnl Copyright (C) 2005-2022 Free Software Foundation, Inc.
+dnl Copyright (C) 2005-2023 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
AC_SUBST(SIM_MIPS_FPU_BITSIZE)
dnl Select the IGEN architecture.
-SIM_MIPS_GEN=IGEN
-sim_mips_igen_machine="-M mipsIV"
+SIM_MIPS_GEN=SINGLE
+sim_mips_single_machine="-M mipsIV"
sim_mips_m16_machine="-M mips16,mipsIII"
-sim_mips_igen_filter="32,64,f"
+sim_mips_single_filter="32,64,f"
sim_mips_m16_filter="16"
AS_CASE([${target}],
[mips*tx39*], [dnl
- SIM_MIPS_GEN=IGEN
- sim_mips_igen_filter="32,f"
- sim_mips_igen_machine="-M r3900"],
+ SIM_MIPS_GEN=SINGLE
+ sim_mips_single_filter="32,f"
+ sim_mips_single_machine="-M r3900"],
[mips64vr41*], [dnl
SIM_MIPS_GEN=M16
- sim_mips_igen_machine="-M vr4100"
+ sim_mips_single_machine="-M vr4100"
sim_mips_m16_machine="-M vr4100"],
[mips64*], [dnl
SIM_MIPS_GEN=MULTI
mips32r2:mips32r2,mips3d,mips16,mips16e,mdmx,dsp,dsp2,smartmips:32,f:mipsisa32r2"
sim_mips_multi_default=mipsisa32r2],
[mipsisa32r6*], [dnl
- SIM_MIPS_GEN=IGEN
- sim_mips_igen_machine="-M mips32r6"
- sim_mips_igen_filter="32,f"],
+ SIM_MIPS_GEN=SINGLE
+ sim_mips_single_machine="-M mips32r6"
+ sim_mips_single_filter="32,f"],
[mipsisa32*], [dnl
SIM_MIPS_GEN=M16
- sim_mips_igen_machine="-M mips32,mips16,mips16e,smartmips"
+ sim_mips_single_machine="-M mips32,mips16,mips16e,smartmips"
sim_mips_m16_machine="-M mips16,mips16e,mips32"
- sim_mips_igen_filter="32,f"],
+ sim_mips_single_filter="32,f"],
[mipsisa64r2*], [dnl
SIM_MIPS_GEN=M16
- sim_mips_igen_machine="-M mips64r2,mips3d,mips16,mips16e,mdmx,dsp,dsp2"
+ sim_mips_single_machine="-M mips64r2,mips3d,mips16,mips16e,mdmx,dsp,dsp2"
sim_mips_m16_machine="-M mips16,mips16e,mips64r2"],
[mipsisa64r6*], [dnl
- SIM_MIPS_GEN=IGEN
- sim_mips_igen_machine="-M mips64r6"],
+ SIM_MIPS_GEN=SINGLE
+ sim_mips_single_machine="-M mips64r6"],
[mipsisa64sb1*], [dnl
- SIM_MIPS_GEN=IGEN
- sim_mips_igen_machine="-M mips64,mips3d,sb1"],
+ SIM_MIPS_GEN=SINGLE
+ sim_mips_single_machine="-M mips64,mips3d,sb1"],
[mipsisa64*], [dnl
SIM_MIPS_GEN=M16
- sim_mips_igen_machine="-M mips64,mips3d,mips16,mips16e,mdmx"
+ sim_mips_single_machine="-M mips64,mips3d,mips16,mips16e,mdmx"
sim_mips_m16_machine="-M mips16,mips16e,mips64"],
[mips*lsi*], [dnl
SIM_MIPS_GEN=M16
- sim_mips_igen_machine="-M mipsIII,mips16"
+ sim_mips_single_machine="-M mipsIII,mips16"
sim_mips_m16_machine="-M mips16,mipsIII"
- sim_mips_igen_filter="32,f"],
+ sim_mips_single_filter="32,f"],
[mips*], [dnl
- SIM_MIPS_GEN=IGEN
- sim_mips_igen_filter="32,f"])
+ SIM_MIPS_GEN=SINGLE
+ sim_mips_single_filter="32,f"])
dnl The MULTI generator can combine several simulation engines into one.
dnl executable. A configuration which uses the MULTI should set two
cat << __EOF__ > mips/multi-run.c
/* Main entry point for MULTI simulators.
- Copyright (C) 2003-2022 Free Software Foundation, Inc.
+ Copyright (C) 2003-2023 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
#include "sim-main.h"
#include "multi-include.h"
-#include "elf-bfd.h"
-#include "elfxx-mips.h"
+#include "bfd/elf-bfd.h"
+#include "bfd/elfxx-mips.h"
#include "elf/mips.h"
#define SD sd
dnl The top-level function for the mips16 simulator is
dnl in a file m16${name}_run.c, generated by the
dnl tmp-run-multi Makefile rule.
- AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" m16${name}_run.c"])
- AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" m16${name}_run.o"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" mips/m16${name}_run.c"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" mips/m16${name}_run.o"])
AS_VAR_APPEND([SIM_MIPS_IGEN_ITABLE_FLAGS], [" -F 16"])
],
[*:*micromips32*:*], [dnl
dnl The top-level function for the micromips simulator is
dnl in a file micromips${name}_run.c, generated by the
dnl tmp-run-multi Makefile rule.
- AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" micromips${name}_run.c"])
- AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" micromips${name}_run.o"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" mips/micromips${name}_run.c"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" mips/micromips${name}_run.o"])
AS_VAR_APPEND([SIM_MIPS_IGEN_ITABLE_FLAGS], [" -F 16,32"])
],
[*:*micromips64*:*], [dnl
dnl The top-level function for the micromips simulator is
dnl in a file micromips${name}_run.c, generated by the
dnl tmp-run-multi Makefile rule.
- AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" micromips${name}_run.c"])
- AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" micromips${name}_run.o"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" mips/micromips${name}_run.c"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" mips/micromips${name}_run.o"])
AS_VAR_APPEND([SIM_MIPS_IGEN_ITABLE_FLAGS], [" -F 16,32,64"])
],
[ws=m32])
dnl and ${SIM_MIPS_MULTI_OBJ}.
for w in ${ws}; do
for base in engine icache idecode model semantics support; do
- AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" ${w}${name}_${base}.c"])
- AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" ${w}${name}_${base}.h"])
- AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" ${w}${name}_${base}.o"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" mips/${w}${name}_${base}.c"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_SRC], [" mips/${w}${name}_${base}.h"])
+ AS_VAR_APPEND([SIM_MIPS_MULTI_OBJ], [" mips/${w}${name}_${base}.o"])
done
AS_VAR_APPEND([SIM_MIPS_MULTI_IGEN_CONFIGS], [" ${w}${c}"])
done
__EOF__
], [dnl
dnl For clean-extra target.
- SIM_MIPS_MULTI_SRC=doesnt-exist.c
- SIM_MIPS_IGEN_ITABLE_FLAGS='$(SIM_MIPS_IGEN_FLAGS)'
+ SIM_MIPS_MULTI_SRC=mips/doesnt-exist.c
+ SIM_MIPS_IGEN_ITABLE_FLAGS='$(SIM_MIPS_SINGLE_FLAGS)'
AS_VAR_IF([SIM_MIPS_GEN], ["M16"], [AS_VAR_APPEND([SIM_MIPS_IGEN_ITABLE_FLAGS], [' $(SIM_MIPS_M16_FLAGS)'])])
])
-SIM_MIPS_IGEN_FLAGS="-F ${sim_mips_igen_filter} ${sim_mips_igen_machine}"
+SIM_MIPS_SINGLE_FLAGS="-F ${sim_mips_single_filter} ${sim_mips_single_machine}"
SIM_MIPS_M16_FLAGS="-F ${sim_mips_m16_filter} ${sim_mips_m16_machine}"
-AC_SUBST(SIM_MIPS_IGEN_FLAGS)
+AC_SUBST(SIM_MIPS_SINGLE_FLAGS)
AC_SUBST(SIM_MIPS_M16_FLAGS)
AC_SUBST(SIM_MIPS_GEN)
AC_SUBST(SIM_MIPS_IGEN_ITABLE_FLAGS)
AC_SUBST(SIM_MIPS_MULTI_IGEN_CONFIGS)
AC_SUBST(SIM_MIPS_MULTI_SRC)
AC_SUBST(SIM_MIPS_MULTI_OBJ)
+AM_CONDITIONAL([SIM_MIPS_GEN_MODE_SINGLE], [test "$SIM_MIPS_GEN" = "SINGLE"])
+AM_CONDITIONAL([SIM_MIPS_GEN_MODE_M16], [test "$SIM_MIPS_GEN" = "M16"])
+AM_CONDITIONAL([SIM_MIPS_GEN_MODE_MULTI], [test "$SIM_MIPS_GEN" = "MULTI"])