ghc plugins make compilation very slow on Windows
Summary
ghc plugins make compilation very slow on Windows.
Steps to reproduce
- Install a library for a ghc plugin, for example:
cabal install --lib imp
- Create an empty Haskell module with nothing but a module name and an empty export list:
module Parser () where
- Compile without the plugin:
ghc --make Parser.hs -Wall
- Compile with the plugin:
ghc --make Parser.hs -Wall -fplugin=Imp
Why I suspect that the issue is specific to Windows and might affect all ghc plugins:
- I also got extremely slow compilation with a different plugin (monadic-bang).
- The author of imp wasn't able to reproduce the performance issue on mac.
There's some additional discussion in this imp issue: https://github.com/tfausak/imp/issues/37
Expected behavior
I didn't expect such a noticeable performance penalty (a couple of seconds -> about 50 seconds) on a small project if the same plugin works quickly on mac.
Environment
- GHC version used: 9.10.1
- Operating System: Windows 10
label Windows label compiler perf label needs triage label plugins