X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=docs%2Fusers_guide%2Fprofiling.xml;h=adb7a336921ddd1bccec7c4737ebbc14a5f16095;hb=1cce2f51656cfbd8c7933a914a4bd981792aa1e6;hp=51ae6f71c381e55e1a35100f92201351d2a5f34e;hpb=9d6a760bfa5755a44fc9d44ec0234dc6184ae6d6;p=ghc-hetmet.git diff --git a/docs/users_guide/profiling.xml b/docs/users_guide/profiling.xml index 51ae6f7..adb7a33 100644 --- a/docs/users_guide/profiling.xml +++ b/docs/users_guide/profiling.xml @@ -266,6 +266,22 @@ MAIN MAIN 0 0.0 0.0 100.0 100.0 far to the right as possible when parsing. (SCC stands for "Set Cost Centre"). + Here is an example of a program with a couple of SCCs: + + +main :: IO () +main = do let xs = {-# SCC "X" #-} [1..1000000] + let ys = {-# SCC "Y" #-} [1..2000000] + print $ last xs + print $ last $ init xs + print $ last ys + print $ last $ init ys + + + which gives this heap profile when run: + + +