ovni/src/emu/emu_stat.h

26 lines
609 B
C
Raw Normal View History

2023-02-16 15:54:25 +01:00
/* Copyright (c) 2021-2023 Barcelona Supercomputing Center (BSC)
* SPDX-License-Identifier: GPL-3.0-or-later */
#ifndef EMU_STAT_H
#define EMU_STAT_H
#include "player.h"
/* Easier to parse emulation event */
struct emu_stat {
double in_progress;
double period;
double last_time;
2023-02-17 17:36:01 +01:00
double reported_time;
2023-02-16 17:03:41 +01:00
double first_time;
2023-02-17 17:36:01 +01:00
int64_t last_nprocessed;
int64_t ncalls;
int64_t maxcalls;
2023-02-16 15:54:25 +01:00
};
2023-02-17 17:36:01 +01:00
void emu_stat_init(struct emu_stat *stat);
2023-02-16 15:54:25 +01:00
void emu_stat_update(struct emu_stat *stat, struct player *player);
2023-02-17 17:36:01 +01:00
void emu_stat_report(struct emu_stat *stat, struct player *player, int last);
2023-02-16 15:54:25 +01:00
#endif /* EMU_STAT_H */