Project

General

Profile

[logo] 
 
Home
News
Activity
About/Contact
Major Tools
  Dinotrace
  Verilator
  Verilog-mode
  Verilog-Perl
Other Tools
  IPC::Locker
  Parallel::Forker
  Voneline
General Info
  Papers

Issue #1085

Besides ignore regex, need force regex for auto-output

Added by Terrence Sun over 3 years ago. Updated about 2 years ago.

Status:
Feature
Priority:
Normal
Assignee:
-
Category:
Autos
% Done:

0%


Description

If a signal is sub-module's input, then it is excluded from auto output.

I would like to add a verilog-auto-force-regex variable, and always output signal matches it.

For instance, do below changes to the sig-list generate:
-(verilog-subdecls-get-inputs modsubdecls)
+(verilog-signals-not-matching-regex (verilog-subdecls-get-inputs modsubdecls) verilog-auto-output-force-regexp)

History

#1 Updated by Wilson Snyder over 3 years ago

Rather than a force, which is sort of a don't not include something, how about a verilog-auto-subdecl-regexp or something that defaults to .*, I.e. by default exclude all sub signals?

#2 Updated by Terrence Sun over 3 years ago

Wilson Snyder wrote:

Rather than a force, which is sort of a don't not include something, how about a verilog-auto-subdecl-regexp or something that defaults to .*, I.e. by default exclude all sub signals?

By using '.*', the same as before. By using '!(paddr|pwrite|pwdata)', we export paddr, pwrite and pwdata to the output. This is workable, but the 'not' in regex make it less straightforward. Maybe we can pick another name for it.

#3 Updated by Wilson Snyder over 3 years ago

  • Status changed from New to AskedReporter

I suspect an AUTOOUTPUT followed by AUTOOUTPUTEVERY") will do what you want. If not can you please attach a small verilog module showing a realistic case with what you want to do (I understand the solution you propose, just not the use case.)

#4 Updated by Terrence Sun over 3 years ago

Use-case:

1. apb wrapper

We have two modules: ahb to apb mux (ahb2apb) and apb async bridge (apb_async).

ahb2apb can be connected to 32 apb slaves, and some of them are from different clock domain.

We make a wrapper (apb_wrapper) to instance one ahb2apb and multiple apb_async according to clock structure, so as to make chip top more clear.

We also make a apb_slave_map module to map ahb2apb.psel[31:0] to individual slave selector (for example, psel_gpio, psel_uart).

  • gpio has single clock, so a asyn bridge is needed.
  • uart has apb clock and uart clock, so direct connect it.
So, the topology of apb_wrapper is as below :
ahb2apb <-> apb_slave_map <-> apb_asyc_uart1 <->| connect to gpio of gpio clock (psel_gpio/paddr/pwrite/pwdata from apb_aysc_uart1)
                          <->                   | connect to uart of apb clock (psel_uart from apb_slave_map, paddr/pwrite/pwdate from ahb2apb)
ahb2apb.psel[31:0] is never needed to be exported as output, only paddr/pwrite/pwdata is needed.

So, OUTPUTEVERY is not suitable here.

2. export busy flag for system control

Busy flag can be read back by CPU from apb bus, and also needed by clock control module for clock management.

So, for the top of a SOC component, engine_busy is connected to the apb slave sub-module as input, and also exported as output (for clock control).

For this case, only the engine_busy is need to exported.

These use-cases show that, only selected part of signals needed to export as output, and they are highly depending on the architecture of design.

#5 Updated by Wilson Snyder about 2 years ago

  • Category set to Autos
  • Status changed from AskedReporter to Feature

Also available in: Atom