Ok, it seems that my brain let me down. I simply can't figure out how to use the instruction. Can you give a concerete example if i need to get the path of file 'graphics.exe'?
Ok, it seems that my brain let me down. I simply can't figure out how to use the instruction. Can you give a concerete example if i need to get the path of file 'graphics.exe'?
Is graphics.exe the executable of your application?
Yes, an executable application has been build when i compiled the program, i presume that should be the executable from which i need to extract the path.
That is correct. Adn you get full finelane (path of your file + filename) of your executable with
Code:Application.ExeName
My comment was very brief, to show very basic example of profiling.
I'm not sure that GetTickCount actually gets a value from a hardware tick counter directly. At least in Delphi for Windows it is alias for WinApi function GetTickCount (https://msdn.microsoft.com/en-us/library/aa915056.aspx this is for windows mobile, because the original help is somehow unavailable, but i think its the same of desktop windows), which is stated to return "milliseconds until windows has started". And if you run windows for a while this value will reset, since it is wrapper by max value of DWORD/Cardinal. Well of course it is not very precise, actually it seems it is update by over 16 milliseconds.
I havent used LclIntf.GetTickCount in Lazarus but I think it will have the same behavior as Winapi.
Yes i think this is very effective approachif posible I tend to repeat certain procedure multiple times and check how much time is taken for that
Last edited by Anton; 25-03-2015 at 07:06 AM.
Bookmarks