Skip to content

Instantly share code, notes, and snippets.

@jneira
Created October 16, 2019 22:17
Show Gist options
  • Save jneira/35a53177d6265216273304e4bf10568a to your computer and use it in GitHub Desktop.
Save jneira/35a53177d6265216273304e4bf10568a to your computer and use it in GitHub Desktop.
Intructions from mpickering to profile hie
  1. Add profiling: True to the cabal.project file of haskell-ide-engine
  2. cabal new-build hie
  3. (IMPORTANT) Add profiling: True to the cabal.project file of the project being opened by hie
  4. Make a wrapper script somewhere which calls the hie you built in step 2 with +RTS -hc -l-au
  5. Modify your editor settings to call this wrapper script instead of looking for hie on the path
  6. Try using h-i-e as normal and then you can either send me the *.eventlog which was created or process it yourself using eventlog2html

So +RTS -hc -l-au says, do cost centre profiling and create an eventlog which has the profiling samples in, my tool eventlog2html can turn that into a profile graph and I have a branch which renders cost centre profiles in an even nicer way Other modes which might be of interest, -hd Also whilst your waiting for hie to compile from source, you could try using the existing version with +RTS -hT as you can use -hT even without profiling hopefully that's a good enough README

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment