aboutsummaryrefslogtreecommitdiff
path: root/arch_test_target
diff options
context:
space:
mode:
Diffstat (limited to 'arch_test_target')
-rw-r--r--arch_test_target/spike/device/rv32e_unratified/C/Makefile.include35
-rw-r--r--arch_test_target/spike/device/rv32e_unratified/E/Makefile.include35
-rw-r--r--arch_test_target/spike/device/rv32e_unratified/M/Makefile.include35
3 files changed, 3 insertions, 102 deletions
diff --git a/arch_test_target/spike/device/rv32e_unratified/C/Makefile.include b/arch_test_target/spike/device/rv32e_unratified/C/Makefile.include
index 7aad017..daf0f43 100644
--- a/arch_test_target/spike/device/rv32e_unratified/C/Makefile.include
+++ b/arch_test_target/spike/device/rv32e_unratified/C/Makefile.include
@@ -1,37 +1,4 @@
-TARGET_SIM ?= spike
-TARGET_FLAGS ?= $(RISCV_TARGET_FLAGS)
-ifeq ($(shell command -v $(TARGET_SIM) 2> /dev/null),)
- $(error Target simulator executable '$(TARGET_SIM)` not found)
-endif
-
-RISCV_PREFIX ?= riscv32-unknown-elf-
-RISCV_GCC ?= $(RISCV_PREFIX)gcc
-RISCV_OBJDUMP ?= $(RISCV_PREFIX)objdump
-RISCV_GCC_OPTS ?= -g -static -mcmodel=medany -fvisibility=hidden -nostdlib -nostartfiles $(RVTEST_DEFINES)
-
-COMPILE_CMD = $$(RISCV_GCC) $(1) $$(RISCV_GCC_OPTS) \
- -I$(ROOTDIR)/riscv-test-suite/env/ \
- -I$(TARGETDIR)/$(RISCV_TARGET)/ \
- -T$(TARGETDIR)/$(RISCV_TARGET)/link.ld \
- $$(<) -o $$@
-OBJ_CMD = $$(RISCV_OBJDUMP) $$@ -D > $$@.objdump; \
- $$(RISCV_OBJDUMP) $$@ --source > $$@.debug
-
-
-COMPILE_TARGET=\
- $(COMPILE_CMD); \
- if [ $$$$? -ne 0 ] ; \
- then \
- echo "\e[31m$$(RISCV_GCC) failed for target $$(@) \e[39m" ; \
- exit 1 ; \
- fi ; \
- $(OBJ_CMD); \
- if [ $$$$? -ne 0 ] ; \
- then \
- echo "\e[31m $$(RISCV_OBJDUMP) failed for target $$(@) \e[39m" ; \
- exit 1 ; \
- fi ;
-
+include $(TARGETDIR)/spike/device/Makefile_common.inc
RUN_CMD = $(TARGET_SIM) $(TARGET_FLAGS) --isa=rv32ec \
+signature=$(*).signature.output +signature-granularity=4\
$<
diff --git a/arch_test_target/spike/device/rv32e_unratified/E/Makefile.include b/arch_test_target/spike/device/rv32e_unratified/E/Makefile.include
index 86b32e2..548b17d 100644
--- a/arch_test_target/spike/device/rv32e_unratified/E/Makefile.include
+++ b/arch_test_target/spike/device/rv32e_unratified/E/Makefile.include
@@ -1,37 +1,4 @@
-TARGET_SIM ?= spike
-TARGET_FLAGS ?= $(RISCV_TARGET_FLAGS)
-ifeq ($(shell command -v $(TARGET_SIM) 2> /dev/null),)
- $(error Target simulator executable '$(TARGET_SIM)` not found)
-endif
-
-RISCV_PREFIX ?= riscv32-unknown-elf-
-RISCV_GCC ?= $(RISCV_PREFIX)gcc
-RISCV_OBJDUMP ?= $(RISCV_PREFIX)objdump
-RISCV_GCC_OPTS ?= -g -static -mcmodel=medany -fvisibility=hidden -nostdlib -nostartfiles $(RVTEST_DEFINES)
-
-COMPILE_CMD = $$(RISCV_GCC) $(1) $$(RISCV_GCC_OPTS) \
- -I$(ROOTDIR)/riscv-test-suite/env/ \
- -I$(TARGETDIR)/$(RISCV_TARGET)/ \
- -T$(TARGETDIR)/$(RISCV_TARGET)/link.ld \
- $$(<) -o $$@
-OBJ_CMD = $$(RISCV_OBJDUMP) $$@ -D > $$@.objdump; \
- $$(RISCV_OBJDUMP) $$@ --source > $$@.debug
-
-
-COMPILE_TARGET=\
- $(COMPILE_CMD); \
- if [ $$$$? -ne 0 ] ; \
- then \
- echo "\e[31m$$(RISCV_GCC) failed for target $$(@) \e[39m" ; \
- exit 1 ; \
- fi ; \
- $(OBJ_CMD); \
- if [ $$$$? -ne 0 ] ; \
- then \
- echo "\e[31m $$(RISCV_OBJDUMP) failed for target $$(@) \e[39m" ; \
- exit 1 ; \
- fi ;
-
+include $(TARGETDIR)/spike/device/Makefile_common.inc
RUN_CMD = $(TARGET_SIM) $(TARGET_FLAGS) --isa=rv32e \
+signature=$(*).signature.output +signature-granularity=4\
$<
diff --git a/arch_test_target/spike/device/rv32e_unratified/M/Makefile.include b/arch_test_target/spike/device/rv32e_unratified/M/Makefile.include
index 141974d..749c7fc 100644
--- a/arch_test_target/spike/device/rv32e_unratified/M/Makefile.include
+++ b/arch_test_target/spike/device/rv32e_unratified/M/Makefile.include
@@ -1,37 +1,4 @@
-TARGET_SIM ?= spike
-TARGET_FLAGS ?= $(RISCV_TARGET_FLAGS)
-ifeq ($(shell command -v $(TARGET_SIM) 2> /dev/null),)
- $(error Target simulator executable '$(TARGET_SIM)` not found)
-endif
-
-RISCV_PREFIX ?= riscv32-unknown-elf-
-RISCV_GCC ?= $(RISCV_PREFIX)gcc
-RISCV_OBJDUMP ?= $(RISCV_PREFIX)objdump
-RISCV_GCC_OPTS ?= -g -static -mcmodel=medany -fvisibility=hidden -nostdlib -nostartfiles $(RVTEST_DEFINES)
-
-COMPILE_CMD = $$(RISCV_GCC) $(1) $$(RISCV_GCC_OPTS) \
- -I$(ROOTDIR)/riscv-test-suite/env/ \
- -I$(TARGETDIR)/$(RISCV_TARGET)/ \
- -T$(TARGETDIR)/$(RISCV_TARGET)/link.ld \
- $$(<) -o $$@
-OBJ_CMD = $$(RISCV_OBJDUMP) $$@ -D > $$@.objdump; \
- $$(RISCV_OBJDUMP) $$@ --source > $$@.debug
-
-
-COMPILE_TARGET=\
- $(COMPILE_CMD); \
- if [ $$$$? -ne 0 ] ; \
- then \
- echo "\e[31m$$(RISCV_GCC) failed for target $$(@) \e[39m" ; \
- exit 1 ; \
- fi ; \
- $(OBJ_CMD); \
- if [ $$$$? -ne 0 ] ; \
- then \
- echo "\e[31m $$(RISCV_OBJDUMP) failed for target $$(@) \e[39m" ; \
- exit 1 ; \
- fi ;
-
+include $(TARGETDIR)/spike/device/Makefile_common.inc
RUN_CMD = $(TARGET_SIM) $(TARGET_FLAGS) --isa=rv32em \
+signature=$(*).signature.output +signature-granularity=4\
$<