Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
29285 Discussions

Reported executable run times in Windows XP vs Windows 2000

Jon_D
New Contributor II
680 Views
Hello,

I have a Fortran executable that prints out the elapsed CPU time at the end of executaion using the CPU_TIME intrinsic. I use this information as a measure of the efficiency of different routines I implement in the code. I am using CVF 6.6.C. I noticed that when my computer had Windows 2000 as the OS, the reported run times did not change from one run to another when I executed the same program. However, with Windows XP I get slightly different run times each time I execute the same program. Does anybody know the reason for it? Is there a difference between XP and 2000 so that CPU_TIME works differently? Maybe Compaq never made adjustments to the compiler to compensate for the differences between the two OS, at least for the CPU_TIME intrinsic? Also, does anybody know how CPU_TIME works in IVF (can I expect consistency in reported run times)?

Thanks for any help,
John
0 Kudos
2 Replies
Steven_L_Intel1
Employee
680 Views
Any difference you are seeing is outside the control of the compiler and its runtime library. The system routine used to get the CPU_TIMEvalue is the same and there are no differences I know of between W2K and XP in this regard.
0 Kudos
jimdempseyatthecove
Honored Contributor III
680 Views

There may be an initial load or virtual memory situation going on. To reduce these effects on your timing runs test your code by making several runs of the routine under test in a loop. Discount any runs that are abnormaly long. This will usualy bethe first run but it could be intermediate runs should your app happen to get charged for what would otherwise be considered operating system overhead.

Also, consider using QueryPerformanceCounter

Jim dempsey

0 Kudos
Reply