mirror of
https://github.com/openhwgroup/cvw
synced 2025-01-23 13:04:28 +00:00
Cleanup.
Linux makefile wally tracer. probably reduce some complexity here.
This commit is contained in:
parent
1f7d91e8e0
commit
540d8d930d
3
.gitignore
vendored
3
.gitignore
vendored
@ -172,3 +172,6 @@ tests/fp/combined_IF_vectors/IF_vectors/*.tv
|
||||
/sim/obj_dir/Vtestbench_tlbram__Pz1_T20__DepSet_hab70f5b0__0.cpp
|
||||
/sim/obj_dir/Vtestbench_tlbram__Pz1_T20__DepSet_hab70f5b0__0__Slow.cpp
|
||||
/sim/obj_dir/Vtestbench_tlbram__Pz1_T20__Slow.cpp
|
||||
sim/bp-results/*.log
|
||||
sim/branch*.log
|
||||
/tests/custom/fpga-test-sdc/bin/fpga-test-sdc
|
||||
|
@ -27,15 +27,6 @@ BINARIES := fw_jump.elf vmlinux busybox
|
||||
OBJDUMPS := $(foreach name, $(BINARIES), $(basename $(name) .elf))
|
||||
OBJDUMPS := $(foreach name, $(OBJDUMPS), $(DIS)/$(name).objdump)
|
||||
|
||||
# LINUXDIR := $(shell ls $(BUILDROOT)/output/build | grep -e '^linux-[0-9]\+\.[0-9]\+\.[0-9]\+$$' )
|
||||
# LINUXDIR := $(BUILDROOT)/output/build/$(LINUXDIR)
|
||||
# BUSYBOXDIR := $(shell ls $(BUILDROOT)/output/build | grep -e '^linux-[0-9]\+\.[0-9]\+\.[0-9]\+$$' )
|
||||
# BUSYBOXDIR := $(BUILDROOT)/output/build/$(BUSYBOXDIR)
|
||||
|
||||
# Gets Linux and Busybox output folders for objedect dumps
|
||||
# LINUXDIR ?= $(shell find $(BUILDROOT)/output/build -maxdepth 2 -type d -regex ".*/linux-[0-9]+\.[0-9]+\.[0-9]+$$")
|
||||
# BUSYBOXDIR ?= $(shell find $(BUILDROOT)/output/build -maxdepth 2 -type d -regex ".*/busybox-[0-9]+\.[0-9]+\.[0-9]+$$")
|
||||
|
||||
define linuxDir =
|
||||
$(shell find $(BUILDROOT)/output/build -maxdepth 2 -type d -regex ".*/linux-[0-9]+\.[0-9]+\.[0-9]+$$")
|
||||
endef
|
||||
@ -46,10 +37,6 @@ endef
|
||||
|
||||
.PHONY: all generate disassemble install clean cleanDTB cleanDriver test
|
||||
|
||||
# Generate all device trees -------------------------------------------
|
||||
# TODO: Add configuration for only generating device tree for specified
|
||||
# supported FPGA.
|
||||
|
||||
all:
|
||||
$(MAKE) install
|
||||
make -C $(BUILDROOT) --jobs
|
||||
@ -99,18 +86,6 @@ $(IMAGES)/busybox: $(call busyboxDir)/busybox
|
||||
install: $(BUILDROOT)/package/fpga-axi-sdc $(WALLYBOARD)
|
||||
cp $(WALLYBOARD)/main.config $(BUILDROOT)/.config
|
||||
|
||||
# CONFIG DEPENDENCIES 2021.05 -----------------------------------------
|
||||
# $(WALLYBOARD)/main.config: $(WALLYBOARD) $(BRPACKAGES)/wally.config
|
||||
# cp $(BRPACKAGES)/wally.config $@
|
||||
|
||||
# $(WALLYBOARD)/linux.config: $(BRPACKAGES)/linux.config $(WALLYBOARD)
|
||||
# cp $(BRPACKAGES)/linux.config $@
|
||||
|
||||
# $(WALLYBOARD): $(BUILDROOT)
|
||||
# cp -r $(WALLYBOARDSRC) $(BUILDROOT)/board
|
||||
# cp $(BRPACKAGES)/wally.config $(WALLYBOARD)/main.config
|
||||
# cp $(BRPACKAGES)/linux.config $(WALLYBOARD)/linux.config
|
||||
|
||||
# CONFIG DEPENDENCIES 2023.05.1 ---------------------------------------
|
||||
$(WALLYBOARD): $(BUILDROOT)
|
||||
cp -r $(WALLYBOARDSRC) $(BUILDROOT)/board
|
||||
@ -129,13 +104,6 @@ $(PATCHFILE):
|
||||
$(BUILDROOT):
|
||||
git clone https://github.com/buildroot/buildroot.git $@
|
||||
cd $@; git checkout 2023.05.x
|
||||
#cd $@; git checkout 2021.05
|
||||
|
||||
#$(DRIVER):
|
||||
# @ if [ -d "$(WALLY)/addins/vivado-risc-v" ] ; then git submodule update --init $(WALLY)/addins/vivado-risc-v; fi
|
||||
# cp ../addins/vivado-risc-v/patches/fpga-axi-sdc.c $@
|
||||
# For 2021.05
|
||||
#sed -i "s|card_hw_reset|hw_reset|1" $@
|
||||
|
||||
# ---------------------------------------------------------------------
|
||||
|
||||
|
@ -267,6 +267,7 @@ module wallyTracer import cvw::*; #(parameter cvw_t P) (rvviTrace rvvi);
|
||||
flopenrc #(1) TrapWReg (clk, reset, 1'b0, ~StallW, TrapM, TrapW);
|
||||
flopenrc #(1) HaltWReg (clk, reset, 1'b0, ~StallW, HaltM, HaltW);
|
||||
|
||||
// **** remove? are these used?
|
||||
flopenrc #(1) IntrFReg (clk, reset, 1'b0, ~StallF, TrapM, IntrF);
|
||||
flopenrc #(1) IntrDReg (clk, reset, FlushD, ~StallD, IntrF, IntrD);
|
||||
flopenrc #(1) IntrEReg (clk, reset, FlushE, ~StallE, IntrD, IntrE);
|
||||
@ -285,9 +286,9 @@ module wallyTracer import cvw::*; #(parameter cvw_t P) (rvviTrace rvvi);
|
||||
assign rvvi.order[0][0] = CSRArray[12'hB02]; // TODO: IMPERAS Should be event order
|
||||
assign rvvi.insn[0][0] = InstrRawW;
|
||||
assign rvvi.pc_rdata[0][0] = PCW;
|
||||
assign rvvi.trap[0][0] = 0; // TODO: IMPERAS TrapW;
|
||||
assign rvvi.trap[0][0] = 0;
|
||||
assign rvvi.halt[0][0] = HaltW;
|
||||
assign rvvi.intr[0][0] = IntrW;
|
||||
assign rvvi.intr[0][0] = 0;
|
||||
assign rvvi.mode[0][0] = PrivilegeModeW;
|
||||
assign rvvi.ixl[0][0] = PrivilegeModeW == 2'b11 ? 2'b10 :
|
||||
PrivilegeModeW == 2'b01 ? STATUS_SXL : STATUS_UXL;
|
||||
|
@ -30,7 +30,7 @@ LINKER :=$(ROOT)/linker1000.x
|
||||
AFLAGS =$(MARCH) $(MABI) -W
|
||||
# Override directive allows us to prepend other options on the command line
|
||||
# e.g. $ make CFLAGS=-g
|
||||
override CFLAGS +=$(MARCH) $(MABI) -mcmodel=medany -O2
|
||||
override CFLAGS +=$(MARCH) $(MABI) -mcmodel=medany -O2 -g
|
||||
AS=riscv64-unknown-elf-as
|
||||
CC=riscv64-unknown-elf-gcc
|
||||
AR=riscv64-unknown-elf-ar
|
||||
|
Loading…
Reference in New Issue
Block a user