mirror of https://github.com/YosysHQ/yosys.git
Change pmgen default rule to reject, switch peepopt behavior to accept
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
parent
03f98d9176
commit
eb80d3d43f
|
@ -23,6 +23,7 @@ code
|
|||
finally
|
||||
chain.pop_back();
|
||||
log_assert(chain.empty());
|
||||
accept;
|
||||
endcode
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
@ -48,7 +49,6 @@ endmatch
|
|||
|
||||
code
|
||||
non_first_cells.insert(next);
|
||||
reject;
|
||||
endcode
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
@ -74,7 +74,6 @@ code
|
|||
if (GetSize(chain) > GetSize(longest_chain))
|
||||
longest_chain = chain;
|
||||
}
|
||||
reject;
|
||||
finally
|
||||
if (next)
|
||||
chain.pop_back();
|
||||
|
|
|
@ -159,4 +159,5 @@ code clock clock_pol clock_vld
|
|||
clock_pol = cp;
|
||||
clock_vld = true;
|
||||
}
|
||||
accept;
|
||||
endcode
|
||||
|
|
|
@ -32,5 +32,5 @@ code
|
|||
log("muldiv pattern in %s: mul=%s, div=%s\n", log_id(module), log_id(mul), log_id(div));
|
||||
module->connect(div_y, val_y);
|
||||
autoremove(div);
|
||||
reject;
|
||||
accept;
|
||||
endcode
|
||||
|
|
|
@ -91,6 +91,6 @@ code
|
|||
shift->setParam(\B_WIDTH, GetSize(new_b));
|
||||
|
||||
blacklist(shift);
|
||||
reject;
|
||||
accept;
|
||||
}
|
||||
endcode
|
||||
|
|
|
@ -494,8 +494,6 @@ with open(outfile, "w") as f:
|
|||
current_pattern, current_subpattern = block["pattern"]
|
||||
|
||||
if block["type"] == "final":
|
||||
print(" on_accept();", file=f)
|
||||
print(" check_blacklist_{}();".format(current_pattern), file=f)
|
||||
print(" }", file=f)
|
||||
if index+1 != len(blocks):
|
||||
print("", file=f)
|
||||
|
@ -556,7 +554,7 @@ with open(outfile, "w") as f:
|
|||
print("#define reject do {{ check_blacklist_{}(); goto rollback_label; }} while(0)".format(current_pattern), file=f)
|
||||
print("#define accept do {{ on_accept(); check_blacklist_{}(); if (rollback) goto rollback_label; }} while(0)".format(current_pattern), file=f)
|
||||
print("#define branch do {{ block_{}(); if (rollback) goto rollback_label; }} while(0)".format(index+1), file=f)
|
||||
print("#define subpattern(pattern_name) block_subpattern_{}_ ## pattern_name ()".format(current_pattern), file=f)
|
||||
print("#define subpattern(pattern_name) do {{ block_subpattern_{}_ ## pattern_name (); if (rollback) goto rollback_label; }} while(0)".format(current_pattern), file=f)
|
||||
|
||||
for line in block["code"]:
|
||||
print(" " + line, file=f)
|
||||
|
|
Loading…
Reference in New Issue