mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 17:15:33 +00:00
ast: translate $display/$write tasks in always blocks to new $print cell.
This commit is contained in:
parent
9f8e039a4b
commit
d5c9953c09
5 changed files with 115 additions and 19 deletions
|
@ -22,6 +22,8 @@ X(always_ff)
|
|||
X(always_latch)
|
||||
X(anyconst)
|
||||
X(anyseq)
|
||||
X(ARGS)
|
||||
X(ARGS_WIDTH)
|
||||
X(ARST)
|
||||
X(ARST_POLARITY)
|
||||
X(ARST_VALUE)
|
||||
|
@ -86,6 +88,7 @@ X(equiv_merged)
|
|||
X(equiv_region)
|
||||
X(extract_order)
|
||||
X(F)
|
||||
X(FORMAT)
|
||||
X(force_downto)
|
||||
X(force_upto)
|
||||
X(fsm_encoding)
|
||||
|
@ -233,6 +236,10 @@ X(TRANS_NUM)
|
|||
X(TRANSPARENCY_MASK)
|
||||
X(TRANSPARENT)
|
||||
X(TRANS_TABLE)
|
||||
X(TRG)
|
||||
X(TRG_ENABLE)
|
||||
X(TRG_POLARITY)
|
||||
X(TRG_WIDTH)
|
||||
X(T_RISE_MAX)
|
||||
X(T_RISE_MIN)
|
||||
X(T_RISE_TYP)
|
||||
|
|
|
@ -1720,6 +1720,17 @@ namespace {
|
|||
return;
|
||||
}
|
||||
|
||||
if (cell->type == ID($print)) {
|
||||
param(ID(FORMAT));
|
||||
param_bool(ID::TRG_ENABLE);
|
||||
param(ID::TRG_POLARITY);
|
||||
port(ID::EN, 1);
|
||||
port(ID::TRG, param(ID::TRG_WIDTH));
|
||||
port(ID::ARGS, param(ID::ARGS_WIDTH));
|
||||
check_expected();
|
||||
return;
|
||||
}
|
||||
|
||||
if (cell->type == ID($_BUF_)) { port(ID::A,1); port(ID::Y,1); check_expected(); return; }
|
||||
if (cell->type == ID($_NOT_)) { port(ID::A,1); port(ID::Y,1); check_expected(); return; }
|
||||
if (cell->type == ID($_AND_)) { port(ID::A,1); port(ID::B,1); port(ID::Y,1); check_expected(); return; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue