This commit is contained in:
Blaise Tine
2020-08-07 10:12:29 -07:00
6 changed files with 62 additions and 16 deletions

View File

@@ -62,12 +62,12 @@ Install Verilator
Install Vortex
$ git clone https://github.gatech.edu/casl/Vortex.git
$ git clone --recursive https://github.gatech.edu/casl/Vortex.git
$ cd Vortex
$ make
Quick Test running SGEMM kernel
$ cd /Vortex/benchmarks/opencl/sgemm
$ cd /Vortex/benchmarks/opencl/vecadd
$ make
$ make run
$ make run-rtlsim

View File

@@ -0,0 +1,2 @@
run:
$(MAKE) -C isa run

View File

@@ -0,0 +1,6 @@
TESTS := $(wildcard *.hex)
#VTESTS := $(wildcard *-v-*.hex)
#TESTS := $(filter-out $(VTESTS) rv32ud-p-fclass.hex, $(TESTS))
run:
cd ../../../hw/simulate/obj_dir && ./VVortex -f $(foreach test,$(TESTS),../../../benchmarks/riscv_tests/isa/$(test))

14
driver/tests/Makefile Normal file
View File

@@ -0,0 +1,14 @@
all:
$(MAKE) -C basic
$(MAKE) -C demo
run:
$(MAKE) -C basic run-rtlsim
$(MAKE) -C basic run-simx
$(MAKE) -C demo run-rtlsim
$(MAKE) -C demo run-simx
clean:
$(MAKE) -C basic clean
$(MAKE) -C demo clean

View File

@@ -143,18 +143,42 @@ int main(int argc, char **argv) {
#endif
} else {
bool passed = true;
char* test = argv[2];
std::vector<std::string> tests(argv+2, argv+argc);
for (std::string test : tests) {
std::cerr << DEFAULT << "\n---------------------------------------\n";
std::cerr << test << std::endl;
RAM ram;
Simulator simulator;
simulator.attach_ram(&ram);
simulator.load_ihex(test.c_str());
simulator.run();
bool status = (1 == simulator.get_last_wb_value(3));
if (status) std::cerr << GREEN << "Test Passed: " << test << std::endl;
if (!status) std::cerr << RED << "Test Failed: " << test << std::endl;
std::cerr << DEFAULT;
passed = passed && status;
if (!passed)
break;
}
std::cerr << test << std::endl;
RAM ram;
Simulator simulator;
simulator.attach_ram(&ram);
simulator.load_ihex(test);
simulator.run();
// char* test = argv[2];
// std::cerr << test << std::endl;
// RAM ram;
// Simulator simulator;
// simulator.attach_ram(&ram);
// simulator.load_ihex(test);
// simulator.run();
return 0;
}
}
}

View File

@@ -6,11 +6,11 @@ all:
$(MAKE) -C vecadd
run:
cd simple && $(MAKE) run
cd dev && $(MAKE) run
cd hello && $(MAKE) run
cd nlTest && $(MAKE) run
cd vecadd && $(MAKE) run
$(MAKE) -C simple run
$(MAKE) -C dev run
$(MAKE) -C hello run
$(MAKE) -C nlTest run
$(MAKE) -C vecadd run
clean:
$(MAKE) -C simple clean