Hi Gabor On Sun, 2009-05-17 at 23:10 -0400, gabor papp wrote: > >> As long as it doesn't impact performance, please feel free to improve > i am testing the performance of vector operators and comparing them to > simple macros that can handle every vector sizes. i attached a vadd > test. it turns out that it is even a bit faster than the c++ version, > probably due to the scheme->c conversion overhead. > > adding 2 random vectors: > vadd: 0.00564 0.00783 0.0007 > vaddx: 0.00401 0.00724 0.00056 > > adding 3 random vectors: > vadd: 0.00608 0.01074 0.00064 > vaddx: 0.00489 0.00951 0.00108 > > the results are calculated by adding the vectors 100000 times and > calculating the average time needed to execute the instructions. vadd is > the current vector addition fluxus uses, vaddx is the macro attached. > the three numbers are: the number of milliseconds of CPU time required > to obtain this result, the number of "real" milliseconds required for > the result, and the number of milliseconds of CPU time spent on garbage > collection. > > what do you think? can we change the vector operations to more flexible > scheme versions or am i overlooking something?
This is great news, I tried this a few years ago and the C++ versions were faster - which I was surprised at. I say we should switch to these scheme versions now. cheers, dave
