Skip to content

Commit 2e105e2

Browse files
authored
Add the cabal guide to application profiling (#9)
* Add the cabal guide to application profiling * Rename the post
1 parent 3975414 commit 2e105e2

File tree

2 files changed

+39
-0
lines changed

2 files changed

+39
-0
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
+++
2+
title = "How to collect performance statistics with Cabal"
3+
date = 2024-12-23
4+
[taxonomies]
5+
authors = ["Hécate"]
6+
categories = ["Cabal"]
7+
tags = ["Performance", "Profiling"]
8+
+++
9+
10+
The [Cabal Manual][Cabal Manual] now has a guide on how to collect performance statistics of Haskell applications.
11+
12+
<!-- more -->
13+
14+
This guide was very generously contributed by Malte Neuss. It describes the various options you can set in your `cabal.project` file in order to get a time or space profile of your application.
15+
16+
## Project Configuration Guide
17+
18+
It is the recommended entry point for newcomers into the world of Haskell performance analysis.
19+
As you progress through it, you will be pointed to other resources like the [Profiling section of the GHC Users Guide][GHC]
20+
and the [Haskell Optimization Handbook][HsOpt], which present you with more in-depth techniques and configuration options.
21+
22+
Moreover, you will be shown how to produce time and space profiles that can be rendered and analysed with third-party tools like [Speedscope](https://speedscope.app).
23+
24+
<img src=./speedscope.png />
25+
26+
You can read it there: <https://cabal.readthedocs.io/en/latest/how-to-enable-profiling.html>.
27+
28+
## Contribute to the documentation
29+
30+
The manual follows the [documentation best practices](@/documentation-best-practices-in-2024/index.md) of the Haddock team,
31+
and the Cabal team is eager to receive more contributions to improve the life of our users.
32+
Do not hesitate to open a pull request at <https://github.com/haskell/cabal>.
33+
34+
Cheers!
35+
36+
37+
[Cabal Manual]: https://cabal.readthedocs.io/en/latest/
38+
[GHC]: https://downloads.haskell.org/ghc/latest/docs/users_guide/profiling.html
39+
[HsOpt]: https://haskell.foundation/hs-opt-handbook.github.io/
Loading

0 commit comments

Comments
 (0)