summaryrefslogtreecommitdiffstats
path: root/src/base/abci/abc.c
diff options
context:
space:
mode:
authorAlan Mishchenko <alanmi@berkeley.edu>2012-02-11 00:43:37 -0800
committerAlan Mishchenko <alanmi@berkeley.edu>2012-02-11 00:43:37 -0800
commit112f797c731ac45b713efd87dd5956695b983ecd (patch)
treee1bb5ccba8e41559e9642394a888d9d30e6c0bd1 /src/base/abci/abc.c
parentc5067f7d04dc4c8ee919d9597a4a94a5c4ac3552 (diff)
downloadabc-112f797c731ac45b713efd87dd5956695b983ecd.tar.gz
abc-112f797c731ac45b713efd87dd5956695b983ecd.tar.bz2
abc-112f797c731ac45b713efd87dd5956695b983ecd.zip
Added switch -f to 'print_io' to suppress printing flops.
Diffstat (limited to 'src/base/abci/abc.c')
-rw-r--r--src/base/abci/abc.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/base/abci/abc.c b/src/base/abci/abc.c
index 8a95e252..477adf06 100644
--- a/src/base/abci/abc.c
+++ b/src/base/abci/abc.c
@@ -1088,14 +1088,17 @@ int Abc_CommandPrintIo( Abc_Frame_t * pAbc, int argc, char ** argv )
{
Abc_Ntk_t * pNtk = Abc_FrameReadNtk(pAbc);
Abc_Obj_t * pNode;
- int c;
+ int c, fPrintFlops = 1;
// set defaults
Extra_UtilGetoptReset();
- while ( ( c = Extra_UtilGetopt( argc, argv, "h" ) ) != EOF )
+ while ( ( c = Extra_UtilGetopt( argc, argv, "fh" ) ) != EOF )
{
switch ( c )
{
+ case 'f':
+ fPrintFlops ^= 1;
+ break;
case 'h':
goto usage;
default:
@@ -1127,12 +1130,13 @@ int Abc_CommandPrintIo( Abc_Frame_t * pAbc, int argc, char ** argv )
return 0;
}
// print the nodes
- Abc_NtkPrintIo( stdout, pNtk );
+ Abc_NtkPrintIo( stdout, pNtk, fPrintFlops );
return 0;
usage:
- Abc_Print( -2, "usage: print_io [-h] <node>\n" );
- Abc_Print( -2, "\t prints the PIs/POs or fanins/fanouts of a node\n" );
+ Abc_Print( -2, "usage: print_io [-fh] <node>\n" );
+ Abc_Print( -2, "\t prints the PIs/POs/flops or fanins/fanouts of a node\n" );
+ Abc_Print( -2, "\t-f : toggles printing flops [default = %s]\n", fPrintFlops? "yes": "no" );
Abc_Print( -2, "\t-h : print the command usage\n");
Abc_Print( -2, "\tnode : the node to print fanins/fanouts\n");
return 1;