Skip to content

Commit

Permalink
Add a small benchmark code
Browse files Browse the repository at this point in the history
  • Loading branch information
firephil committed Mar 15, 2021
1 parent 019ac46 commit 51510d8
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions app/Time.hs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
module Time where
import Control.Exception
import Formatting
import Formatting.Clock
import System.Clock

execute f =
do start <- getTime Monotonic
evaluate (f)
end <- getTime Monotonic
fprint (timeSpecs % "\n") start end

0 comments on commit 51510d8

Please sign in to comment.