File: runtime.hs

package info (click to toggle)
haskell-primes 0.2.1.0-12
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 80 kB
  • sloc: haskell: 128; makefile: 2
file content (11 lines) | stat: -rw-r--r-- 322 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
-- ghc -O2 --make runtime
-- ./runtime -u runtime.csv
-- barchart criterion runtime.csv

import Criterion.Main
import Data.Numbers.Primes

main :: IO ()
main = defaultMain [ test size | size <- [5..15] ]
 where test size = bench ("wheel"++show size) $ whnf comp size
       comp size = (wheelSieve size :: [Int]) !! 10000