From f0cf384db038ff3b83770dbf11a89ecd20178899 Mon Sep 17 00:00:00 2001 From: Ben Gamari Date: Wed, 25 Jan 2023 15:16:46 -0500 Subject: hadrian: Add +boot_nonmoving_gc flavour transformer For using GHC bootstrapping to validate the non-moving GC. --- hadrian/src/Flavour.hs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/hadrian/src/Flavour.hs b/hadrian/src/Flavour.hs index 39ef49f11a..79eb18bed4 100644 --- a/hadrian/src/Flavour.hs +++ b/hadrian/src/Flavour.hs @@ -65,6 +65,7 @@ flavourTransformers = M.fromList , "haddock" =: enableHaddock , "hi_core" =: enableHiCore , "late_ccs" =: enableLateCCS + , "boot_nonmoving_gc" =: enableBootNonmovingGc ] where (=:) = (,) @@ -283,6 +284,13 @@ enableAssertions flav = flav { ghcDebugAssertions = f } f Stage2 = True f st = ghcDebugAssertions flav st +-- | Build the stage3 compiler using the non-moving GC. +enableBootNonmovingGc :: Flavour -> Flavour +enableBootNonmovingGc = addArgs $ mconcat + [ stage Stage2 ? builder Ghc + ? pure ["+RTS", "--nonmoving-gc", "-RTS"] + ] + -- | Produce fully statically-linked executables and build libraries suitable -- for static linking. fullyStatic :: Flavour -> Flavour -- cgit v1.2.1