Cost Centre MAIN

Christian Höner zu Siederdissen choener at tbi.univie.ac.at
Sun Sep 19 14:38:07 EDT 2010


Yeah that was a bit lazy by me (or bull, if you want...;-); looks like you
have runStmLogger on the top-level of your Main module ("MAIN") as well.

What functions are defined there? And what vars?

Gruss,
Christian

* Stefan Wehr <stefan.wehr at gmail.com> [19.09.2010 20:28]:
> 2010/9/19 Christian Höner zu Siederdissen <choener at tbi.univie.ac.at>:
> > You should either try "-auto-all" while compiling to get cost centres
> > for every top-level function or insert cost centres by hand with "SCC":
> >
> > http://haskell.cs.yale.edu/ghc/docs/6.12.2/html/users_guide/profiling.html
> 
> Well, I did compile with -auto-all and -caf-all
> 
> > Otherwise, MAIN is "main = ..."
> 
> Really? Here are the first couple of lines of the detailed profiling
> report I get:
> 
> COST CENTRE              MODULE
>        no.    entries  %time %alloc   %time %alloc
> 
> MAIN                     MAIN
>          1           0  47.5    0.2   100.0  100.0
>  runStmLogger            MobileGateway.Util.Logging
>       5223           0   0.0    0.0     0.0    0.0
>  main                    Main
>       5166           1   0.0    0.0     0.6    0.2
>   main                   MobileGateway.LubSyncClient
>       5167           5   0.0    0.0     0.6    0.2
>    getUrl                MobileGateway.Util.Config
>       5274           1   0.0    0.0     0.0    0.0
> 
> Doesn't look like MAIN is the same as "main = ...".
> 
> -- Stefan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
Url : http://www.haskell.org/pipermail/glasgow-haskell-users/attachments/20100919/34991149/attachment.bin


More information about the Glasgow-haskell-users mailing list