Timing Macro's

Started by MikeTrader, January 03, 2008, 01:25:28 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

MikeTrader

Charles,
I assume this timing code is not High Priority?
  ! mov ebx,tick              ' var address where count is to be stored.
  ! db  &h0f,&h31             ' RDTSC read time-stamp counter into edx:eax hi lo.
  ! mov [ebx],eax             ' save low order 4 bytes.
  ! mov [ebx+4],edx           ' save high order 4 bytes.


What do you think of using HIGH_PRIORITY_CLASS for timing Macro's
http://www.masm32.com/board/index.php?topic=770.0


Charles Pegge

Reading around, I would say that the user has very little control over the operating system.  Even the CPU makes its own scheduling decisions. So to measure performance realistically, the only way is to do controlled experiments.

Inserting and removing test code or substituting one function for another, but not attempting to change the PRIORITY_CLASS, will give a fair measurement of performance.