MPSolve 3.2.1
Loading...
Searching...
No Matches
debug.h File Reference

Debugging functions, that honor the status os s->DOLOG and autodetect if the output stream is or not a tty to select the best output method. More...

#include <unistd.h>
#include <mps/gmptools.h>
#include <gmp.h>
#include <time.h>
#include <mps/mps.h>

Go to the source code of this file.

Macros

#define MPS_DEBUG(args ...)
 
#define MPS_DEBUG_MPC(args ...)
 
#define MPS_DEBUG_CPLX(args ...)
 
#define MPS_DEBUG_RDPE(args ...)
 
#define MPS_DEBUG_CDPE(args ...)
 
#define MPS_DEBUG_CALL(args ...)
 
#define MPS_DEBUG_MCLUSTER_ROOTS(args ...)
 
#define MPS_DEBUG_THIS_CALL(ctx)
 
#define MPS_DEBUG_WITH_INFO(args ...)
 
#define MPS_DEBUG_WITH_IO(args ...)
 
#define __MPS_DEBUG(args ...)
 
#define MPS_DEBUG   __c_impl__MPS_DEBUG
 
#define __MPS_DEBUG   __c_impl____MPS_DEBUG
 
#define MPS_DEBUG_INFO   (0x0001 << 0)
 This is the flag that enables debugging of general information about the flow of the program.
 
#define MPS_DEBUG_CLUSTER   (0x0001 << 1)
 This is the flag used to debug cluster-related informations.
 
#define MPS_DEBUG_APPROXIMATIONS   (0x0001 << 2)
 This is the flag used to debug informations on approximations during the execution of MPSolve.
 
#define MPS_DEBUG_IMPROVEMENT   (0x0001 << 3)
 Flag used to show debug about final approximation of the roots using newton iterations.
 
#define MPS_DEBUG_TIMINGS   (0x0001 << 4)
 Flag used to obtain information about timings in the algorithm.
 
#define MPS_DEBUG_FUNCTION_CALLS   (0x0001 << 5)
 Debug function calls.
 
#define MPS_DEBUG_IO   (0x0001 << 6)
 Debug I/O informations.
 
#define MPS_DEBUG_MEMORY   (0x0001 << 7)
 Debug memory management.
 
#define MPS_DEBUG_PACKETS   (0x0001 << 8)
 Debug checks for the convergence of the various iterations packets.
 
#define MPS_DEBUG_REGENERATION   (0x0001 << 9)
 Debug the regenration of the coefficients-.
 
#define MPS_DEBUG_TRACE   (0xFFFF)
 This is the flag used to debug informations about virtually every step in the program, it enables every debug level.
 
#define MPS_DEBUG_IF(s, debug_level, debug_instruction)
 

Functions

MPS_BEGIN_DECLS clock_t * mps_start_timer (void)
 
unsigned long int mps_stop_timer (clock_t *my_timer)
 
void __c_impl__MPS_DEBUG (mps_context *s, const char *templ,...)
 
void __c_impl____MPS_DEBUG (mps_context *s, const char *templ,...)
 

Detailed Description

Debugging functions, that honor the status os s->DOLOG and autodetect if the output stream is or not a tty to select the best output method.

Macro Definition Documentation

◆ MPS_DEBUG_IF

#define MPS_DEBUG_IF (   s,
  debug_level,
  debug_instruction 
)
Value:
if (debug_level & s->debug_level) { \
debug_instruction; \
}
mps_debug_level debug_level
Bytes containing the flags of debug enabled.
Definition: context.h:117