core/core: Replace includes with forward declarations where applicable
The follow-up to e2457418da
, which
replaces most of the includes in the core header with forward declarations.
This makes it so that if any of the headers the core header was
previously including change, then no one will need to rebuild the bulk
of the core, due to core.h being quite a prevalent inclusion.
This should make turnaround for changes much faster for developers.
This commit is contained in:
parent
42588493d5
commit
4a587b81b2
29 changed files with 185 additions and 66 deletions
|
@ -10,6 +10,17 @@
|
|||
|
||||
namespace Core {
|
||||
|
||||
struct PerfStatsResults {
|
||||
/// System FPS (LCD VBlanks) in Hz
|
||||
double system_fps;
|
||||
/// Game FPS (GSP frame submissions) in Hz
|
||||
double game_fps;
|
||||
/// Walltime per system frame, in seconds, excluding any waits
|
||||
double frametime;
|
||||
/// Ratio of walltime / emulated time elapsed
|
||||
double emulation_speed;
|
||||
};
|
||||
|
||||
/**
|
||||
* Class to manage and query performance/timing statistics. All public functions of this class are
|
||||
* thread-safe unless stated otherwise.
|
||||
|
@ -18,22 +29,11 @@ class PerfStats {
|
|||
public:
|
||||
using Clock = std::chrono::high_resolution_clock;
|
||||
|
||||
struct Results {
|
||||
/// System FPS (LCD VBlanks) in Hz
|
||||
double system_fps;
|
||||
/// Game FPS (GSP frame submissions) in Hz
|
||||
double game_fps;
|
||||
/// Walltime per system frame, in seconds, excluding any waits
|
||||
double frametime;
|
||||
/// Ratio of walltime / emulated time elapsed
|
||||
double emulation_speed;
|
||||
};
|
||||
|
||||
void BeginSystemFrame();
|
||||
void EndSystemFrame();
|
||||
void EndGameFrame();
|
||||
|
||||
Results GetAndResetStats(std::chrono::microseconds current_system_time_us);
|
||||
PerfStatsResults GetAndResetStats(std::chrono::microseconds current_system_time_us);
|
||||
|
||||
/**
|
||||
* Gets the ratio between walltime and the emulated time of the previous system frame. This is
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue