Hi,
I'm using the following function for getting the number of CPU cycles elapsed
since I rebooted:
/* Read Timer Stamp Counter */
unsigned long long int rdtsc(void)
{
unsigned long long int x;
__asm__ volatile(".byte 0x0f,0x31" : "=A" (x));
return x;
}
The problem is that the value I get dividing by my processor frequency (my
computer is a 650Mhz toshiba satellite pro 4340) is giving me about 1 hour
and I'm using the computer for about 4 fours.
Am I forgetting something obvious? I already googled around but I came to the
conclusion that only new P4 M processors are able to change speed.
I'm sorry if this is not the place to ask.
Thanks
Marco
ps: Please CC me as I'm not subscribed
--
Marco Correia <mvc _at_ netcabo.pt>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo _at_ vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Follow-Ups:
- Re: why is rdtsc reporting wrong cpu cycles?Willy Tarreau
- Prev by Date: PCMCIA for LC2420 with 2.6.0 kernel
- Next by Date: RE: IDE-RAID Drive Performance
- Previous by thread: PCMCIA for LC2420 with 2.6.0 kernel
- Next by thread: Re: why is rdtsc reporting wrong cpu cycles?
- Indexes:[Main][Thread]