Created
April 23, 2019 20:51
-
-
Save JarvisPrestidge/8cd6b22ec2e094fffccfc22a48740559 to your computer and use it in GitHub Desktop.
how to precisely profile a hotkey / function in AHK
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*F10:: | |
DllCall("QueryPerformanceFrequency", "Int64*", freq) | |
DllCall("QueryPerformanceCounter", "Int64*", CounterBefore) | |
<Call your code here> | |
DllCall("QueryPerformanceCounter", "Int64*", CounterAfter) | |
EllapsedMs := (CounterAfter - CounterBefore) / freq * 1000 | |
MsgBox Elapsed QPC time is %EllapsedMs% ms |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment