We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Verilator requires string parameters to be surrounded by quotes: -Gparam="value"
-Gparam="value"
Strings Strings must be in double quotes (“”). They must be escaped properly on the command line, e.g. as -GSTR="\"My String\"" or -GSTR='"My String"'
Strings
Strings must be in double quotes (“”). They must be escaped properly on the command line, e.g. as -GSTR="\"My String\"" or -GSTR='"My String"'
If given a dict like { "param" : "value" } cocotb_test will generate -Gparam=value and Verilator will fail to compile.
{ "param" : "value" }
-Gparam=value
Some simple logic can be added to do this wrapping in simulator.py:
for name, value in parameters.items(): parameters_cmd.append("-G" + name + "=\"" + str(value) + "\"") if type(value) is str else parameters_cmd.append("-G" + name + "=" + str(value))
The text was updated successfully, but these errors were encountered:
Add quotes to verilator paramters #181
9021a3a
@rishubn Does #200 work for you?
Sorry, something went wrong.
d37bcc4
Adding quotes fails on my local machine. Maybe I am doing something wrong.
No branches or pull requests
Verilator requires string parameters to be surrounded by quotes:
-Gparam="value"
If given a dict like
{ "param" : "value" }
cocotb_test will generate-Gparam=value
and Verilator will fail to compile.Some simple logic can be added to do this wrapping in simulator.py:
The text was updated successfully, but these errors were encountered: