{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreihna5sgr6r6o4n6e4wxqren36ad2ivoyvencqquwjx23m5ye2pg6u",
"uri": "at://did:plc:pi6woz4d47bkuws673w2il2r/app.bsky.feed.post/3mgdtsrv4sxt2"
},
"path": "/t/how-to-profile-a-ghc-plugin/13745#post_12",
"publishedAt": "2026-03-05T20:19:39.000Z",
"site": "https://discourse.haskell.org",
"tags": [
"[link",
"timestats"
],
"textContent": "Hello! In Liquid Haskell, a ghc plugin, the procedure documented here [link] worked for me with GHC 9.14.1.\n\nThis is inspired by this oldish post about profiling ghc [link]. The idea is to build a Haskell program that loads the source files and the plugin using the GHC API. The program is linked with the profiling runtime, and then can load plugins compiled with profiling enabled.\n\nThe procedure sometimes breaks and needs an update. It was broken for a while until I investigated it today once more.\n\nThat said, I haven’t used this tooling myself. When I had to profile time, I have used timestats a couple of times.",
"title": "How to profile a GHC Plugin?"
}