Hi,

On Saturday, July 14, 2012 2:17:54 PM UTC+2, Dmitry Ivanov wrote:
>
> I can't figure out a way to build yi so that time or heap profiling 
> reports anything. Is it even possible in dynamic binary? If not, how 
> to build static one? 
>
> I can't get -fhacking to work, and according to 
>
> https://groups.google.com/group/yi-devel/browse_thread/thread/6df93ad5c24e3c07
>  
> , it is sort of deprecated anyway.


I had similar problems.
As far as I understand it, one would have to first add a config option for 
passing GHC RTS arguments to Dyre library that Yi uses for configuration 
management.
Then one can add all ghc compilation options to ghcOptions in 
src/library/Yi/Main.hs, and RTS options to Dyre launch parameters.

--- a/yi/src/library/Yi/Main.hs
+++ b/yi/src/library/Yi/Main.hs
@@ -60,7 +60,7 @@ data ConsoleConfig =
 defaultConsoleConfig :: ConsoleConfig
 defaultConsoleConfig = 
   ConsoleConfig { 
-                  ghcOptions = [],
+                  ghcOptions = ["-auto-all", "-prof", "-osuf=p_o", 
"-hisuf=p_hi", "-rtsopts"],
                   selfCheck = False
                 }
The issue is that runtime system parameters are normally invisible to 
Haskell programs, and thus they do not get forwarded by Dyre when Yi real 
"main" is relaunched.
So probably one can have two issues to open:
1. Against GHC: access runtime system parameters or command line arguments 
before RTS processing.
2. Against Dyre: add runtime parameters, or just arbitrary parameters to be 
forwarded during program relaunch.
--
  Best regards
    Michal 

-- 
Yi development mailing list
yi-devel@googlegroups.com
http://groups.google.com/group/yi-devel

Reply via email to