compiling with -O2 optimization

Hi, Is it inadvisable to compile your xmonad.hs with level 2 optimization enabled? I added the following pragma to my config, and haven't had any problems yet: {-# OPTIONS_GHC -O2 #-} I searched issues/commits/google but wasn't able to find any discussion on this -Ivan.

I doubt it makes much difference. The amount of computation xmonad is
doing is relatively small, so optimizations shouldn't make much noticeable
difference. On the other hand it very well may increase compile times
(i.e. how long you have to wait after hitting mod-q to do a hot reload).
Disclaimer: I am not a Haskell performance expert.
-Brent
On Mon, Sep 21, 2020 at 8:18 PM ivan
Hi,
Is it inadvisable to compile your xmonad.hs with level 2 optimization enabled? I added the following pragma to my config, and haven't had any problems yet:
{-# OPTIONS_GHC -O2 #-}
I searched issues/commits/google but wasn't able to find any discussion on this
-Ivan. _______________________________________________ xmonad mailing list xmonad@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/xmonad

I think that this only makes sense if you also compile all libraries with -O2.
On September 22, 2020 3:18:10 AM GMT+02:00, ivan
Hi,
Is it inadvisable to compile your xmonad.hs with level 2 optimization enabled? I added the following pragma to my config, and haven't had any problems yet:
{-# OPTIONS_GHC -O2 #-}
I searched issues/commits/google but wasn't able to find any discussion on this
-Ivan.
-- Sent from my Android device with K-9 Mail. Please excuse my brevity.
participants (3)
-
Brent Yorgey
-
Dominik Schrempf
-
ivan