?? elapsetime.cpp
字號:
#include "stdafx.h"
#include "elapsetime.h"
unsigned __int64 GetCycleCount(void){
__asm _emit 0x0F;
__asm _emit 0x31;
}
static unsigned long TimeOfBegine;
static unsigned long TimeOfEnd;
static double TimeOfElapse;
void CycleCountStart(void){
TimeOfBegine = (unsigned long) GetCycleCount();
}
void CycleCountEnd (void){
TimeOfEnd=(unsigned long) GetCycleCount();
}
double CycleCountElapse(void){
TimeOfElapse=(TimeOfEnd-TimeOfBegine)/1000000.0; //ms
return TimeOfElapse;
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -