Skip to content
This repository was archived by the owner on Oct 7, 2020. It is now read-only.

Commit 8dae303

Browse files
committed
documentation about profiling
1 parent 2ff3893 commit 8dae303

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -783,3 +783,19 @@ can happen because cabal-helper compiles and runs above executable at runtime wi
783783

784784
Liquid Haskell requires an SMT solver on the path. We do not take care of installing one, thus, Liquid Haskell will not run until one is installed.
785785
The recommended SMT solver is [z3](https://github.com/Z3Prover/z3). To run the tests, it is also required to have an SMT solver on the path, otherwise the tests will fail for Liquid Haskell.
786+
787+
### Profiling `haskell-ide-engine`.
788+
789+
If you think `haskell-ide-engine` is using a lot of memory then the most useful
790+
thing you can do is prepare a profile of the memory usage whilst you're using
791+
the program.
792+
793+
1. Add `profiling: True` to the cabal.project file of `haskell-ide-engine
794+
2. `cabal new-build hie`
795+
3. (IMPORTANT) Add `profiling: True` to the `cabal.project` file of the project you want to profile.
796+
4. Make a wrapper script which calls the `hie` you built in step 2 with the additional options `+RTS -hd -l-au`
797+
5. Modify your editor settings to call this wrapper script instead of looking for `hie` on the path
798+
6. Try using `h-i-e` as normal and then process the `*.eventlog` which will be created using `eventlog2html`.
799+
7. Repeat the process again using different profiling options if you like.
800+
801+

0 commit comments

Comments
 (0)