Clear average line and increase elapsed precision

This commit is contained in:
Rodrigo Arias 2023-03-08 16:32:44 +01:00 committed by Rodrigo Arias Mallo
parent 4f440c5104
commit 4b053b9a38

View File

@ -56,10 +56,10 @@ emu_stat_report(struct emu_stat *stat, struct player *player, int last)
if (last) { if (last) {
int tmin = (int) (time_elapsed / 60.0); int tmin = (int) (time_elapsed / 60.0);
int tsec = (int) ((time_elapsed / 60.0 - tmin) * 60.0); int tsec = (int) ((time_elapsed / 60.0 - tmin) * 60.0);
info("%5.1f%% done at avg %.0f kev/s\n", info("%5.1f%% done at avg %.0f kev/s \n",
progress * 100.0, avgspeed * 1e-3, tmin, tsec); progress * 100.0, avgspeed * 1e-3, tmin, tsec);
info("processed %ld input events in %d min %d s\n", info("processed %ld input events in %.2f s\n",
nprocessed, tmin, tsec); nprocessed, time_elapsed);
} else { } else {
int tmin = (int) (time_left / 60.0); int tmin = (int) (time_left / 60.0);
int tsec = (int) ((time_left / 60.0 - tmin) * 60.0); int tsec = (int) ((time_left / 60.0 - tmin) * 60.0);