mirror of https://github.com/YosysHQ/yosys.git
Added RTLIL::SigSpec::optimized() API
This commit is contained in:
parent
fb2bf934dc
commit
eec2cd1e78
|
@ -1024,6 +1024,13 @@ void RTLIL::SigSpec::optimize()
|
|||
check();
|
||||
}
|
||||
|
||||
RTLIL::SigSpec RTLIL::SigSpec::optimized() const
|
||||
{
|
||||
RTLIL::SigSpec ret = *this;
|
||||
ret.optimize();
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool RTLIL::SigChunk::compare(const RTLIL::SigChunk &a, const RTLIL::SigChunk &b)
|
||||
{
|
||||
if (a.wire != b.wire) {
|
||||
|
|
|
@ -373,6 +373,7 @@ struct RTLIL::SigSpec {
|
|||
SigSpec(std::vector<RTLIL::SigBit> bits);
|
||||
void expand();
|
||||
void optimize();
|
||||
RTLIL::SigSpec optimized() const;
|
||||
void sort();
|
||||
void sort_and_unify();
|
||||
void replace(const RTLIL::SigSpec &pattern, const RTLIL::SigSpec &with);
|
||||
|
|
Loading…
Reference in New Issue