OT: Timing (RDTSC etc)

I was surprised to find that QueryPerformanceCounter uses RDTSC on my P4 2.8 (SMT) / XP machine.

I searched the web and somewhere I read that the multiprocessor HAL of NT uses RDTSC for QueryPerformanceCounter, while the Uniprocessor HAL does not.

To me this sounds very backward, since I thought that in an SMP system the multiple CPU cores may not be in cycle-exact sync. Anyhow, this leads me to believe that the cores ARE in sync, so that (finally a conclusion) RDTSC can safely be used on both SMP and SMT systems.

Can someone please verify this?


Yes, You are right. This is OT.

Michal Krol

To justify: this is for the timer of GLFW (my OpenGL framework)…

I should probably move this question to GameDev or so. Appologies to those who are/were offended by this thread…