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
Question: AUTO_TEMPLATE - queries #1049
Comments
Original Redmine Comment
.blk_apb_(.*) (blk_apb_if_h.@"(upcase \"\1\")"[]),
3/4. The mode will use the indentation of the ( opening the signals. So do this
|
Original Redmine Comment Hi Wilson, Thanks for your suggestions. Am sorry, I didn't get your last suggestion. Did you mean to say, both my indentation problem as well as the picking parameters value from package will be resolved if I use below. cellname I tried using AUTOPARAM but that's doesn't help. can you pls elaborate it. Thank you rgds |
Original Redmine Comment There is no automatic way to get parameters from a package. You can use AUTO_TEMPLATE (which applies to both parameters and normal signals) to either explicitly list them, or use a wildcard template to add them. |
Original Redmine Comment Thanks for the info Wilson. I was trying to use the below to see if I can get the value of the parameters while I expand the auto's // Local Variables: However I still see the parameter name used in the expanded code. May I pls know if you have any suggestions in this regard. The design file had the parameters info like below. The design file has the parameters defined like below module abc (signal_a, signal_b... endmodule rgds |
Original Redmine Comment verilog-auto-inst-param-value only affects AUTOINSTPARAM which you didn't have in your example; there's an example under "M-x describe-variable auto-inst-param-value". If you still think it should work attach a complete example please. |
Original Redmine Comment Hi Wilson, Yeah, I used the AUTOINSTPARAM. Also I looked at the FAQ's and it looks I am following the steps suggested, but wondering why parameters value doesn't get the substituted during instantiation. Pls suggest me if I am missing anything here. Pls find the info that I have used. AUTO_TEMPLATE had few more signals, I have trimmed them to avoid lengthy email
And the rtl had parameters info in the below format:
rgds |
Original Redmine Comment Sorry, I may have confused you. It reads the value of the parameter from a handcrafted value in the parameters in the instantiation. Like this - note the 15 in axi0_data. A case could be made to improve this.
|
Author Name: kishore babu nainappagari
Original Redmine Message: 1833 from https://www.veripool.org
Hi Wilson,
I am having trouble to expand the below , using AUTO_TEMPLATE , Pls provide your suggestions
The expanded dut signals instantiation were either following the signals declarations hierarchy in the input file or getting sorted out using verilog-auto-inst-sort.
the expanded signals info was seen like below
.clnt29_clk ( clk_inst[29].clk),
.clnt30_clk ( clk_inst[30].clk),
.clnt29_wdata ( clk_inst[29].wdata),
.clnt30_wdata ( clk_inst[30].wdata),
...
However if I wish to have the signals info in the below format, May I know how can I do that.
//expected signals info
...
.clnt29_clk ( clk_inst[29].clk),
.clnt29_rst_n ( clk_inst[29].rst_n),
.clnt29_wdata ( clk_inst[29].wdata),
.clnt29_rdata ( clk_inst[29].rdata),
The expanded signals were seen like with improper number of white spaces
.blk_clnt0_rctl(clnt_inst[0].rctl[1:0]), // Templated
.blk_clnt0_rdata(clnt_inst[0].rdata[63:0]), // Templated
.blk_clnt0_rderr(clnt_inst[0].rderr), // Templated
.blk_clnt10_wstat_vld(clnt_inst[10].wstat_vld), // Templated
May I pls know how can I get the info in the below format (neatly aligned)
.blk_clnt0_rctl (clnt_inst[0].rctl[1:0]), // Templated
.blk_clnt0_rdata (clnt_inst[0].rdata[63:0]), // Templated
.blk_clnt0_rderr (clnt_inst[0].rderr), // Templated
.blk_clnt10_wstat_vld (clnt_inst[10].wstat_vld), // Templated
or at least in the below manner.
.blk_clnt0_rctl(clnt_inst[0].rctl[1:0]), // Templated
.blk_clnt0_rdata(clnt_inst[0].rdata[63:0]), // Templated
.blk_clnt0_rderr(clnt_inst[0].rderr), // Templated
.blk_clnt10_wstat_vld(clnt_inst[10].wstat_vld), // Templated
I have few signals like
.apb_blk_paddr (blk_apb_if_h.PADDR)
.apb_blk_pslverr (blk_apb_if_h.PSLVERR)
.apb_blk_pwdata (blk_apb_if_h.PWDATA)
I tried using syntax in AUTO_TEMPLATE, but it flags error.
.blk_apb_(.*) (blk_apb_if_h.@"(upcase \1)"[]),
However when I tried below, I was successful. but pls let me know if there is a better way to deal with these.
.blk_apb_(.*) (blk_apb_if_h.@"(substring (upcase vl-name) 8)"[])
The block has few parameters which I was able to get them using AUTOINSTPARAM like below
blk blk_i #(/AUTOINSTPARAM/
// Parameters
.SUPPORT (SUPPORT))(
...
however if I wish to get it like below, may I pls know if there is a way
blk blk_i #(/AUTOINSTPARAM/
// Parameters
.SUPPORT (blk_pkg::SUPPORT))(
...
Pls suggest.
rgds
Kishore
The text was updated successfully, but these errors were encountered: