Dear GHC users,

I am puzzled with the following effect in  ghc-4.04, 06.
In certain large program
                                          f x = let  XX...
                                                     p = ...
                                                     YY...
                                                in   r p
p  is found respectively cheaply from  x,  
r  is found expensively via  x, p.
Now, without having profiling, I want to know what part of the time 
cost takes evaluating  p.
For this, I replace  `r p'  with     error $ show p.

And it takes 1000 times more than computing  p  by separate program,
without `YY...' part.
The problem is that with all this, it is too hard to measure the parts
of computation; one needs to rewrite the part of the program as 
the completly new program.

What do you think of this?

------------------
Sergey Mechveliani
[EMAIL PROTECTED]





Reply via email to