24 #ifndef __SCIP_STAT_H__ 25 #define __SCIP_STAT_H__ 207 #define SCIPstatUpdate(stat, set, field, val) do { \ 208 (stat)->field = (val); \ 211 #define SCIPstatIncrement(stat, set, field) do { \ 215 #define SCIPstatAdd(stat, set, field, val) do { \ 216 (stat)->field += (val); \ 222 #define SCIPupdateDeterministicTimeCount(stat, set, val) do { \ 223 (stat)->detertimecnt += (val); \ 224 if( (stat)->detertimecnt > 10000.0 ) { \ 225 SCIP_CALL_ABORT( SCIPincrementConcurrentTime( (set)->scip, (stat)->detertimecnt ) ); \ 226 (stat)->detertimecnt = 0.0; \ 230 #define SCIPstatUpdate(stat, set, field, val) do { \ 231 switch( offsetof(SCIP_STAT, field) ) \ 235 case offsetof(SCIP_STAT, nprimalresolvelpiterations): \ 236 SCIPupdateDeterministicTimeCount(stat, set, 0.00328285264101 * ((val) - (stat)->field) * (stat)->nnz ); \ 238 case offsetof(SCIP_STAT, ndualresolvelpiterations): \ 239 SCIPupdateDeterministicTimeCount(stat, set, 0.00531625104146 * ((val) - (stat)->field) * (stat)->nnz ); \ 241 case offsetof(SCIP_STAT, nprobboundchgs): \ 242 SCIPupdateDeterministicTimeCount(stat, set, 0.000738719124051 * ((val) - (stat)->field) * (stat)->nnz ); \ 244 case offsetof(SCIP_STAT, nisstoppedcalls): \ 245 SCIPupdateDeterministicTimeCount(stat, set, 0.0011123144764 * ((val) - (stat)->field) * (stat)->nnz ); \ 247 (stat)->field = (val); \ 251 #define SCIPstatIncrement(stat, set, field) do { \ 252 switch( offsetof(SCIP_STAT, field) ) \ 256 case offsetof(SCIP_STAT, nprimalresolvelpiterations): \ 257 SCIPupdateDeterministicTimeCount(stat, set, 0.00328285264101 * (stat)->nnz ); \ 259 case offsetof(SCIP_STAT, ndualresolvelpiterations): \ 260 SCIPupdateDeterministicTimeCount(stat, set, 0.00531625104146 * (stat)->nnz ); \ 262 case offsetof(SCIP_STAT, nprobboundchgs): \ 263 SCIPupdateDeterministicTimeCount(stat, set, 0.000738719124051 * (stat)->nnz ); \ 265 case offsetof(SCIP_STAT, nisstoppedcalls): \ 266 SCIPupdateDeterministicTimeCount(stat, set, 0.0011123144764 * (stat)->nnz ); \ 271 #define SCIPstatAdd(stat, set, field, val) do { \ 272 switch( offsetof(SCIP_STAT, field) ) \ 276 case offsetof(SCIP_STAT, nprimalresolvelpiterations): \ 277 SCIPupdateDeterministicTimeCount(stat, set, 0.00328285264101 * (val) * (stat)->nnz); \ 279 case offsetof(SCIP_STAT, ndualresolvelpiterations): \ 280 SCIPupdateDeterministicTimeCount(stat, set, 0.00531625104146 * (val) * (stat)->nnz); \ 282 case offsetof(SCIP_STAT, nprobboundchgs): \ 283 SCIPupdateDeterministicTimeCount(stat, set, 0.000738719124051 * (val) * (stat)->nnz ); \ 285 case offsetof(SCIP_STAT, nisstoppedcalls): \ 286 SCIPupdateDeterministicTimeCount(stat, set, 0.0011123144764 * (val) * (stat)->nnz ); \ 288 (stat)->field += (val); \ 294 #ifdef SCIP_HAVE_VARIADIC_MACROS 298 #define SCIPstatDebugMsg(set, ...) SCIPstatPrintDebugMessage(stat, __FILE__, __LINE__, __VA_ARGS__) 299 #define SCIPstatDebugMsgPrint(set, ...) SCIPstatPrintDebugMessagePrint(stat, __VA_ARGS__) 301 #define SCIPstatDebugMsg(set, ...) while ( FALSE ) SCIPstatPrintDebugMessage(stat, __FILE__, __LINE__, __VA_ARGS__) 302 #define SCIPstatDebugMsgPrint(set, ...) while ( FALSE ) SCIPstatPrintDebugMessagePrint(stat, __VA_ARGS__) 310 #define SCIPstatDebugMsg printf("debug: "), SCIPstatDebugMessagePrint 311 #define SCIPstatDebugMsgPrint SCIPstatDebugMessagePrint 313 #define SCIPstatDebugMsg while ( FALSE ) SCIPstatDebugMessagePrint 314 #define SCIPstatDebugMsgPrint while ( FALSE ) SCIPstatDebugMessagePrint 324 const char* sourcefile,
326 const char* formatstr,
334 const char* formatstr,
SCIP_Longint SCIPstatGetMemExternEstim(SCIP_STAT *stat)
void SCIPstatEnableOrDisableStatClocks(SCIP_STAT *stat, SCIP_Bool enable)
void SCIPstatResetImplications(SCIP_STAT *stat)
void SCIPstatResetCurrentRun(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_Bool solved)
void SCIPstatDebugMessagePrint(SCIP_STAT *stat, const char *formatstr,...)
enum SCIP_Retcode SCIP_RETCODE
type definitions for global SCIP settings
void SCIPstatMark(SCIP_STAT *stat)
type definitions for return codes for SCIP methods
type definitions for problem statistics
void SCIPstatEnforceLPUpdates(SCIP_STAT *stat)
void SCIPstatReset(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
void SCIPstatResetPresolving(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
SCIP_RETCODE SCIPstatUpdateVarRootLPBestEstimate(SCIP_STAT *stat, SCIP_SET *set, SCIP_VAR *var, SCIP_Real oldrootpscostscore)
void SCIPstatResetPrimalDualIntegral(SCIP_STAT *stat, SCIP_SET *set, SCIP_Bool partialreset)
datastructures for problem statistics
helper functions for concurrent scip solvers
type definitions for storing and manipulating the main problem
SCIP_RETCODE SCIPstatFree(SCIP_STAT **stat, BMS_BLKMEM *blkmem)
void SCIPstatResetDisplay(SCIP_STAT *stat)
type definitions for block memory pools and memory buffers
void SCIPstatEnableVarHistory(SCIP_STAT *stat)
public methods for message output
void SCIPstatComputeRootLPBestEstimate(SCIP_STAT *stat, SCIP_SET *set, SCIP_Real rootlpobjval, SCIP_VAR **vars, int nvars)
void SCIPstatPrintDebugMessage(SCIP_STAT *stat, const char *sourcefile, int sourceline, const char *formatstr,...)
void SCIPstatUpdatePrimalDualIntegral(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_Real primalbound, SCIP_Real dualbound)
SCIP_RETCODE SCIPstatCreate(SCIP_STAT **stat, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_MESSAGEHDLR *messagehdlr)
common defines and data types used in all packages of SCIP
struct BMS_BlkMem BMS_BLKMEM
void SCIPstatDisableVarHistory(SCIP_STAT *stat)
void SCIPstatUpdateMemsaveMode(SCIP_STAT *stat, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, SCIP_MEM *mem)
SCIP_Real SCIPstatGetPrimalDualIntegral(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
memory allocation routines