a4f3ed629e
This is a generic floating point multiply and accumulate test for single precision floating point values. I've split of the common float functions into a helper library so additional tests can use the same common code. As I don't have references for all architectures I've allowed some flexibility for tests to pass without reference files. They can be added as we get collect them. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
47 lines
1.4 KiB
Makefile
47 lines
1.4 KiB
Makefile
# -*- Mode: makefile -*-
|
|
#
|
|
# Multiarch Tests - included from tests/tcg/Makefile.target
|
|
#
|
|
# These tests are plain C and built without any architecture specific code.
|
|
#
|
|
|
|
MULTIARCH_SRC=$(SRC_PATH)/tests/tcg/multiarch
|
|
|
|
# Set search path for all sources
|
|
VPATH += $(MULTIARCH_SRC)
|
|
MULTIARCH_SRCS =$(notdir $(wildcard $(MULTIARCH_SRC)/*.c))
|
|
MULTIARCH_TESTS =$(filter-out float_helpers, $(MULTIARCH_SRCS:.c=))
|
|
|
|
#
|
|
# The following are any additional rules needed to build things
|
|
#
|
|
|
|
|
|
float_madds: LDFLAGS+=-lm
|
|
float_madds: float_madds.c float_helpers.c
|
|
$(CC) $(CFLAGS) $(EXTRA_CFLAGS) $< $(MULTIARCH_SRC)/float_helpers.c -o $@ $(LDFLAGS)
|
|
|
|
run-float_madds: float_madds
|
|
$(call run-test,$<, $(QEMU) $(QEMU_OPTS) $<,"$< on $(TARGET_NAME)")
|
|
$(call conditional-diff-out,$<,$(SRC_PATH)/tests/tcg/$(TARGET_NAME)/$<.ref)
|
|
|
|
|
|
testthread: LDFLAGS+=-lpthread
|
|
|
|
# We define the runner for test-mmap after the individual
|
|
# architectures have defined their supported pages sizes. If no
|
|
# additional page sizes are defined we only run the default test.
|
|
|
|
# default case (host page size)
|
|
run-test-mmap: test-mmap
|
|
$(call run-test, test-mmap, $(QEMU) $<, \
|
|
"$< (default) on $(TARGET_NAME)")
|
|
|
|
# additional page sizes (defined by each architecture adding to EXTRA_RUNS)
|
|
run-test-mmap-%: test-mmap
|
|
$(call run-test, test-mmap-$*, $(QEMU) -p $* $<,\
|
|
"$< ($* byte pages) on $(TARGET_NAME)")
|
|
|
|
# Update TESTS
|
|
TESTS += $(MULTIARCH_TESTS)
|