Page 1 of 1
Measuring Performance
Posted: Tue Dec 17, 2002 11:42 am
by Slasher
hi,
How can one measure the Performance of their OS?
I'd like to see which of my scheduling,message passing etc algorithms perform the best. Have any of you guys done any similar testing before?
Thanks.
Re:Measuring Performance
Posted: Tue Dec 17, 2002 11:50 am
by jrfritz
Use the PIT.
Re:Measuring Performance
Posted: Tue Dec 17, 2002 2:30 pm
by jrfritz
What that what you were looking for?
Re:Measuring Performance
Posted: Tue Dec 17, 2002 2:44 pm
by Tim
How can one measure the Performance of their OS?
The same way as any other software: time how long it takes to do some typical code sequences. The Pentium RDTSC (ReaD Time Stamp Counter) instruction is useful here.
Re:Measuring Performance
Posted: Tue Dec 17, 2002 3:38 pm
by Slasher
the RDTSC instruction is not supported on CPUs < pentium, right?
so if I run it in BOCHS or PC < pentium, it would not work!
corect me if i'm wrong! also where can i get explaination on using it!
thanks
Re:Measuring Performance
Posted: Tue Dec 17, 2002 4:40 pm
by Tim
The Bochs 1.2.1 sources I have seem to support RDTSC, and I'd be surprised if you saw a non-Pentium machine that you could test your code on.
If you don't want to use RDTSC, however, you could use the RTC's high-resolution timer.
also where can i get explaination on using it!
Well, the obvious place would be the Intel manuals. But assuming you're running in ring 0, it's as easy as executing RDTSC; the number of CPU clock cycles since boot is stored in EDX:EAX (it's 64 bits).