VirtualLarry
No Lifer
I was just thinking about writing a benchmarking tool, which would take a command-line parameter and spawn another process (blocking), and then return, and calculate timestamps using the TSC before and after and determine the execution time.
1) Is there a program that already does this, am I re-inventing the wheel.
2) In order to get accurate TSC elapsed-time measurements, the TSC that is read should be the same CPU core both times, in order to avoid TSC multi-core drift issues. Is it possible to set CPU affinity on one executable image, and have it spawn another process which is multi-threaded (not locked to a single CPU affinity)? Will the spawned process inherit the CPU affinity mask settings from the parent process? Is this something that is configurable?
Ideally, I want my simple program to be marked in the executable image to be locked to CPU #0, to ensure accurate TSC readings, but be able to spawn multi-threaded programs for benchmarking purposes.
Also, are there any good RAMDISK programs for Vista?
1) Is there a program that already does this, am I re-inventing the wheel.
2) In order to get accurate TSC elapsed-time measurements, the TSC that is read should be the same CPU core both times, in order to avoid TSC multi-core drift issues. Is it possible to set CPU affinity on one executable image, and have it spawn another process which is multi-threaded (not locked to a single CPU affinity)? Will the spawned process inherit the CPU affinity mask settings from the parent process? Is this something that is configurable?
Ideally, I want my simple program to be marked in the executable image to be locked to CPU #0, to ensure accurate TSC readings, but be able to spawn multi-threaded programs for benchmarking purposes.
Also, are there any good RAMDISK programs for Vista?