Disable specific optim. in Config/Types/Instances

pull/51/head
Lennart Spitzner 2017-08-12 17:55:41 +02:00
parent 3751e83f8d
commit 1288c37204
1 changed files with 13 additions and 0 deletions

View File

@ -1,4 +1,17 @@
{-# OPTIONS_GHC -fno-warn-orphans #-}
-- These optimizations are disabled to improve compile times (and compilation
-- memory usage). When we do not disable them, the CI servers take more than
-- 10 minutes to compile this module alone.
-- Having looked into aeson and how the instances are written, I still do
-- not understand what makes GHC choke so much here. The size of the raw
-- expressions below looks fairly negligible, so there must be some expansion
-- due to inlining going on. But even disabling INLINE pragmas in aeson did
-- not seem to change anything.
-- Nonetheless, this solution works and has no downsides because the
-- instances defined here are not in any way performance-critical.
{-# OPTIONS_GHC -fno-pre-inlining #-}
{-# OPTIONS_GHC -fno-specialise #-}
{-# OPTIONS_GHC -fignore-interface-pragmas #-}
module Language.Haskell.Brittany.Internal.Config.Types.Instances
where