mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 09:05:32 +00:00
Added sat -ignore_div_by_zero switch
This commit is contained in:
parent
d0e93e04d1
commit
2f3da54f26
2 changed files with 17 additions and 2 deletions
|
@ -39,9 +39,10 @@ struct SatGen
|
|||
SigMap *sigmap;
|
||||
std::string prefix;
|
||||
SigPool initial_state;
|
||||
bool ignore_div_by_zero;
|
||||
|
||||
SatGen(ezSAT *ez, RTLIL::Design *design, SigMap *sigmap, std::string prefix = std::string()) :
|
||||
ez(ez), design(design), sigmap(sigmap), prefix(prefix)
|
||||
ez(ez), design(design), sigmap(sigmap), prefix(prefix), ignore_div_by_zero(false)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -310,6 +311,10 @@ struct SatGen
|
|||
else
|
||||
ez->assume(ez->vec_eq(y, chain_buf));
|
||||
}
|
||||
|
||||
if (ignore_div_by_zero)
|
||||
ez->assume(ez->expression(ezSAT::OpOr, b));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue