next up previous contents index
Next: Program matropt Up: Optimizing and Example Previous: Program lastest

Program vectopt

 

The program vectopt could be applied to check efficiency of several implementations of the vector operation:

  <Vector 1> += <Vector 2>.
It produces results like these:
Results:    (for dimension 1000000, cycles 100)
--------

 implementation    CPU time
-----------------------------------------
    LASPack       2.518e-01 s = 100.0 %
       1          3.548e-01 s = 140.9 %
       2          3.196e-01 s = 126.9 %
       3          2.481e-01 s =  98.5 %
       4          2.392e-01 s =  95.0 %
       5          2.395e-01 s =  95.1 %
-----------------------------------------

For details to the implementations look at the file laspack/examples/vectopt/testproc.c. The current LASPack version corresponds to the implementation 2 and 3 depending on the computer architecture, respectively. They are, in comparison with LASPack , simplified and can be therefore a little faster.



Tomas Skalicky (skalicky@msmfs1.mw.tu-dresden.de)