ABC: A System for Sequential Synthesis and Verification
 
Loading...
Searching...
No Matches
absRpmOld.c File Reference
#include "abs.h"
Include dependency graph for absRpmOld.c:

Go to the source code of this file.

Functions

ABC_NAMESPACE_IMPL_START Gia_Man_tGia_ManDupIn2Ff (Gia_Man_t *p)
 DECLARATIONS ///.
 
int Gia_ManDupFf2In_rec (Gia_Man_t *pNew, Gia_Obj_t *pObj)
 
Gia_Man_tGia_ManDupFf2In (Gia_Man_t *p, int nFlopsOld)
 
Gia_Man_tAbs_RpmPerformOld (Gia_Man_t *p, int fVerbose)
 

Function Documentation

◆ Abs_RpmPerformOld()

Gia_Man_t * Abs_RpmPerformOld ( Gia_Man_t * p,
int fVerbose )

Function*************************************************************

Synopsis [Reparameterized to get rid of useless primary inputs.]

Description []

SideEffects []

SeeAlso []

Definition at line 141 of file absRpmOld.c.

142{
143// extern Aig_Man_t * Saig_ManRetimeMinArea( Aig_Man_t * p, int nMaxIters, int fForwardOnly, int fBackwardOnly, int fInitial, int fVerbose );
144 Aig_Man_t * pMan, * pTemp;
145 Gia_Man_t * pNew, * pTmp;
146 int nFlopsOld = Gia_ManRegNum(p);
147 if ( fVerbose )
148 {
149 printf( "Original AIG:\n" );
150 Gia_ManPrintStats( p, NULL );
151 }
152
153 // perform input trimming
154 pNew = Gia_ManDupTrimmed( p, 1, 0, 0, -1 );
155 if ( fVerbose )
156 {
157 printf( "After PI trimming:\n" );
158 Gia_ManPrintStats( pNew, NULL );
159 }
160 // transform GIA
161 pNew = Gia_ManDupIn2Ff( pTmp = pNew );
162 Gia_ManStop( pTmp );
163 if ( fVerbose )
164 {
165 printf( "After PI-2-FF transformation:\n" );
166 Gia_ManPrintStats( pNew, NULL );
167 }
168
169 // derive AIG
170 pMan = Gia_ManToAigSimple( pNew );
171 Gia_ManStop( pNew );
172 // perform min-reg retiming
173 pMan = Saig_ManRetimeMinArea( pTemp = pMan, 10, 0, 0, 1, 0 );
174 Aig_ManStop( pTemp );
175 // derive GIA
176 pNew = Gia_ManFromAigSimple( pMan );
177 Aig_ManStop( pMan );
178 if ( fVerbose )
179 {
180 printf( "After min-area retiming:\n" );
181 Gia_ManPrintStats( pNew, NULL );
182 }
183
184 // transform back
185 pNew = Gia_ManDupFf2In( pTmp = pNew, nFlopsOld );
186 Gia_ManStop( pTmp );
187 if ( fVerbose )
188 {
189 printf( "After FF-2-PI transformation:\n" );
190 Gia_ManPrintStats( pNew, NULL );
191 }
192 return pNew;
193}
Gia_Man_t * Gia_ManDupFf2In(Gia_Man_t *p, int nFlopsOld)
Definition absRpmOld.c:108
ABC_NAMESPACE_IMPL_START Gia_Man_t * Gia_ManDupIn2Ff(Gia_Man_t *p)
DECLARATIONS ///.
Definition absRpmOld.c:45
void Aig_ManStop(Aig_Man_t *p)
Definition aigMan.c:187
typedefABC_NAMESPACE_HEADER_START struct Aig_Man_t_ Aig_Man_t
INCLUDES ///.
Definition aig.h:50
Cube * p
Definition exorList.c:222
Aig_Man_t * Gia_ManToAigSimple(Gia_Man_t *p)
Definition giaAig.c:408
Gia_Man_t * Gia_ManFromAigSimple(Aig_Man_t *p)
Definition giaAig.c:212
void Gia_ManStop(Gia_Man_t *p)
Definition giaMan.c:82
Gia_Man_t * Gia_ManDupTrimmed(Gia_Man_t *p, int fTrimCis, int fTrimCos, int fDualOut, int OutValue)
Definition giaDup.c:2431
struct Gia_Man_t_ Gia_Man_t
Definition gia.h:96
void Gia_ManPrintStats(Gia_Man_t *p, Gps_Par_t *pPars)
Definition giaMan.c:495
Aig_Man_t * Saig_ManRetimeMinArea(Aig_Man_t *p, int nMaxIters, int fForwardOnly, int fBackwardOnly, int fInitial, int fVerbose)
Definition saigRetMin.c:623
Here is the call graph for this function:

◆ Gia_ManDupFf2In()

Gia_Man_t * Gia_ManDupFf2In ( Gia_Man_t * p,
int nFlopsOld )

Function*************************************************************

Synopsis [Reverses the above step.]

Description []

SideEffects []

SeeAlso []

Definition at line 108 of file absRpmOld.c.

109{
110 Gia_Man_t * pNew;
111 Gia_Obj_t * pObj;
112 int i;
113 pNew = Gia_ManStart( Gia_ManObjNum(p) );
114 pNew->pName = Abc_UtilStrsav( p->pName );
115 pNew->pSpec = Abc_UtilStrsav( p->pSpec );
117 Gia_ManConst0(p)->Value = 0;
118 Gia_ManForEachRo( p, pObj, i )
119 pObj->Value = Gia_ManAppendCi( pNew );
120 for ( i = Gia_ManPiNum(p) - nFlopsOld; i < Gia_ManPiNum(p); i++ )
121 Gia_ManPi(p, i)->Value = Gia_ManAppendCi( pNew );
122 Gia_ManForEachPo( p, pObj, i )
123 Gia_ManDupFf2In_rec( pNew, Gia_ObjFanin0(pObj) );
124 Gia_ManForEachPo( p, pObj, i )
125 Gia_ManAppendCo( pNew, Gia_ObjFanin0Copy(pObj) );
126 Gia_ManSetRegNum( pNew, nFlopsOld );
127 return pNew;
128}
int Gia_ManDupFf2In_rec(Gia_Man_t *pNew, Gia_Obj_t *pObj)
Definition absRpmOld.c:87
#define Gia_ManForEachRo(p, pObj, i)
Definition gia.h:1252
#define Gia_ManForEachPo(p, pObj, i)
Definition gia.h:1250
void Gia_ManSetRegNum(Gia_Man_t *p, int nRegs)
Definition giaMan.c:764
Gia_Man_t * Gia_ManStart(int nObjsMax)
FUNCTION DEFINITIONS ///.
Definition giaMan.c:57
struct Gia_Obj_t_ Gia_Obj_t
Definition gia.h:76
void Gia_ManFillValue(Gia_Man_t *p)
Definition giaUtil.c:369
char * pSpec
Definition gia.h:100
char * pName
Definition gia.h:99
unsigned Value
Definition gia.h:89
Here is the call graph for this function:
Here is the caller graph for this function:

◆ Gia_ManDupFf2In_rec()

int Gia_ManDupFf2In_rec ( Gia_Man_t * pNew,
Gia_Obj_t * pObj )

Function*************************************************************

Synopsis [Reverses the above step.]

Description []

SideEffects []

SeeAlso []

Definition at line 87 of file absRpmOld.c.

88{
89 if ( pObj->Value != ~0 )
90 return pObj->Value;
91 assert( Gia_ObjIsAnd(pObj) );
92 Gia_ManDupFf2In_rec( pNew, Gia_ObjFanin0(pObj) );
93 Gia_ManDupFf2In_rec( pNew, Gia_ObjFanin1(pObj) );
94 return pObj->Value = Gia_ManAppendAnd( pNew, Gia_ObjFanin0Copy(pObj), Gia_ObjFanin1Copy(pObj) );
95}
#define assert(ex)
Definition util_old.h:213
Here is the call graph for this function:
Here is the caller graph for this function:

◆ Gia_ManDupIn2Ff()

ABC_NAMESPACE_IMPL_START Gia_Man_t * Gia_ManDupIn2Ff ( Gia_Man_t * p)

DECLARATIONS ///.

CFile****************************************************************

FileName [absRpmOld.c]

SystemName [ABC: Logic synthesis and verification system.]

PackageName [Scalable AIG package.]

Synopsis [Old min-cut-based reparametrization.]

Author [Alan Mishchenko]

Affiliation [UC Berkeley]

Date [Ver. 1.0. Started - June 20, 2005.]

Revision [

Id
absRpmOld.c,v 1.00 2005/06/20 00:00:00 alanmi Exp

] FUNCTION DEFINITIONS /// Function*************************************************************

Synopsis [Specialized duplication.]

Description [Replaces registers by PIs/POs and PIs by registers.]

SideEffects []

SeeAlso []

Definition at line 45 of file absRpmOld.c.

46{
47 Vec_Int_t * vPiOuts;
48 Gia_Man_t * pNew;
49 Gia_Obj_t * pObj;
50 int i;
51 vPiOuts = Vec_IntAlloc( Gia_ManPiNum(p) );
52 pNew = Gia_ManStart( Gia_ManObjNum(p) + 2 * Gia_ManPiNum(p) );
53 pNew->pName = Abc_UtilStrsav( p->pName );
54 pNew->pSpec = Abc_UtilStrsav( p->pSpec );
56 Gia_ManConst0(p)->Value = 0;
57 Gia_ManForEachPi( p, pObj, i )
58 Vec_IntPush( vPiOuts, Gia_ManAppendCi(pNew) );
59 Gia_ManForEachRo( p, pObj, i )
60 pObj->Value = Gia_ManAppendCi( pNew );
61 Gia_ManForEachPi( p, pObj, i )
62 pObj->Value = Gia_ManAppendCi( pNew );
63 Gia_ManForEachAnd( p, pObj, i )
64 pObj->Value = Gia_ManAppendAnd( pNew, Gia_ObjFanin0Copy(pObj), Gia_ObjFanin1Copy(pObj) );
65 Gia_ManForEachPo( p, pObj, i )
66 pObj->Value = Gia_ManAppendCo( pNew, Gia_ObjFanin0Copy(pObj) );
67 Gia_ManForEachRi( p, pObj, i )
68 pObj->Value = Gia_ManAppendCo( pNew, Gia_ObjFanin0Copy(pObj) );
69 Gia_ManForEachPi( p, pObj, i )
70 Gia_ManAppendCo( pNew, Vec_IntEntry(vPiOuts, i) );
71 Gia_ManSetRegNum( pNew, Gia_ManPiNum(p) );
72 Vec_IntFree( vPiOuts );
73 return pNew;
74}
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
Definition bblif.c:37
#define Gia_ManForEachAnd(p, pObj, i)
Definition gia.h:1214
#define Gia_ManForEachPi(p, pObj, i)
Definition gia.h:1248
#define Gia_ManForEachRi(p, pObj, i)
Definition gia.h:1254
Here is the call graph for this function:
Here is the caller graph for this function: