Environment Setup and Makefile Target Errors#2277
Environment Setup and Makefile Target Errors#2277WajahatRiaz wants to merge 5 commits intolowRISC:masterfrom
Conversation
Add -fexceptions flag to verilator CFLAGS to support C++ exception handling in the simple system simulation environment.
|
Something seems rather odd about the first commit. I think that GCC defaults to |
|
Well I built verilator from their GitHub repository. Would that be causing this issue? |
|
@rswarbrick can you test things out using the environment details I provided? |
marnovandermaas
left a comment
There was a problem hiding this comment.
Interesting that you need to add these include directories relative to verilator root. I appreciate you putting the effort into getting the Verilator root directly from Verilator.
|
@marnovandermaas @rswarbrick Here you go, added appropriate changes. Please review. |
|
@marnovandermaas @rswarbrick any feedback on this? |
| - '--trace-params' | ||
| - '--trace-max-array 1024' | ||
| - '-CFLAGS "-std=c++14 -Wall -DVM_TRACE_FMT_FST -DTOPLEVEL_NAME=ibex_simple_system -g"' | ||
| - '-CFLAGS "-std=c++14 -Wall -fexceptions -DVM_TRACE_FMT_FST -DTOPLEVEL_NAME=ibex_simple_system -g"' |
There was a problem hiding this comment.
Rupert mentioned that this flag should be enabled by default. Do you know why you need this explicitly? Do you still need this after you changed to the lowRISC toolchain?
|
|
||
| # ARCH = rv32im # to disable compressed instructions | ||
| ARCH ?= rv32imc | ||
| ARCH ?= rv32imc_zicsr |
There was a problem hiding this comment.
Do you mind squashing this change to remove it from the commit history?
There was a problem hiding this comment.
Sure, will let you know once I'm done.
dv/cs_registers/Makefile
Outdated
| $(TOOLDIR)share/verilator/include \ | ||
| $(TOOLDIR)share/verilator/include/vltstd \ | ||
| /usr/share/verilator/include \ | ||
| /usr/share/verilator/include/vltstd \ | ||
| /usr/local/share/verilator/include \ | ||
| /usr/local/share/verilator/include/vltstd \ | ||
| /opt/verilator/share/verilator/include \ | ||
| $(HOME)/verilator/include | ||
| /opt/verilator/share/verilator/include/vltstd \ | ||
| $(HOME)/verilator/include \ | ||
| $(HOME)/verilator/include/vltstd |
There was a problem hiding this comment.
Not sure if I think it's a good idea to list all possible paths where Verilator is installed. What's the problem with requiring people to define verilator root?
There was a problem hiding this comment.
I defined verilator root and still couldn't find the svdpi header file.
There was a problem hiding this comment.
If that's the problem I'm on board with adding the "vlstd" path to the Verilator root, but I don't think it's a good idea to add all the possible locations where Verilator could be installed.
I cloned the repository and followed the steps outlined in the README.md. To verify functionality, I ran the following Makefile targets. However, I encountered errors in both cases. Screenshots of the corresponding error logs are attached below.
Target/Issue No. 1: make build-simple-system
When I run
make build-simple-systemI get the following error:Target/Issue No. 2: make build-csr-test
When I run
make build-csr-testI get the following error:Environment Details
Please let me know if any additional setup steps are required or if the errors are known issues with the current branch/version. I'm happy to help troubleshoot further.