Merge remote-tracking branch 'origin/main' into develop
This commit is contained in:
@ -2,7 +2,7 @@ TARGET := dhrystone
|
||||
ISA?=imc
|
||||
|
||||
ASM_SRCS :=
|
||||
C_SRCS := dhry_stubs.c dhry_printf.c dhry_1.c dhry_2.c
|
||||
C_SRCS := dhry_stubs.c dhry_1.c dhry_2.c
|
||||
HEADERS := dhry.h
|
||||
|
||||
BOARD=iss
|
||||
@ -14,12 +14,11 @@ else
|
||||
RISCV_ABI:=ilp32
|
||||
endif
|
||||
# '-lgcc -lm' are needed to add softfloat routines
|
||||
CFLAGS := -g -march=$(RISCV_ARCH) -mabi=$(RISCV_ABI) -mcmodel=medlow -O3 -DHZ=32768 -DTIME -DNO_INIT -fno-inline -fno-builtin-printf -fno-common -Wno-implicit \
|
||||
CFLAGS := -g -march=$(RISCV_ARCH)_zicsr_zifencei -mabi=$(RISCV_ABI) -mcmodel=medlow -O3 -DHZ=32768 -DTIME -DNO_INIT -fno-inline -fno-builtin-printf -fno-common -Wno-implicit \
|
||||
-funroll-loops -fpeel-loops -fgcse-sm -fgcse-las
|
||||
LDFLAGS := -g -march=$(RISCV_ARCH) -mabi=$(RISCV_ABI) -mcmodel=medlow -Wl,--wrap=scanf -Wl,--wrap=printf -Wl,--wrap=exit -lgcc -lm
|
||||
LDFLAGS := -g -march=$(RISCV_ARCH)_zicsr_zifencei -mabi=$(RISCV_ABI) -mcmodel=medlow -Wl,--wrap=scanf -Wl,--wrap=printf -Wl,--wrap=exit -lgcc -lm
|
||||
|
||||
TOOL_DIR=$(dir $(compiler))
|
||||
|
||||
TRIPLET=riscv32-unknown-elf
|
||||
BSP_BASE = ../../bare-metal-bsp
|
||||
include $(BSP_BASE)/env/common-gcc.mk
|
||||
|
@ -1,15 +0,0 @@
|
||||
/* The functions in this file are only meant to support Dhrystone on an
|
||||
* embedded RV32 system and are obviously incorrect in general. */
|
||||
|
||||
#include <stdarg.h>
|
||||
#include <stddef.h>
|
||||
#include <stdio.h>
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
|
||||
//#undef putchar
|
||||
//int putchar(int ch)
|
||||
//{
|
||||
// return write(1, &ch, 1) == 1 ? ch : -1;
|
||||
//}
|
@ -11,12 +11,12 @@ long time(void)
|
||||
// set the number of dhrystone iterations
|
||||
void __wrap_scanf(const char* fmt, int* n)
|
||||
{
|
||||
*n = 200000;
|
||||
*n = 20000;
|
||||
}
|
||||
|
||||
extern volatile uint32_t tohost;
|
||||
|
||||
void __wrap_exit(int n){
|
||||
void exit(int n){
|
||||
tohost = 0x1;
|
||||
for (;;);
|
||||
}
|
||||
|
Reference in New Issue
Block a user