{"id":3909,"date":"2016-05-13T16:44:47","date_gmt":"2016-05-13T08:44:47","guid":{"rendered":"http:\/\/blog.qdac.cc\/?p=3909"},"modified":"2016-05-13T16:44:47","modified_gmt":"2016-05-13T08:44:47","slug":"qlog-%e6%9b%b4%e6%96%b0%ef%bc%9a%e6%96%b0%e5%a2%9e-calcperf-%e5%87%bd%e6%95%b0%e6%9d%a5%e7%bb%9f%e8%ae%a1%e4%b8%80%e4%b8%aa%e5%87%bd%e6%95%b0%e7%9a%84%e6%89%a7%e8%a1%8c%e6%97%b6%e9%95%bf","status":"publish","type":"post","link":"https:\/\/blog.qdac.cc\/?p=3909","title":{"rendered":"[QLog] \u66f4\u65b0\uff1a\u65b0\u589e CalcPerf \u51fd\u6570\u6765\u7edf\u8ba1\u4e00\u4e2a\u51fd\u6570\u7684\u6267\u884c\u65f6\u957f"},"content":{"rendered":"<h4>\u3010\u66f4\u65b0\u8bf4\u660e\u3011<\/h4>\n<p>1\u3001\u65b0\u589e\u7684 CalcPerf \u51fd\u6570\u53ef\u4ee5\u7528\u6765\u7edf\u8ba1\u4e00\u4e2a\u51fd\u6570\u7684\u6267\u884c\u65f6\u95f4\uff0c\u53ea\u9700\u8981\u5728\u51fd\u6570\u7684\u5f00\u59cb\u4f4d\u7f6e\u8c03\u7528\u5b83\u5c31\u53ef\u4ee5\u4e86\u3002\u60a8\u9700\u8981\u4e3a\u5b83\u6307\u5b9a\u4e00\u4e2a\u5b57\u7b26\u4e32\u6807\u7b7e\uff08Tag\uff09\uff0c\u4ee5\u4fbf\u5728\u65e5\u5fd7\u4e2d\u533a\u5206\u4e0d\u540c\u7684\u51fd\u6570\u8c03\u7528\u3002\u793a\u4f8b\u4ee3\u7801\u5982\u4e0b\uff1a<\/p>\n<pre class=\"lang:delphi decode:true \">procedure TForm2.Button2Click(Sender: TObject);\r\nbegin\r\n  CalcPerf('Button2Click');\r\n  Sleep(1000);\r\nend;<\/pre>\n<p>\u5b9e\u9645\u8f93\u51fa\u65e5\u5fd7\u5185\u5bb9\u5982\u4e0b\uff1a<\/p>\n<blockquote><p>[16:30:46.689][5112][DEBUG]:[Button2Click] \u5f00\u59cb\u6267\u884c<br \/>\n[16:30:47.691][5112][DEBUG]:[Button2Click] \u6267\u884c\u5b8c\u6210\uff0c\u7528\u65f6 1000 ms<\/p><\/blockquote>\n<p>\u53ef\u4ee5\u770b\u5230\uff0c\u8fbe\u5230\u4e86\u6211\u4eec\u7edf\u8ba1\u6027\u80fd\u7684\u76ee\u7684\u3002<\/p>\n<p>\u8981\u81ea\u5b9a\u4e49\u8f93\u51fa\u65e5\u5fd7\u5185\u5bb9\u7684\u683c\u5f0f\uff0c\u8bf7\u4fee\u6539\u00a0PerfTagStartFormat \u548c PerfTagStopFormat \u4e24\u4e2a\u5168\u5c40\u53d8\u91cf\u7684\u503c\u3002<\/p>\n<p>2\u3001\u4fee\u6b63\u4e86\u7279\u5b9a\u573a\u666f\u4e0b\u65e5\u5fd7\u8f93\u51fa\u65f6\uff0c\u65f6\u95f4\u6233\u4fe1\u606f\u4e22\u5931\u7684\u95ee\u9898\u3002<\/p>\n<h4>\u3010\u66f4\u65b0\u7ea7\u522b\u3011<\/h4>\n<p>\u53ef\u9009<\/p>\n<h4>\u3010\u7279\u522b\u611f\u8c22\u3011<\/h4>\n<p>\u9752\u6625<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3010\u66f4\u65b0\u8bf4\u660e\u3011 1\u3001\u65b0\u589e\u7684 CalcPer [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[69,8,9,135,2],"tags":[117,137,623],"class_list":["post-3909","post","type-post","status-publish","format-standard","hentry","category-c-builder","category-delphi","category-qdac","category-qlog","category-update","tag-117","tag-137","tag-623"],"views":4850,"_links":{"self":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/3909","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3909"}],"version-history":[{"count":1,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/3909\/revisions"}],"predecessor-version":[{"id":3910,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/3909\/revisions\/3910"}],"wp:attachment":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3909"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3909"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3909"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}