summaryrefslogtreecommitdiff
path: root/testsuite/tests/profiling/should_run/dynamic-prof3.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/profiling/should_run/dynamic-prof3.hs')
-rw-r--r--testsuite/tests/profiling/should_run/dynamic-prof3.hs15
1 files changed, 15 insertions, 0 deletions
diff --git a/testsuite/tests/profiling/should_run/dynamic-prof3.hs b/testsuite/tests/profiling/should_run/dynamic-prof3.hs
new file mode 100644
index 0000000000..f5a17bef8d
--- /dev/null
+++ b/testsuite/tests/profiling/should_run/dynamic-prof3.hs
@@ -0,0 +1,15 @@
+{-# LANGUAGE BangPatterns #-}
+module Main where
+
+import GHC.Profiling
+import Control.Exception
+
+main = do
+ startHeapProfTimer
+ let !t = [0..1000000]
+ evaluate (length t)
+ requestHeapCensus
+ evaluate (length t)
+ stopHeapProfTimer
+
+