2.2. Version 9.4.5

The significant changes to the various parts of the compiler are listed in the following sections.

The LLVM backend of this release is to be used with LLVM 10, 11, 12, 13, or 14.

2.2.1. Significant Changes

Issues fixed in this release include:

2.2.1.1. Compiler

  • Fix a compiler bug where programs using Template Haskell involving Constant Applicative forms could be garbage collected too early (%s22417).
  • Fix a shadowing related bug in the occurence analysis phase of the simplifier (%s22623).
  • Fix a regression in the typechecker where certain typeclass instances involving type and data familes would fail to resolve (%s22647, %s23134).
  • Fix a regression in the constrain solver which resulted in a loop when trying to expand superclasses (%s22516).
  • Fix the linker warning about chained fixups on Darwin platforms for programs compiled with GHC (%s22429).
  • Fix a compiler panic in the demand analyser due to a bug involving shadowing (%s22718).
  • Fix a driver bug where certain non-fatal Safe Haskell related warnings were being marked as fatal (%s22728).
  • Fix a bug to do with missing parenthesis while printing splices with -ddump-splices (%s22784).
  • Fix a bug with the graph-colouring register allocater leading to compiler panics when compiling with -fregs-graph (%s22798,
  • Fix a bug to do with code emitted on Darwin platforms using relocations not supported on the platform (%s21972).

  • Improve performance for code generated by the native code generator on x86 for programs involving atomic counters (%s22764).

  • Fix core lint errors arising from incorrect scoping of type variables within SPECIALISE pragmas occuring in instance definitions (%s22913).

  • Fix core lint errors arising from an incorrect type given to the decodeDouble_Int64 rule (%s23019).

  • Improve code generation for bitmasks on AArch64 with the native code generator (%s23030).

  • Many improvements to recompilation checking with multiple home units (%s22675, %s22677, %s22669, %s22678,

  • Fix a spurious warning with -Wmissing-home-modules (%s22676).

  • Fix a typechecker panic on certain programs involving representation polymorphism (%s22743).

  • Fix bugs to do with GHCi and compiler loops pariticularly when using -dppr-debug (%s22695).

  • Fix memory leak in the compiler and in GHCi, including a bug where old environments would persist on reloading (%s22530, %s22833).

  • Fix a miscompilation due to a simplifier bug (%s23184).

  • Fix a miscompilation to do with unlifted bindings due to a bug in the specialiser (%s22998).

  • Fix a compiler panic during the “Float In” optimsation pass due to improper handling of shadowing (%s22662).

  • Fix a compiler panic when compiling certain programs involving representation polymoprhism with optimisation (:ghc-ticet:`22725`).

2.2.1.2. Runtime system

  • Fix a GC bug where a race condition in the parallel GC could cause it to garbage collect live sparks (%s22528).
  • Truncate eventlog events with a large payload (%s20221).
  • Fix a bug with the alignment of RTS data structures that could result in segfaults when compiled with high optimisation settings on certain platforms (%s22975 , %s22965).
  • Take section alignment into account in the RTS linker (%s23066).
  • Fix a bug causing segfaults where certain sections of the RTS would assume that the number of capabilites was equal to the number passed via the command line, even though the number of capabilites can be dynamically changed (%s23088).
  • Fix a race with the nonmoving GC (%s23170).
  • A bug in the nonmoving garbage collector regarding the treatment of zero-length SmallArray#s has been fixed (%s22264).
  • A number of bugs regarding the non-moving garbage collector’s treatment of Weak# pointers have been fixed (%s22327).
  • A few race conditions between the non-moving collector and setNumCapabilities which could result in undefined behavior have been fixed (%s22926, %s22927).
  • The non-moving collector is now able to better schedule marking work during the post-mark synchronization phase of collection, significantly reducing pause times in some workloads (%s22929).
  • Various bugs in the non-moving collector’s implementation of the selector optimisation have been fixed (%s22930).
  • Accounting for live bytes is now performed accurately when using the non-moving GC (%s17574).
  • Allow performing memory inventory with the non-moving GC (%s21840).

2.2.1.3. Build system and packaging

  • Bump gmp-tarballs to a version which doesn’t use the reserved x18 register on AArch64/Darwin systems, and also has fixes for CVE-2021-43618 (%s22497, %s22789).
  • Remove quarantine attribute when installing binary distribution on MacOS (%s21506, %s23009).
  • Fail in the binary distribution configure script if find is not available (%s22691).
  • Install manpages with the binary distribution (%s22371).
  • Fix a bug to do with merging of archives causing GHC to fail to bootstrap on Windows (%s21990).
  • Hadrian bug fixes to do with building a Windows cross compiler (%s20697, %s22805).
  • Fix escaping of $tooldir in the configure script (%s22561).
  • Allow LLVM 14 and use it for the Windows toolchain (%s21964).

2.2.1.4. Core libraries

  • Bump base to 4.17.1.0
  • base: Remove mingwex dependency on Windows (%s22166).
  • base: Fix inconsistency with decoding terminal input on Windows (%s21488).
  • Bump bytestring to 0.11.4.0
  • Bump``parsec`` to 3.1.16.1
  • Bump text to 2.0.2
  • Bump containers to 0.6.7

2.2.1.5. Included libraries

The package database provided with this distribution also contains a number of packages other than GHC itself. See the changelogs provided with these packages for further change information.

Package Version Reason for inclusion
ghc 9.4.6 The compiler itself
Cabal-syntax 3.8.1.0 Dependency of ghc-pkg utility
Cabal 3.8.1.0 Dependency of ghc-pkg utility
Win32 2.12.0.1 Dependency of ghc library
array 0.5.4.0 Dependency of ghc library
base 4.17.2.0 Core library
binary 0.8.9.1 Dependency of ghc library
bytestring 0.11.5.1 Dependency of ghc library
containers 0.6.7 Dependency of ghc library
deepseq 1.4.8.0 Dependency of ghc library
directory 1.3.7.1 Dependency of ghc library
exceptions 0.10.5 Dependency of ghc and haskeline library
filepath 1.4.2.2 Dependency of ghc library
ghc-boot-th 9.4.6 Internal compiler library
ghc-boot 9.4.6 Internal compiler library
ghc-compact 0.1.0.0 Core library
ghc-heap 9.4.6 GHC heap-walking library
ghc-prim 0.9.1 Core library
ghci 9.4.6 The REPL interface
haskeline 0.8.2 Dependency of ghci executable
hpc 0.6.1.0 Dependency of hpc executable
integer-gmp 1.1 Core library
libiserv 9.4.6 Internal compiler library
mtl 2.2.2 Dependency of Cabal library
parsec 3.1.16.1 Dependency of Cabal library
pretty 1.1.3.6 Dependency of ghc library
process 1.6.17.0 Dependency of ghc library
stm 2.5.1.0 Dependency of haskeline library
template-haskell 2.19.0.0 Core library
terminfo 0.4.1.5 Dependency of haskeline library
text 2.0.2 Dependency of Cabal library
time 1.12.2 Dependency of ghc library
transformers 0.5.6.2 Dependency of ghc library
unix 2.7.3 Dependency of ghc library
xhtml 3000.2.2.1 Dependency of haddock executable