[commit: packages/time] format-widths, master, tasty: benchmark getTimeZone and getCurrentTime (08f8296)
git at git.haskell.org
git at git.haskell.org
Mon Feb 20 21:19:21 UTC 2017
Repository : ssh://git@git.haskell.org/time
On branches: format-widths,master,tasty
Link : http://git.haskell.org/packages/time.git/commitdiff/08f8296f06981afd9ea3031ba145ec0ea708305b
>---------------------------------------------------------------
commit 08f8296f06981afd9ea3031ba145ec0ea708305b
Author: Ashley Yakeley <ashley at yakeley.org>
Date: Sun Dec 11 23:32:27 2016 -0800
benchmark getTimeZone and getCurrentTime
>---------------------------------------------------------------
08f8296f06981afd9ea3031ba145ec0ea708305b
benchmark/Main.hs | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/benchmark/Main.hs b/benchmark/Main.hs
index 8eeb7a0..dbee637 100644
--- a/benchmark/Main.hs
+++ b/benchmark/Main.hs
@@ -26,6 +26,8 @@ main = do
[ bgroup "new"
[ bench "getCurrentTime" $ nfIO getCurrentTime
, bench "getPOSIXTime" $ nfIO getPOSIXTime
+ , bench "getTimeZone" $ nfIO $ getTimeZone ct
+ , bench "getCurrentTimeZone" $ nfIO getCurrentTimeZone
, bench "getZonedTime" $ nfIO getZonedTime
, bench "formatTime" $ nf (formatTime defaultTimeLocale "%a, %_d %b %Y %H:%M:%S %Z") ct
]
@@ -33,8 +35,9 @@ main = do
bgroup "old"
[ bench "getCurrentTime" $ nfIO O.getCurrentTime
, bench "getPOSIXTime" $ nfIO O.getPOSIXTime
+ , bench "getTimeZone" $ nfIO $ O.getTimeZone oct
+ , bench "getCurrentTimeZone" $ nfIO O.getCurrentTimeZone
, bench "getZonedTime" $ nfIO O.getZonedTime
, bench "formatTime" $ nf (O.formatTime O.defaultTimeLocale "%a, %_d %b %Y %H:%M:%S %Z") oct
]
]
-
More information about the ghc-commits
mailing list