summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorAlberto Ruiz <aruiz@um.es>2015-06-14 13:14:24 +0200
committerAlberto Ruiz <aruiz@um.es>2015-06-14 13:14:24 +0200
commit517dfdbf884ef2b3f3f3d365294a6a714ba7ff9d (patch)
tree52c0a64c454c3d23b293023602b0093d5a59b658 /packages
parent717c680a4b65a2226b0dd6fc13f7c63e7bc0431d (diff)
benchmark luPacked'
Diffstat (limited to 'packages')
-rw-r--r--packages/tests/src/Numeric/LinearAlgebra/Tests.hs18
1 files changed, 18 insertions, 0 deletions
diff --git a/packages/tests/src/Numeric/LinearAlgebra/Tests.hs b/packages/tests/src/Numeric/LinearAlgebra/Tests.hs
index 4cfa5cb..ffa45e7 100644
--- a/packages/tests/src/Numeric/LinearAlgebra/Tests.hs
+++ b/packages/tests/src/Numeric/LinearAlgebra/Tests.hs
@@ -613,6 +613,7 @@ runBenchmarks = do
613 cholBench 613 cholBench
614 svdBench 614 svdBench
615 eigBench 615 eigBench
616 luBench
616 putStrLn "" 617 putStrLn ""
617 618
618-------------------------------- 619--------------------------------
@@ -762,3 +763,20 @@ cholBench = do
762 cholBenchN 300 763 cholBenchN 300
763-- cholBenchN 150 764-- cholBenchN 150
764-- cholBenchN 50 765-- cholBenchN 50
766
767--------------------------------------------------------------------------------
768
769luBenchN f n x msg = do
770 let m = diagRect 1 (fromList (replicate n x)) n n
771 m `seq` putStr ""
772 time (msg ++ " "++ show n) (f m)
773
774luBench = do
775 luBenchN luPacked 1000 (5::R) "luPacked Double "
776 luBenchN luPacked' 1000 (5::R) "luPacked' Double "
777 luBenchN luPacked' 1000 (5::Mod 9973 I) "luPacked' I mod 9973"
778 luBenchN luPacked' 1000 (5::Mod 9973 Z) "luPacked' Z mod 9973"
779
780
781
782