Compare commits

...

8 Commits

Author SHA1 Message Date
Mike Frysinger
abd30f23b0 sim: aarch64: remove recursive make entirely 2022-11-11 01:44:16 +07:00
Mike Frysinger
5894c5944c squash: more modules.c work 2022-11-11 01:44:16 +07:00
Mike Frysinger
267058274c sim: modules.c: move generation to top-level
In order to compile arch objects from the top-level, we need to
generate the modules.c file, so move that logic up to the top
level first.  The deps are a bit imperfect currently due to the
common/ files not being shared.  That'll improve as we share the
sources more.
2022-11-11 01:44:16 +07:00
Mike Frysinger
007b6af6e1 [WIP] sim: aarch64: merge libsim.a build into top-level 2022-11-11 01:44:16 +07:00
Mike Frysinger
430e1e5517 sim: aarch64: move libsim.a creation to top-level 2022-11-11 01:44:16 +07:00
Mike Frysinger
ef3bd6c15e sim: hw-config.h: move generation to top-level
In order to compile arch objects from the top-level, we need to
generate the hw-config.h header, so move that logic up to the top
level first.
2022-11-11 01:44:16 +07:00
Mike Frysinger
6f9208a40f sim: build: hoist lists of hw devices up
We need these in the top-level to generate libsim.a, but also in the
subdirs to generate hw-config.h.  Move it to the local.mk, and pass
it down when running recursive make.  This avoids duplication, and
makes it available to both.  We can simplify this once we move the
various steps up to the top-level too.
2022-11-11 01:44:16 +07:00
Mike Frysinger
7f19eb0786 sim: build: hoist lists of common objects up
In order to create libsim.a in the common dir, we need the list of
objects for each target.  To avoid duplicating the list with the
recursive make in each port, pass it down as a variable.  This is
a temporary hack until the top-level creates libsim.a for ports.
2022-11-11 01:44:16 +07:00
22 changed files with 217 additions and 161 deletions

View File

@@ -47,8 +47,11 @@ AM_CPPFLAGS = \
-I$(srcroot)/include \
-I../bfd \
-I.. \
-I$(@D) \
-I$(srcdir)/$(@D) \
$(SIM_HW_CFLAGS) \
$(SIM_INLINE)
$(SIM_INLINE) \
$(AM_CPPFLAGS_$(@D))
AM_CPPFLAGS_FOR_BUILD = \
-I$(srcroot)/include \

View File

@@ -21,13 +21,7 @@
## COMMON_PRE_CONFIG_FRAG
SIM_OBJS = \
$(SIM_NEW_COMMON_OBJS) \
interp.o \
cpustate.o \
simulator.o \
memory.o \
sim-resume.o \
SIM_LIBSIM =
## COMMON_POST_CONFIG_FRAG

View File

@@ -16,6 +16,22 @@
## You should have received a copy of the GNU General Public License
## along with this program. If not, see <http://www.gnu.org/licenses/>.
AM_CPPFLAGS_%D% = -DSIM_TOPDIR_BUILD
%C%_libsim_a_SOURCES = \
%D%/cpustate.c \
%D%/interp.c \
%D%/memory.c \
%D%/modules.c \
%D%/simulator.c
%C%_libsim_a_LIBADD = \
$(common_libcommon_a_OBJECTS) \
$(patsubst %,%D%/%,$(SIM_NEW_COMMON_OBJS)) \
$(patsubst %,%D%/dv-%.o,$(SIM_HW_DEVICES)) \
%D%/sim-resume.o
noinst_LIBRARIES += %D%/libsim.a
%C%_run_SOURCES =
%C%_run_LDADD = \
%D%/nrun.o \
@@ -23,3 +39,10 @@
$(SIM_COMMON_LIBS)
noinst_PROGRAMS += %D%/run
SIM_ALL_RECURSIVE_DEPS += %D%/modules.c
$(%C%_libsim_a_OBJECTS) $(%C%_run_OBJECTS) $(%C%_libsim_a_LIBADD): | $(SIM_ALL_RECURSIVE_DEPS)
%D%/%.o: common/%.c | $(SIM_ALL_RECURSIVE_DEPS)
$(AM_V_CC)$(COMPILE) -c -o $@ $<

View File

@@ -71,6 +71,5 @@ CGENDIR = @cgendir@
SIM_INLINE = @SIM_INLINE@
SIM_HW_CFLAGS = @SIM_HW_CFLAGS@
SIM_HW_SOCKSER = @SIM_HW_SOCKSER@
SIM_HW_OBJS = $(SIM_COMMON_HW_OBJS) $(SIM_HW_DEVICES:%=dv-%.o) $(SIM_HW_SOCKSER)
SIM_HW_OBJS = $(SIM_HW_DEVICES:%=dv-%.o)
@SIM_ENABLE_HW_FALSE@SIM_HW_OBJS =

View File

@@ -17,6 +17,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = bfin
SIM_OBJS = \
$(SIM_NEW_COMMON_OBJS) \
bfin-sim.o \
@@ -26,39 +28,6 @@ SIM_OBJS = \
machs.o \
sim-resume.o
SIM_EXTRA_HW_DEVICES = \
bfin_cec \
bfin_ctimer \
bfin_dma \
bfin_dmac \
bfin_ebiu_amc \
bfin_ebiu_ddrc \
bfin_ebiu_sdc \
bfin_emac \
bfin_eppi \
bfin_evt \
bfin_gpio \
bfin_gpio2 \
bfin_gptimer \
bfin_jtag \
bfin_mmu \
bfin_nfc \
bfin_otp \
bfin_pfmon \
bfin_pint \
bfin_pll \
bfin_ppi \
bfin_rtc \
bfin_sic \
bfin_spi \
bfin_trace \
bfin_twi \
bfin_uart \
bfin_uart2 \
bfin_wdog \
bfin_wp \
eth_phy
SIM_EXTRA_CFLAGS = $(SDL_CFLAGS)
## COMMON_POST_CONFIG_FRAG

View File

@@ -24,6 +24,40 @@
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = \
bfin_cec \
bfin_ctimer \
bfin_dma \
bfin_dmac \
bfin_ebiu_amc \
bfin_ebiu_ddrc \
bfin_ebiu_sdc \
bfin_emac \
bfin_eppi \
bfin_evt \
bfin_gpio \
bfin_gpio2 \
bfin_gptimer \
bfin_jtag \
bfin_mmu \
bfin_nfc \
bfin_otp \
bfin_pfmon \
bfin_pint \
bfin_pll \
bfin_ppi \
bfin_rtc \
bfin_sic \
bfin_spi \
bfin_trace \
bfin_twi \
bfin_uart \
bfin_uart2 \
bfin_wdog \
bfin_wp \
eth_phy
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"
%D%/linux-fixed-code.h: @MAINT@ $(srcdir)/%D%/linux-fixed-code.s %D%/local.mk %D%/$(am__dirstamp)
$(AM_V_GEN)$(AS_FOR_TARGET_BFIN) $(srcdir)/%D%/linux-fixed-code.s -o %D%/linux-fixed-code.o
$(AM_V_at)(\

View File

@@ -100,6 +100,7 @@ SIM_EXTRA_CFLAGS =
SIM_EXTRA_LIBS =
# List of main object files for `run'.
SIM_RUN_OBJS = nrun.o
SIM_LIBSIM = libsim.a
# Dependency of `clean' to clean any extra files.
SIM_EXTRA_CLEAN =
# Likewise `distclean'
@@ -114,50 +115,6 @@ SIM_EXTRA_DISTCLEAN =
# here. Some files are used by all simulators (e.g. callback.o).
# Those files are specified in LIB_OBJS below.
SIM_COMMON_HW_OBJS = \
hw-alloc.o \
hw-base.o \
hw-device.o \
hw-events.o \
hw-handles.o \
hw-instances.o \
hw-ports.o \
hw-properties.o \
hw-tree.o \
sim-hw.o \
SIM_NEW_COMMON_OBJS = \
sim-arange.o \
sim-bits.o \
sim-close.o \
sim-command.o \
sim-config.o \
sim-core.o \
sim-cpu.o \
sim-endian.o \
sim-engine.o \
sim-events.o \
sim-fpu.o \
sim-hload.o \
sim-hrw.o \
sim-io.o \
sim-info.o \
sim-memopt.o \
sim-model.o \
sim-module.o \
sim-options.o \
sim-profile.o \
sim-reason.o \
sim-reg.o \
sim-signal.o \
sim-stop.o \
sim-syscall.o \
sim-trace.o \
sim-utils.o \
sim-watch.o \
\
$(SIM_HW_OBJS) \
## End COMMON_PRE_CONFIG_FRAG
## COMMON_POST_CONFIG_FRAG
@@ -180,7 +137,8 @@ BUILD_CFLAGS = $(CFLAGS_FOR_BUILD) $(CSEARCH)
COMMON_DEP_CFLAGS = $(CONFIG_CFLAGS) $(CSEARCH) $(SIM_EXTRA_CFLAGS)
SIM_HW_DEVICES = cfi core pal glue $(SIM_EXTRA_HW_DEVICES)
SIM_HW_DEVICES = $(SIM_HW_DEVICES_) $($(arch)_SIM_EXTRA_HW_DEVICES)
SIM_NEW_COMMON_OBJS = $(SIM_NEW_COMMON_OBJS_) $(SIM_HW_OBJS)
LIBIBERTY_LIB = ../../libiberty/libiberty.a
BFD_LIB = ../../bfd/libbfd.la
@@ -208,7 +166,7 @@ LINK_FOR_BUILD = $(CC_FOR_BUILD) $(BUILD_CFLAGS) $(LDFLAGS_FOR_BUILD) -o $@
RUNTESTFLAGS =
all: libsim.a $(SIM_RUN_OBJS)
all: $(SIM_LIBSIM) $(LIB_OBJS) $(SIM_RUN_OBJS)
libsim.a: $(LIB_OBJS)
$(SILENCE) rm -f libsim.a
@@ -238,10 +196,7 @@ override POSTCOMPILE =
endif
all_object_files = $(LIB_OBJS) $(SIM_RUN_OBJS)
generated_files = \
$(SIM_EXTRA_DEPS) \
hw-config.h \
modules.c
generated_files = $(SIM_EXTRA_DEPS)
# Ensure that generated files are created early. Use order-only
# dependencies if available. They require GNU make 3.80 or newer,
@@ -255,49 +210,11 @@ endif
# Dependencies.
-include $(patsubst %.o, $(DEPDIR)/%.Po, $(all_object_files))
# FIXME This is one very simple-minded way of generating the file hw-config.h
hw-config.h: stamp-hw ; @true
stamp-hw: Makefile.in $(srccom)/Make-common.in $(config.status) Makefile
$(ECHO_STAMP) hw-config.h
$(SILENCE) ( \
sim_hw="$(SIM_HW_DEVICES)" ; \
echo "/* generated by Makefile */" ; \
printf "extern const struct hw_descriptor dv_%s_descriptor[];\n" $$sim_hw ; \
echo "const struct hw_descriptor * const hw_descriptors[] = {" ; \
printf " dv_%s_descriptor,\n" $$sim_hw ; \
echo " NULL," ; \
echo "};" \
) > tmp-hw.h
$(SILENCE) $(SHELL) $(srcroot)/move-if-change tmp-hw.h hw-config.h
$(SILENCE) touch $@
test-hw-events: $(srccom)/hw-events.c libsim.a
$(ECHO_CCLD) $(LIBTOOL) $(AM_V_lt) --tag=CC --mode=link \
$(CC) $(ALL_CFLAGS) -DMAIN -o test-hw-events$(EXEEXT) \
$(srccom)/hw-events.c libsim.a $(EXTRA_LIBS)
# See sim_pre_argv_init and sim_module_install in sim-module.c for more details.
modules.c: stamp-modules ; @true
stamp-modules: Makefile $(SIM_OBJS:.o=.c)
$(ECHO_STAMP) modules.c
$(SILENCE) LANG=C ; export LANG ; \
LC_ALL=C ; export LC_ALL ; \
sed -n -e '/^sim_install_/{s/^\(sim_install_[a-z_0-9A-Z]*\).*/\1/;p}' $^ | sort >$@.l-tmp
@set -e; (\
echo '/* Do not modify this file. */'; \
echo '/* It is created automatically by the Makefile. */'; \
echo '#include "libiberty.h"'; \
echo '#include "sim-module.h"'; \
sed -e 's:\(.*\):extern MODULE_INIT_FN \1;:' $@.l-tmp; \
echo 'MODULE_INSTALL_FN * const sim_modules_detected[] = {'; \
sed -e 's:\(.*\): \1,:' $@.l-tmp; \
echo '};'; \
echo 'const int sim_modules_detected_len = ARRAY_SIZE (sim_modules_detected);'; \
) >$@.tmp
$(SILENCE) $(SHELL) $(srcroot)/move-if-change $@.tmp modules.c
$(SILENCE) rm -f $@.l-tmp $@.tmp
$(SILENCE) touch $@
# Support targets.
install:
@@ -333,8 +250,6 @@ TAGS: force
mostlyclean clean: $(SIM_EXTRA_CLEAN)
rm -f *.[oa] *~ core \
run$(EXEEXT) libsim.a \
hw-config.h stamp-hw \
modules.c stamp-modules \
tmp-mloop.hin tmp-mloop.h tmp-mloop.cin tmp-mloop.c
distclean maintainer-clean realclean: clean $(SIM_EXTRA_DISTCLEAN)

View File

@@ -35,7 +35,7 @@
#undef PACKAGE_VERSION
/* Include common sim's various configure tests. */
#ifndef SIM_COMMON_BUILD
#if !defined(SIM_COMMON_BUILD) && !defined(SIM_TOPDIR_BUILD)
#include "../config.h"
#else
#include "config.h"

View File

@@ -18,9 +18,8 @@
## Parts of the common/ sim code that have been unified.
## Most still lives in common/Make-common.in.
AM_CPPFLAGS += \
-I$(srcdir)/%D% \
-DSIM_COMMON_BUILD
AM_CPPFLAGS += -I$(srcdir)/%D%
AM_CPPFLAGS_%D% = -DSIM_COMMON_BUILD
AM_CPPFLAGS_FOR_BUILD += -I$(srcdir)/%D%
## This makes sure common parts are available before building the arch-subdirs
@@ -56,6 +55,112 @@ CLEANFILES += \
## For subdirs.
##
SIM_COMMON_HW_OBJS = \
hw-alloc.o \
hw-base.o \
hw-device.o \
hw-events.o \
hw-handles.o \
hw-instances.o \
hw-ports.o \
hw-properties.o \
hw-tree.o \
sim-hw.o
SIM_NEW_COMMON_OBJS = \
sim-arange.o \
sim-bits.o \
sim-close.o \
sim-command.o \
sim-config.o \
sim-core.o \
sim-cpu.o \
sim-endian.o \
sim-engine.o \
sim-events.o \
sim-fpu.o \
sim-hload.o \
sim-hrw.o \
sim-io.o \
sim-info.o \
sim-memopt.o \
sim-model.o \
sim-module.o \
sim-options.o \
sim-profile.o \
sim-reason.o \
sim-reg.o \
sim-signal.o \
sim-stop.o \
sim-syscall.o \
sim-trace.o \
sim-utils.o \
sim-watch.o
AM_MAKEFLAGS += SIM_NEW_COMMON_OBJS_="$(SIM_NEW_COMMON_OBJS)"
SIM_HW_DEVICES = cfi core pal glue
if SIM_ENABLE_HW
SIM_NEW_COMMON_OBJS += \
$(SIM_COMMON_HW_OBJS) \
$(SIM_HW_SOCKSER)
AM_MAKEFLAGS += SIM_HW_DEVICES_="$(SIM_HW_DEVICES)"
endif
# FIXME This is one very simple-minded way of generating the file hw-config.h.
%/hw-config.h: %/stamp-hw ; @true
%/stamp-hw: Makefile
$(AM_V_GEN)set -e; \
( \
sim_hw="$(SIM_HW_DEVICES) $($(@D)_SIM_EXTRA_HW_DEVICES)" ; \
echo "/* generated by Makefile */" ; \
printf "extern const struct hw_descriptor dv_%s_descriptor[];\n" $$sim_hw ; \
echo "const struct hw_descriptor * const hw_descriptors[] = {" ; \
printf " dv_%s_descriptor,\n" $$sim_hw ; \
echo " NULL," ; \
echo "};" \
) > $@.tmp; \
$(SHELL) $(srcroot)/move-if-change $@.tmp $(@D)/hw-config.h; \
touch $@
.PRECIOUS: %/stamp-hw
%C%_HW_CONFIG_H_TARGETS = $(patsubst %,%/hw-config.h,$(SIM_ENABLED_ARCHES))
MOSTLYCLEANFILES += $(%C%_HW_CONFIG_H_TARGETS) $(patsubst %,%/stamp-hw,$(SIM_ENABLED_ARCHES))
SIM_ALL_RECURSIVE_DEPS += $(%C%_HW_CONFIG_H_TARGETS)
# See sim_pre_argv_init and sim_module_install in sim-module.c for more details.
GEN_MODULES_C_SRCS = \
$(wildcard \
$(patsubst %.o,$(srcdir)/%.c,$($(@D)_libsim_a_OBJECTS) $($(@D)_libsim_a_LIBADD)) \
$(patsubst $(@D)/%.o,$(srcdir)/common/%.c,$($(@D)_libsim_a_LIBADD)))
%/modules.c: %/stamp-modules ; @true
%/stamp-modules: Makefile
$(AM_V_GEN)set -e; \
LANG=C ; export LANG; \
LC_ALL=C ; export LC_ALL; \
sed -n -e '/^sim_install_/{s/^\(sim_install_[a-z_0-9A-Z]*\).*/\1/;p}' Makefile $(GEN_MODULES_C_SRCS) | sort >$@.l-tmp; \
( \
echo '/* Do not modify this file. */'; \
echo '/* It is created automatically by the Makefile. */'; \
echo '#include "libiberty.h"'; \
echo '#include "sim-module.h"'; \
sed -e 's:\(.*\):extern MODULE_INIT_FN \1;:' $@.l-tmp; \
echo 'MODULE_INSTALL_FN * const sim_modules_detected[] = {'; \
sed -e 's:\(.*\): \1,:' $@.l-tmp; \
echo '};'; \
echo 'const int sim_modules_detected_len = ARRAY_SIZE (sim_modules_detected);'; \
) >$@.tmp; \
$(SHELL) $(srcroot)/move-if-change $@.tmp $(@D)/modules.c; \
rm -f $@.l-tmp; \
touch $@
.PRECIOUS: %/stamp-modules
%C%_GEN_MODULES_C_TARGETS = $(patsubst %,%/modules.c,$(SIM_ENABLED_ARCHES))
MOSTLYCLEANFILES += $(%C%_GEN_MODULES_C_TARGETS) $(patsubst %,%/stamp-moules,$(SIM_ENABLED_ARCHES))
SIM_ALL_RECURSIVE_DEPS += $(%C%_GEN_MODULES_C_TARGETS)
LIBIBERTY_LIB = ../libiberty/libiberty.a
BFD_LIB = ../bfd/libbfd.la
OPCODES_LIB = ../opcodes/libopcodes.la

View File

@@ -70,7 +70,7 @@ m4_define([SIM_BUILD_TARGET], [dnl
AS_VAR_APPEND([SIM_ENABLED_ARCHES], [" $1"])
m4_if($2, [true], [dnl
AC_CONFIG_SUBDIRS($1)
], [dnl
], $2, [false], [], [dnl
AC_CONFIG_FILES($1/Makefile.sim:$1/Makefile.in)
AC_CONFIG_COMMANDS([$1/Makefile],
[sed -n \
@@ -88,10 +88,12 @@ m4_define([SIM_BUILD_TARGET], [dnl
AS_VAR_APPEND([SIM_SUBDIRS], [" $1"])
])
AC_CONFIG_FILES($1/.gdbinit:common/gdbinit.in)
dnl Create the depdirs for ports until we can convert them to automake.
AC_CONFIG_COMMANDS([depdir-$1],
[$SHELL $ac_aux_dir/mkinstalldirs $1/$DEPDIR],
[ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR])
m4_if($2, [false], [], [dnl
dnl Create the depdirs for ports until we can convert them to automake.
AC_CONFIG_COMMANDS([depdir-$1],
[$SHELL $ac_aux_dir/mkinstalldirs $1/$DEPDIR],
[ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR])
])
])
dnl Enable a particular arch subdir.
dnl arg[1] is the matching target triple.
@@ -125,7 +127,7 @@ if test "${enable_sim}" != no; then
sim_igen=no
for targ in `echo $target $enable_targets | sed 's/,/ /g'`
do
SIM_TARGET([aarch64*-*-*], [aarch64])
SIM_TARGET([aarch64*-*-*], [aarch64], [false])
SIM_TARGET([arm*-*-*], [arm])
SIM_TARGET([avr*-*-*], [avr])
SIM_TARGET([bfin-*-*], [bfin])

View File

@@ -19,6 +19,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = cris
CRISV10F_OBJS = crisv10f.o cpuv10.o decodev10.o modelv10.o mloopv10f.o
CRISV32F_OBJS = crisv32f.o cpuv32.o decodev32.o modelv32.o mloopv32f.o
@@ -31,14 +33,10 @@ SIM_OBJS = \
$(CRISV32F_OBJS) \
traps.o
SIM_EXTRA_HW_DEVICES = rv cris cris_900000xx
SIM_EXTRA_CLEAN = cris-clean
## COMMON_POST_CONFIG_FRAG
arch = cris
cris-clean:
-rm -f stamp-arch
-rm -f tmp-*

View File

@@ -24,6 +24,9 @@
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = rv cris cris_900000xx
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"
## rvdummy is just used for testing -- it runs on the same host as `run`.
## It does nothing if --enable-sim-hardware isn't active.
%C%_rvdummy_SOURCES = %D%/rvdummy.c

View File

@@ -3,6 +3,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = lm32
# List of object files, less common parts.
SIM_OBJS = \
$(SIM_NEW_COMMON_OBJS) \
@@ -12,14 +14,10 @@ SIM_OBJS = \
cpu.o decode.o sem.o model.o mloop.o \
lm32.o traps.o user.o
SIM_EXTRA_HW_DEVICES = lm32cpu lm32timer lm32uart
SIM_EXTRA_CLEAN = lm32-clean
## COMMON_POST_CONFIG_FRAG
arch = lm32
lm32-clean:
rm -f stamp-arch stamp-cpu
rm -f tmp-*

View File

@@ -24,6 +24,9 @@
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = lm32cpu lm32timer lm32uart
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"
%C%_BUILD_OUTPUTS = \
%D%/eng.h \
%D%/mloop.c \

View File

@@ -19,6 +19,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = m32r
M32R_OBJS = m32r.o cpu.o decode.o sem.o model.o mloop.o
M32RX_OBJS = m32rx.o cpux.o decodex.o modelx.o mloopx.o
M32R2_OBJS = m32r2.o cpu2.o decode2.o model2.o mloop2.o
@@ -33,8 +35,6 @@ SIM_OBJS = \
$(M32R2_OBJS) \
traps.o
SIM_EXTRA_HW_DEVICES = m32r_cache m32r_uart
SIM_EXTRA_CLEAN = m32r-clean
# Some modules don't build cleanly yet.
@@ -42,8 +42,6 @@ cpu.o cpu2.o cpux.o m32r.o m32r2.o m32rx.o mloop.o mloop2.o mloopx.o sem.o sim-i
## COMMON_POST_CONFIG_FRAG
arch = m32r
m32r-clean:
rm -f stamp-arch stamp-cpu stamp-xcpu stamp-2cpu
rm -f tmp-*

View File

@@ -24,6 +24,9 @@
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = m32r_cache m32r_uart
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"
%C%_BUILD_OUTPUTS = \
%D%/eng.h \
%D%/mloop.c \

View File

@@ -17,6 +17,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = m68hc11
M68HC11_OBJS = interp.o m68hc11int.o m68hc12int.o \
emulos.o interrupts.o m68hc11_sim.o
@@ -24,8 +26,6 @@ SIM_OBJS = $(M68HC11_OBJS) \
$(SIM_NEW_COMMON_OBJS) \
sim-resume.o
SIM_EXTRA_HW_DEVICES = m68hc11 m68hc11sio m68hc11eepr m68hc11tim m68hc11spi nvram
# We must use 32-bit addresses to support memory bank switching.
# The WORD_BITSIZE is normally 16 but must be switched (temporarily)
# to 32 to avoid a bug in the sim-common which uses 'unsigned_word'

View File

@@ -24,6 +24,9 @@
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = m68hc11 m68hc11sio m68hc11eepr m68hc11tim m68hc11spi nvram
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"
%C%_BUILD_OUTPUTS = \
%D%/gencode$(EXEEXT) \
%D%/m68hc11int.c \

View File

@@ -3,6 +3,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = mips
# Object files created by various simulator generators.
@@ -64,8 +66,6 @@ SIM_OBJS = \
sim-main.o \
sim-resume.o \
SIM_EXTRA_HW_DEVICES = tx3904cpu tx3904irc tx3904tmr tx3904sio
# List of flags to always pass to $(CC).
SIM_SUBTARGET=@SIM_SUBTARGET@
SIM_EXTRA_CFLAGS = $(SIM_SUBTARGET)

View File

@@ -23,3 +23,6 @@
$(SIM_COMMON_LIBS)
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = tx3904cpu tx3904irc tx3904tmr tx3904sio
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"

View File

@@ -17,6 +17,8 @@
## COMMON_PRE_CONFIG_FRAG
arch = mn10300
MN10300_OBJS = \
itable.o semantics.o idecode.o icache.o engine.o irun.o support.o \
$(SIM_NEW_COMMON_OBJS) \
@@ -25,8 +27,6 @@ MN10300_OBJS = \
SIM_OBJS = $(MN10300_OBJS) interp.o
SIM_EXTRA_HW_DEVICES = mn103cpu mn103int mn103tim mn103ser mn103iop
# List of extra flags to always pass to $(CC).
SIM_EXTRA_CFLAGS = \
-DPOLL_QUIT_INTERVAL=0x20 \

View File

@@ -24,6 +24,9 @@
noinst_PROGRAMS += %D%/run
%C%_SIM_EXTRA_HW_DEVICES = mn103cpu mn103int mn103tim mn103ser mn103iop
AM_MAKEFLAGS += %C%_SIM_EXTRA_HW_DEVICES="$(%C%_SIM_EXTRA_HW_DEVICES)"
%C%_BUILT_SRC_FROM_IGEN = \
%D%/icache.h \
%D%/icache.c \