Вниз
Скачать: CL | DM;

processor frequency   Найти похожие ветки 

← →
CrazyTemo   (2002-04-09 10:33) [0]

есть ли такая функция которая возврашает частату процесора

сбасибо


← →
handra ©   (2002-04-09 10:53) [1]

function GetCPUSpeed : Double;
const
DelayTime = 500;
var
TimerHi,
TimerLo : DWORD;
PriorityClass,
Priority : Integer;
begin
PriorityClass := GetPriorityClass(GetCurrentProcess);
Priority := GetThreadPriority(GetCurrentThread);

SetPriorityClass(GetCurrentProcess, REALTIME_PRIORITY_CLASS);
SetThreadPriority(GetCurrentThread, THREAD_PRIORITY_TIME_CRITICAL);

Sleep(10);
asm
dw 310Fh
mov TimerLo, eax
mov TimerHi, edx
end;
Sleep(DelayTime);
asm
dw 310Fh
sub eax, TimerLo
sbb edx, TimerHi
mov TimerLo, eax
mov TimerHi, edx
end;

SetThreadPriority(GetCurrentThread, Priority);
SetPriorityClass(GetCurrentProcess, PriorityClass);

Result := TimerLo / (1000 * DelayTime);
end;



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.44 MB
Время: 0.009 c
3-30689
Alek_1
2002-05-13 17:54
2002.06.10
DBF or Paradaox


14-30990
MemoryLeak
2002-05-07 09:40
2002.06.10
Чужое адресное пространство.


1-30836
dimich
2002-05-29 09:20
2002.06.10
И обратно про TreeView


3-30735
Натик
2002-05-20 11:38
2002.06.10
TDBCombobox


4-31040
Question
2002-03-30 23:31
2002.06.10
Очень нужна помощь! (тяга к знаниям ;)




   Наверх