Here is a new version of the speed testing program. This one allows the pipeline to fill up and as such will give different results than before. This test seems to run a lot better for me which suggests the the P4 pipeline is quite nasty for floating point.
Here are my numbers for the new program (1.8Ghz P4)
As you can see, the numbers are a lot closer now. This makes floating point worth it.
PS: The attached program was compiled unoptimized and compiled for a 386 so anyone should be able to run it. If compiled optimized the three numbers are basically equal.
Mach3 2010 Screenset
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
That's better. Now both you and I are seeing around the same speed for all three tests. This goes to prove that pipelining and memory access can make a big difference in the results. This also makes me comfortable that floating point should be OK to use in the cutting simulator.
Originally Posted by ger21
AMD 64bit 3400+
Last edited by MrBean; 08-02-2005 at 08:34 PM. Reason: Input wrong numbers. Oooops.
Thanks MrBean! That's what I like to see: The floating point version was actually faster than the integer version! That's esp good because the floating point unit has a seperate pipeline from the main processor. That means that while the FPU is crunching on numbers the integer portion can do other things (branching, loops, sending data to the video card, etc).
This settles it. I hope to start coding up a test application w/ the floating point array idea sometime tomorrow. Hopefully I'll have something else people can run in a few days.
I hear and I forget.
I see and I remember.
I do and I understand.
I dont know what this is but...
Time for int test: 1.041000
Time for float test: 0.841000
Time for double test: 0.821000
CNC Mini Lathe Plans and Rotary Table kits:
amd64 @ 2.8ghz
results are inconsistent but float and double are usually the same?
Thanks again all! This is providing some interesting data.
The results will be inconsistant because it's running in windows so background tasks and random fluctuations in the space-time continuum effect the results (that or random task switching...)
Single and Double are usually the same speed or very close. Chances are that the processor's FPU is all double precision inside (actually I think some FPU's are 80 bit floating point inside) and just modifies the precision on the way out for single precision.
Originally Posted by fyffe555
amd64 @ 2.8ghz XP64
P4 2.8g dell
I = 0.656000
F = 0.609000
D = 0.610000
800 Mhz PIII: