ABC: A System for Sequential Synthesis and Verification
 
Loading...
Searching...
No Matches
mioInt.h
Go to the documentation of this file.
1
18
19#ifndef ABC__map__mio__mioInt_h
20#define ABC__map__mio__mioInt_h
21
22
26
27#include <stdio.h>
28#include <stdlib.h>
29#include <string.h>
30#include <assert.h>
31#include "misc/vec/vec.h"
32#include "misc/mem/mem.h"
33#include "misc/st/st.h"
34#include "mio.h"
35
37
38
42
43#define MIO_STRING_GATE "GATE"
44#define MIO_STRING_LATCH "LATCH"
45#define MIO_STRING_PIN "PIN"
46#define MIO_STRING_NONINV "NONINV"
47#define MIO_STRING_INV "INV"
48#define MIO_STRING_UNKNOWN "UNKNOWN"
49
50#define MIO_STRING_CONST0 "CONST0"
51#define MIO_STRING_CONST1 "CONST1"
52
53// the bit masks
54#define MIO_MASK(n) ((~((unsigned)0)) >> (32-(n)))
55#define MIO_FULL (~((unsigned)0))
56
60
62{
63 char * pName; // the name of the library
64 char * pFileName; // the original file name
65 int nGates; // the number of the gates
66 Mio_Gate_t ** ppGates0; // the array of gates in the original order
67 Mio_Gate_t ** ppGatesName; // the array of gates sorted by name
68 Mio_Gate_t * pGates; // the linked list of all gates in no particular order
69 Mio_Gate_t * pGate0; // the constant zero gate
70 Mio_Gate_t * pGate1; // the constant one gate
71 Mio_Gate_t * pGateBuf; // the buffer
72 Mio_Gate_t * pGateInv; // the inverter
73 Mio_Gate_t * pGateNand2; // the NAND2 gate
74 Mio_Gate_t * pGateAnd2; // the AND2 gate
75 Mio_Gate_t * pGateNor2; // the NOR2 gate
76 Mio_Gate_t * pGateOr2; // the OR2 gate
77 st__table * tName2Gate; // the mapping of gate names into their pointer
78 Mem_Flex_t * pMmFlex; // the memory manaqer for SOPs
79 Vec_Str_t * vCube; // temporary cube
80 // matching
81 int fPinFilter; // pin filtering
82 int fPinPerm; // pin permutation
83 int fPinQuick; // pin permutation
84 Vec_Mem_t * vTtMem; // truth tables
85 Vec_Wec_t * vTt2Match; // matches for truth tables
86 Mio_Cell2_t * pCells; // library gates
87 int nCells; // library gate count
94};
95
97{
98 // information derived from the genlib file
99 char * pName; // the name of the gate
100 double dArea; // the area of the gate
101 char * pForm; // the formula describing functionality of the gate
102 Mio_Pin_t * pPins; // the linked list of all pins (one pin if info is the same)
103 char * pOutName; // the name of the output pin
104 // the library to which this gate belongs
106 // the next gate in the list
109
110 // the derived information
111 int Cell; // cell id
112 int nInputs; // the number of inputs
113 int Profile; // the number of occurrences
114 int Profile2; // the number of occurrences
115 double dDelayMax; // the maximum delay
116 char * pSop; // sum-of-products
117 Vec_Int_t * vExpr; // boolean expression
118 union { word uTruth; // truth table
119 word * pTruth; }; // pointer to the truth table
120 int Value; // user's information
121};
122
136
137
141
145
149
150/*=== mio.c =============================================================*/
151/*=== mioRead.c =============================================================*/
152/*=== mioUtils.c =============================================================*/
153
154
156
157#endif
158
#define ABC_NAMESPACE_HEADER_END
#define ABC_NAMESPACE_HEADER_START
NAMESPACES ///.
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
Definition bblif.c:37
struct Vec_Str_t_ Vec_Str_t
Definition bblif.c:46
unsigned __int64 word
DECLARATIONS ///.
Definition kitPerm.c:36
Mio_PinPhase_t
INCLUDES ///.
Definition mio.h:40
struct Mio_LibraryStruct_t_ Mio_Library_t
Definition mio.h:42
struct Mio_Cell2_t_ Mio_Cell2_t
Definition mio.h:57
struct Mio_PinStruct_t_ Mio_Pin_t
Definition mio.h:44
struct Mio_GateStruct_t_ Mio_Gate_t
Definition mio.h:43
struct Mem_Flex_t_ Mem_Flex_t
Definition mem.h:34
char * pOutName
Definition mioInt.h:103
Vec_Int_t * vExpr
Definition mioInt.h:117
Mio_Library_t * pLib
Definition mioInt.h:105
Mio_Pin_t * pPins
Definition mioInt.h:102
double dDelayMax
Definition mioInt.h:115
Mio_Gate_t * pTwin
Definition mioInt.h:108
Mio_Gate_t * pNext
Definition mioInt.h:107
STRUCTURE DEFINITIONS ///.
Definition mioInt.h:62
Mio_Gate_t * pGateAnd2
Definition mioInt.h:74
Vec_Mem_t * vTtMem2[3]
Definition mioInt.h:92
Mio_Cell2_t * pCells
Definition mioInt.h:86
Vec_Int_t * vConfigs
Definition mioInt.h:91
Mio_Gate_t * pGateInv
Definition mioInt.h:72
Mio_Gate_t ** ppGates0
Definition mioInt.h:66
Vec_Int_t * vTt2Match4
Definition mioInt.h:90
Mio_Gate_t * pGateNor2
Definition mioInt.h:75
Mio_Gate_t * pGate1
Definition mioInt.h:70
Vec_Mem_t * vTtMem
Definition mioInt.h:84
Mio_Gate_t * pGateOr2
Definition mioInt.h:76
Mio_Gate_t * pGateNand2
Definition mioInt.h:73
Mio_Gate_t * pGate0
Definition mioInt.h:69
Vec_Wrd_t * vTruths
Definition mioInt.h:89
Mio_Gate_t ** ppGatesName
Definition mioInt.h:67
Vec_Int_t * vTt2Match2[3]
Definition mioInt.h:93
Vec_Ptr_t * vNames
Definition mioInt.h:88
Mio_Gate_t * pGates
Definition mioInt.h:68
st__table * tName2Gate
Definition mioInt.h:77
Vec_Wec_t * vTt2Match
Definition mioInt.h:85
Vec_Str_t * vCube
Definition mioInt.h:79
Mio_Gate_t * pGateBuf
Definition mioInt.h:71
Mem_Flex_t * pMmFlex
Definition mioInt.h:78
double dDelayBlockMax
Definition mioInt.h:133
double dDelayBlockFall
Definition mioInt.h:131
Mio_Pin_t * pNext
Definition mioInt.h:134
double dDelayFanoutRise
Definition mioInt.h:130
double dLoadMax
Definition mioInt.h:128
Mio_PinPhase_t Phase
Definition mioInt.h:126
double dDelayBlockRise
Definition mioInt.h:129
double dLoadInput
Definition mioInt.h:127
double dDelayFanoutFall
Definition mioInt.h:132
Definition st.h:52
typedefABC_NAMESPACE_IMPL_START struct Vec_Mem_t_ Vec_Mem_t
DECLARATIONS ///.
Definition utilMem.c:35
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
Definition vecPtr.h:42
typedefABC_NAMESPACE_HEADER_START struct Vec_Wec_t_ Vec_Wec_t
INCLUDES ///.
Definition vecWec.h:42
typedefABC_NAMESPACE_HEADER_START struct Vec_Wrd_t_ Vec_Wrd_t
INCLUDES ///.
Definition vecWrd.h:42