summaryrefslogtreecommitdiff
path: root/testsuite/tests/profiling/should_run/5314.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/profiling/should_run/5314.hs')
-rw-r--r--testsuite/tests/profiling/should_run/5314.hs10
1 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/tests/profiling/should_run/5314.hs b/testsuite/tests/profiling/should_run/5314.hs
new file mode 100644
index 0000000000..681eb9586e
--- /dev/null
+++ b/testsuite/tests/profiling/should_run/5314.hs
@@ -0,0 +1,10 @@
+import Control.Concurrent
+import Control.Monad (forever)
+
+main = do
+ empty <- newEmptyMVar
+ exit <- newEmptyMVar
+ _ <- forkIO $ threadDelay 200000 >> putMVar exit ()
+ _ <- forkIO $ takeMVar empty >> return ()
+ _ <- forkIO $ print (sum [1..10000])
+ takeMVar exit