AppleWin's Config>Benchmark, reported a "Pure CPU MHz" which was not a good indicator of unthrottled speed for v1.26+, as it was still getting the emulator to do full NTSC/cycle-accurate video update. The reality (when in full-speed/unthrottled mode) is that the video is only refreshed at 16.6ms (wall-clock).

So added a 2nd "Pure CPU MHz" for full-speed (ie. no video update), eg:

---------------------------
Benchmarks
---------------------------
Pure Video FPS:	2860 hires, 2868 text
Pure CPU MHz:	10.3 (video update)
Pure CPU MHz:	241.3 (full-speed)

EXPECTED AVERAGE VIDEO GAME
PERFORMANCE: 476 FPS

(ref: #424, #540)
This commit is contained in:
tomcw 2018-03-03 22:01:03 +00:00
parent d9accc82c5
commit 2d2304b4c6

View File

@ -227,16 +227,18 @@ void VideoBenchmark () {
// DETERMINE HOW MANY 65C02 CLOCK CYCLES WE CAN EMULATE PER SECOND WITH
// NOTHING ELSE GOING ON
CpuSetupBenchmark();
DWORD totalmhz10 = 0;
milliseconds = GetTickCount();
while (GetTickCount() == milliseconds) ;
milliseconds = GetTickCount();
cycle = 0;
do {
CpuExecute(100000, true);
totalmhz10++;
} while (GetTickCount() - milliseconds < 1000);
DWORD totalmhz10[2] = {0,0}; // bVideoUpdate & !bVideoUpdate
for (UINT i=0; i<2; i++)
{
CpuSetupBenchmark();
milliseconds = GetTickCount();
while (GetTickCount() == milliseconds) ;
milliseconds = GetTickCount();
do {
CpuExecute(100000, i==0 ? true : false);
totalmhz10[i]++;
} while (GetTickCount() - milliseconds < 1000);
}
// IF THE PROGRAM COUNTER IS NOT IN THE EXPECTED RANGE AT THE END OF THE
// CPU BENCHMARK, REPORT AN ERROR AND OPTIONALLY TRACK IT DOWN
@ -321,14 +323,14 @@ void VideoBenchmark () {
TCHAR outstr[256];
wsprintf(outstr,
TEXT("Pure Video FPS:\t%u hires, %u text\n")
TEXT("Pure CPU MHz:\t%u.%u%s\n\n")
TEXT("Pure CPU MHz:\t%u.%u%s (video update)\n")
TEXT("Pure CPU MHz:\t%u.%u%s (full-speed)\n\n")
TEXT("EXPECTED AVERAGE VIDEO GAME\n")
TEXT("PERFORMANCE: %u FPS"),
(unsigned)totalhiresfps,
(unsigned)totaltextfps,
(unsigned)(totalmhz10/10),
(unsigned)(totalmhz10 % 10),
(LPCTSTR)(IS_APPLE2 ? TEXT(" (6502)") : TEXT("")),
(unsigned)(totalmhz10[0] / 10), (unsigned)(totalmhz10[0] % 10), (LPCTSTR)(IS_APPLE2 ? TEXT(" (6502)") : TEXT("")),
(unsigned)(totalmhz10[1] / 10), (unsigned)(totalmhz10[1] % 10), (LPCTSTR)(IS_APPLE2 ? TEXT(" (6502)") : TEXT("")),
(unsigned)realisticfps);
MessageBox(g_hFrameWindow,
outstr,