scip_mem.h
Go to the documentation of this file.
29 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
74 #define SCIPallocClearMemoryArray(scip,ptr,num) ( (BMSallocClearMemoryArray((ptr), (num)) == NULL) \
78 #define SCIPreallocMemoryArray(scip,ptr,newnum) ( (BMSreallocMemoryArray((ptr), (newnum)) == NULL) \
80 #define SCIPreallocMemorySize(scip,ptr,newsize) ( (BMSreallocMemorySize((ptr), (newsize)) == NULL) \
84 #define SCIPduplicateMemoryArray(scip, ptr, source, num) ( (BMSduplicateMemoryArray((ptr), (source), (num)) == NULL) \
97 #define SCIPallocBlockMemory(scip,ptr) ( (BMSallocBlockMemory(SCIPblkmem(scip), (ptr)) == NULL) \
99 #define SCIPallocBlockMemoryArray(scip,ptr,num) ( (BMSallocBlockMemoryArray(SCIPblkmem(scip), (ptr), (num)) == NULL) \
101 #define SCIPallocBlockMemorySize(scip,ptr,size) ( (BMSallocBlockMemorySize(SCIPblkmem(scip), (ptr), (size)) == NULL) \
103 #define SCIPallocClearBlockMemoryArray(scip,ptr,num) ( (BMSallocClearBlockMemoryArray(SCIPblkmem(scip), (ptr), (num)) == NULL) \
105 #define SCIPreallocBlockMemoryArray(scip,ptr,oldnum,newnum) ( (BMSreallocBlockMemoryArray(SCIPblkmem(scip), (ptr), (oldnum), (newnum)) == NULL) \
107 #define SCIPreallocBlockMemorySize(scip,ptr,oldsize,newsize) ( (BMSreallocBlockMemorySize(SCIPblkmem(scip), (ptr), (oldsize), (newsize)) == NULL) \
109 #define SCIPduplicateBlockMemory(scip, ptr, source) ( (BMSduplicateBlockMemory(SCIPblkmem(scip), (ptr), (source)) == NULL) \
111 #define SCIPduplicateBlockMemoryArray(scip, ptr, source, num) ( (BMSduplicateBlockMemoryArray(SCIPblkmem(scip), (ptr), (source), (num)) == NULL) \
113 #define SCIPensureBlockMemoryArray(scip,ptr,arraysizeptr,minsize) ( (SCIPensureBlockMemoryArray_call((scip), (void**)(ptr), sizeof(**(ptr)), (arraysizeptr), (minsize))) )
116 #define SCIPfreeBlockMemoryArray(scip,ptr,num) BMSfreeBlockMemoryArray(SCIPblkmem(scip), (ptr), (num))
117 #define SCIPfreeBlockMemoryArrayNull(scip,ptr,num) BMSfreeBlockMemoryArrayNull(SCIPblkmem(scip), (ptr), (num))
118 #define SCIPfreeBlockMemorySize(scip,ptr,size) BMSfreeBlockMemorySize(SCIPblkmem(scip), (ptr), (size))
119 #define SCIPfreeBlockMemorySizeNull(scip,ptr,size) BMSfreeBlockMemorySizeNull(SCIPblkmem(scip), (ptr), (size))
130 #define SCIPallocBufferArray(scip,ptr,num) ( (BMSallocBufferMemoryArray(SCIPbuffer(scip), (ptr), (num)) == NULL) \
132 #define SCIPallocClearBufferArray(scip,ptr,num) ( (BMSallocClearBufferMemoryArray(SCIPbuffer(scip), (ptr), (num)) == NULL) \
134 #define SCIPreallocBufferArray(scip,ptr,num) ( (BMSreallocBufferMemoryArray(SCIPbuffer(scip), (ptr), (num)) == NULL) \
136 #define SCIPduplicateBuffer(scip,ptr,source) ( (BMSduplicateBufferMemory(SCIPbuffer(scip), (ptr), (source), (size_t)sizeof(**(ptr))) \
138 #define SCIPduplicateBufferArray(scip,ptr,source,num) ( (BMSduplicateBufferMemoryArray(SCIPbuffer(scip), (ptr), (source), (num)) == NULL) \
146 #define SCIPallocCleanBuffer(scip,ptr) ( (BMSallocBufferMemory(SCIPcleanbuffer(scip), (ptr)) == NULL) \
148 #define SCIPallocCleanBufferArray(scip,ptr,num) ( (BMSallocBufferMemoryArray(SCIPcleanbuffer(scip), (ptr), (num)) == NULL) \
152 #define SCIPfreeCleanBufferArray(scip,ptr) BMSfreeBufferMemoryArray(SCIPcleanbuffer(scip), (ptr))
153 #define SCIPfreeCleanBufferArrayNull(scip,ptr) BMSfreeBufferMemoryArrayNull(SCIPcleanbuffer(scip), (ptr))
225 /** extends a dynamically allocated block memory array to be able to store at least the given number of elements;
228 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
Definition: memory.c:2461
internal methods for branch and bound tree
Definition: struct_scip.h:58
type definitions for return codes for SCIP methods
SCIP_RETCODE SCIPensureBlockMemoryArray_call(SCIP *scip, void **arrayptr, size_t elemsize, int *arraysize, int minsize)
Definition: scip_mem.c:226
type definitions for SCIP's main datastructure
internal miscellaneous methods
internal methods for global SCIP settings
SCIP main data structure.
internal methods for problem variables
methods for debugging
datastructures for problem statistics
internal methods for main solving loop and node processing
internal methods for constraints and constraint handlers
common defines and data types used in all packages of SCIP
Definition: objbenders.h:33
memory allocation routines