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

Go to the source code of this file.

Classes

struct  Super2_ManStruct_t_
 
struct  Super2_LibStruct_t_
 
struct  Super2_GateStruct_t_
 

Macros

#define SUPER_MASK(n)
 DECLARATIONS ///.
 
#define SUPER_FULL   (~((unsigned)0))
 
#define Super2_IsComplement(p)
 
#define Super2_Regular(p)
 
#define Super2_Not(p)
 
#define Super2_NotCond(p, c)
 
#define Super2_LibForEachGate(Lib, Gate)
 
#define Super2_LibForEachGate2(Lib, Gate2)
 

Typedefs

typedef struct Super2_ManStruct_t_ Super2_Man_t
 
typedef struct Super2_LibStruct_t_ Super2_Lib_t
 
typedef struct Super2_GateStruct_t_ Super2_Gate_t
 

Functions

void Super2_Precompute (int nInputs, int nLevels, int fVerbose)
 FUNCTION DEFINITIONS ///.
 

Macro Definition Documentation

◆ Super2_IsComplement

#define Super2_IsComplement ( p)
Value:
(((int)((ABC_PTRUINT_T) (p) & 01)))
Cube * p
Definition exorList.c:222

Definition at line 67 of file superAnd.c.

◆ Super2_LibForEachGate

#define Super2_LibForEachGate ( Lib,
Gate )
Value:
for ( Lib->i = 0; \
Lib->i < Lib->nGates && (Gate = Lib->pGates[Lib->i]); \
Lib->i++ )

Definition at line 73 of file superAnd.c.

73#define Super2_LibForEachGate( Lib, Gate ) \
74 for ( Lib->i = 0; \
75 Lib->i < Lib->nGates && (Gate = Lib->pGates[Lib->i]); \
76 Lib->i++ )

◆ Super2_LibForEachGate2

#define Super2_LibForEachGate2 ( Lib,
Gate2 )
Value:
for ( Lib->k = 0; \
Lib->k < Lib->i && (Gate2 = Lib->pGates[Lib->k]); \
Lib->k++ )

Definition at line 77 of file superAnd.c.

77#define Super2_LibForEachGate2( Lib, Gate2 ) \
78 for ( Lib->k = 0; \
79 Lib->k < Lib->i && (Gate2 = Lib->pGates[Lib->k]); \
80 Lib->k++ )

◆ Super2_Not

#define Super2_Not ( p)
Value:
((Super2_Gate_t *)((ABC_PTRUINT_T)(p) ^ 01))
struct Super2_GateStruct_t_ Super2_Gate_t
Definition superAnd.c:35

Definition at line 69 of file superAnd.c.

◆ Super2_NotCond

#define Super2_NotCond ( p,
c )
Value:
((Super2_Gate_t *)((ABC_PTRUINT_T)(p) ^ (c)))

Definition at line 70 of file superAnd.c.

◆ Super2_Regular

#define Super2_Regular ( p)
Value:
((Super2_Gate_t *)((ABC_PTRUINT_T)(p) & ~01))

Definition at line 68 of file superAnd.c.

◆ SUPER_FULL

#define SUPER_FULL   (~((unsigned)0))

Definition at line 30 of file superAnd.c.

◆ SUPER_MASK

#define SUPER_MASK ( n)
Value:
((~((unsigned)0)) >> (32-n))

DECLARATIONS ///.

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

FileName [superAnd.c]

PackageName [MVSIS 1.3: Multi-valued logic synthesis system.]

Synopsis [Pre-computation of supergates.]

Author [MVSIS Group]

Affiliation [UC Berkeley]

Date [Ver. 1.0. Started - September 8, 2003.]

Revision [

Id
superAnd.c,v 1.3 2004/06/28 14:20:25 alanmi Exp

]

Definition at line 29 of file superAnd.c.

Typedef Documentation

◆ Super2_Gate_t

Definition at line 35 of file superAnd.c.

◆ Super2_Lib_t

Definition at line 34 of file superAnd.c.

◆ Super2_Man_t

Definition at line 33 of file superAnd.c.

Function Documentation

◆ Super2_Precompute()

void Super2_Precompute ( int nInputs,
int nLevels,
int fVerbose )

FUNCTION DEFINITIONS ///.

INCLUDES ///.

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

Synopsis [Precomputes the library of AND2 gates.]

Description []

SideEffects []

SeeAlso []

Definition at line 113 of file superAnd.c.

114{
115 Super2_Man_t * pMan;
116 Super2_Lib_t * pLibCur, * pLibNext;
117 int Level;
118 abctime clk;
119
120 assert( nInputs < 6 );
121
122 // start the manager
123 pMan = Super2_ManStart();
124
125 // get the starting supergates
126 pLibCur = Super2_LibFirst( pMan, nInputs );
127
128 // perform the computation of supergates
129printf( "Computing supergates for %d inputs and %d levels:\n", nInputs, nLevels );
130 for ( Level = 1; Level <= nLevels; Level++ )
131 {
132clk = Abc_Clock();
133 pLibNext = Super2_LibCompute( pMan, pLibCur );
134 pLibNext->nLevels = Level;
135 Super2_LibStop( pLibCur );
136 pLibCur = pLibNext;
137printf( "Level %d: Tried = %7d. Computed = %7d. ", Level, pMan->nTried, pLibCur->nGates );
138ABC_PRT( "Runtime", Abc_Clock() - clk );
139fflush( stdout );
140 }
141
142printf( "Writing the output file...\n" );
143fflush( stdout );
144 // write them into a file
145 Super2_LibWrite( pLibCur );
146 Super2_LibStop( pLibCur );
147
148 // stop the manager
149 Super2_ManStop( pMan );
150}
ABC_INT64_T abctime
Definition abc_global.h:332
#define ABC_PRT(a, t)
Definition abc_global.h:255
struct Super2_ManStruct_t_ Super2_Man_t
Definition superAnd.c:33
struct Super2_LibStruct_t_ Super2_Lib_t
Definition superAnd.c:34
#define assert(ex)
Definition util_old.h:213