X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=sim%2Fmips%2Facinclude.m4;h=58b55a2782b6b8491bb4508e3416a2eaf4b6a0cf;hb=ae0411a4858e7e55d2f31dde5a66cdaf9d463a26;hp=452dfc84514f4d7aa5ded3cc07fce64f1c35c0e9;hpb=67c952d109873321b45b6de99cdbefbcd4249745;p=binutils-gdb.git diff --git a/sim/mips/acinclude.m4 b/sim/mips/acinclude.m4 index 452dfc84514..58b55a2782b 100644 --- a/sim/mips/acinclude.m4 +++ b/sim/mips/acinclude.m4 @@ -1,4 +1,4 @@ -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 @@ -59,19 +59,19 @@ AC_MSG_RESULT([$SIM_MIPS_FPU_BITSIZE]) 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 @@ -98,36 +98,36 @@ AS_CASE([${target}], 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 @@ -169,7 +169,7 @@ AS_VAR_IF([SIM_MIPS_GEN], ["MULTI"], [dnl 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 @@ -190,8 +190,8 @@ AS_VAR_IF([SIM_MIPS_GEN], ["MULTI"], [dnl #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 @@ -252,8 +252,8 @@ __EOF__ 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 @@ -264,8 +264,8 @@ __EOF__ 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 @@ -276,8 +276,8 @@ __EOF__ 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]) @@ -286,9 +286,9 @@ __EOF__ 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 @@ -320,16 +320,19 @@ __EOF__ __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"])