Comments (3)
Hello,
Thanks for the question. The cell_window
view is doing something different than you expect. Starting from some pivot node, which is a cell root, it creates a window around that node (bounded in size by some parameters) such that the window is covered itself by cells. So it does not cut through any cells. The motivation behind this is that you could throw away the current mapping of the window, remap it, and then insert it back into the original network without making the overall mapping inconsistent.
If you like to have a network structure around the cell then you can use cut_view
instead.
I hope that this clarifies the problem.
from mockturtle.
Thanks for the quick response and the helpful comment! The cut_view
does exactly what I want. Here is an updated version of the code above, just in case someone has the same question and comes across this issue:
template<class Ntk>
void print_cell_io( Ntk const& ntk ) // ntk is a mapped network
{
ntk.foreach_node( [&]( auto const n ) {
if ( ntk.is_constant( n ) || ntk.is_pi( n ) || !ntk.is_cell_root( n ) )
return;
std::vector<typename Ntk::node> leaves;
ntk.foreach_cell_fanin( n, [&]( auto const f ) {
leaves.push_back( f );
} );
std::cout << "cell has " << leaves.size() << " fanins\n";
auto cut = mockturtle::cut_view( ntk, leaves, n );
std::cout << "cut_view i/o = " << cut.num_pis() << "/" << cut.num_pos() << "\n";
} );
}
Best regards!
from mockturtle.
Thanks for providing the updated example!
from mockturtle.
Related Issues (20)
- Bug in akers_synthesis (known)
- NEQ bug in aig_resub HOT 1
- buffer_insertion::dry_run with until_sat is endless HOT 1
- mig_algebraic_depth_rewriting_splitters::run_selective is endless HOT 1
- Using mockturtle as a library in another project HOT 1
- ALAP in depth_view
- `substitute_node`: Should it be allowed to substitute with a dead node? HOT 2
- Is it intended that `create_pi()` does not trigger `on_add` events? HOT 5
- Bug in refactoring HOT 3
- Write a sequential circuit with register outputs.
- `write_blif` outputs duplicate `.names` HOT 4
- Optimization algorithms to support names_view<sequential<xxx_network>> HOT 1
- lut_map creates non-equivalent network HOT 1
- Bug in aqfp_flow_date HOT 1
- NEQ bug in new LUT mapper HOT 1
- Technology Mapping of sequential aig fails. HOT 2
- `write_blif` incorrect behavior when PO is connected to PI of the same index HOT 4
- `aig_resubstitution` following `cut_rewriting` without `cleanup_dangling` in between creates NEQ circuits HOT 3
- `refactoring` using `sop_factoring` assertion fails in `mffc_view` HOT 2
- How to reproduce DATE20 Exact DAG-Aware Rewriting? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mockturtle.