summaryrefslogtreecommitdiff
path: root/compiler/GHC/Core/Op/Simplify/Monad.hs
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2020-04-14 00:53:39 -0400
committerBen Gamari <ben@smart-cactus.org>2020-05-25 21:24:31 -0400
commitf410697319fbd2336af5fbf6ab8ca8334fd4b32b (patch)
treed44d0864e2c95e23eabb5891a5c7b45a9c59de59 /compiler/GHC/Core/Op/Simplify/Monad.hs
parentfdcb8f736e45cdebb8cef2e8675d547263529004 (diff)
downloadhaskell-wip/lower-tc-tracing-cost.tar.gz
Avoid unnecessary allocations due to tracing utilitieswip/lower-tc-tracing-cost
While ticky-profiling the typechecker I noticed that hundreds of millions of SDocs are being allocated just in case -ddump-*-trace is enabled. This is awful. We avoid this by ensuring that the dump flag check is inlined into the call site, ensuring that the tracing document needn't be allocated unless it's actually needed. See Note [INLINE conditional tracing utilities] for details. Fixes #18168. Metric Decrease: T9961 haddock.Cabal haddock.base haddock.compiler
Diffstat (limited to 'compiler/GHC/Core/Op/Simplify/Monad.hs')
0 files changed, 0 insertions, 0 deletions