mirror of
https://github.com/vortexgpgpu/vortex.git
synced 2025-04-23 21:39:10 -04:00
minor update
This commit is contained in:
parent
ca1d97a3c2
commit
28e26f3130
12 changed files with 81 additions and 113 deletions
|
@ -1,9 +1,15 @@
|
|||
OPAE_HOME ?= /tools/opae/1.4.0
|
||||
|
||||
RTL_DIR=../../hw/rtl
|
||||
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
OPAE_SYN_DIR=../../hw/syn/opae
|
||||
|
||||
CXXFLAGS += -std=c++11 -O2 -DNDEBUG -Wall -Wextra -pedantic -Wfatal-errors
|
||||
#CXXFLAGS += -std=c++11 -O0 -g -Wall -Wextra -pedantic -Wfatal-errors
|
||||
|
||||
CXXFLAGS += -I../include -I../../hw -I$(OPAE_HOME)/include
|
||||
CXXFLAGS += -I../include -I../../hw -I$(OPAE_HOME)/include -I$(OPAE_SYN_DIR)
|
||||
|
||||
LDFLAGS += -L$(OPAE_HOME)/lib -luuid -lopae-c-ase
|
||||
|
||||
|
@ -27,10 +33,6 @@ CXXFLAGS += -DDUMP_PERF_STATS
|
|||
|
||||
LDFLAGS += -shared
|
||||
|
||||
RTL_DIR=../../hw/rtl
|
||||
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
PROJECT = libvortex.so
|
||||
|
||||
AFU_JSON_INFO = vortex_afu.h
|
||||
|
@ -51,9 +53,8 @@ endif
|
|||
|
||||
all: $(PROJECT)
|
||||
|
||||
# AFU info from JSON file, including AFU UUID
|
||||
json: ../../hw/opae/vortex_afu.json
|
||||
afu_json_mgr json-info --afu-json=$^ --c-hdr=$@
|
||||
$(OPAE_SYN_DIR)/vortex_afu.h:
|
||||
$(MAKE) -C $(OPAE_SYN_DIR) vortex_afu.h
|
||||
|
||||
scope-defs.h: $(SCRIPT_DIR)/scope.json
|
||||
$(SCRIPT_DIR)/scope.py $(CONFIGS) -cc scope-defs.h -vl $(RTL_DIR)/scope-defs.vh $(SCRIPT_DIR)/scope.json
|
||||
|
@ -61,7 +62,7 @@ scope-defs.h: $(SCRIPT_DIR)/scope.json
|
|||
# generate scope data
|
||||
scope: scope-defs.h
|
||||
|
||||
$(PROJECT): $(SRCS) $(SCOPE_H)
|
||||
$(PROJECT): $(SRCS) $(OPAE_SYN_DIR)/vortex_afu.h $(SCOPE_H)
|
||||
$(CXX) $(CXXFLAGS) -DUSE_ASE $(SRCS) $(LDFLAGS) -o $(PROJECT)
|
||||
|
||||
.depend: $(SRCS)
|
||||
|
|
|
@ -1,9 +1,15 @@
|
|||
OPAE_HOME ?= /tools/opae/1.4.0
|
||||
|
||||
RTL_DIR=../../hw/rtl
|
||||
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
OPAE_SYN_DIR=../../hw/syn/opae
|
||||
|
||||
CXXFLAGS += -std=c++11 -O2 -DNDEBUG -Wall -Wextra -pedantic -Wfatal-errors
|
||||
#CXXFLAGS += -std=c++11 -O0 -g -Wall -Wextra -pedantic -Wfatal-errors
|
||||
|
||||
CXXFLAGS += -I../include -I$(OPAE_HOME)/include -I../../hw
|
||||
CXXFLAGS += -I../include -I../../hw -I$(OPAE_HOME)/include -I$(OPAE_SYN_DIR)
|
||||
|
||||
LDFLAGS += -L$(OPAE_HOME)/lib -luuid -lopae-c
|
||||
|
||||
|
@ -29,10 +35,6 @@ CXXFLAGS += -DDUMP_PERF_STATS
|
|||
|
||||
LDFLAGS += -shared
|
||||
|
||||
RTL_DIR=../../hw/rtl
|
||||
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
PROJECT = libvortex.so
|
||||
|
||||
AFU_JSON_INFO = vortex_afu.h
|
||||
|
@ -53,9 +55,8 @@ endif
|
|||
|
||||
all: $(PROJECT)
|
||||
|
||||
# AFU info from JSON file, including AFU UUID
|
||||
json: ../../hw/opae/vortex_afu.json
|
||||
afu_json_mgr json-info --afu-json=$^ --c-hdr=$@
|
||||
$(OPAE_SYN_DIR)/vortex_afu.h:
|
||||
$(MAKE) -C $(OPAE_SYN_DIR) vortex_afu.h
|
||||
|
||||
scope-defs.h: $(SCRIPT_DIR)/scope.json
|
||||
$(SCRIPT_DIR)/scope.py $(CONFIGS) -cc scope-defs.h -vl $(RTL_DIR)/scope-defs.vh $(SCRIPT_DIR)/scope.json
|
||||
|
@ -63,7 +64,7 @@ scope-defs.h: $(SCRIPT_DIR)/scope.json
|
|||
# generate scope data
|
||||
scope: scope-defs.h
|
||||
|
||||
$(PROJECT): $(SRCS) $(SCOPE_H)
|
||||
$(PROJECT): $(SRCS) $(OPAE_SYN_DIR)/vortex_afu.h $(SCOPE_H)
|
||||
$(CXX) $(CXXFLAGS) -DUSE_FPGA $^ $(LDFLAGS) -o $(PROJECT)
|
||||
|
||||
.depend: $(SRCS)
|
||||
|
|
|
@ -34,5 +34,5 @@ $(PROJECT): $(SRCS)
|
|||
$(CXX) $(CXXFLAGS) $(SRCS) $(LDFLAGS) -o $(PROJECT)
|
||||
|
||||
clean:
|
||||
$(MAKE) -C $(RTLSIM_DIR) clean-objdir
|
||||
$(MAKE) -C $(RTLSIM_DIR) clean-static
|
||||
rm -rf $(PROJECT) *.o .depend
|
|
@ -1,5 +1,3 @@
|
|||
PROJECT = libvortex.so
|
||||
|
||||
SIMX_DIR = ../../sim/simX
|
||||
|
||||
CXXFLAGS += -std=c++11 -O2 -Wall -Wextra -Wfatal-errors
|
||||
|
@ -15,6 +13,8 @@ LDFLAGS += $(SIMX_DIR)/libsimX.a
|
|||
|
||||
SRCS = vortex.cpp ../common/vx_utils.cpp
|
||||
|
||||
PROJECT = libvortex.so
|
||||
|
||||
all: $(PROJECT)
|
||||
|
||||
$(PROJECT): $(SRCS)
|
||||
|
@ -25,5 +25,5 @@ $(PROJECT): $(SRCS)
|
|||
$(CXX) $(CXXFLAGS) -MM $^ > .depend;
|
||||
|
||||
clean:
|
||||
$(MAKE) -C $(SIMX_DIR) clean-objdir
|
||||
$(MAKE) -C $(SIMX_DIR) clean-static
|
||||
rm -rf $(PROJECT) *.o .depend
|
|
@ -1,5 +1,9 @@
|
|||
VLSIM_DIR = ../../sim/vlsim
|
||||
|
||||
RTL_DIR=../../hw/rtl
|
||||
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
CXXFLAGS += -std=c++11 -O2 -DNDEBUG -Wall -Wextra -pedantic -Wfatal-errors
|
||||
#CXXFLAGS += -std=c++11 -O0 -g -Wall -Wextra -pedantic -Wfatal-errors
|
||||
|
||||
|
@ -18,10 +22,6 @@ CXXFLAGS += -DDUMP_PERF_STATS
|
|||
|
||||
LDFLAGS += -shared
|
||||
|
||||
RTL_DIR=../../hw/rtl
|
||||
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
AFU_JSON_INFO = vortex_afu.h
|
||||
|
||||
SRCS = ../common/opae.cpp ../common/vx_utils.cpp
|
||||
|
@ -56,7 +56,7 @@ $(PROJECT): $(SRCS) $(SCOPE_H)
|
|||
$(CXX) $(CXXFLAGS) -MM $(SRCS) > .depend;
|
||||
|
||||
clean:
|
||||
$(MAKE) -C $(VLSIM_DIR) clean-objdir
|
||||
$(MAKE) -C $(VLSIM_DIR) clean-static
|
||||
rm -rf $(PROJECT) *.o .depend
|
||||
|
||||
ifneq ($(MAKECMDGOALS),clean)
|
||||
|
|
12
hw/Makefile
12
hw/Makefile
|
@ -1,16 +1,12 @@
|
|||
RTL_DIR=./rtl
|
||||
SCRIPT_DIR=./scripts
|
||||
DESTDIR ?= .
|
||||
|
||||
all: VX_config.h vortex_afu.h
|
||||
all: VX_config.h
|
||||
|
||||
VX_config.h: $(RTL_DIR)/VX_config.vh
|
||||
$(SCRIPT_DIR)/gen_config.py -i $(RTL_DIR)/VX_config.vh -o $(DESTDIR)/VX_config.h
|
||||
|
||||
vortex_afu.h : $(RTL_DIR)/afu/vortex_afu.vh
|
||||
$(SCRIPT_DIR)/gen_config.py -i $(RTL_DIR)/afu/vortex_afu.vh -o $(DESTDIR)/vortex_afu.h
|
||||
$(SCRIPT_DIR)/gen_config.py -i $(RTL_DIR)/VX_config.vh -o VX_config.h
|
||||
|
||||
clean:
|
||||
rm -f $(DESTDIR)/VX_config.h $(DESTDIR)/vortex_afu.h
|
||||
rm -f VX_config.h
|
||||
|
||||
.PHONY: VX_config.h vortex_afu.h
|
||||
.PHONY: VX_config.h
|
|
@ -54,7 +54,11 @@ ifdef PERF
|
|||
CFLAGS += -DPERF_ENABLE
|
||||
endif
|
||||
|
||||
all: ase-1c
|
||||
all: vortex_afu.h ase-1c
|
||||
|
||||
# AFU info from JSON file, including AFU UUID
|
||||
vortex_afu.h: vortex_afu.json
|
||||
afu_json_mgr json-info --afu-json=$^ --c-hdr=$@
|
||||
|
||||
$(BUILD_DIR)_ase_1c/Makefile:
|
||||
afu_sim_setup -s setup.cfg $(BUILD_DIR)_ase_1c
|
||||
|
@ -196,4 +200,4 @@ clean-fpga-32c:
|
|||
clean-fpga-64c:
|
||||
rm -rf $(BUILD_DIR)_fpga_64c sources.txt
|
||||
|
||||
clean: clean-ase-1c clean-ase-2c clean-ase-4c clean-fpga-1c clean-fpga-2c clean-fpga-4c clean-fpga-8c clean-fpga-16c clean-fpga-32c clean-fpga-64c
|
||||
clean: vortex_afu.h clean-ase-1c clean-ase-2c clean-ase-4c clean-fpga-1c clean-fpga-2c clean-fpga-4c clean-fpga-8c clean-fpga-16c clean-fpga-32c clean-fpga-64c
|
|
@ -2,8 +2,7 @@ CXXFLAGS += -std=c++11 -O2 -Wall -Wextra -Wfatal-errors
|
|||
#CXXFLAGS += -std=c++11 -g -O0 -Wall -Wextra -Wfatal-errors
|
||||
|
||||
CXXFLAGS += -fPIC -Wno-maybe-uninitialized
|
||||
CXXFLAGS += -I. -I../../../hw -I../../common
|
||||
CXXFLAGS += -I$(VERILATOR_ROOT)/include -I$(VERILATOR_ROOT)/include/vltstd
|
||||
CXXFLAGS += -I../../../hw -I../../common
|
||||
|
||||
# control RTL debug print states
|
||||
DBG_PRINT_FLAGS += -DDBG_PRINT_PIPELINE
|
||||
|
@ -33,7 +32,7 @@ RTL_INCLUDE = -I$(RTL_DIR) -I$(DPI_DIR) -I$(RTL_DIR)/libs -I$(RTL_DIR)/interface
|
|||
|
||||
SRCS = ../common/util.cpp ../common/mem.cpp
|
||||
SRCS += $(DPI_DIR)/util_dpi.cpp $(DPI_DIR)/float_dpi.cpp
|
||||
SRCS += simulator.cpp
|
||||
SRCS += main.cpp simulator.cpp
|
||||
|
||||
ifdef AXI_BUS
|
||||
TOP = Vortex_axi
|
||||
|
@ -42,7 +41,7 @@ else
|
|||
TOP = Vortex
|
||||
endif
|
||||
|
||||
VL_FLAGS = --cc $(TOP) --top-module $(TOP)
|
||||
VL_FLAGS = --exe --cc $(TOP) --top-module $(TOP)
|
||||
VL_FLAGS += -O2 --language 1800-2009 --assert -Wall -Wpedantic
|
||||
VL_FLAGS += -Wno-DECLFILENAME -Wno-REDEFMACRO
|
||||
VL_FLAGS += --x-initial unique --x-assign unique
|
||||
|
@ -75,49 +74,34 @@ VL_FLAGS += -D$(FPU_CORE)
|
|||
|
||||
THREADS ?= $(shell python3 -c 'import multiprocessing as mp; print(max(1, mp.cpu_count() // 2))')
|
||||
|
||||
OBJS := $(patsubst %.cpp, obj_dir/%.o, $(notdir $(SRCS)))
|
||||
VPATH := $(sort $(dir $(SRCS)))
|
||||
|
||||
#$(info OBJS is $(OBJS))
|
||||
#$(info VPATH is $(VPATH))
|
||||
|
||||
PROJECT = rtlsim
|
||||
|
||||
all: build-s
|
||||
|
||||
build-s:
|
||||
verilator --build --exe main.cpp $(SRCS) $(VL_FLAGS) -DNDEBUG $(SINGLECORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(SINGLECORE)' -o ../$(PROJECT)
|
||||
build-s: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) -DNDEBUG $(SRCS) $(SINGLECORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(SINGLECORE)' -o ../$(PROJECT)
|
||||
|
||||
build-sd:
|
||||
verilator --build --exe main.cpp $(SRCS) $(VL_FLAGS) $(SINGLECORE) -CFLAGS '$(CXXFLAGS) $(DBG_FLAGS) $(SINGLECORE)' --trace --trace-structs $(DBG_FLAGS) -o ../$(PROJECT)
|
||||
build-sd: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) $(SRCS) $(SINGLECORE) -CFLAGS '$(CXXFLAGS) $(DBG_FLAGS) $(SINGLECORE)' --trace --trace-structs $(DBG_FLAGS) -o ../$(PROJECT)
|
||||
|
||||
build-st:
|
||||
verilator --build --exe main.cpp $(SRCS) $(VL_FLAGS) -DNDEBUG $(SINGLECORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(SINGLECORE)' --threads $(THREADS) -o ../$(PROJECT)
|
||||
build-st: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) -DNDEBUG $(SRCS) $(SINGLECORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(SINGLECORE)' --threads $(THREADS) -o ../$(PROJECT)
|
||||
|
||||
build-m:
|
||||
verilator --build --exe main.cpp $(SRCS) $(VL_FLAGS) -DNDEBUG $(MULTICORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(MULTICORE)' -o ../$(PROJECT)
|
||||
build-m: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) -DNDEBUG $(SRCS) $(MULTICORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(MULTICORE)' -o ../$(PROJECT)
|
||||
|
||||
build-md:
|
||||
verilator --build --exe main.cpp $(SRCS) $(VL_FLAGS) $(MULTICORE) -CFLAGS '$(CXXFLAGS) $(DBG_FLAGS) $(MULTICORE)' --trace --trace-structs $(DBG_FLAGS) -o ../$(PROJECT)
|
||||
build-md: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) $(SRCS) $(MULTICORE) -CFLAGS '$(CXXFLAGS) $(DBG_FLAGS) $(MULTICORE)' --trace --trace-structs $(DBG_FLAGS) -o ../$(PROJECT)
|
||||
|
||||
build-mt:
|
||||
verilator --build --exe main.cpp $(SRCS) $(VL_FLAGS) -DNDEBUG $(MULTICORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(MULTICORE)' --threads $(THREADS) -o ../$(PROJECT)
|
||||
build-mt: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) -DNDEBUG $(SRCS) $(MULTICORE) -CFLAGS '$(CXXFLAGS) -DNDEBUG $(MULTICORE)' --threads $(THREADS) -o ../$(PROJECT)
|
||||
|
||||
obj_dir/V$(TOP)__ALL.a:
|
||||
verilator --build $(VL_FLAGS) -CFLAGS '$(CXXFLAGS)'
|
||||
static: $(SRCS)
|
||||
verilator --build $(VL_FLAGS) $(SRCS) -CFLAGS '$(CXXFLAGS)'
|
||||
$(AR) rs lib$(PROJECT).a obj_dir/*.o
|
||||
|
||||
obj_dir/%.o: %.cpp
|
||||
cd obj_dir && $(CXX) $(CXXFLAGS) -c ../$< -o $(notdir $@)
|
||||
clean-static:
|
||||
rm -rf lib$(PROJECT).a obj_dir
|
||||
|
||||
obj_dir/verilated.o: $(VERILATOR_ROOT)/include/verilated.cpp
|
||||
cd obj_dir && $(CXX) $(CXXFLAGS) -c $< -o verilated.o
|
||||
|
||||
static: obj_dir/V$(TOP)__ALL.a $(OBJS) obj_dir/verilated.o
|
||||
cp obj_dir/V$(TOP)__ALL.a lib$(PROJECT).a
|
||||
$(AR) rs lib$(PROJECT).a $(OBJS) obj_dir/verilated.o
|
||||
|
||||
clean-objdir:
|
||||
rm -rf obj_dir
|
||||
|
||||
clean: clean-objdir
|
||||
rm -rf $(PROJECT) lib$(PROJECT).a
|
||||
clean: clean-static
|
||||
rm -rf $(PROJECT)
|
||||
|
|
|
@ -42,8 +42,8 @@ static: $(OBJS)
|
|||
.depend: $(SRCS)
|
||||
$(CXX) $(CXXFLAGS) -MM $^ > .depend;
|
||||
|
||||
clean-objdir:
|
||||
rm -rf obj_dir .depend
|
||||
clean-static:
|
||||
rm -rf lib$(PROJECT).a obj_dir .depend
|
||||
|
||||
clean: clean-objdir
|
||||
rm -rf $(PROJECT) lib$(PROJECT).a
|
||||
clean: clean-static
|
||||
rm -rf $(PROJECT)
|
|
@ -2,8 +2,7 @@ CXXFLAGS += -std=c++11 -O2 -Wall -Wextra -Wfatal-errors
|
|||
#CXXFLAGS += -std=c++11 -g -O0 -Wall -Wextra -Wfatal-errors
|
||||
|
||||
CXXFLAGS += -fPIC -Wno-maybe-uninitialized
|
||||
CXXFLAGS += -I. -I../../../hw -I../../common
|
||||
CXXFLAGS += -I$(VERILATOR_ROOT)/include -I$(VERILATOR_ROOT)/include/vltstd
|
||||
CXXFLAGS += -I.. -I../../../hw -I../../common
|
||||
|
||||
# control RTL debug print states
|
||||
DBG_PRINT_FLAGS += -DDBG_PRINT_PIPELINE
|
||||
|
@ -30,6 +29,7 @@ LDFLAGS += -shared
|
|||
|
||||
RTL_DIR = ../../hw/rtl
|
||||
DPI_DIR = ../../hw/dpi
|
||||
SCRIPT_DIR=../../hw/scripts
|
||||
|
||||
SRCS = ../common/util.cpp ../common/mem.cpp
|
||||
SRCS += $(DPI_DIR)/util_dpi.cpp $(DPI_DIR)/float_dpi.cpp
|
||||
|
@ -41,7 +41,7 @@ RTL_INCLUDE += -I$(RTL_DIR)/afu -I$(RTL_DIR)/afu/ccip
|
|||
|
||||
TOP = vortex_afu_shim
|
||||
|
||||
VL_FLAGS = --cc $(TOP) --top-module $(TOP)
|
||||
VL_FLAGS = --exe --cc $(TOP) --top-module $(TOP)
|
||||
VL_FLAGS += -O2 --language 1800-2009 --assert -Wall -Wpedantic
|
||||
VL_FLAGS += -Wno-DECLFILENAME -Wno-REDEFMACRO
|
||||
VL_FLAGS += --x-initial unique --x-assign unique
|
||||
|
@ -86,31 +86,22 @@ VL_FLAGS += -DIDIV_DPI
|
|||
FPU_CORE ?= FPU_DPI
|
||||
VL_FLAGS += -D$(FPU_CORE)
|
||||
|
||||
OBJS := $(patsubst %.cpp, obj_dir/%.o, $(notdir $(SRCS)))
|
||||
VPATH := $(sort $(dir $(SRCS)))
|
||||
|
||||
#$(info OBJS is $(OBJS))
|
||||
#$(info VPATH is $(VPATH))
|
||||
|
||||
PROJECT = libopae-c-vlsim
|
||||
|
||||
all: shared
|
||||
|
||||
shared: $(SRCS)
|
||||
verilator --build --exe $(VL_FLAGS) $(SRCS) -CFLAGS '$(CXXFLAGS)' -LDFLAGS '$(LDFLAGS)' -o ../$(PROJECT).so
|
||||
vortex_afu.h : $(RTL_DIR)/afu/vortex_afu.vh
|
||||
$(SCRIPT_DIR)/gen_config.py -i $(RTL_DIR)/afu/vortex_afu.vh -o vortex_afu.h
|
||||
|
||||
obj_dir/V$(TOP)__ALL.a:
|
||||
verilator --build $(VL_FLAGS) -CFLAGS '$(CXXFLAGS)'
|
||||
shared: $(SRCS) vortex_afu.h
|
||||
verilator --build $(VL_FLAGS) $(SRCS) -CFLAGS '$(CXXFLAGS)' -LDFLAGS '$(LDFLAGS)' -o ../$(PROJECT).so
|
||||
|
||||
obj_dir/%.o: %.cpp
|
||||
cd obj_dir && $(CXX) $(CXXFLAGS) -c ../$< -o $(notdir $@)
|
||||
static: $(SRCS) vortex_afu.h
|
||||
verilator --build $(VL_FLAGS) $(SRCS) -CFLAGS '$(CXXFLAGS)' -LDFLAGS '$(LDFLAGS)'
|
||||
$(AR) rs $(PROJECT).a obj_dir/*.o
|
||||
|
||||
static: obj_dir/V$(TOP)__ALL.a $(OBJS)
|
||||
cp obj_dir/V$(TOP)__ALL.a $(PROJECT).a
|
||||
$(AR) rs $(PROJECT).a $(OBJS)
|
||||
clean-static:
|
||||
rm -rf $(PROJECT).a obj_dir vortex_afu.h
|
||||
|
||||
clean-objdir:
|
||||
rm -rf obj_dir
|
||||
|
||||
clean: clean-objdir
|
||||
rm -rf $(PROJECT).a $(PROJECT).so
|
||||
clean: clean-static
|
||||
rm -rf $(PROJECT).so
|
||||
|
|
|
@ -6,7 +6,7 @@ all:
|
|||
$(MAKE) -C nearn
|
||||
$(MAKE) -C guassian
|
||||
$(MAKE) -C oclprintf
|
||||
$(MAKE) -C psort
|
||||
#$(MAKE) -C psort
|
||||
|
||||
run-simx:
|
||||
$(MAKE) -C vecadd run-simx
|
||||
|
|
|
@ -1,8 +1,4 @@
|
|||
#LLVM_PREFIX ?= /opt/llvm-riscv
|
||||
#LLVM_PREFIX=/home/blaise/dev/llvm-riscv/builddbg
|
||||
#LLVM_PREFIX=/home/blaise/dev/llvm_rv12/build_dbg/release
|
||||
LLVM_PREFIX=/home/blaise/dev/llvm-riscv/build_rel
|
||||
|
||||
LLVM_PREFIX ?= /opt/llvm-riscv
|
||||
RISCV_TOOLCHAIN_PATH ?= /opt/riscv-gnu-toolchain
|
||||
SYSROOT ?= $(RISCV_TOOLCHAIN_PATH)/riscv32-unknown-elf
|
||||
POCL_CC_PATH ?= /opt/pocl/compiler
|
||||
|
@ -13,11 +9,6 @@ OPTS ?= -f -n16
|
|||
VORTEX_DRV_PATH ?= $(realpath ../../../driver)
|
||||
VORTEX_RT_PATH ?= $(realpath ../../../runtime)
|
||||
|
||||
#CC = ${CLANG_PATH}/bin/clang
|
||||
#AR = ${CLANG_PATH}/bin/llvm-ar
|
||||
#DP = ${CLANG_PATH}/bin/llvm-objdump
|
||||
#CP = ${CLANG_PATH}/bin/llvm-objcopy
|
||||
|
||||
K_LLCFLAGS += "-O3 -march=riscv32 -target-abi=ilp32f -mcpu=generic-rv32 -mattr=+m,+f -mattr=+vortex -float-abi=hard -code-model=small"
|
||||
K_CFLAGS += "-v -O3 --sysroot=$(SYSROOT) --gcc-toolchain=$(RISCV_TOOLCHAIN_PATH) -march=rv32imf -mabi=ilp32f -Xclang -target-feature -Xclang +vortex -I$(VORTEX_RT_PATH)/include -fno-rtti -fno-exceptions -ffreestanding -nostartfiles -fdata-sections -ffunction-sections"
|
||||
K_LDFLAGS += "-Wl,-Bstatic,-T$(VORTEX_RT_PATH)/linker/vx_link.ld -Wl,--gc-sections $(VORTEX_RT_PATH)/libvortexrt.a -lm"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue