1 /**CFile**************************************************************** 2 3 FileName [mapperInt.h] 4 5 PackageName [MVSIS 2.0: Multi-valued logic synthesis system.] 6 7 Synopsis [Generic technology mapping engine.] 8 9 Author [MVSIS Group] 10 11 Affiliation [UC Berkeley] 12 13 Date [Ver. 2.0. Started - June 1, 2004.] 14 15 Revision [$Id: mapperInt.h,v 1.8 2004/09/30 21:18:10 satrajit Exp $] 16 17 ***********************************************************************/ 18 19 #ifndef ABC__map__mapper__mapperInt_h 20 #define ABC__map__mapper__mapperInt_h 21 22 23 //////////////////////////////////////////////////////////////////////// 24 /// INCLUDES /// 25 //////////////////////////////////////////////////////////////////////// 26 27 #include <stdio.h> 28 #include <stdlib.h> 29 #include <string.h> 30 #include <float.h> 31 #include <math.h> 32 33 #include "base/main/main.h" 34 #include "map/mio/mio.h" 35 #include "mapper.h" 36 37 ABC_NAMESPACE_HEADER_START 38 39 40 //////////////////////////////////////////////////////////////////////// 41 /// PARAMETERS /// 42 //////////////////////////////////////////////////////////////////////// 43 44 // uncomment to have fanouts represented in the mapping graph 45 //#define MAP_ALLOCATE_FANOUT 1 46 47 //////////////////////////////////////////////////////////////////////// 48 /// MACRO DEFINITIONS /// 49 //////////////////////////////////////////////////////////////////////// 50 51 // the bit masks 52 #define MAP_MASK(n) ((~((unsigned)0)) >> (32-(n))) 53 #define MAP_FULL (~((unsigned)0)) 54 #define MAP_NO_VAR (-9999.0) 55 56 // maximum/minimum operators 57 #define MAP_MIN(a,b) (((a) < (b))? (a) : (b)) 58 #define MAP_MAX(a,b) (((a) > (b))? (a) : (b)) 59 60 // the small and large numbers (min/max float are 1.17e-38/3.40e+38) 61 #define MAP_FLOAT_LARGE ((float)(FLT_MAX/10)) 62 #define MAP_FLOAT_SMALL ((float)1.0e-03) 63 64 // generating random unsigned (#define RAND_MAX 0x7fff) 65 #define MAP_RANDOM_UNSIGNED ((((unsigned)rand()) << 24) ^ (((unsigned)rand()) << 12) ^ ((unsigned)rand())) 66 67 // internal macros to work with cuts 68 #define Map_CutIsComplement(p) (((int)((ABC_PTRUINT_T) (p) & 01))) 69 #define Map_CutRegular(p) ((Map_Cut_t *)((ABC_PTRUINT_T)(p) & ~01)) 70 #define Map_CutNot(p) ((Map_Cut_t *)((ABC_PTRUINT_T)(p) ^ 01)) 71 #define Map_CutNotCond(p,c) ((Map_Cut_t *)((ABC_PTRUINT_T)(p) ^ (c))) 72 73 // internal macros for referencing of nodes 74 #define Map_NodeReadRef(p) ((Map_Regular(p))->nRefs) 75 #define Map_NodeRef(p) ((Map_Regular(p))->nRefs++) 76 77 // macros to get hold of the bits in the support info 78 #define Map_InfoSetVar(p,i) (p[(i)>>5] |= (1<<((i) & 31))) 79 #define Map_InfoRemVar(p,i) (p[(i)>>5] &= ~(1<<((i) & 31))) 80 #define Map_InfoFlipVar(p,i) (p[(i)>>5] ^= (1<<((i) & 31))) 81 #define Map_InfoReadVar(p,i) ((p[(i)>>5] & (1<<((i) & 31))) > 0) 82 83 // returns the complemented attribute of the node 84 #define Map_NodeIsSimComplement(p) (Map_IsComplement(p)? !(Map_Regular(p)->fInv) : (p)->fInv) 85 86 //////////////////////////////////////////////////////////////////////// 87 /// STRUCTURE DEFINITIONS /// 88 //////////////////////////////////////////////////////////////////////// 89 90 // the mapping manager 91 struct Map_ManStruct_t_ 92 { 93 // the mapping graph 94 Map_Node_t ** pBins; // the table of nodes hashed by their children 95 int nBins; // the size of the table 96 Map_Node_t ** pInputs; // the array of inputs 97 int nInputs; // the number of inputs 98 Map_Node_t ** pOutputs; // the array of outputs 99 int nOutputs; // the number of outputs 100 int nNodes; // the total number of nodes 101 Map_Node_t * pConst1; // the constant 1 node 102 Map_NodeVec_t * vMapObjs; // the array of all nodes 103 Map_NodeVec_t * vMapBufs; // the array of all nodes 104 float * pNodeDelays; // the array of node delays 105 106 // info about the original circuit 107 char ** ppOutputNames; // the primary output names 108 Map_Time_t * pInputArrivals;// the PI arrival times 109 Map_Time_t * pOutputRequireds;// the PI arrival times 110 111 // mapping parameters 112 int nVarsMax; // the max number of variables 113 int fAreaRecovery; // the flag to enable area recovery 114 int fVerbose; // the verbosiness flag 115 int fMappingMode; // set to 1 when doing area 116 float fRequiredGlo; // the global required times 117 float fEpsilon; // the epsilon used to compare floats 118 float AreaBase; // the area after delay-oriented mapping 119 float AreaFinal; // the area after delay-oriented mapping 120 int nIterations; // How many matching passes to do 121 int fObeyFanoutLimits;// Should mapper try to obey fanout limits or not 122 float DelayTarget; // the required times set by the user 123 int nTravIds; // the traversal counter 124 int fSwitching; // use switching activity 125 int fSkipFanout; // skip large gates when mapping high-fanout nodes 126 int fUseProfile; // use standard-cell profile 127 128 // the supergate library 129 Map_SuperLib_t * pSuperLib; // the current supergate library 130 unsigned uTruths[6][2]; // the elementary truth tables 131 unsigned uTruthsLarge[10][32]; // the elementary truth tables 132 int nCounts[32]; // the counter of minterms 133 int nCountsBest[32];// the counter of minterms 134 Map_NodeVec_t * vVisited; // the visited cuts during cut computation 135 136 // the memory managers 137 Extra_MmFixed_t * mmNodes; // the memory manager for nodes 138 Extra_MmFixed_t * mmCuts; // the memory manager for cuts 139 140 // precomputed N-canonical forms 141 unsigned short * uCanons; // N-canonical forms 142 char ** uPhases; // N-canonical phases 143 char * pCounters; // counters of phases 144 145 // various statistical variables 146 int nChoiceNodes; // the number of choice nodes 147 int nChoices; // the number of all choices 148 int nCanons; // the number of times N-canonical form was computed 149 int nMatches; // the number of times supergate matching was performed 150 int nPhases; // the number of phases considered during matching 151 int nFanoutViolations; // the number of nodes in mapped circuit violating fanout 152 153 // runtime statistics 154 abctime timeToMap; // time to transfer to the mapping structure 155 abctime timeCuts; // time to compute k-feasible cuts 156 abctime timeTruth; // time to compute the truth table for each cut 157 abctime timeMatch; // time to perform matching for each node 158 abctime timeArea; // time to recover area after delay oriented mapping 159 abctime timeSweep; // time to perform technology dependent sweep 160 abctime timeToNet; // time to transfer back to the network 161 abctime timeTotal; // the total mapping time 162 abctime time1; // time to transfer to the mapping structure 163 abctime time2; // time to transfer to the mapping structure 164 abctime time3; // time to transfer to the mapping structure 165 }; 166 167 // the supergate library 168 struct Map_SuperLibStruct_t_ 169 { 170 // general info 171 char * pName; // the name of the supergate library 172 Mio_Library_t * pGenlib; // the generic library 173 174 // other info 175 int nVarsMax; // the max number of variables 176 int nSupersAll; // the total number of supergates 177 int nSupersReal; // the total number of supergates 178 int nLines; // the total number of lines in the supergate file 179 int fVerbose; // the verbosity flag 180 181 // hash tables 182 Map_Super_t ** ppSupers; // the array of supergates 183 Map_HashTable_t * tTableC; // the table mapping N-canonical forms into supergates 184 Map_HashTable_t * tTable; // the table mapping truth tables into supergates 185 186 // data structures for N-canonical form computation 187 unsigned uTruths[6][2]; // the elementary truth tables 188 unsigned uMask[2]; // the mask for the truth table 189 190 // the invertor 191 Mio_Gate_t * pGateInv; // the pointer to the intertor gate 192 Map_Time_t tDelayInv; // the delay of the inverter 193 float AreaInv; // the area of the inverter 194 float AreaBuf; // the area of the buffer 195 Map_Super_t * pSuperInv; // the supergate representing the inverter 196 197 // the memory manager for the internal table 198 Extra_MmFixed_t * mmSupers; // the mamory manager for supergates 199 Extra_MmFixed_t * mmEntries; // the memory manager for the entries 200 Extra_MmFlex_t * mmForms; // the memory manager for formulas 201 }; 202 203 // the mapping node 204 struct Map_NodeStruct_t_ 205 { 206 // general information about the node 207 Map_Man_t * p; // the mapping manager 208 Map_Node_t * pNext; // the next node in the hash table 209 int Num; // the unique number of this node 210 int TravId; // the traversal ID (use to avoid cleaning marks) 211 int nRefs; // the number of references (fanouts) of the given node 212 unsigned fMark0 : 1; // the mark used for traversals 213 unsigned fMark1 : 1; // the mark used for traversals 214 unsigned fUsed : 1; // the mark to mark the node or its fanins 215 unsigned fInv : 1; // the complemented attribute for the equivalent nodes 216 unsigned fInvert: 1; // the flag to denote the use of interter 217 unsigned Level :16; // the level of the given node 218 unsigned NumTemp:10; // the level of the given node 219 int nRefAct[3]; // estimated fanout for current covering phase, neg and pos and sum 220 float nRefEst[3]; // actual fanout for previous covering phase, neg and pos and sum 221 float Switching; // the probability of switching 222 223 // connectivity 224 Map_Node_t * p1; // the first child 225 Map_Node_t * p2; // the second child 226 Map_Node_t * pNextE; // the next functionally equivalent node 227 Map_Node_t * pRepr; // the representative of the functionally equivalent class 228 229 #ifdef MAP_ALLOCATE_FANOUT 230 // representation of node's fanouts 231 Map_Node_t * pFanPivot; // the first fanout of this node 232 Map_Node_t * pFanFanin1; // the next fanout of p1 233 Map_Node_t * pFanFanin2; // the next fanout of p2 234 // Map_NodeVec_t * vFanouts; // the array of fanouts of the gate 235 #endif 236 237 // the delay information 238 Map_Time_t tArrival[2]; // the best arrival time of the neg (0) and pos (1) phases 239 Map_Time_t tRequired[2]; // the required time of the neg (0) and pos (1) phases 240 241 // misc information 242 Map_Cut_t * pCutBest[2]; // the best mapping for neg and pos phase 243 Map_Cut_t * pCuts; // mapping choices for the node (elementary comes first) 244 char * pData0; // temporary storage for the corresponding network node 245 char * pData1; // temporary storage for the corresponding network node 246 }; 247 248 // the match of the cut 249 struct Map_MatchStruct_t_ 250 { 251 // information used for matching 252 Map_Super_t * pSupers; 253 unsigned uPhase; 254 // information about the best selected match 255 unsigned uPhaseBest; // the best phase (the EXOR of match's phase and gate's phase) 256 Map_Super_t * pSuperBest; // the best supergate matched 257 // the parameters of the match 258 Map_Time_t tArrive; // the arrival time of this match 259 float AreaFlow; // the area flow or area of this match 260 }; 261 262 // the cuts used for matching 263 struct Map_CutStruct_t_ 264 { 265 Map_Cut_t * pNext; // the pointer to the next cut in the list 266 Map_Cut_t * pOne; // the father of this cut 267 Map_Cut_t * pTwo; // the mother of this cut 268 Map_Node_t * ppLeaves[6]; // the leaves of this cut 269 unsigned uTruth; // truth table for five-input cuts 270 char nLeaves; // the number of leaves 271 char nVolume; // the volume of this cut 272 char fMark; // the mark to denote visited cut 273 char Phase; // the mark to denote complemented cut 274 Map_Match_t M[2]; // the matches for positive/negative phase 275 }; 276 277 // the supergate internally represented 278 struct Map_SuperStruct_t_ 279 { 280 int Num; // the ID of the supergate 281 unsigned fSuper : 1; // the flag to distinquish a real super from a fake one 282 unsigned fExclude: 1; // the flag if set causes gate to be excluded from being used for mapping 283 unsigned nFanins : 3; // the number of inputs 284 unsigned nGates : 3; // the number of gates inside this supergate 285 unsigned nFanLimit: 4; // the max number of fanout count 286 unsigned nSupers : 16; // the number of supergates in the list 287 unsigned nPhases : 4; // the number of phases for matching with canonical form 288 unsigned char uPhases[4]; // the maximum of 4 phases for matching with canonical form 289 int nUsed; // the number of times the supergate is used 290 Map_Super_t * pFanins[6]; // the fanins of the gate 291 Mio_Gate_t * pRoot; // the root gate 292 unsigned uTruth[2]; // the truth table 293 Map_Time_t tDelaysR[6]; // the pin-to-pin delay constraints for the rise of the output 294 Map_Time_t tDelaysF[6]; // the pin-to-pin delay constraints for the rise of the output 295 Map_Time_t tDelayMax; // the maximum delay 296 float Area; // the area 297 char * pFormula; // the symbolic formula 298 Map_Super_t * pNext; // the pointer to the next super in the list 299 }; 300 301 // the vector of nodes 302 struct Map_NodeVecStruct_t_ 303 { 304 Map_Node_t ** pArray; // the array of nodes 305 int nSize; // the number of entries in the array 306 int nCap; // the number of allocated entries 307 }; 308 309 // the hash table 310 struct Map_HashTableStruct_t_ 311 { 312 Map_HashEntry_t ** pBins; // the table bins 313 int nBins; // the size of the table 314 int nEntries; // the total number of entries in the table 315 Extra_MmFixed_t * mmMan; // the memory manager for entries 316 }; 317 318 // the entry in the hash table 319 struct Map_HashEntryStruct_t_ 320 { 321 unsigned uTruth[2]; // the truth table for 6-var function 322 unsigned uPhase; // the phase to tranform it into the canonical form 323 Map_Super_t * pGates; // the linked list of matching supergates 324 Map_HashEntry_t * pNext; // the next entry in the hash table 325 }; 326 327 // getting hold of the next fanout of the node 328 #define Map_NodeReadNextFanout( pNode, pFanout ) \ 329 ( ( pFanout == NULL )? NULL : \ 330 ((Map_Regular((pFanout)->p1) == (pNode))? \ 331 (pFanout)->pFanFanin1 : (pFanout)->pFanFanin2) ) 332 333 // getting hold of the place where the next fanout will be attached 334 #define Map_NodeReadNextFanoutPlace( pNode, pFanout ) \ 335 ( (Map_Regular((pFanout)->p1) == (pNode))? \ 336 &(pFanout)->pFanFanin1 : &(pFanout)->pFanFanin2 ) 337 338 // iterator through the fanouts of the node 339 #define Map_NodeForEachFanout( pNode, pFanout ) \ 340 for ( pFanout = (pNode)->pFanPivot; pFanout; \ 341 pFanout = Map_NodeReadNextFanout(pNode, pFanout) ) 342 343 // safe iterator through the fanouts of the node 344 #define Map_NodeForEachFanoutSafe( pNode, pFanout, pFanout2 ) \ 345 for ( pFanout = (pNode)->pFanPivot, \ 346 pFanout2 = Map_NodeReadNextFanout(pNode, pFanout); \ 347 pFanout; \ 348 pFanout = pFanout2, \ 349 pFanout2 = Map_NodeReadNextFanout(pNode, pFanout) ) 350 351 //////////////////////////////////////////////////////////////////////// 352 /// GLOBAL VARIABLES /// 353 //////////////////////////////////////////////////////////////////////// 354 355 //////////////////////////////////////////////////////////////////////// 356 /// FUNCTION DEFINITIONS /// 357 //////////////////////////////////////////////////////////////////////// 358 359 /*=== mapperCanon.c =============================================================*/ 360 /*=== mapperCut.c ===============================================================*/ 361 extern void Map_MappingCuts( Map_Man_t * p ); 362 /*=== mapperCutUtils.c ===============================================================*/ 363 extern Map_Cut_t * Map_CutAlloc( Map_Man_t * p ); 364 extern void Map_CutFree( Map_Man_t * p, Map_Cut_t * pCut ); 365 extern void Map_CutPrint( Map_Man_t * p, Map_Node_t * pRoot, Map_Cut_t * pCut, int fPhase ); 366 extern float Map_CutGetRootArea( Map_Cut_t * pCut, int fPhase ); 367 extern int Map_CutGetLeafPhase( Map_Cut_t * pCut, int fPhase, int iLeaf ); 368 extern int Map_NodeGetLeafPhase( Map_Node_t * pNode, int fPhase, int iLeaf ); 369 extern Map_Cut_t * Map_CutListAppend( Map_Cut_t * pSetAll, Map_Cut_t * pSets ); 370 extern void Map_CutListRecycle( Map_Man_t * p, Map_Cut_t * pSetList, Map_Cut_t * pSave ); 371 extern int Map_CutListCount( Map_Cut_t * pSets ); 372 extern void Map_CutRemoveFanouts( Map_Node_t * pNode, Map_Cut_t * pCut, int fPhase ); 373 extern void Map_CutInsertFanouts( Map_Node_t * pNode, Map_Cut_t * pCut, int fPhase ); 374 /*=== mapperFanout.c =============================================================*/ 375 extern void Map_NodeAddFaninFanout( Map_Node_t * pFanin, Map_Node_t * pFanout ); 376 extern void Map_NodeRemoveFaninFanout( Map_Node_t * pFanin, Map_Node_t * pFanoutToRemove ); 377 extern int Map_NodeGetFanoutNum( Map_Node_t * pNode ); 378 /*=== mapperLib.c ============================================================*/ 379 extern Map_SuperLib_t * Map_SuperLibCreate( Mio_Library_t * pGenlib, Vec_Str_t * vStr, char * pFileName, char * pExcludeFile, int fAlgorithm, int fVerbose ); 380 extern void Map_SuperLibFree( Map_SuperLib_t * p ); 381 /*=== mapperMatch.c ===============================================================*/ 382 extern int Map_MappingMatches( Map_Man_t * p ); 383 /*=== mapperRefs.c =============================================================*/ 384 extern void Map_MappingEstimateRefsInit( Map_Man_t * p ); 385 extern void Map_MappingEstimateRefs( Map_Man_t * p ); 386 extern float Map_CutGetAreaFlow( Map_Cut_t * pCut, int fPhase ); 387 extern float Map_CutGetAreaRefed( Map_Cut_t * pCut, int fPhase ); 388 extern float Map_CutGetAreaDerefed( Map_Cut_t * pCut, int fPhase ); 389 extern float Map_CutRef( Map_Cut_t * pCut, int fPhase, int fProfile ); 390 extern float Map_CutDeref( Map_Cut_t * pCut, int fPhase, int fProfile ); 391 extern void Map_MappingSetRefs( Map_Man_t * pMan ); 392 extern float Map_MappingGetArea( Map_Man_t * pMan ); 393 /*=== mapperSwitch.c =============================================================*/ 394 extern float Map_SwitchCutGetDerefed( Map_Node_t * pNode, Map_Cut_t * pCut, int fPhase ); 395 extern float Map_SwitchCutRef( Map_Node_t * pNode, Map_Cut_t * pCut, int fPhase ); 396 extern float Map_SwitchCutDeref( Map_Node_t * pNode, Map_Cut_t * pCut, int fPhase ); 397 extern float Map_MappingGetSwitching( Map_Man_t * pMan ); 398 /*=== mapperTree.c ===============================================================*/ 399 extern int Map_LibraryDeriveGateInfo( Map_SuperLib_t * pLib, st__table * tExcludeGate ); 400 extern int Map_LibraryReadFileTreeStr( Map_SuperLib_t * pLib, Mio_Library_t * pGenlib, Vec_Str_t * vStr, char * pFileName ); 401 extern int Map_LibraryReadTree( Map_SuperLib_t * pLib, Mio_Library_t * pGenlib, char * pFileName, char * pExcludeFile ); 402 extern void Map_LibraryPrintTree( Map_SuperLib_t * pLib ); 403 /*=== mapperSuper.c ===============================================================*/ 404 extern int Map_LibraryRead( Map_SuperLib_t * p, char * pFileName ); 405 extern void Map_LibraryPrintSupergate( Map_Super_t * pGate ); 406 /*=== mapperTable.c ============================================================*/ 407 extern Map_HashTable_t * Map_SuperTableCreate( Map_SuperLib_t * pLib ); 408 extern void Map_SuperTableFree( Map_HashTable_t * p ); 409 extern int Map_SuperTableInsertC( Map_HashTable_t * pLib, unsigned uTruthC[], Map_Super_t * pGate ); 410 extern int Map_SuperTableInsert( Map_HashTable_t * pLib, unsigned uTruth[], Map_Super_t * pGate, unsigned uPhase ); 411 extern Map_Super_t * Map_SuperTableLookup( Map_HashTable_t * p, unsigned uTruth[], unsigned * puPhase ); 412 extern void Map_SuperTableSortSupergates( Map_HashTable_t * p, int nSupersMax ); 413 extern void Map_SuperTableSortSupergatesByDelay( Map_HashTable_t * p, int nSupersMax ); 414 /*=== mapperTime.c =============================================================*/ 415 extern float Map_TimeCutComputeArrival( Map_Node_t * pNode, Map_Cut_t * pCut, int fPhase, float tWorstCaseLimit ); 416 extern float Map_TimeComputeArrivalMax( Map_Man_t * p ); 417 extern void Map_TimeComputeRequiredGlobal( Map_Man_t * p ); 418 /*=== mapperTruth.c ===============================================================*/ 419 extern void Map_MappingTruths( Map_Man_t * pMan ); 420 extern int Map_TruthsCutDontCare( Map_Man_t * pMan, Map_Cut_t * pCut, unsigned * uTruthDc ); 421 extern int Map_TruthCountOnes( unsigned * uTruth, int nLeaves ); 422 extern int Map_TruthDetectTwoFirst( unsigned * uTruth, int nLeaves ); 423 /*=== mapperUtils.c ===============================================================*/ 424 extern Map_NodeVec_t * Map_MappingDfs( Map_Man_t * pMan, int fCollectEquiv ); 425 extern int Map_MappingCountLevels( Map_Man_t * pMan ); 426 extern void Map_MappingUnmark( Map_Man_t * pMan ); 427 extern void Map_MappingMark_rec( Map_Node_t * pNode ); 428 extern void Map_MappingUnmark_rec( Map_Node_t * pNode ); 429 extern void Map_MappingPrintOutputArrivals( Map_Man_t * p ); 430 extern void Map_MappingSetupMask( unsigned uMask[], int nVarsMax ); 431 extern int Map_MappingNodeIsViolator( Map_Node_t * pNode, Map_Cut_t * pCut, int fPosPol ); 432 extern float Map_MappingGetAreaFlow( Map_Man_t * p ); 433 extern void Map_MappingSortByLevel( Map_Man_t * pMan, Map_NodeVec_t * vNodes ); 434 extern int Map_MappingCountDoubles( Map_Man_t * pMan, Map_NodeVec_t * vNodes ); 435 extern void Map_MappingExpandTruth( unsigned uTruth[2], int nVars ); 436 extern float Map_MappingPrintSwitching( Map_Man_t * pMan ); 437 extern void Map_MappingSetPlacementInfo( Map_Man_t * p ); 438 extern float Map_MappingPrintWirelength( Map_Man_t * p ); 439 extern void Map_MappingWireReport( Map_Man_t * p ); 440 extern float Map_MappingComputeDelayWithFanouts( Map_Man_t * p ); 441 extern int Map_MappingGetMaxLevel( Map_Man_t * pMan ); 442 extern void Map_MappingSetChoiceLevels( Map_Man_t * pMan ); 443 extern void Map_MappingReportChoices( Map_Man_t * pMan ); 444 /*=== mapperVec.c =============================================================*/ 445 extern Map_NodeVec_t * Map_NodeVecAlloc( int nCap ); 446 extern void Map_NodeVecFree( Map_NodeVec_t * p ); 447 extern Map_NodeVec_t * Map_NodeVecDup( Map_NodeVec_t * p ); 448 extern Map_Node_t ** Map_NodeVecReadArray( Map_NodeVec_t * p ); 449 extern int Map_NodeVecReadSize( Map_NodeVec_t * p ); 450 extern void Map_NodeVecGrow( Map_NodeVec_t * p, int nCapMin ); 451 extern void Map_NodeVecShrink( Map_NodeVec_t * p, int nSizeNew ); 452 extern void Map_NodeVecClear( Map_NodeVec_t * p ); 453 extern void Map_NodeVecPush( Map_NodeVec_t * p, Map_Node_t * Entry ); 454 extern int Map_NodeVecPushUnique( Map_NodeVec_t * p, Map_Node_t * Entry ); 455 extern Map_Node_t * Map_NodeVecPop( Map_NodeVec_t * p ); 456 extern void Map_NodeVecRemove( Map_NodeVec_t * p, Map_Node_t * Entry ); 457 extern void Map_NodeVecWriteEntry( Map_NodeVec_t * p, int i, Map_Node_t * Entry ); 458 extern Map_Node_t * Map_NodeVecReadEntry( Map_NodeVec_t * p, int i ); 459 extern void Map_NodeVecSortByLevel( Map_NodeVec_t * p ); 460 461 462 463 ABC_NAMESPACE_HEADER_END 464 465 #endif 466 467 //////////////////////////////////////////////////////////////////////// 468 /// END OF FILE /// 469 //////////////////////////////////////////////////////////////////////// 470