Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 13 lines (10 sloc) 0.298 kb
bd2df96 @kmcallister add benchmark
authored
1 import System.GlobalLock
2
3 import Control.Concurrent.MVar
4 import Criterion.Main
5
6 main :: IO ()
7 main = do
8 mVar <- newMVar ()
9 defaultMain
10 [ bench "bare" $ (return () :: IO ())
11 , bench "MVar" $ withMVar mVar (const $ return ())
12 , bench "global" $ lock (return ()) ]
Something went wrong with that request. Please try again.