File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ static const char* detectFrequency(FFCPUResult* cpu)
6060
6161 if (pMax > 0 )
6262 {
63- if (pMax > 100000000 ) // Assume that pMax is in MHz , M1~M3
63+ if (pMax > 100000000 ) // Assume that pMax is in Hz , M1~M3
6464 cpu -> frequencyMax = pMax / 1000 / 1000 ;
6565 else // Assume that pMax is in kHz, M4 and later (#1394)
6666 cpu -> frequencyMax = pMax / 1000 ;
Original file line number Diff line number Diff line change @@ -68,7 +68,13 @@ static const char* detectFrequency(FFGPUResult* gpu)
6868 pMax = pMax > pStart [i ] ? pMax : pStart [i ];
6969
7070 if (pMax > 0 )
71- gpu -> frequency = pMax / 1000 / 1000 ;
71+ {
72+ // While this is not necessary for now (seems), we add this logic just in case. See cpu_apple.c
73+ if (pMax > 100000000 ) // Assume that pMax is in Hz
74+ cpu -> frequencyMax = pMax / 1000 / 1000 ;
75+ else // Assume that pMax is in kHz
76+ cpu -> frequencyMax = pMax / 1000 ;
77+ }
7278
7379 return NULL ;
7480}
You can’t perform that action at this time.
0 commit comments