aboutsummaryrefslogtreecommitdiffstats
path: root/driver
diff options
context:
space:
mode:
authorYann Herklotz <git@yannherklotz.com>2021-11-13 23:00:12 +0000
committerYann Herklotz <git@yannherklotz.com>2021-11-13 23:00:12 +0000
commit003c2ebeed882c83ac06a0cd1f7449677ca31d14 (patch)
treeab2aa367b86b2bfa6b1f66bb747390dabf1f3e78 /driver
parent182b6dec50ee4698bff6ef70f93788641d154cdb (diff)
downloadvericert-003c2ebeed882c83ac06a0cd1f7449677ca31d14.tar.gz
vericert-003c2ebeed882c83ac06a0cd1f7449677ca31d14.zip
Rename the verilator script
Diffstat (limited to 'driver')
-rw-r--r--driver/verilator_main.cpp35
1 files changed, 0 insertions, 35 deletions
diff --git a/driver/verilator_main.cpp b/driver/verilator_main.cpp
deleted file mode 100644
index 4561158..0000000
--- a/driver/verilator_main.cpp
+++ /dev/null
@@ -1,35 +0,0 @@
-#include <stdlib.h>
-#include <stdio.h>
-#include "Vmain.h"
-#include "verilated.h"
-
-int main(int argc, char **argv) {
- // Initialize Verilators variables
- Verilated::commandArgs(argc, argv);
-
- // Create an instance of our module under test
- Vmain *tb = new Vmain;
-
- tb->clk = 0;
- tb->start = 0;
- tb->reset = 0;
- tb->eval(); tb->clk = 1; tb->eval(); tb->clk = 0; tb->eval();
- tb->reset = 1;
- tb->eval(); tb->clk = 1; tb->eval(); tb->clk = 0; tb->eval();
- tb->reset = 0;
- tb->eval(); tb->clk = 1; tb->eval(); tb->clk = 0; tb->eval();
-
- int cycles = 1;
-
- // Tick the clock until we are done
- while(!tb->finish) {
- tb->clk = 1;
- tb->eval();
- tb->clk = 0;
- tb->eval();
- cycles++;
- }
-
- printf("cycles: %d\nfinished: %d\n", cycles, (unsigned)tb->return_val);
- exit(EXIT_SUCCESS);
-}