Re: Is timeGetTime monotonic and uniform?
- From: NoSpam@xxxxxxxxxxx (Bob Masta)
- Date: Mon, 04 Dec 2006 13:47:51 GMT
On 3 Dec 2006 12:16:49 -0800, "alanglloyd@xxxxxxx"
<alanglloyd@xxxxxxx> wrote:
Bob Masta wrote:
The instruction I would use is RDTSC, which is an<snip>
assembler opcode (ReaD Time Stamp Counter)
that returns the CPU ticks since boot time in EDX:EAX.
Some time ago I read that when you get the RDTSC overhead (ie the time
to actuaaly call RDTSC which should be taken account of in timing) that
one should call RDTSC three times, checking the overhead between the
second and third time. This was because of caching of the call. I don't
know if this is still the case with present-day CPUs.
I have always done this when using RDTSC, but of course I have no means
of checking whether the above recommendation is really necessary, or is
effective.
I haven't run into the 3-times approach, but I have heard
recommendations to call CPUID just before RDTSC to
"serialize" the instructions. I believe this refers to
forcing all other instructions out of the internal CPU
pipeline, but don't know if this covers caches.
Best regards,
Bob Masta
dqatechATdaqartaDOTcom
D A Q A R T A
Data AcQuisition And Real-Time Analysis
www.daqarta.com
Home of DaqGen, the FREEWARE signal generator
.
- Follow-Ups:
- Re: Is timeGetTime monotonic and uniform?
- From: alanglloyd@xxxxxxx
- Re: Is timeGetTime monotonic and uniform?
- References:
- Is timeGetTime monotonic and uniform?
- From: "Martin v. Löwis"
- Re: Is timeGetTime monotonic and uniform?
- From: Bob Masta
- Re: Is timeGetTime monotonic and uniform?
- From: alanglloyd@xxxxxxx
- Is timeGetTime monotonic and uniform?
- Prev by Date: Re: math calculation problem when looking for silence
- Next by Date: Re: math calculation problem when looking for silence
- Previous by thread: Re: Is timeGetTime monotonic and uniform?
- Next by thread: Re: Is timeGetTime monotonic and uniform?
- Index(es):
Relevant Pages
|