diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2010-11-01 01:35:04 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2010-11-01 01:35:04 -0700 |
commit | 6130e39b18b5f53902e4eab14f6d5cdde5219563 (patch) | |
tree | 0db0628479a1b750e9af1f66cb8379ebd0913d31 /src/bdd/cudd/cuddLevelQ.c | |
parent | f0e77f6797c0504b0da25a56152b707d3357f386 (diff) | |
download | abc-6130e39b18b5f53902e4eab14f6d5cdde5219563.tar.gz abc-6130e39b18b5f53902e4eab14f6d5cdde5219563.tar.bz2 abc-6130e39b18b5f53902e4eab14f6d5cdde5219563.zip |
initial commit of public abc
Diffstat (limited to 'src/bdd/cudd/cuddLevelQ.c')
-rw-r--r-- | src/bdd/cudd/cuddLevelQ.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/src/bdd/cudd/cuddLevelQ.c b/src/bdd/cudd/cuddLevelQ.c index 28823a83..1a09820a 100644 --- a/src/bdd/cudd/cuddLevelQ.c +++ b/src/bdd/cudd/cuddLevelQ.c @@ -21,7 +21,7 @@ pointers. The level queue functions make sure that each node appears at most once in the queue. They do so by keeping a hash table where the node is used as key. Queue items are recycled via a - ABC_FREE list for efficiency. + free list for efficiency. Internal procedures provided by this module: <ul> @@ -53,6 +53,9 @@ #include "util_hack.h" #include "cuddInt.h" +ABC_NAMESPACE_IMPL_START + + /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ @@ -125,7 +128,7 @@ static int hashResize ARGS((DdLevelQueue *queue)); Description [Initializes a level queue. A level queue is a queue where inserts are based on the levels of the nodes. Within each level the policy is FIFO. Level queues are useful in traversing a - BDD top-down. Queue items are kept in a ABC_FREE list when dequeued for + BDD top-down. Queue items are kept in a free list when dequeued for efficiency. Returns a pointer to the new queue if successful; NULL otherwise.] @@ -263,7 +266,7 @@ cuddLevelQueueEnqueue( item = hashLookup(queue,key); if (item != NULL) return(item); - /* Get a ABC_FREE item from either the ABC_FREE list or the memory manager. */ + /* Get a free item from either the free list or the memory manager. */ if (queue->freelist == NULL) { item = (DdQueueItem *) ABC_ALLOC(char, queue->itemsize); if (item == NULL) @@ -335,7 +338,7 @@ cuddLevelQueueDequeue( queue->last[level] = NULL; queue->first = item->next; - /* Put item on the ABC_FREE list. */ + /* Put item on the free list. */ item->next = queue->freelist; queue->freelist = item; /* Update stats. */ @@ -493,7 +496,7 @@ hashResize( #endif int shift; int oldNumBuckets = queue->numBuckets; - extern void (*MMoutOfMemory)(long); +// extern void (*MMoutOfMemory)(long); void (*saveHandler)(long); /* Compute the new size of the subtable. */ @@ -531,3 +534,5 @@ hashResize( return(1); } /* end of hashResize */ +ABC_NAMESPACE_IMPL_END + |