Geogram  Version 1.9.1-rc
A programming library of geometric algorithms
GEO::PCK::PredicateStats Class Reference

Logs statistics for predicates. The statistics are displayed on exit if the command line flag "sys:statistics" is set. It is used as follows in a predicate: More...

#include <geogram/numerics/PCK.h>

Public Member Functions

 PredicateStats (const char *name)
 
void log_invoke ()
 
void log_exact ()
 
void log_SOS ()
 

Static Public Member Functions

static void show_all_stats ()
 

Detailed Description

Logs statistics for predicates. The statistics are displayed on exit if the command line flag "sys:statistics" is set. It is used as follows in a predicate:

void my_predicate(...) {
static PCK::PredicateStats stats("my_predicate");
my_predicate.log_invoke();
// Filter
{
Sign s = ...;
if(s != ZERO) {
return s;
}
}
// Exact
{
stats.log_exact();
Sign s = ...;
if(s != ZERO) {
return s;
}
}
// SOS
{
stats.log_SOS();
...
}
}
Sign
Integer constants that represent the sign of a value.
Definition: numeric.h:68
@ ZERO
Definition: numeric.h:72

Definition at line 122 of file PCK.h.


The documentation for this class was generated from the following file: