- 人气:
- 放大
- 缩小
- 二维码
- 赞赏
delphi 时间耗时统计
处理事情:
数据处理过程中,速度很慢,无法准确定位分析是DB问题还是客户端处理问题,所以增加计时统计日志;
Delphi计时首次使用,查阅资料,予以记录:
var
BgPoint, EdPoind: int64;
OffSet: int64;
begin
BgPoint := GetTickCount;
//>> 逻辑处理语句。。。。。。
EdPoind := GetTickCount;
OffSet := EdPoind - BgPoint; //耗时(ms)
end;
//>>注:GetTickCount函数返回从操作系统启动所经过的毫秒数,它的返回值是DWORD。
————————————————
原文链接:https://blog.csdn.net/zhengzhiyujl/article/details/40142885