Commit a3d69dc6 authored by Sebastian Graf's avatar Sebastian Graf Committed by Ben Gamari

GHC.Core.Unify: Make UM actions one-shot by default

This MR makes the UM monad in GHC.Core.Unify into a one-shot
monad.  See the long Note [The one-shot state monad trick].

See also #18202 and !3309, which applies this to all Reader/State-like
monads in GHC for compile-time perf improvements. The pattern used
here enables something similar to the state-hack, but is applicable to
user-defined monads, not just `IO`.

Metric Decrease 'runtime/bytes allocated' (test_env='i386-linux-deb9'):
parent d3c2d59b
Pipeline #21543 failed with stages
in 1111 minutes and 57 seconds