forked from cvc5/ethos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstats.h
56 lines (47 loc) · 1.25 KB
/
stats.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/******************************************************************************
* This file is part of the ethos project.
*
* Copyright (c) 2023-2024 by the authors listed in the file AUTHORS
* in the top-level source directory and their institutional affiliations.
* All rights reserved. See the file COPYING in the top-level source
* directory for licensing information.
******************************************************************************/
#ifndef STATS_H
#define STATS_H
#include <string>
#include <map>
#include <ctime>
namespace ethos {
class ExprValue;
class Stats;
class State;
class RuleStat
{
public:
RuleStat();
size_t d_count;
size_t d_mkExprCount;
std::time_t d_time;
void increment(Stats& s);
// frame
static std::time_t d_startTime;
static size_t d_startMkExprCount;
static void start(Stats& s);
std::string toString(std::time_t totalTime) const;
};
class Stats
{
public:
Stats();
size_t d_mkExprCount;
size_t d_exprCount;
size_t d_deleteExprCount;
size_t d_symCount;
size_t d_litCount;
std::time_t d_startTime;
std::map<const ExprValue*, RuleStat> d_rstats;
std::string toString(State& s, bool compact) const;
static std::time_t getCurrentTime();
};
} // namespace ethos
#endif /* STATS_H */