mirror of
https://github.com/openhwgroup/cvw
synced 2025-02-11 06:05:49 +00:00
Merge branch 'main' of github.com:davidharrishmc/riscv-wally into main
This commit is contained in:
commit
c7be8a701e
1
.gitignore
vendored
1
.gitignore
vendored
@ -21,6 +21,7 @@ wlft*
|
||||
/imperas-riscv-tests/logs
|
||||
*.o
|
||||
*.d
|
||||
*.vstf
|
||||
testsBP/*/*/*.elf*
|
||||
testsBP/*/OBJ/*
|
||||
testsBP/*/*.a
|
||||
|
35
Makefile
35
Makefile
@ -1,31 +1,18 @@
|
||||
#make all: submodules other
|
||||
#make all: submodules other
|
||||
#submodules: addins/riscv-isa-sim addins/riscv-arch-test
|
||||
# git pull --recurse-submodules
|
||||
#
|
||||
#other:
|
||||
make all:
|
||||
# move these parts into compiling archtest separtately
|
||||
cp -r addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/I addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/F
|
||||
cp -r addins/riscv-isa-sim/arch_test_target/spike/device/rv64i_m/I addins/riscv-isa-sim/arch_test_target/spike/device/rv64i_m/D
|
||||
<<<<<<< HEAD
|
||||
#why cat
|
||||
cat addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/F/Makefile.include
|
||||
=======
|
||||
>>>>>>> 29f2a1c5479d7a80debdb1ac337fcda628cc57a3
|
||||
sed -i 's/--isa=rv32i /--isa=32if/' addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/F/Makefile.include
|
||||
sed -i 's/--isa=rv64i /--isa=64if/' addins/riscv-isa-sim/arch_test_target/spike/device/rv64i_m/D/Makefile.include
|
||||
if [ -d "addins/riscv-isa-sim/build" ]; then echo "Build exists"; else mkdir addins/riscv-isa-sim/build; fi
|
||||
cd addins/riscv-isa-sim/build; ../configure --prefix=/cad/riscv/gcc/bin
|
||||
make -C addins/riscv-isa-sim/build
|
||||
# does sudo work?
|
||||
|
||||
sudo make install -C addins/riscv-isa-sim/build
|
||||
|
||||
cp addins/riscv-isa-sim/arch_test_target/spike/Makefile.include addins/riscv-arch-test/
|
||||
# cp -r addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/I addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/F
|
||||
# cp -r addins/riscv-isa-sim/arch_test_target/spike/device/rv64i_m/I addins/riscv-isa-sim/arch_test_target/spike/device/rv64i_m/D
|
||||
# sed -i 's/--isa=rv32i /--isa=32if/' addins/riscv-isa-sim/arch_test_target/spike/device/rv32i_m/F/Makefile.include
|
||||
# sed -i 's/--isa=rv64i /--isa=64id/' addins/riscv-isa-sim/arch_test_target/spike/device/rv64i_m/D/Makefile.include
|
||||
# if [ -d "addins/riscv-isa-sim/build" ]; then echo "Build exists"; else mkdir addins/riscv-isa-sim/build; fi
|
||||
# cd addins/riscv-isa-sim/build; ../configure --prefix=/cad/riscv/gcc/bin
|
||||
# make -C addins/riscv-isa-sim/build
|
||||
# sudo make install -C addins/riscv-isa-sim/build
|
||||
# cp addins/riscv-isa-sim/arch_test_target/spike/Makefile.include addins/riscv-arch-test/
|
||||
# update with path including $RISCV_TOOLS
|
||||
# separate into make tests and make regression
|
||||
sed -i '/export TARGETDIR ?=/c\export TARGETDIR ?= /home/harris/riscv-wally/addins/riscv-isa-sim/arch_test_target' tests/wally-riscv-arch-test/Makefile.include
|
||||
cp $RISCV/riscv-isa-sim/arch_test_target/spike/Makefile.include addins/riscv-arch-test/
|
||||
sed -i '/export TARGETDIR ?=/c\export TARGETDIR ?= $RISCV/riscv-isa-sim/arch_test_target' tests/wally-riscv-arch-test/Makefile.include
|
||||
echo export RISCV_PREFIX = riscv64-unknown-elf- >> tests/wally-riscv-arch-test/Makefile.include
|
||||
make -C addins/riscv-arch-test
|
||||
make -C addins/riscv-arch-test XLEN=32
|
||||
|
50
wally-pipelined/README.txt
Normal file
50
wally-pipelined/README.txt
Normal file
@ -0,0 +1,50 @@
|
||||
Code Improvements
|
||||
David_Harris@hmc.edu 15 Nov 2021
|
||||
|
||||
Remove depricated N-Mode stuff, including sd in privileged.sv
|
||||
Look at version 13? of privileged spec. What should we add?
|
||||
Reduce size of repo
|
||||
|
||||
Timing optimization (Kip, Shreya)
|
||||
Use ForwardSrcA instead of SrcA for mdu / fpu
|
||||
Look at TLB -> PMP -> Access Fault -> Trap
|
||||
may be able to precompute
|
||||
Try flattening, see speedup
|
||||
Take out Mul synthesis modes
|
||||
|
||||
RISCV-Arch-tests
|
||||
Port MMU tests
|
||||
|
||||
FPU
|
||||
spec difference on signaling/quiet NAN propagation
|
||||
SRT Div/Sqrt (Katherine, maybe Udeema)
|
||||
Get riscv-arch-tests running (James, Katherine)
|
||||
Get testfloat all passing
|
||||
Katherine's FPU optimization
|
||||
|
||||
Linux Boot
|
||||
Ben, Skyler
|
||||
|
||||
FPGA Boot Linux (Ross)
|
||||
|
||||
IFU/LSU
|
||||
Block diagrams, code cleanup
|
||||
Burst mode transfers to speed up IPC
|
||||
Implications of no byte enables on subword write - do stores take extra cycle, should this be avoided?
|
||||
|
||||
28 nm Implementation
|
||||
Install processor
|
||||
Memory macros
|
||||
Synthesis & PNR
|
||||
Timing review
|
||||
|
||||
Benchmarking
|
||||
|
||||
Flow
|
||||
Kevin Kim has a makefile to check out and build all the pieces. Make sure this is running; change Repo README to use his makefile
|
||||
|
||||
Code cleanup
|
||||
.* fixes by thanksgiving
|
||||
Rename top-level modules to abbreviations
|
||||
Rename muldiv to mdu
|
||||
Get rid of DESIGN_COMPILER flag and redundant multiplier
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/all.txt
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/bootmem.txt
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/checkpoint8500000
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/ram.txt
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/vmlinux.objdump
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/vmlinux.objdump.addr
|
@ -1 +0,0 @@
|
||||
/courses/e190ax/buildroot_boot/vmlinux.objdump.lab
|
12
wally-pipelined/regression/make-tests.sh
Executable file
12
wally-pipelined/regression/make-tests.sh
Executable file
@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
rm -r work*
|
||||
cd ../../tests/imperas-riscv-tests/
|
||||
make allclean
|
||||
make
|
||||
cd ../wally-riscv-arch-test
|
||||
make allclean
|
||||
make
|
||||
make XLEN=32
|
||||
exe2memfile.pl work/*/*/*.elf
|
||||
cd ../../wally-pipelined/regression
|
@ -89,21 +89,27 @@ def run_test_case(config):
|
||||
|
||||
def main():
|
||||
"""Run the tests and count the failures"""
|
||||
# Scale the number of concurrent processes to the number of test cases, but
|
||||
# max out at a limited number of concurrent processes to not overwhelm the system
|
||||
|
||||
if '-all' in sys.argv:
|
||||
TIMEOUT_DUR = 20*3600
|
||||
configs.append(getBuildrootTC(short=False))
|
||||
else:
|
||||
TIMEOUT_DUR = 300
|
||||
configs.append(getBuildrootTC(short=True))
|
||||
print(configs)
|
||||
|
||||
global configs
|
||||
try:
|
||||
os.mkdir("logs")
|
||||
except:
|
||||
pass
|
||||
|
||||
if '-makeTests' in sys.argv:
|
||||
os.system('./make-tests.sh | tee ./logs/make-tests.log')
|
||||
|
||||
if '-all' in sys.argv:
|
||||
TIMEOUT_DUR = 20*3600 # seconds
|
||||
configs.append(getBuildrootTC(short=False))
|
||||
elif '-buildroot' in sys.argv:
|
||||
TIMEOUT_DUR = 20*3600 # seconds
|
||||
configs=[getBuildrootTC(short=False)]
|
||||
else:
|
||||
TIMEOUT_DUR = 5*60 # seconds
|
||||
configs.append(getBuildrootTC(short=True))
|
||||
|
||||
# Scale the number of concurrent processes to the number of test cases, but
|
||||
# max out at a limited number of concurrent processes to not overwhelm the system
|
||||
with Pool(processes=min(len(configs),25)) as pool:
|
||||
num_fail = 0
|
||||
results = {}
|
||||
|
BIN
wally-pipelined/srt/sqrttestgen
Executable file
BIN
wally-pipelined/srt/sqrttestgen
Executable file
Binary file not shown.
BIN
wally-pipelined/srt/testgen
Executable file
BIN
wally-pipelined/srt/testgen
Executable file
Binary file not shown.
26
wally-setup.sh
Normal file
26
wally-setup.sh
Normal file
@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
|
||||
# wally-setup.sh
|
||||
# David_Harris@hmc.edu and kekim@hmc.edu 1 December 2021
|
||||
# Set up tools for riscv-wally
|
||||
|
||||
echo "Executing wally-setup.sh"
|
||||
|
||||
# Path to RISC-V Tools
|
||||
export RISCV=/opt/riscv # change this if you installed the tools in a different location
|
||||
|
||||
# Tools
|
||||
export PATH=$RISCV/riscv-gnu-toolchain/bin:$RISCV/riscv-gnu-toolchain/riscv64-unknown-elf/bin:$PATH # GCC tools
|
||||
export PATH=~/riscv-wally/bin:$PATH # exe2memfile; change this if riscv-wally isn't at your home directory
|
||||
export PATH=/cad/mentor/questa_sim-2021.2_1/questasim/bin:$PATH # Change this for your path to Modelsim
|
||||
export PATH=/usr/local/bin/verilator:$PATH # Change this for your path to Verilator
|
||||
export LD_LIBRARY_PATH=$RISCV/riscv-gnu-toolchain/lib:$RISCV/riscv-gnu-toolchain/riscv64-unknown-elf/lib:$LD_LIBRARY_PATH
|
||||
|
||||
export MGLS_LICENSE_FILE=1717@solidworks.eng.hmc.edu # *** is this the right license server now
|
||||
|
||||
# Imperas; *** remove if not using
|
||||
PATH=/cad/riscv/imperas-riscv-tests/riscv-ovpsim-plus/bin/Linux64:/cad/riscv/imperas-riscv-tests/riscv-ovpsim/bin/Liux64:$PATH # *** maybe take this out based on Imperas
|
||||
export LD_LIBRARY_PATH=/cad/imperas/Imperas.20200630/bin/Linux64:$LD_LIBRARY_PATH # remove if no imperas
|
||||
IMPERAS_HOME=/cad/imperas/Imperas.20200630
|
||||
source $IMPERAS_HOME/bin/setup.sh
|
||||
setupImperas $IMPERAS_HOME
|
Loading…
Reference in New Issue
Block a user