-fexternal-interpreter slow for profiling with template haskell
I'm trying to build the following program (in Foo.hs
) with profiling enabled:
{-# LANGUAGE TemplateHaskell #-}
main = print $([| 10 |])
With the "alternate object file suffix" method, I have correct build time:
$ time ghc -prof -osuf o_p Foo.hs
[1 of 1] Compiling Main ( Foo.hs, Foo.o_p )
Linking Foo ...
real 0m1.698s
user 0m1.518s
sys 0m0.184s
However with -fexternal-interpreter
, times are abysmally slow:
$ time ghc -prof -fexternal-interpreter -osuf "p_o" Foo.hs
[1 of 1] Compiling Main ( Foo.hs, Foo.p_o )
Linking Foo ...
real 0m26.077s
user 0m1.531s
sys 0m0.190s
I'm using ghc-8.6.3
on nixos.
Trac metadata
Trac field | Value |
---|---|
Version | 8.6.3 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |