mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-27 02:45:52 +00:00
Added $anyseq cell type
This commit is contained in:
parent
2733994aeb
commit
bdc316db50
11 changed files with 40 additions and 11 deletions
|
@ -762,7 +762,7 @@ void AstNode::detectSignWidthWorker(int &width_hint, bool &sign_hint, bool *foun
|
|||
break;
|
||||
|
||||
case AST_FCALL:
|
||||
if (str == "\\$anyconst") {
|
||||
if (str == "\\$anyconst" || str == "\\$anyseq") {
|
||||
if (GetSize(children) == 1) {
|
||||
while (children[0]->simplify(true, false, false, 1, -1, false, true) == true) { }
|
||||
if (children[0]->type != AST_CONSTANT)
|
||||
|
@ -1465,7 +1465,7 @@ RTLIL::SigSpec AstNode::genRTLIL(int width_hint, bool sign_hint)
|
|||
} break;
|
||||
|
||||
case AST_FCALL: {
|
||||
if (str == "\\$anyconst")
|
||||
if (str == "\\$anyconst" || str == "\\$anyseq")
|
||||
{
|
||||
string myid = stringf("%s$%d", str.c_str() + 1, autoidx++);
|
||||
int width = width_hint;
|
||||
|
|
|
@ -1807,8 +1807,8 @@ skip_dynamic_range_lvalue_expansion:;
|
|||
goto apply_newNode;
|
||||
}
|
||||
|
||||
// $anyconst is mapped in AstNode::genRTLIL()
|
||||
if (str == "\\$anyconst") {
|
||||
// $anyconst and $anyseq are mapped in AstNode::genRTLIL()
|
||||
if (str == "\\$anyconst" || str == "\\$anyseq") {
|
||||
recursion_counter--;
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -1229,7 +1229,7 @@ rvalue:
|
|||
$$ = new AstNode(AST_IDENTIFIER, $2);
|
||||
$$->str = *$1;
|
||||
delete $1;
|
||||
if ($2 == nullptr && formal_mode && ($$->str == "\\$initstate" || $$->str == "\\$anyconst"))
|
||||
if ($2 == nullptr && formal_mode && ($$->str == "\\$initstate" || $$->str == "\\$anyconst" || $$->str == "\\$anyseq"))
|
||||
$$->type = AST_FCALL;
|
||||
} |
|
||||
hierarchical_id non_opt_multirange {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue