#include "msatInt.h"
Go to the source code of this file.
Functions | |
Msat_ClauseVec_t * | Msat_ClauseVecAlloc (int nCap) |
void | Msat_ClauseVecFree (Msat_ClauseVec_t *p) |
Msat_Clause_t ** | Msat_ClauseVecReadArray (Msat_ClauseVec_t *p) |
int | Msat_ClauseVecReadSize (Msat_ClauseVec_t *p) |
void | Msat_ClauseVecGrow (Msat_ClauseVec_t *p, int nCapMin) |
void | Msat_ClauseVecShrink (Msat_ClauseVec_t *p, int nSizeNew) |
void | Msat_ClauseVecClear (Msat_ClauseVec_t *p) |
void | Msat_ClauseVecPush (Msat_ClauseVec_t *p, Msat_Clause_t *Entry) |
Msat_Clause_t * | Msat_ClauseVecPop (Msat_ClauseVec_t *p) |
void | Msat_ClauseVecWriteEntry (Msat_ClauseVec_t *p, int i, Msat_Clause_t *Entry) |
Msat_Clause_t * | Msat_ClauseVecReadEntry (Msat_ClauseVec_t *p, int i) |
Msat_ClauseVec_t* Msat_ClauseVecAlloc | ( | int | nCap | ) |
CFile****************************************************************
FileName [msatClauseVec.c]
PackageName [A C version of SAT solver MINISAT, originally developed in C++ by Niklas Een and Niklas Sorensson, Chalmers University of Technology, Sweden: http://www.cs.chalmers.se/~een/Satzoo.]
Synopsis [Procedures working with arrays of SAT clauses.]
Author [Alan Mishchenko <alanmi@eecs.berkeley.edu>]
Affiliation [UC Berkeley]
Date [Ver. 1.0. Started - January 1, 2004.]
Revision [
] DECLARATIONS /// FUNCTION DEFINITIONS ///Function*************************************************************
Synopsis [Allocates a vector with the given capacity.]
Description []
SideEffects []
SeeAlso []
Definition at line 42 of file msatClauseVec.c.
00043 { 00044 Msat_ClauseVec_t * p; 00045 p = ALLOC( Msat_ClauseVec_t, 1 ); 00046 if ( nCap > 0 && nCap < 16 ) 00047 nCap = 16; 00048 p->nSize = 0; 00049 p->nCap = nCap; 00050 p->pArray = p->nCap? ALLOC( Msat_Clause_t *, p->nCap ) : NULL; 00051 return p; 00052 }
void Msat_ClauseVecClear | ( | Msat_ClauseVec_t * | p | ) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 150 of file msatClauseVec.c.
00151 { 00152 p->nSize = 0; 00153 }
void Msat_ClauseVecFree | ( | Msat_ClauseVec_t * | p | ) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 65 of file msatClauseVec.c.
void Msat_ClauseVecGrow | ( | Msat_ClauseVec_t * | p, | |
int | nCapMin | |||
) |
Function*************************************************************
Synopsis [Resizes the vector to the given capacity.]
Description []
SideEffects []
SeeAlso []
Definition at line 114 of file msatClauseVec.c.
Msat_Clause_t* Msat_ClauseVecPop | ( | Msat_ClauseVec_t * | p | ) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 189 of file msatClauseVec.c.
void Msat_ClauseVecPush | ( | Msat_ClauseVec_t * | p, | |
Msat_Clause_t * | Entry | |||
) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 166 of file msatClauseVec.c.
00167 { 00168 if ( p->nSize == p->nCap ) 00169 { 00170 if ( p->nCap < 16 ) 00171 Msat_ClauseVecGrow( p, 16 ); 00172 else 00173 Msat_ClauseVecGrow( p, 2 * p->nCap ); 00174 } 00175 p->pArray[p->nSize++] = Entry; 00176 }
Msat_Clause_t** Msat_ClauseVecReadArray | ( | Msat_ClauseVec_t * | p | ) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 82 of file msatClauseVec.c.
00083 { 00084 return p->pArray; 00085 }
Msat_Clause_t* Msat_ClauseVecReadEntry | ( | Msat_ClauseVec_t * | p, | |
int | i | |||
) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 222 of file msatClauseVec.c.
int Msat_ClauseVecReadSize | ( | Msat_ClauseVec_t * | p | ) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 98 of file msatClauseVec.c.
00099 { 00100 return p->nSize; 00101 }
void Msat_ClauseVecShrink | ( | Msat_ClauseVec_t * | p, | |
int | nSizeNew | |||
) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 133 of file msatClauseVec.c.
void Msat_ClauseVecWriteEntry | ( | Msat_ClauseVec_t * | p, | |
int | i, | |||
Msat_Clause_t * | Entry | |||
) |
Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
Definition at line 205 of file msatClauseVec.c.