|
abc-master
|
#include <stdio.h>#include <string.h>#include <stdlib.h>#include <assert.h>#include "abc_global.h"Go to the source code of this file.
Data Structures | |
| struct | Vec_Mem_t_ |
Macros | |
| #define | ABC_MEM_ALLOC(type, num) ((type *) malloc(sizeof(type) * (num))) |
| #define | ABC_MEM_CALLOC(type, num) ((type *) calloc((num), sizeof(type))) |
| #define | ABC_MEM_FALLOC(type, num) ((type *) memset(malloc(sizeof(type) * (num)), 0xff, sizeof(type) * (num))) |
| #define | ABC_MEM_FREE(obj) ((obj) ? (free((char *) (obj)), (obj) = 0) : 0) |
| #define | ABC_MEM_REALLOC(type, obj, num) |
Typedefs | |
| typedef typedefABC_NAMESPACE_IMPL_START struct Vec_Mem_t_ | Vec_Mem_t |
| DECLARATIONS ///. More... | |
Functions | |
| static Vec_Mem_t * | Vec_MemAlloc (int nCap) |
| FUNCTION DEFINITIONS ///. More... | |
| static void | Vec_MemFree (Vec_Mem_t *p) |
| static void | Vec_MemGrow (Vec_Mem_t *p, int nCapMin) |
| static void | Vec_MemPush (Vec_Mem_t *p, void *Entry) |
| static void | Vec_MemSort (Vec_Mem_t *p, int(*Vec_MemSortCompare)()) |
| void * | Util_MemRecAlloc (void *pMem) |
| BASIC TYPES ///. More... | |
| void * | Util_MemRecFree (void *pMem) |
| int | Util_ComparePointers (void **pp1, void **pp2) |
| static Vec_Mem_t * | Vec_MemTwoMerge (Vec_Mem_t *vArr1, Vec_Mem_t *vArr2) |
| void | Util_MemRecRecycle () |
| void | Util_MemRecStart () |
| void | Util_MemRecQuit () |
| int | Util_MemRecIsSet () |
Variables | |
| void * | s_vAllocs = NULL |
| INCLUDES ///. More... | |
| void * | s_vFrees = NULL |
| int | s_fInterrupt = 0 |
| #define ABC_MEM_ALLOC | ( | type, | |
| num | |||
| ) | ((type *) malloc(sizeof(type) * (num))) |
| #define ABC_MEM_CALLOC | ( | type, | |
| num | |||
| ) | ((type *) calloc((num), sizeof(type))) |
| #define ABC_MEM_FREE | ( | obj | ) | ((obj) ? (free((char *) (obj)), (obj) = 0) : 0) |
| #define ABC_MEM_REALLOC | ( | type, | |
| obj, | |||
| num | |||
| ) |
| typedef typedefABC_NAMESPACE_IMPL_START struct Vec_Mem_t_ Vec_Mem_t |
DECLARATIONS ///.
CFile****************************************************************
FileName [utilMem.c]
SystemName [ABC: Logic synthesis and verification system.]
PackageName [Memory recycling utilities.]
Synopsis [Memory recycling utilities.]
Author [Alan Mishchenko]
Affiliation [UC Berkeley]
Date [Ver. 1.0. Started - June 20, 2005.]
Revision [
]
| int Util_ComparePointers | ( | void ** | pp1, |
| void ** | pp2 | ||
| ) |
Function*************************************************************
Synopsis [Procedure used for sorting the nodes in decreasing order of levels.]
Description []
SideEffects []
SeeAlso []
| void* Util_MemRecAlloc | ( | void * | pMem | ) |
BASIC TYPES ///.
Function*************************************************************
Synopsis [Remembers an allocated pointer.]
Description []
SideEffects []
SeeAlso []
Definition at line 172 of file utilMem.c.
| void* Util_MemRecFree | ( | void * | pMem | ) |
Function*************************************************************
Synopsis [Remembers a deallocated pointer.]
Description []
SideEffects []
SeeAlso []
Definition at line 190 of file utilMem.c.
| int Util_MemRecIsSet | ( | ) |
| void Util_MemRecQuit | ( | ) |
Function*************************************************************
Synopsis [Quits memory structures.]
Description []
SideEffects []
SeeAlso []
Definition at line 312 of file utilMem.c.
| void Util_MemRecRecycle | ( | ) |
Function*************************************************************
Synopsis [Recycles the accumulated memory.]
Description []
SideEffects []
SeeAlso []
Definition at line 272 of file utilMem.c.
| void Util_MemRecStart | ( | ) |
Function*************************************************************
Synopsis [Starts memory structures.]
Description []
SideEffects []
SeeAlso []
Definition at line 294 of file utilMem.c.
|
inlinestatic |
FUNCTION DEFINITIONS ///.
Function*************************************************************
Synopsis [Allocates a vector with the given capacity.]
Description []
SideEffects []
SeeAlso []
Definition at line 70 of file utilMem.c.
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
static |
Function*************************************************************
Synopsis [Finds entries that do not appear in both lists.]
Description [Assumes that the vectors are sorted in the increasing order.]
SideEffects []
SeeAlso []
Definition at line 228 of file utilMem.c.
| void* s_vAllocs = NULL |
INCLUDES ///.
CFile****************************************************************
FileName [utilInt.h]
SystemName [ABC: Logic synthesis and verification system.]
PackageName [Memory recycling utilities.]
Synopsis [Internal declarations.]
Author [Alan Mishchenko]
Affiliation [UC Berkeley]
Date [Ver. 1.0. Started - June 20, 2005.]
Revision [
]PARAMETERS ///