-
Notifications
You must be signed in to change notification settings - Fork 18
Verilog: introduce the Verilog indexer #397
New issue
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
Conversation
d25aa62
to
3e86eac
Compare
de89a04
to
7eb881c
Compare
cd027f2
to
74f74d2
Compare
74f74d2
to
864df21
Compare
a6c284e
to
db8bae1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving subject to making CI pass plus a few comments below. Tests would really be appreciated.
module main(input x, input y); | ||
|
||
reg result; | ||
|
||
always @(x, y) | ||
case(x) | ||
0: result = 0; | ||
1: | ||
case(y) | ||
1: result = 1; | ||
0: result = 0; | ||
endcase | ||
endcase | ||
|
||
always assert p1: result == (x && y); | ||
|
||
endmodule |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In what way is this test exercising the new indexer?
src/vlindex/vlindex_parse_options.h
Outdated
virtual int doit(); | ||
virtual void help(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use override
instead?
// possibly a macro that wasn't found | ||
std::cout << "LPAREN: " << verilog_parser.get_file() << ':' | ||
<< verilog_parser.get_line_no() << ' ' << token.text << "\n"; | ||
rParenExpression(); | ||
} | ||
else | ||
{ | ||
// something else | ||
std::cout << "ELSE: " << verilog_parser.get_file() << ':' | ||
<< verilog_parser.get_line_no() << ' ' << token.text << "\n"; | ||
next_token(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Debug leftovers?
7bb5761
to
c287968
Compare
3a5d3d7
to
cc04e64
Compare
Now with tests in CI. |
This adds a recusive decent parser for quicky indexing large quantities of Verilog, tolerating parsing errors, for the purpose of creating overview data very quickly. A new executable, vlindex, is added to output it.
cc04e64
to
2dbb123
Compare
This adds a recusive decent parser for quicky indexing large quantities of Verilog, tolerating parsing errors, for the purpose of creating overview data very quickly. A new executable,
vlindex
, is added to output it.