model: make comment more accurate
[c11tester.git] / clockvector.h
1 /** @file clockvector.h
2  *  @brief Implements a clock vector.
3  */
4
5 #ifndef __CLOCKVECTOR_H__
6 #define __CLOCKVECTOR_H__
7
8 #include "threads.h"
9 #include "mymemory.h"
10
11 /* Forward declaration */
12 class ModelAction;
13
14 class ClockVector {
15 public:
16         ClockVector(ClockVector *parent = NULL, ModelAction *act = NULL);
17         ~ClockVector();
18         void merge(ClockVector *cv);
19         bool synchronized_since(ModelAction *act) const;
20
21         void print() const;
22
23         MEMALLOC
24 private:
25         /** @brief Holds the actual clock data, as an array. */
26         int *clock;
27
28         /** @brief The number of threads recorded in clock (i.e., its length).  */
29         int num_threads;
30 };
31
32 #endif /* __CLOCKVECTOR_H__ */