[Git][ghc/ghc][wip/26435] 3 commits: base: generalize delete{Firsts,}By
by Zubin (@wz1000) 18 Dec '25
by Zubin (@wz1000) 18 Dec '25
18 Dec '25
Zubin pushed to branch wip/26435 at Glasgow Haskell Compiler / GHC
Commits:
b230d549 by mangoiv at 2025-12-16T15:17:45-05:00
base: generalize delete{Firsts,}By
When we delete{Firsts,}By we should not require the
lists to be the same type. This is an especially useful
generalisation in the case of deleteFirstsBy because we
can skip an invocation of the map function.
This change was discussed on the core-libraries-committee's bug
tracker at https://github.com/haskell/core-libraries-committee/issues/372.
- - - - -
6a2b43e3 by Cheng Shao at 2025-12-16T15:18:30-05:00
compiler: clean up redundant LANGUAGE pragmas
This patch bumps `default-language` of `ghc`/`ghc-bin` from `GHC2021`
to `GHC2024` (which is supported in ghc 9.10, current boot ghc lower
version bound), and also cleans up redundant `LANGUAGE` pragmas (as
well as `default-extensions`/`other-extensions`) that are already
implied by `GHC2024`.
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
83dcb194 by Zubin Duggal at 2025-12-18T14:29:45+05:30
compiler: Warn when -finfo-table-map is used with -fllvm
These are currently not supported together.
Fixes #26435
- - - - -
447 changed files:
- compiler/GHC.hs
- compiler/GHC/Builtin/PrimOps.hs
- compiler/GHC/Builtin/PrimOps/Ids.hs
- compiler/GHC/Builtin/Types/Literals.hs
- compiler/GHC/ByteCode/Asm.hs
- compiler/GHC/ByteCode/Breakpoints.hs
- compiler/GHC/ByteCode/InfoTable.hs
- compiler/GHC/ByteCode/Instr.hs
- compiler/GHC/ByteCode/Linker.hs
- compiler/GHC/ByteCode/Types.hs
- compiler/GHC/Cmm.hs
- compiler/GHC/Cmm/BlockId.hs
- compiler/GHC/Cmm/CLabel.hs
- compiler/GHC/Cmm/CommonBlockElim.hs
- compiler/GHC/Cmm/Config.hs
- compiler/GHC/Cmm/ContFlowOpt.hs
- compiler/GHC/Cmm/Dataflow.hs
- compiler/GHC/Cmm/Dataflow/Block.hs
- compiler/GHC/Cmm/Dataflow/Graph.hs
- compiler/GHC/Cmm/Dataflow/Label.hs
- compiler/GHC/Cmm/DebugBlock.hs
- compiler/GHC/Cmm/Dominators.hs
- compiler/GHC/Cmm/Expr.hs
- compiler/GHC/Cmm/Graph.hs
- compiler/GHC/Cmm/Info/Build.hs
- compiler/GHC/Cmm/LRegSet.hs
- compiler/GHC/Cmm/LayoutStack.hs
- compiler/GHC/Cmm/Lint.hs
- compiler/GHC/Cmm/Liveness.hs
- compiler/GHC/Cmm/MachOp.hs
- compiler/GHC/Cmm/Node.hs
- compiler/GHC/Cmm/Parser.y
- compiler/GHC/Cmm/ProcPoint.hs
- compiler/GHC/Cmm/Reducibility.hs
- compiler/GHC/Cmm/Reg.hs
- compiler/GHC/Cmm/Sink.hs
- compiler/GHC/Cmm/Switch.hs
- compiler/GHC/Cmm/Switch/Implement.hs
- compiler/GHC/Cmm/ThreadSanitizer.hs
- compiler/GHC/Cmm/UniqueRenamer.hs
- compiler/GHC/Cmm/Utils.hs
- compiler/GHC/CmmToAsm/BlockLayout.hs
- compiler/GHC/CmmToAsm/CFG.hs
- compiler/GHC/CmmToAsm/CPrim.hs
- compiler/GHC/CmmToAsm/Dwarf/Types.hs
- compiler/GHC/CmmToAsm/Format.hs
- compiler/GHC/CmmToAsm/LA64/CodeGen.hs
- compiler/GHC/CmmToAsm/Monad.hs
- compiler/GHC/CmmToAsm/PPC/CodeGen.hs
- compiler/GHC/CmmToAsm/PPC/Ppr.hs
- compiler/GHC/CmmToAsm/RV64/CodeGen.hs
- compiler/GHC/CmmToAsm/RV64/Ppr.hs
- compiler/GHC/CmmToAsm/Reg/Graph.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillClean.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillCost.hs
- compiler/GHC/CmmToAsm/Reg/Linear/State.hs
- compiler/GHC/CmmToAsm/Reg/Linear/X86.hs
- compiler/GHC/CmmToAsm/Reg/Linear/X86_64.hs
- compiler/GHC/CmmToAsm/Wasm.hs
- compiler/GHC/CmmToAsm/Wasm/Asm.hs
- compiler/GHC/CmmToAsm/Wasm/FromCmm.hs
- compiler/GHC/CmmToAsm/Wasm/Types.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToAsm/X86/Ppr.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/CmmToLlvm/Base.hs
- compiler/GHC/CmmToLlvm/CodeGen.hs
- compiler/GHC/Core/Coercion.hs
- compiler/GHC/Core/Coercion.hs-boot
- compiler/GHC/Core/Coercion/Axiom.hs
- compiler/GHC/Core/DataCon.hs
- compiler/GHC/Core/FamInstEnv.hs
- compiler/GHC/Core/InstEnv.hs
- compiler/GHC/Core/LateCC/OverloadedCalls.hs
- compiler/GHC/Core/LateCC/TopLevelBinds.hs
- compiler/GHC/Core/Lint.hs
- compiler/GHC/Core/Lint/Interactive.hs
- compiler/GHC/Core/Map/Expr.hs
- compiler/GHC/Core/Map/Type.hs
- compiler/GHC/Core/Opt/CallerCC.hs
- compiler/GHC/Core/Opt/ConstantFold.hs
- compiler/GHC/Core/Opt/Monad.hs
- compiler/GHC/Core/Opt/SpecConstr.hs
- compiler/GHC/Core/Ppr.hs
- compiler/GHC/Core/Predicate.hs
- compiler/GHC/Core/SimpleOpt.hs
- compiler/GHC/Core/TyCo/Compare.hs
- compiler/GHC/Core/TyCo/Rep.hs
- compiler/GHC/Core/TyCon.hs
- compiler/GHC/Core/TyCon/Env.hs
- compiler/GHC/Core/Type.hs
- compiler/GHC/Core/Type.hs-boot
- compiler/GHC/Core/Unify.hs
- compiler/GHC/CoreToStg.hs
- compiler/GHC/Data/Bag.hs
- compiler/GHC/Data/FastString.hs
- compiler/GHC/Data/Graph/Collapse.hs
- compiler/GHC/Data/Graph/Color.hs
- compiler/GHC/Data/Graph/Directed.hs
- compiler/GHC/Data/List/Infinite.hs
- compiler/GHC/Data/List/NonEmpty.hs
- compiler/GHC/Data/Maybe.hs
- compiler/GHC/Data/Pair.hs
- compiler/GHC/Data/Stream.hs
- compiler/GHC/Data/Strict.hs
- compiler/GHC/Data/StringBuffer.hs
- compiler/GHC/Data/TrieMap.hs
- compiler/GHC/Data/Word64Map.hs
- compiler/GHC/Driver/Backend.hs
- compiler/GHC/Driver/Backpack.hs
- compiler/GHC/Driver/CmdLine.hs
- compiler/GHC/Driver/CodeOutput.hs
- compiler/GHC/Driver/Config/StgToCmm.hs
- compiler/GHC/Driver/Config/Tidy.hs
- compiler/GHC/Driver/Downsweep.hs
- compiler/GHC/Driver/DynFlags.hs
- compiler/GHC/Driver/Env.hs
- compiler/GHC/Driver/Env/KnotVars.hs
- compiler/GHC/Driver/Errors.hs
- compiler/GHC/Driver/Errors/Ppr.hs
- compiler/GHC/Driver/Errors/Types.hs
- compiler/GHC/Driver/Flags.hs
- compiler/GHC/Driver/GenerateCgIPEStub.hs
- compiler/GHC/Driver/Hooks.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Driver/Make.hs
- compiler/GHC/Driver/MakeSem.hs
- compiler/GHC/Driver/Pipeline.hs
- compiler/GHC/Driver/Pipeline/Execute.hs
- compiler/GHC/Driver/Pipeline/LogQueue.hs
- compiler/GHC/Driver/Pipeline/Monad.hs
- compiler/GHC/Driver/Pipeline/Phases.hs
- compiler/GHC/Driver/Plugins.hs
- compiler/GHC/Driver/Session.hs
- compiler/GHC/Driver/Session/Inspect.hs
- compiler/GHC/Driver/Session/Units.hs
- compiler/GHC/Hs.hs
- compiler/GHC/Hs/Basic.hs
- compiler/GHC/Hs/Binds.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/Hs/Doc.hs
- compiler/GHC/Hs/Doc.hs-boot
- compiler/GHC/Hs/DocString.hs
- compiler/GHC/Hs/Dump.hs
- compiler/GHC/Hs/Expr.hs
- compiler/GHC/Hs/Expr.hs-boot
- compiler/GHC/Hs/Extension.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/Hs/Instances.hs
- compiler/GHC/Hs/Lit.hs
- compiler/GHC/Hs/Pat.hs
- compiler/GHC/Hs/Pat.hs-boot
- compiler/GHC/Hs/Stats.hs
- compiler/GHC/Hs/Type.hs
- compiler/GHC/Hs/Utils.hs
- compiler/GHC/HsToCore/Arrows.hs
- compiler/GHC/HsToCore/Binds.hs
- compiler/GHC/HsToCore/Docs.hs
- compiler/GHC/HsToCore/Errors/Ppr.hs
- compiler/GHC/HsToCore/Errors/Types.hs
- compiler/GHC/HsToCore/Expr.hs
- compiler/GHC/HsToCore/Foreign/Decl.hs
- compiler/GHC/HsToCore/ListComp.hs
- compiler/GHC/HsToCore/Match.hs
- compiler/GHC/HsToCore/Match/Literal.hs
- compiler/GHC/HsToCore/Monad.hs
- compiler/GHC/HsToCore/Pmc.hs
- compiler/GHC/HsToCore/Pmc/Check.hs
- compiler/GHC/HsToCore/Pmc/Desugar.hs
- compiler/GHC/HsToCore/Pmc/Solver.hs
- compiler/GHC/HsToCore/Pmc/Solver/Types.hs
- compiler/GHC/HsToCore/Pmc/Types.hs
- compiler/GHC/HsToCore/Pmc/Utils.hs
- compiler/GHC/HsToCore/Quote.hs
- compiler/GHC/HsToCore/Utils.hs
- compiler/GHC/Iface/Binary.hs
- compiler/GHC/Iface/Decl.hs
- compiler/GHC/Iface/Env.hs
- compiler/GHC/Iface/Errors.hs
- compiler/GHC/Iface/Errors/Ppr.hs
- compiler/GHC/Iface/Errors/Types.hs
- compiler/GHC/Iface/Ext/Ast.hs
- compiler/GHC/Iface/Ext/Debug.hs
- compiler/GHC/Iface/Ext/Types.hs
- compiler/GHC/Iface/Ext/Utils.hs
- compiler/GHC/Iface/Load.hs
- compiler/GHC/Iface/Recomp.hs
- compiler/GHC/Iface/Rename.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/Iface/Tidy.hs
- compiler/GHC/Iface/Type.hs
- compiler/GHC/IfaceToCore.hs
- compiler/GHC/JS/Ident.hs
- compiler/GHC/JS/JStg/Monad.hs
- compiler/GHC/JS/JStg/Syntax.hs
- compiler/GHC/JS/Make.hs
- compiler/GHC/JS/Optimizer.hs
- compiler/GHC/JS/Ppr.hs
- compiler/GHC/JS/Syntax.hs
- compiler/GHC/JS/Transform.hs
- compiler/GHC/Linker/Deps.hs
- compiler/GHC/Linker/Loader.hs
- compiler/GHC/Linker/Types.hs
- compiler/GHC/Llvm/MetaData.hs
- compiler/GHC/Llvm/Ppr.hs
- compiler/GHC/Llvm/Types.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/Annotation.hs
- compiler/GHC/Parser/Errors/Basic.hs
- compiler/GHC/Parser/Errors/Ppr.hs
- compiler/GHC/Parser/Errors/Types.hs
- compiler/GHC/Parser/Lexer.x
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Parser/PostProcess/Haddock.hs
- compiler/GHC/Parser/String.hs
- compiler/GHC/Parser/Types.hs
- compiler/GHC/Platform.hs
- compiler/GHC/Platform/Reg/Class.hs
- compiler/GHC/Platform/Reg/Class/NoVectors.hs
- compiler/GHC/Platform/Reg/Class/Separate.hs
- compiler/GHC/Platform/Reg/Class/Unified.hs
- compiler/GHC/Rename/Bind.hs
- compiler/GHC/Rename/Env.hs
- compiler/GHC/Rename/Expr.hs
- compiler/GHC/Rename/Expr.hs-boot
- compiler/GHC/Rename/HsType.hs
- compiler/GHC/Rename/Module.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Pat.hs
- compiler/GHC/Rename/Splice.hs
- compiler/GHC/Rename/Unbound.hs
- compiler/GHC/Rename/Utils.hs
- compiler/GHC/Runtime/Eval.hs
- compiler/GHC/Runtime/Heap/Layout.hs
- compiler/GHC/Runtime/Interpreter.hs
- compiler/GHC/Runtime/Interpreter/JS.hs
- compiler/GHC/Runtime/Interpreter/Process.hs
- compiler/GHC/Runtime/Interpreter/Types.hs
- compiler/GHC/Runtime/Interpreter/Types/SymbolCache.hs
- compiler/GHC/Settings/IO.hs
- compiler/GHC/Stg/Debug.hs
- compiler/GHC/Stg/EnforceEpt.hs
- compiler/GHC/Stg/EnforceEpt/Rewrite.hs
- compiler/GHC/Stg/EnforceEpt/TagSig.hs
- compiler/GHC/Stg/EnforceEpt/Types.hs
- compiler/GHC/Stg/FVs.hs
- compiler/GHC/Stg/Lift/Analysis.hs
- compiler/GHC/Stg/Lift/Monad.hs
- compiler/GHC/Stg/Lift/Types.hs
- compiler/GHC/Stg/Lint.hs
- compiler/GHC/Stg/Pipeline.hs
- compiler/GHC/Stg/Syntax.hs
- compiler/GHC/Stg/Unarise.hs
- compiler/GHC/Stg/Utils.hs
- compiler/GHC/StgToByteCode.hs
- compiler/GHC/StgToCmm.hs
- compiler/GHC/StgToCmm/ArgRep.hs
- compiler/GHC/StgToCmm/CgUtils.hs
- compiler/GHC/StgToCmm/Closure.hs
- compiler/GHC/StgToCmm/ExtCode.hs
- compiler/GHC/StgToCmm/Lit.hs
- compiler/GHC/StgToCmm/Monad.hs
- compiler/GHC/StgToCmm/Prim.hs
- compiler/GHC/StgToCmm/Utils.hs
- compiler/GHC/StgToJS/Apply.hs
- compiler/GHC/StgToJS/Arg.hs
- compiler/GHC/StgToJS/CodeGen.hs
- compiler/GHC/StgToJS/DataCon.hs
- compiler/GHC/StgToJS/Deps.hs
- compiler/GHC/StgToJS/Expr.hs
- compiler/GHC/StgToJS/ExprCtx.hs
- compiler/GHC/StgToJS/FFI.hs
- compiler/GHC/StgToJS/Heap.hs
- compiler/GHC/StgToJS/Linker/Linker.hs
- compiler/GHC/StgToJS/Linker/Opt.hs
- compiler/GHC/StgToJS/Linker/Types.hs
- compiler/GHC/StgToJS/Literal.hs
- compiler/GHC/StgToJS/Monad.hs
- compiler/GHC/StgToJS/Object.hs
- compiler/GHC/StgToJS/Rts/Rts.hs
- compiler/GHC/StgToJS/Rts/Types.hs
- compiler/GHC/StgToJS/Sinker/Collect.hs
- compiler/GHC/StgToJS/Sinker/Sinker.hs
- compiler/GHC/StgToJS/Sinker/StringsUnfloat.hs
- compiler/GHC/StgToJS/Types.hs
- compiler/GHC/StgToJS/Utils.hs
- compiler/GHC/SysTools.hs
- compiler/GHC/SysTools/Ar.hs
- compiler/GHC/SysTools/BaseDir.hs
- compiler/GHC/SysTools/Cpp.hs
- compiler/GHC/SysTools/Tasks.hs
- compiler/GHC/SysTools/Terminal.hs
- compiler/GHC/Tc/Deriv.hs
- compiler/GHC/Tc/Deriv/Functor.hs
- compiler/GHC/Tc/Deriv/Generate.hs
- compiler/GHC/Tc/Deriv/Generics.hs
- compiler/GHC/Tc/Errors.hs
- compiler/GHC/Tc/Errors/Hole.hs
- compiler/GHC/Tc/Errors/Hole/FitTypes.hs
- compiler/GHC/Tc/Errors/Hole/Plugin.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Errors/Types.hs
- compiler/GHC/Tc/Errors/Types/PromotionErr.hs
- compiler/GHC/Tc/Gen/Annotation.hs
- compiler/GHC/Tc/Gen/App.hs
- compiler/GHC/Tc/Gen/Arrow.hs
- compiler/GHC/Tc/Gen/Bind.hs
- compiler/GHC/Tc/Gen/Default.hs
- compiler/GHC/Tc/Gen/Do.hs
- compiler/GHC/Tc/Gen/Export.hs
- compiler/GHC/Tc/Gen/Expr.hs
- compiler/GHC/Tc/Gen/Foreign.hs
- compiler/GHC/Tc/Gen/Head.hs
- compiler/GHC/Tc/Gen/HsType.hs
- compiler/GHC/Tc/Gen/Match.hs
- compiler/GHC/Tc/Gen/Pat.hs
- compiler/GHC/Tc/Gen/Splice.hs
- compiler/GHC/Tc/Instance/Family.hs
- compiler/GHC/Tc/Instance/FunDeps.hs
- compiler/GHC/Tc/Instance/Typeable.hs
- compiler/GHC/Tc/Module.hs
- compiler/GHC/Tc/Solver.hs
- compiler/GHC/Tc/Solver/Equality.hs
- compiler/GHC/Tc/Solver/InertSet.hs
- compiler/GHC/Tc/Solver/Irred.hs
- compiler/GHC/Tc/Solver/Monad.hs
- compiler/GHC/Tc/Solver/Types.hs
- compiler/GHC/Tc/TyCl.hs
- compiler/GHC/Tc/TyCl/Instance.hs
- compiler/GHC/Tc/TyCl/PatSyn.hs
- compiler/GHC/Tc/TyCl/Utils.hs
- compiler/GHC/Tc/Types.hs
- compiler/GHC/Tc/Types/Constraint.hs
- compiler/GHC/Tc/Types/ErrCtxt.hs
- compiler/GHC/Tc/Types/Evidence.hs
- compiler/GHC/Tc/Types/Origin.hs
- compiler/GHC/Tc/Utils/Backpack.hs
- compiler/GHC/Tc/Utils/Env.hs
- compiler/GHC/Tc/Utils/Instantiate.hs
- compiler/GHC/Tc/Utils/TcMType.hs
- compiler/GHC/Tc/Utils/TcType.hs
- compiler/GHC/Tc/Utils/Unify.hs
- compiler/GHC/Tc/Validity.hs
- compiler/GHC/Tc/Zonk/Monad.hs
- compiler/GHC/Tc/Zonk/Type.hs
- compiler/GHC/ThToHs.hs
- compiler/GHC/Types/Annotations.hs
- compiler/GHC/Types/Avail.hs
- compiler/GHC/Types/Basic.hs
- compiler/GHC/Types/CompleteMatch.hs
- compiler/GHC/Types/CostCentre.hs
- compiler/GHC/Types/CostCentre/State.hs
- compiler/GHC/Types/DefaultEnv.hs
- compiler/GHC/Types/Demand.hs
- compiler/GHC/Types/Error.hs
- compiler/GHC/Types/Error/Codes.hs
- compiler/GHC/Types/FieldLabel.hs
- compiler/GHC/Types/Fixity.hs
- compiler/GHC/Types/ForeignCall.hs
- compiler/GHC/Types/ForeignStubs.hs
- compiler/GHC/Types/GREInfo.hs
- compiler/GHC/Types/Hint.hs
- compiler/GHC/Types/Hint/Ppr.hs
- compiler/GHC/Types/Id/Info.hs
- compiler/GHC/Types/Id/Make.hs
- compiler/GHC/Types/Literal.hs
- compiler/GHC/Types/Name.hs
- compiler/GHC/Types/Name/Cache.hs
- compiler/GHC/Types/Name/Occurrence.hs
- compiler/GHC/Types/Name/Reader.hs
- compiler/GHC/Types/Name/Set.hs
- compiler/GHC/Types/PkgQual.hs
- compiler/GHC/Types/RepType.hs
- compiler/GHC/Types/SaneDouble.hs
- compiler/GHC/Types/SourceText.hs
- compiler/GHC/Types/SrcLoc.hs
- compiler/GHC/Types/Tickish.hs
- compiler/GHC/Types/TyThing.hs
- compiler/GHC/Types/Unique/DFM.hs
- compiler/GHC/Types/Unique/DSet.hs
- compiler/GHC/Types/Unique/FM.hs
- compiler/GHC/Types/Unique/Map.hs
- compiler/GHC/Types/Unique/SDFM.hs
- compiler/GHC/Types/Unique/Set.hs
- compiler/GHC/Types/Var.hs
- compiler/GHC/Unit.hs
- compiler/GHC/Unit/Env.hs
- compiler/GHC/Unit/Finder.hs
- compiler/GHC/Unit/Home/PackageTable.hs
- compiler/GHC/Unit/Info.hs
- compiler/GHC/Unit/Module.hs
- compiler/GHC/Unit/Module/Deps.hs
- compiler/GHC/Unit/Module/Graph.hs
- compiler/GHC/Unit/Module/ModIface.hs
- compiler/GHC/Unit/Module/ModSummary.hs
- compiler/GHC/Unit/Module/Status.hs
- compiler/GHC/Unit/Module/Warnings.hs
- compiler/GHC/Unit/Module/WholeCoreBindings.hs
- compiler/GHC/Unit/State.hs
- compiler/GHC/Unit/Types.hs
- compiler/GHC/Unit/Types.hs-boot
- compiler/GHC/Utils/Binary.hs
- compiler/GHC/Utils/Binary/Typeable.hs
- compiler/GHC/Utils/Exception.hs
- compiler/GHC/Utils/Json.hs
- compiler/GHC/Utils/Logger.hs
- compiler/GHC/Utils/Misc.hs
- compiler/GHC/Utils/Monad/Codensity.hs
- compiler/GHC/Utils/Outputable.hs
- compiler/GHC/Utils/Panic.hs
- compiler/GHC/Utils/Panic/Plain.hs
- compiler/GHC/Wasm/ControlFlow.hs
- compiler/GHC/Wasm/ControlFlow/FromCmm.hs
- compiler/Language/Haskell/Syntax.hs
- compiler/Language/Haskell/Syntax/Basic.hs
- compiler/Language/Haskell/Syntax/Binds.hs
- compiler/Language/Haskell/Syntax/Decls.hs
- compiler/Language/Haskell/Syntax/Expr.hs
- compiler/Language/Haskell/Syntax/Expr.hs-boot
- compiler/Language/Haskell/Syntax/Extension.hs
- compiler/Language/Haskell/Syntax/ImpExp.hs
- compiler/Language/Haskell/Syntax/Lit.hs
- compiler/Language/Haskell/Syntax/Pat.hs
- compiler/Language/Haskell/Syntax/Pat.hs-boot
- compiler/Language/Haskell/Syntax/Type.hs
- compiler/ghc.cabal.in
- docs/users_guide/debug-info.rst
- ghc/GHC/Driver/Session/Lint.hs
- ghc/GHC/Driver/Session/Mode.hs
- ghc/GHCi/Leak.hs
- ghc/GHCi/UI.hs
- ghc/GHCi/UI/Exception.hs
- ghc/GHCi/UI/Info.hs
- ghc/GHCi/UI/Monad.hs
- ghc/Main.hs
- ghc/ghc-bin.cabal.in
- libraries/base/changelog.md
- libraries/ghc-internal/src/GHC/Internal/Data/OldList.hs
- + testsuite/tests/driver/T26435.ghc.stderr
- + testsuite/tests/driver/T26435.hs
- + testsuite/tests/driver/T26435.stdout
- testsuite/tests/driver/all.T
- testsuite/tests/interface-stability/base-exports.stdout
- testsuite/tests/interface-stability/base-exports.stdout-javascript-unknown-ghcjs
- testsuite/tests/interface-stability/base-exports.stdout-mingw32
- testsuite/tests/interface-stability/base-exports.stdout-ws-32
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/6642d1f6b1f6e7c0770c5738358e54…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/6642d1f6b1f6e7c0770c5738358e54…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/marge_bot_batch_merge_job] 15 commits: X86 CodeGen: fix assign_eax_sse_regs
by Marge Bot (@marge-bot) 18 Dec '25
by Marge Bot (@marge-bot) 18 Dec '25
18 Dec '25
Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC
Commits:
4ec3ffc9 by sheaf at 2025-12-18T03:56:51-05:00
X86 CodeGen: fix assign_eax_sse_regs
We must set %al to the number of SSE2 registers that contain arguments
(in case we are dealing with a varargs function). The logic for counting
how many arguments reside in SSE2 registers was incorrect, as it used
'isFloatFormat', which incorrectly ignores vector registers.
We now instead do case analysis on the register class:
is_sse_reg r =
case targetClassOfReg platform r of
RcFloatOrVector -> True
RcInteger -> False
This change is necessary to prevent segfaults in T20030_test1j, because
subsequent commits change the format calculations, resulting in vector
formats more often.
- - - - -
fb583f9f by sheaf at 2025-12-18T03:56:51-05:00
X86 regUsageOfInstr: fix format for IMUL
When used with 8-bit operands, the IMUL instruction returns the result
in the lower 16 bits of %rax (also known as %ax). This is different
than for the other sizes, where an input at 16, 32 or 64 bits will
result in 16, 32 or 64 bits of output in both %rax and %rdx.
This doesn't affect the behaviour of the compiler, because we don't
allow partial writes at sub-word sizes. The rationale is explained
in Wrinkle [Don't allow scalar partial writes] in Note [Register formats in liveness analysis],
in GHC.CmmToAsm.Reg.Liveness.
- - - - -
acdeb6a9 by sheaf at 2025-12-18T03:56:52-05:00
Liveness analysis: consider register formats
This commit updates the register allocator to be a bit more careful in
situations in which a single register is used at multiple different
formats, e.g. when xmm1 is used both to store a Double# and a DoubleX2#.
This is done by introducing the 'Regs' newtype around 'UniqSet RegWithFormat',
for which the combining operations take the larger of the two formats
instead of overriding the format.
Operations on 'Regs' are defined in 'GHC.CmmToAsm.Reg.Regs'. There is
a modest compile-time cost for the additional overhead for tracking
register formats, which causes the metric increases of this commit.
The subtle aspects of the implementation are outlined in
Note [Register formats in liveness analysis] in GHC.CmmToAsm.Reg.Liveness.
Fixes #26411 #26611
-------------------------
Metric Increase:
T12707
T26425
T3294
-------------------------
- - - - -
b9a384b8 by sheaf at 2025-12-18T03:56:52-05:00
Register allocator: reload at same format as spill
This commit ensures that if we spill a register onto the stack at a
given format, we then always reload the register at this same format.
This ensures we don't end up in a situation where we spill F64x2 but end
up only reloading the lower F64. This first reload would make us believe
the whole data is in a register, thus silently losing the upper 64 bits
of the spilled register's contents.
Fixes #26526
- - - - -
e2f82ed1 by sheaf at 2025-12-18T03:56:52-05:00
Register allocation: writes redefine format
As explained in Note [Allocated register formats] in GHC.CmmToAsm.Reg.Linear,
we consider all writes to redefine the format of the register.
This ensures that in a situation such as
movsd .Ln6m(%rip),%v1
shufpd $0,%v1,%v1
we properly consider the broadcast operation to change the format of %v1
from F64 to F64x2.
This completes the fix to #26411 (test in T26411b).
- - - - -
aa2e8e9a by Vladislav Zavialov at 2025-12-18T03:56:53-05:00
Parser: improve mkModuleImpExp, remove checkImportSpec
1. The `mkModuleImpExp` helper now knows whether it is processing an import or
export list item, and uses this information to produce a more accurate error
message for `import M (T(..,x))` with PatternSynonyms disabled.
The old message incorrectly referred to this case as an export form.
2. The `checkImportSpec` helper is removed in favor of more comprehensive error
checking in `mkModuleImpExp`.
3. Additionaly, the invariants of `ImpExpList` and `ImpExpAllWith` have been
made more explicit in the comments and assertions (calls to 'panic').
Test case: import-syntax-no-ext
- - - - -
f95a6d38 by Vladislav Zavialov at 2025-12-18T03:56:54-05:00
Subordinate namespace-specified wildcards (#25901)
Add support for subordinate namespace-specified wildcards
`X(type ..)` and `X(data ..)` to import and export lists.
Examples:
import M (Cls(type ..)) -- imports Cls and all its associated types
import M (Cls(data ..)) -- imports Cls and all its methods
module M (R(data ..), C(type ..)) where
-- exports R and all its data constructors and record fields;
-- exports C and all its associated types, but not its methods
The scope of this change is limited to the case where the wildcard is the only
subordinate import/export item, whereas the more complex forms `X(type .., f)`
or `X(type .., data ..)` are unsupported and raise the newly introduced
PsErrUnsupportedExplicitNamespace error. This restriction may be lifted later.
Summary of the changes:
1. Refactor IEThingAll to store its extension field XIEThingAll as a record
IEThingAllExt instead of a tuple.
2. Extend the AST by adding a NamespaceSpecifier field to IEThingAllExt,
representing an optional namespace specifier `type` or `data` in front
of a subordinate wildcard `X(..)`.
3. Extend the grammar in Parser.y with productions for `type ..` and `data ..`
in subordinate import/export items.
4. Introduce `filterByNamespaceGREs` to filter [GlobalRdrElt] by a
NamespaceSpecifier; use it in `filterImports` and `exports_from_avail`
to account for the namespace specifier in IEThingAll.
5. Improve diagnostics by storing more information in DodgyImportsEmptyParent
and DodgyExportsEmptyParent.
Test cases:
T25901_sub_e T25901_sub_f T25901_sub_g T25901_sub_a
T25901_sub_b T25901_sub_c T25901_sub_d T25901_sub_w
DodgyImports02 DodgyImports03 DodgyImports04
- - - - -
ba7a6404 by Recursion Ninja at 2025-12-18T03:56:55-05:00
Removing the 'Data' instance for 'InstEnv'.
The 'Data' instance is blocking work on Trees that Grow, and the
'Data' instance seem to have been added without a clear purpose.
- - - - -
40335265 by Recursion Ninja at 2025-12-18T03:56:55-05:00
'Decouple Language.Haskell.Syntax.Decls' from 'GHC.Unit.Module.Warnings'
- - - - -
745c4d7a by Cheng Shao at 2025-12-18T03:56:55-05:00
testsuite: improve coverage of foundation test
This patch refactors the `foundation` test a bit to improve coverage:
- Instead of using a hard-coded seed, a random seed is now taken from
the command line, and printed upon test failure. This improves test
coverage over many future CI runs, and shall a failure occur, the
seed is available in the CI log for local reproduction.
- The iterations count is bumped to 1000 instead of 100, similar to
the bump in `test-primops`. Runtime timeout is bumped 2x just to be
safe.
- Improve `newLCGGen` by using non-atomic loads/stores on a
`MutableByteArray#` for storing mutable `Word64`, this test doesn't
use parallelism in the first place
- Fixed a few compiler warnings and removed redundant pragmas and
imports
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
b6108d39 by Sylvain Henry at 2025-12-18T03:57:16-05:00
Doc: document -pgmi "" (#26634)
- - - - -
c6fac68e by Cheng Shao at 2025-12-18T03:57:17-05:00
rts: use __builtin_mul_overflow for hs_mulIntMayOflo
This patch uses `__builtin_mul_overflow` to implement
`hs_mulIntMayOflo`. This is a GNU C checked arithmetic builtin
function supported by gcc/clang, is type-generic so works for both
32-bit/64-bit, and makes the code both more efficient and easier to
read/maintain than the previous hand rolled logic.
- - - - -
ab6aa90a by Cheng Shao at 2025-12-18T03:57:19-05:00
compiler/rts: fix ABI mismatch in barf() invocations
This patch fixes a long-standing issue of ABI mismatch in `barf()`
invocations, both in compiler-emitted code and in hand written Cmm
code:
- In RTS, we have `barf()` which reports a fatal internal error
message and exits the program.
- `barf()` is a variadic C function! When used as a callee of a
foreign call with `ccall` calling convention instead of `capi`,
there is an ABI mismatch between the caller and the callee!
- Unfortunately, both the compiler and the Cmm sources contain many
places where we call `barf()` via `ccall` convention!! Like, when
you write `foreign "C" barf("foo object (%p) entered!", R1)`, it
totally doesn't do what you think it'll do at all!! The second
argument `R1` is not properly passed in `va_list`, and the behavior
is completely undefined!!
- Even more unfortunately, this issue has been sitting around long
enough because the ABI mismatch is subtle enough on normie platforms
like x64 and arm64.
- But there are platforms like wasm32 that are stricter about ABI, and
the broken `barf()` invocations already causes trouble for wasm
backend: we had to use ugly hacks like `barf(errmsg, NULL)` to make
`wasm-ld` happy, and even with this band-aid, compiler-generated
`barf()` invocations are still broken, resulting in regressions in
certain debug-related functionality, e.g. `-dtag-inference-checks`
is broken on wasm32 (#22882).
This patch properly fixes the issue:
- We add non-variadic `barf` wrappers in the RTS that can be used as
`ccall` callees
- Both the compiler `emitBarf` logic and the hand-written Cmm are
changed to call these wrappers
- `emitBarf` now also properly annotates the foreign call as
`CmmNeverReturns` to indicate it's a noreturn call to enable more
efficient code generation
`-dtag-inference-checks` now works on wasm. Closes #22882.
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
0d4a2618 by Vilim Lendvaj at 2025-12-18T03:57:23-05:00
Remove outdated comment
The Traversable instance for ZipList is no longer in
GHC.Internal.Data.Traversable. In fact, it is right below this very comment.
- - - - -
5c8309bc by Cheng Shao at 2025-12-18T03:57:24-05:00
compiler: remove unused OtherSection logic
This patch removes the OtherSection logic in Cmm, given it's never
actually used by any of our backends.
- - - - -
117 changed files:
- compiler/GHC/Builtin/Utils.hs
- compiler/GHC/Cmm.hs
- compiler/GHC/Cmm/Parser.y
- compiler/GHC/CmmToAsm/AArch64/Ppr.hs
- compiler/GHC/CmmToAsm/LA64/Ppr.hs
- compiler/GHC/CmmToAsm/PPC/Ppr.hs
- compiler/GHC/CmmToAsm/Ppr.hs
- compiler/GHC/CmmToAsm/RV64/Ppr.hs
- compiler/GHC/CmmToAsm/Reg/Graph.hs
- compiler/GHC/CmmToAsm/Reg/Graph/Coalesce.hs
- compiler/GHC/CmmToAsm/Reg/Graph/Spill.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillCost.hs
- compiler/GHC/CmmToAsm/Reg/Linear.hs
- compiler/GHC/CmmToAsm/Reg/Linear/Base.hs
- compiler/GHC/CmmToAsm/Reg/Linear/JoinToTargets.hs
- compiler/GHC/CmmToAsm/Reg/Liveness.hs
- + compiler/GHC/CmmToAsm/Reg/Regs.hs
- compiler/GHC/CmmToAsm/Reg/Target.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToAsm/X86/Ppr.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/CmmToLlvm/Data.hs
- compiler/GHC/Core/InstEnv.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/Hs/Instances.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/Iface/Warnings.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/Errors/Ppr.hs
- compiler/GHC/Parser/Errors/Types.hs
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Rename/Module.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Utils.hs
- compiler/GHC/StgToCmm/Bind.hs
- compiler/GHC/StgToCmm/Utils.hs
- compiler/GHC/Tc/Deriv.hs
- compiler/GHC/Tc/Deriv/Utils.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Errors/Types.hs
- compiler/GHC/Tc/Gen/Export.hs
- compiler/GHC/Tc/Types/Origin.hs
- compiler/GHC/Tc/Utils/Instantiate.hs
- compiler/GHC/Types/DefaultEnv.hs
- compiler/GHC/Types/Error/Codes.hs
- compiler/GHC/Types/Name/Reader.hs
- compiler/GHC/Types/Unique/FM.hs
- compiler/GHC/Types/Unique/Set.hs
- compiler/GHC/Unit/Module/Warnings.hs
- compiler/Language/Haskell/Syntax/Decls.hs
- compiler/Language/Haskell/Syntax/Extension.hs
- compiler/ghc.cabal.in
- docs/users_guide/phases.rst
- libraries/ghc-internal/src/GHC/Internal/Functor/ZipList.hs
- rts/Apply.cmm
- rts/Compact.cmm
- rts/ContinuationOps.cmm
- rts/Exception.cmm
- rts/Jumps.h
- rts/PrimOps.cmm
- rts/RtsMessages.c
- rts/StgMiscClosures.cmm
- rts/StgStartup.cmm
- rts/include/Stg.h
- rts/include/rts/Messages.h
- rts/prim/mulIntMayOflo.c
- testsuite/tests/diagnostic-codes/codes.stdout
- testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr
- testsuite/tests/numeric/should_run/all.T
- testsuite/tests/numeric/should_run/foundation.hs
- testsuite/tests/numeric/should_run/foundation.stdout
- testsuite/tests/patsyn/should_fail/all.T
- + testsuite/tests/patsyn/should_fail/import-syntax-no-ext.hs
- + testsuite/tests/patsyn/should_fail/import-syntax-no-ext.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_e.hs
- + testsuite/tests/rename/should_compile/T25901_sub_f.hs
- + testsuite/tests/rename/should_compile/T25901_sub_f.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_g.hs
- + testsuite/tests/rename/should_compile/T25901_sub_g.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_g_helper.hs
- testsuite/tests/rename/should_compile/all.T
- testsuite/tests/rename/should_fail/T23570b.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_a.hs
- + testsuite/tests/rename/should_fail/T25901_sub_a.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_b.hs
- + testsuite/tests/rename/should_fail/T25901_sub_b.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_c.hs
- + testsuite/tests/rename/should_fail/T25901_sub_c.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_c_helper.hs
- + testsuite/tests/rename/should_fail/T25901_sub_d.hs
- + testsuite/tests/rename/should_fail/T25901_sub_d.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_d_helper.hs
- + testsuite/tests/rename/should_fail/T25901_sub_w.hs
- + testsuite/tests/rename/should_fail/T25901_sub_w.stderr
- testsuite/tests/rename/should_fail/all.T
- + testsuite/tests/simd/should_run/T26411.hs
- + testsuite/tests/simd/should_run/T26411.stdout
- + testsuite/tests/simd/should_run/T26411b.hs
- + testsuite/tests/simd/should_run/T26411b.stdout
- testsuite/tests/simd/should_run/all.T
- testsuite/tests/simplStg/should_compile/all.T
- testsuite/tests/warnings/should_compile/DodgyExports03.stderr
- testsuite/tests/warnings/should_compile/DodgyImports.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports02.hs
- + testsuite/tests/warnings/should_compile/DodgyImports02.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports03.hs
- + testsuite/tests/warnings/should_compile/DodgyImports03.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports03_helper.hs
- + testsuite/tests/warnings/should_compile/DodgyImports04.hs
- + testsuite/tests/warnings/should_compile/DodgyImports04.stderr
- testsuite/tests/warnings/should_compile/DodgyImports_hiding.stderr
- testsuite/tests/warnings/should_compile/all.T
- utils/check-exact/ExactPrint.hs
- utils/genapply/Main.hs
- utils/haddock/haddock-api/src/Haddock/Interface/Create.hs
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/4f0f6406491f215a0762fef7924915…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/4f0f6406491f215a0762fef7924915…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/marge_bot_batch_merge_job] 15 commits: X86 CodeGen: fix assign_eax_sse_regs
by Marge Bot (@marge-bot) 18 Dec '25
by Marge Bot (@marge-bot) 18 Dec '25
18 Dec '25
Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC
Commits:
8c3c6873 by sheaf at 2025-12-18T03:53:49-05:00
X86 CodeGen: fix assign_eax_sse_regs
We must set %al to the number of SSE2 registers that contain arguments
(in case we are dealing with a varargs function). The logic for counting
how many arguments reside in SSE2 registers was incorrect, as it used
'isFloatFormat', which incorrectly ignores vector registers.
We now instead do case analysis on the register class:
is_sse_reg r =
case targetClassOfReg platform r of
RcFloatOrVector -> True
RcInteger -> False
This change is necessary to prevent segfaults in T20030_test1j, because
subsequent commits change the format calculations, resulting in vector
formats more often.
- - - - -
e26b0ec8 by sheaf at 2025-12-18T03:53:49-05:00
X86 regUsageOfInstr: fix format for IMUL
When used with 8-bit operands, the IMUL instruction returns the result
in the lower 16 bits of %rax (also known as %ax). This is different
than for the other sizes, where an input at 16, 32 or 64 bits will
result in 16, 32 or 64 bits of output in both %rax and %rdx.
This doesn't affect the behaviour of the compiler, because we don't
allow partial writes at sub-word sizes. The rationale is explained
in Wrinkle [Don't allow scalar partial writes] in Note [Register formats in liveness analysis],
in GHC.CmmToAsm.Reg.Liveness.
- - - - -
9ed3ce4c by sheaf at 2025-12-18T03:53:49-05:00
Liveness analysis: consider register formats
This commit updates the register allocator to be a bit more careful in
situations in which a single register is used at multiple different
formats, e.g. when xmm1 is used both to store a Double# and a DoubleX2#.
This is done by introducing the 'Regs' newtype around 'UniqSet RegWithFormat',
for which the combining operations take the larger of the two formats
instead of overriding the format.
Operations on 'Regs' are defined in 'GHC.CmmToAsm.Reg.Regs'. There is
a modest compile-time cost for the additional overhead for tracking
register formats, which causes the metric increases of this commit.
The subtle aspects of the implementation are outlined in
Note [Register formats in liveness analysis] in GHC.CmmToAsm.Reg.Liveness.
Fixes #26411 #26611
-------------------------
Metric Increase:
T12707
T26425
T3294
-------------------------
- - - - -
2e4b9c8a by sheaf at 2025-12-18T03:53:49-05:00
Register allocator: reload at same format as spill
This commit ensures that if we spill a register onto the stack at a
given format, we then always reload the register at this same format.
This ensures we don't end up in a situation where we spill F64x2 but end
up only reloading the lower F64. This first reload would make us believe
the whole data is in a register, thus silently losing the upper 64 bits
of the spilled register's contents.
Fixes #26526
- - - - -
e3aa0add by sheaf at 2025-12-18T03:53:49-05:00
Register allocation: writes redefine format
As explained in Note [Allocated register formats] in GHC.CmmToAsm.Reg.Linear,
we consider all writes to redefine the format of the register.
This ensures that in a situation such as
movsd .Ln6m(%rip),%v1
shufpd $0,%v1,%v1
we properly consider the broadcast operation to change the format of %v1
from F64 to F64x2.
This completes the fix to #26411 (test in T26411b).
- - - - -
693c7bfc by Vladislav Zavialov at 2025-12-18T03:53:51-05:00
Parser: improve mkModuleImpExp, remove checkImportSpec
1. The `mkModuleImpExp` helper now knows whether it is processing an import or
export list item, and uses this information to produce a more accurate error
message for `import M (T(..,x))` with PatternSynonyms disabled.
The old message incorrectly referred to this case as an export form.
2. The `checkImportSpec` helper is removed in favor of more comprehensive error
checking in `mkModuleImpExp`.
3. Additionaly, the invariants of `ImpExpList` and `ImpExpAllWith` have been
made more explicit in the comments and assertions (calls to 'panic').
Test case: import-syntax-no-ext
- - - - -
55cff477 by Vladislav Zavialov at 2025-12-18T03:53:51-05:00
Subordinate namespace-specified wildcards (#25901)
Add support for subordinate namespace-specified wildcards
`X(type ..)` and `X(data ..)` to import and export lists.
Examples:
import M (Cls(type ..)) -- imports Cls and all its associated types
import M (Cls(data ..)) -- imports Cls and all its methods
module M (R(data ..), C(type ..)) where
-- exports R and all its data constructors and record fields;
-- exports C and all its associated types, but not its methods
The scope of this change is limited to the case where the wildcard is the only
subordinate import/export item, whereas the more complex forms `X(type .., f)`
or `X(type .., data ..)` are unsupported and raise the newly introduced
PsErrUnsupportedExplicitNamespace error. This restriction may be lifted later.
Summary of the changes:
1. Refactor IEThingAll to store its extension field XIEThingAll as a record
IEThingAllExt instead of a tuple.
2. Extend the AST by adding a NamespaceSpecifier field to IEThingAllExt,
representing an optional namespace specifier `type` or `data` in front
of a subordinate wildcard `X(..)`.
3. Extend the grammar in Parser.y with productions for `type ..` and `data ..`
in subordinate import/export items.
4. Introduce `filterByNamespaceGREs` to filter [GlobalRdrElt] by a
NamespaceSpecifier; use it in `filterImports` and `exports_from_avail`
to account for the namespace specifier in IEThingAll.
5. Improve diagnostics by storing more information in DodgyImportsEmptyParent
and DodgyExportsEmptyParent.
Test cases:
T25901_sub_e T25901_sub_f T25901_sub_g T25901_sub_a
T25901_sub_b T25901_sub_c T25901_sub_d T25901_sub_w
DodgyImports02 DodgyImports03 DodgyImports04
- - - - -
d9b24a2a by Recursion Ninja at 2025-12-18T03:53:51-05:00
Removing the 'Data' instance for 'InstEnv'.
The 'Data' instance is blocking work on Trees that Grow, and the
'Data' instance seem to have been added without a clear purpose.
- - - - -
a5252dae by Recursion Ninja at 2025-12-18T03:53:51-05:00
'Decouple Language.Haskell.Syntax.Decls' from 'GHC.Unit.Module.Warnings'
- - - - -
4ac5ef26 by Cheng Shao at 2025-12-18T03:53:52-05:00
testsuite: improve coverage of foundation test
This patch refactors the `foundation` test a bit to improve coverage:
- Instead of using a hard-coded seed, a random seed is now taken from
the command line, and printed upon test failure. This improves test
coverage over many future CI runs, and shall a failure occur, the
seed is available in the CI log for local reproduction.
- The iterations count is bumped to 1000 instead of 100, similar to
the bump in `test-primops`. Runtime timeout is bumped 2x just to be
safe.
- Improve `newLCGGen` by using non-atomic loads/stores on a
`MutableByteArray#` for storing mutable `Word64`, this test doesn't
use parallelism in the first place
- Fixed a few compiler warnings and removed redundant pragmas and
imports
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
58765c18 by Sylvain Henry at 2025-12-18T03:54:14-05:00
Doc: document -pgmi "" (#26634)
- - - - -
0aec37ac by Cheng Shao at 2025-12-18T03:54:16-05:00
rts: use __builtin_mul_overflow for hs_mulIntMayOflo
This patch uses `__builtin_mul_overflow` to implement
`hs_mulIntMayOflo`. This is a GNU C checked arithmetic builtin
function supported by gcc/clang, is type-generic so works for both
32-bit/64-bit, and makes the code both more efficient and easier to
read/maintain than the previous hand rolled logic.
- - - - -
09ff1a4c by Cheng Shao at 2025-12-18T03:54:17-05:00
compiler/rts: fix ABI mismatch in barf() invocations
This patch fixes a long-standing issue of ABI mismatch in `barf()`
invocations, both in compiler-emitted code and in hand written Cmm
code:
- In RTS, we have `barf()` which reports a fatal internal error
message and exits the program.
- `barf()` is a variadic C function! When used as a callee of a
foreign call with `ccall` calling convention instead of `capi`,
there is an ABI mismatch between the caller and the callee!
- Unfortunately, both the compiler and the Cmm sources contain many
places where we call `barf()` via `ccall` convention!! Like, when
you write `foreign "C" barf("foo object (%p) entered!", R1)`, it
totally doesn't do what you think it'll do at all!! The second
argument `R1` is not properly passed in `va_list`, and the behavior
is completely undefined!!
- Even more unfortunately, this issue has been sitting around long
enough because the ABI mismatch is subtle enough on normie platforms
like x64 and arm64.
- But there are platforms like wasm32 that are stricter about ABI, and
the broken `barf()` invocations already causes trouble for wasm
backend: we had to use ugly hacks like `barf(errmsg, NULL)` to make
`wasm-ld` happy, and even with this band-aid, compiler-generated
`barf()` invocations are still broken, resulting in regressions in
certain debug-related functionality, e.g. `-dtag-inference-checks`
is broken on wasm32 (#22882).
This patch properly fixes the issue:
- We add non-variadic `barf` wrappers in the RTS that can be used as
`ccall` callees
- Both the compiler `emitBarf` logic and the hand-written Cmm are
changed to call these wrappers
- `emitBarf` now also properly annotates the foreign call as
`CmmNeverReturns` to indicate it's a noreturn call to enable more
efficient code generation
`-dtag-inference-checks` now works on wasm. Closes #22882.
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
cf46d43c by Vilim Lendvaj at 2025-12-18T03:54:21-05:00
Remove outdated comment
The Traversable instance for ZipList is no longer in
GHC.Internal.Data.Traversable. In fact, it is right below this very comment.
- - - - -
4f0f6406 by Cheng Shao at 2025-12-18T03:54:22-05:00
compiler: remove unused OtherSection logic
This patch removes the OtherSection logic in Cmm, given it's never
actually used by any of our backends.
- - - - -
117 changed files:
- compiler/GHC/Builtin/Utils.hs
- compiler/GHC/Cmm.hs
- compiler/GHC/Cmm/Parser.y
- compiler/GHC/CmmToAsm/AArch64/Ppr.hs
- compiler/GHC/CmmToAsm/LA64/Ppr.hs
- compiler/GHC/CmmToAsm/PPC/Ppr.hs
- compiler/GHC/CmmToAsm/Ppr.hs
- compiler/GHC/CmmToAsm/RV64/Ppr.hs
- compiler/GHC/CmmToAsm/Reg/Graph.hs
- compiler/GHC/CmmToAsm/Reg/Graph/Coalesce.hs
- compiler/GHC/CmmToAsm/Reg/Graph/Spill.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillCost.hs
- compiler/GHC/CmmToAsm/Reg/Linear.hs
- compiler/GHC/CmmToAsm/Reg/Linear/Base.hs
- compiler/GHC/CmmToAsm/Reg/Linear/JoinToTargets.hs
- compiler/GHC/CmmToAsm/Reg/Liveness.hs
- + compiler/GHC/CmmToAsm/Reg/Regs.hs
- compiler/GHC/CmmToAsm/Reg/Target.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToAsm/X86/Ppr.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/CmmToLlvm/Data.hs
- compiler/GHC/Core/InstEnv.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/Hs/Instances.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/Iface/Warnings.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/Errors/Ppr.hs
- compiler/GHC/Parser/Errors/Types.hs
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Rename/Module.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Utils.hs
- compiler/GHC/StgToCmm/Bind.hs
- compiler/GHC/StgToCmm/Utils.hs
- compiler/GHC/Tc/Deriv.hs
- compiler/GHC/Tc/Deriv/Utils.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Errors/Types.hs
- compiler/GHC/Tc/Gen/Export.hs
- compiler/GHC/Tc/Types/Origin.hs
- compiler/GHC/Tc/Utils/Instantiate.hs
- compiler/GHC/Types/DefaultEnv.hs
- compiler/GHC/Types/Error/Codes.hs
- compiler/GHC/Types/Name/Reader.hs
- compiler/GHC/Types/Unique/FM.hs
- compiler/GHC/Types/Unique/Set.hs
- compiler/GHC/Unit/Module/Warnings.hs
- compiler/Language/Haskell/Syntax/Decls.hs
- compiler/Language/Haskell/Syntax/Extension.hs
- compiler/ghc.cabal.in
- docs/users_guide/phases.rst
- libraries/ghc-internal/src/GHC/Internal/Functor/ZipList.hs
- rts/Apply.cmm
- rts/Compact.cmm
- rts/ContinuationOps.cmm
- rts/Exception.cmm
- rts/Jumps.h
- rts/PrimOps.cmm
- rts/RtsMessages.c
- rts/StgMiscClosures.cmm
- rts/StgStartup.cmm
- rts/include/Stg.h
- rts/include/rts/Messages.h
- rts/prim/mulIntMayOflo.c
- testsuite/tests/diagnostic-codes/codes.stdout
- testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr
- testsuite/tests/numeric/should_run/all.T
- testsuite/tests/numeric/should_run/foundation.hs
- testsuite/tests/numeric/should_run/foundation.stdout
- testsuite/tests/patsyn/should_fail/all.T
- + testsuite/tests/patsyn/should_fail/import-syntax-no-ext.hs
- + testsuite/tests/patsyn/should_fail/import-syntax-no-ext.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_e.hs
- + testsuite/tests/rename/should_compile/T25901_sub_f.hs
- + testsuite/tests/rename/should_compile/T25901_sub_f.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_g.hs
- + testsuite/tests/rename/should_compile/T25901_sub_g.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_g_helper.hs
- testsuite/tests/rename/should_compile/all.T
- testsuite/tests/rename/should_fail/T23570b.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_a.hs
- + testsuite/tests/rename/should_fail/T25901_sub_a.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_b.hs
- + testsuite/tests/rename/should_fail/T25901_sub_b.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_c.hs
- + testsuite/tests/rename/should_fail/T25901_sub_c.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_c_helper.hs
- + testsuite/tests/rename/should_fail/T25901_sub_d.hs
- + testsuite/tests/rename/should_fail/T25901_sub_d.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_d_helper.hs
- + testsuite/tests/rename/should_fail/T25901_sub_w.hs
- + testsuite/tests/rename/should_fail/T25901_sub_w.stderr
- testsuite/tests/rename/should_fail/all.T
- + testsuite/tests/simd/should_run/T26411.hs
- + testsuite/tests/simd/should_run/T26411.stdout
- + testsuite/tests/simd/should_run/T26411b.hs
- + testsuite/tests/simd/should_run/T26411b.stdout
- testsuite/tests/simd/should_run/all.T
- testsuite/tests/simplStg/should_compile/all.T
- testsuite/tests/warnings/should_compile/DodgyExports03.stderr
- testsuite/tests/warnings/should_compile/DodgyImports.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports02.hs
- + testsuite/tests/warnings/should_compile/DodgyImports02.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports03.hs
- + testsuite/tests/warnings/should_compile/DodgyImports03.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports03_helper.hs
- + testsuite/tests/warnings/should_compile/DodgyImports04.hs
- + testsuite/tests/warnings/should_compile/DodgyImports04.stderr
- testsuite/tests/warnings/should_compile/DodgyImports_hiding.stderr
- testsuite/tests/warnings/should_compile/all.T
- utils/check-exact/ExactPrint.hs
- utils/genapply/Main.hs
- utils/haddock/haddock-api/src/Haddock/Interface/Create.hs
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/71846e5e7c6c48daf188a7c6649c0e…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/71846e5e7c6c48daf188a7c6649c0e…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
18 Dec '25
Zubin pushed to branch wip/ghc-9.14-final at Glasgow Haskell Compiler / GHC
Commits:
902339d3 by Zubin Duggal at 2025-12-18T11:00:51+05:30
Prepare final 9.14.1 release
- - - - -
1 changed file:
- configure.ac
Changes:
=====================================
configure.ac
=====================================
@@ -13,7 +13,7 @@ dnl
# see what flags are available. (Better yet, read the documentation!)
#
-AC_INIT([The Glorious Glasgow Haskell Compilation System], [9.14.0], [glasgow-haskell-bugs(a)haskell.org] [ghc-AC_PACKAGE_VERSION])
+AC_INIT([The Glorious Glasgow Haskell Compilation System], [9.14.1], [glasgow-haskell-bugs(a)haskell.org] [ghc-AC_PACKAGE_VERSION])
# Version on master must be X.Y (not X.Y.Z) for ProjectVersionMunged variable
# to be useful (cf #19058). However, the version must have three components
# (X.Y.Z) on stable branches (e.g. ghc-9.2) to ensure that pre-releases are
@@ -22,7 +22,7 @@ AC_INIT([The Glorious Glasgow Haskell Compilation System], [9.14.0], [glasgow-ha
AC_CONFIG_MACRO_DIRS([m4])
# Set this to YES for a released version, otherwise NO
-: ${RELEASE=NO}
+: ${RELEASE=YES}
# The primary version (e.g. 7.5, 7.4.1) is set in the AC_INIT line
# above. If this is not a released version, then we will append the
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/902339d332fb4ce2b3c87dcac1ee649…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/902339d332fb4ce2b3c87dcac1ee649…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/wasm-unlifted-ffi-bytearray] 5 commits: docs: drop obsolete warning about -fexternal-interpreter on windows
by Cheng Shao (@TerrorJack) 18 Dec '25
by Cheng Shao (@TerrorJack) 18 Dec '25
18 Dec '25
Cheng Shao pushed to branch wip/wasm-unlifted-ffi-bytearray at Glasgow Haskell Compiler / GHC
Commits:
2c2a3ef3 by Cheng Shao at 2025-12-15T11:51:53-05:00
docs: drop obsolete warning about -fexternal-interpreter on windows
This patch drops an obsolete warning about -fexternal-interpreter not
supported on windows; it is supported since a long time ago, including
the profiled way.
- - - - -
68573aa5 by Marc Scholten at 2025-12-15T11:53:00-05:00
haddock: Drop Haddock.Backends.HaddockDB as it's unused
- - - - -
b230d549 by mangoiv at 2025-12-16T15:17:45-05:00
base: generalize delete{Firsts,}By
When we delete{Firsts,}By we should not require the
lists to be the same type. This is an especially useful
generalisation in the case of deleteFirstsBy because we
can skip an invocation of the map function.
This change was discussed on the core-libraries-committee's bug
tracker at https://github.com/haskell/core-libraries-committee/issues/372.
- - - - -
6a2b43e3 by Cheng Shao at 2025-12-16T15:18:30-05:00
compiler: clean up redundant LANGUAGE pragmas
This patch bumps `default-language` of `ghc`/`ghc-bin` from `GHC2021`
to `GHC2024` (which is supported in ghc 9.10, current boot ghc lower
version bound), and also cleans up redundant `LANGUAGE` pragmas (as
well as `default-extensions`/`other-extensions`) that are already
implied by `GHC2024`.
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
bb1ffeef by Cheng Shao at 2025-12-18T01:12:57+01:00
wasm: fix handling of ByteArray#/MutableByteArray# arguments in JSFFI imports
This patch fixes the handling of ByteArray#/MutableByteArray#
arguments in JSFFI imports, see the amended note and manual for
explanation. Also adds a test to witness the fix.
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
452 changed files:
- compiler/GHC.hs
- compiler/GHC/Builtin/PrimOps.hs
- compiler/GHC/Builtin/PrimOps/Ids.hs
- compiler/GHC/Builtin/Types/Literals.hs
- compiler/GHC/ByteCode/Asm.hs
- compiler/GHC/ByteCode/Breakpoints.hs
- compiler/GHC/ByteCode/InfoTable.hs
- compiler/GHC/ByteCode/Instr.hs
- compiler/GHC/ByteCode/Linker.hs
- compiler/GHC/ByteCode/Types.hs
- compiler/GHC/Cmm.hs
- compiler/GHC/Cmm/BlockId.hs
- compiler/GHC/Cmm/CLabel.hs
- compiler/GHC/Cmm/CommonBlockElim.hs
- compiler/GHC/Cmm/Config.hs
- compiler/GHC/Cmm/ContFlowOpt.hs
- compiler/GHC/Cmm/Dataflow.hs
- compiler/GHC/Cmm/Dataflow/Block.hs
- compiler/GHC/Cmm/Dataflow/Graph.hs
- compiler/GHC/Cmm/Dataflow/Label.hs
- compiler/GHC/Cmm/DebugBlock.hs
- compiler/GHC/Cmm/Dominators.hs
- compiler/GHC/Cmm/Expr.hs
- compiler/GHC/Cmm/Graph.hs
- compiler/GHC/Cmm/Info/Build.hs
- compiler/GHC/Cmm/LRegSet.hs
- compiler/GHC/Cmm/LayoutStack.hs
- compiler/GHC/Cmm/Lint.hs
- compiler/GHC/Cmm/Liveness.hs
- compiler/GHC/Cmm/MachOp.hs
- compiler/GHC/Cmm/Node.hs
- compiler/GHC/Cmm/Parser.y
- compiler/GHC/Cmm/ProcPoint.hs
- compiler/GHC/Cmm/Reducibility.hs
- compiler/GHC/Cmm/Reg.hs
- compiler/GHC/Cmm/Sink.hs
- compiler/GHC/Cmm/Switch.hs
- compiler/GHC/Cmm/Switch/Implement.hs
- compiler/GHC/Cmm/ThreadSanitizer.hs
- compiler/GHC/Cmm/UniqueRenamer.hs
- compiler/GHC/Cmm/Utils.hs
- compiler/GHC/CmmToAsm/BlockLayout.hs
- compiler/GHC/CmmToAsm/CFG.hs
- compiler/GHC/CmmToAsm/CPrim.hs
- compiler/GHC/CmmToAsm/Dwarf/Types.hs
- compiler/GHC/CmmToAsm/Format.hs
- compiler/GHC/CmmToAsm/LA64/CodeGen.hs
- compiler/GHC/CmmToAsm/Monad.hs
- compiler/GHC/CmmToAsm/PPC/CodeGen.hs
- compiler/GHC/CmmToAsm/PPC/Ppr.hs
- compiler/GHC/CmmToAsm/RV64/CodeGen.hs
- compiler/GHC/CmmToAsm/RV64/Ppr.hs
- compiler/GHC/CmmToAsm/Reg/Graph.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillClean.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillCost.hs
- compiler/GHC/CmmToAsm/Reg/Linear/State.hs
- compiler/GHC/CmmToAsm/Reg/Linear/X86.hs
- compiler/GHC/CmmToAsm/Reg/Linear/X86_64.hs
- compiler/GHC/CmmToAsm/Wasm.hs
- compiler/GHC/CmmToAsm/Wasm/Asm.hs
- compiler/GHC/CmmToAsm/Wasm/FromCmm.hs
- compiler/GHC/CmmToAsm/Wasm/Types.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToAsm/X86/Ppr.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/CmmToLlvm/Base.hs
- compiler/GHC/CmmToLlvm/CodeGen.hs
- compiler/GHC/Core/Coercion.hs
- compiler/GHC/Core/Coercion.hs-boot
- compiler/GHC/Core/Coercion/Axiom.hs
- compiler/GHC/Core/DataCon.hs
- compiler/GHC/Core/FamInstEnv.hs
- compiler/GHC/Core/InstEnv.hs
- compiler/GHC/Core/LateCC/OverloadedCalls.hs
- compiler/GHC/Core/LateCC/TopLevelBinds.hs
- compiler/GHC/Core/Lint.hs
- compiler/GHC/Core/Lint/Interactive.hs
- compiler/GHC/Core/Map/Expr.hs
- compiler/GHC/Core/Map/Type.hs
- compiler/GHC/Core/Opt/CallerCC.hs
- compiler/GHC/Core/Opt/ConstantFold.hs
- compiler/GHC/Core/Opt/Monad.hs
- compiler/GHC/Core/Opt/SpecConstr.hs
- compiler/GHC/Core/Ppr.hs
- compiler/GHC/Core/Predicate.hs
- compiler/GHC/Core/SimpleOpt.hs
- compiler/GHC/Core/TyCo/Compare.hs
- compiler/GHC/Core/TyCo/Rep.hs
- compiler/GHC/Core/TyCon.hs
- compiler/GHC/Core/TyCon/Env.hs
- compiler/GHC/Core/Type.hs
- compiler/GHC/Core/Type.hs-boot
- compiler/GHC/Core/Unify.hs
- compiler/GHC/CoreToStg.hs
- compiler/GHC/Data/Bag.hs
- compiler/GHC/Data/FastString.hs
- compiler/GHC/Data/Graph/Collapse.hs
- compiler/GHC/Data/Graph/Color.hs
- compiler/GHC/Data/Graph/Directed.hs
- compiler/GHC/Data/List/Infinite.hs
- compiler/GHC/Data/List/NonEmpty.hs
- compiler/GHC/Data/Maybe.hs
- compiler/GHC/Data/Pair.hs
- compiler/GHC/Data/Stream.hs
- compiler/GHC/Data/Strict.hs
- compiler/GHC/Data/StringBuffer.hs
- compiler/GHC/Data/TrieMap.hs
- compiler/GHC/Data/Word64Map.hs
- compiler/GHC/Driver/Backend.hs
- compiler/GHC/Driver/Backpack.hs
- compiler/GHC/Driver/CmdLine.hs
- compiler/GHC/Driver/CodeOutput.hs
- compiler/GHC/Driver/Config/StgToCmm.hs
- compiler/GHC/Driver/Config/Tidy.hs
- compiler/GHC/Driver/Downsweep.hs
- compiler/GHC/Driver/DynFlags.hs
- compiler/GHC/Driver/Env.hs
- compiler/GHC/Driver/Env/KnotVars.hs
- compiler/GHC/Driver/Errors.hs
- compiler/GHC/Driver/Errors/Ppr.hs
- compiler/GHC/Driver/Errors/Types.hs
- compiler/GHC/Driver/Flags.hs
- compiler/GHC/Driver/GenerateCgIPEStub.hs
- compiler/GHC/Driver/Hooks.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Driver/Make.hs
- compiler/GHC/Driver/MakeSem.hs
- compiler/GHC/Driver/Pipeline.hs
- compiler/GHC/Driver/Pipeline/Execute.hs
- compiler/GHC/Driver/Pipeline/LogQueue.hs
- compiler/GHC/Driver/Pipeline/Monad.hs
- compiler/GHC/Driver/Pipeline/Phases.hs
- compiler/GHC/Driver/Plugins.hs
- compiler/GHC/Driver/Session.hs
- compiler/GHC/Driver/Session/Inspect.hs
- compiler/GHC/Driver/Session/Units.hs
- compiler/GHC/Hs.hs
- compiler/GHC/Hs/Basic.hs
- compiler/GHC/Hs/Binds.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/Hs/Doc.hs
- compiler/GHC/Hs/Doc.hs-boot
- compiler/GHC/Hs/DocString.hs
- compiler/GHC/Hs/Dump.hs
- compiler/GHC/Hs/Expr.hs
- compiler/GHC/Hs/Expr.hs-boot
- compiler/GHC/Hs/Extension.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/Hs/Instances.hs
- compiler/GHC/Hs/Lit.hs
- compiler/GHC/Hs/Pat.hs
- compiler/GHC/Hs/Pat.hs-boot
- compiler/GHC/Hs/Stats.hs
- compiler/GHC/Hs/Type.hs
- compiler/GHC/Hs/Utils.hs
- compiler/GHC/HsToCore/Arrows.hs
- compiler/GHC/HsToCore/Binds.hs
- compiler/GHC/HsToCore/Docs.hs
- compiler/GHC/HsToCore/Errors/Ppr.hs
- compiler/GHC/HsToCore/Errors/Types.hs
- compiler/GHC/HsToCore/Expr.hs
- compiler/GHC/HsToCore/Foreign/Decl.hs
- compiler/GHC/HsToCore/Foreign/Wasm.hs
- compiler/GHC/HsToCore/ListComp.hs
- compiler/GHC/HsToCore/Match.hs
- compiler/GHC/HsToCore/Match/Literal.hs
- compiler/GHC/HsToCore/Monad.hs
- compiler/GHC/HsToCore/Pmc.hs
- compiler/GHC/HsToCore/Pmc/Check.hs
- compiler/GHC/HsToCore/Pmc/Desugar.hs
- compiler/GHC/HsToCore/Pmc/Solver.hs
- compiler/GHC/HsToCore/Pmc/Solver/Types.hs
- compiler/GHC/HsToCore/Pmc/Types.hs
- compiler/GHC/HsToCore/Pmc/Utils.hs
- compiler/GHC/HsToCore/Quote.hs
- compiler/GHC/HsToCore/Utils.hs
- compiler/GHC/Iface/Binary.hs
- compiler/GHC/Iface/Decl.hs
- compiler/GHC/Iface/Env.hs
- compiler/GHC/Iface/Errors.hs
- compiler/GHC/Iface/Errors/Ppr.hs
- compiler/GHC/Iface/Errors/Types.hs
- compiler/GHC/Iface/Ext/Ast.hs
- compiler/GHC/Iface/Ext/Debug.hs
- compiler/GHC/Iface/Ext/Types.hs
- compiler/GHC/Iface/Ext/Utils.hs
- compiler/GHC/Iface/Load.hs
- compiler/GHC/Iface/Recomp.hs
- compiler/GHC/Iface/Rename.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/Iface/Tidy.hs
- compiler/GHC/Iface/Type.hs
- compiler/GHC/IfaceToCore.hs
- compiler/GHC/JS/Ident.hs
- compiler/GHC/JS/JStg/Monad.hs
- compiler/GHC/JS/JStg/Syntax.hs
- compiler/GHC/JS/Make.hs
- compiler/GHC/JS/Optimizer.hs
- compiler/GHC/JS/Ppr.hs
- compiler/GHC/JS/Syntax.hs
- compiler/GHC/JS/Transform.hs
- compiler/GHC/Linker/Deps.hs
- compiler/GHC/Linker/Loader.hs
- compiler/GHC/Linker/Types.hs
- compiler/GHC/Llvm/MetaData.hs
- compiler/GHC/Llvm/Ppr.hs
- compiler/GHC/Llvm/Types.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/Annotation.hs
- compiler/GHC/Parser/Errors/Basic.hs
- compiler/GHC/Parser/Errors/Ppr.hs
- compiler/GHC/Parser/Errors/Types.hs
- compiler/GHC/Parser/Lexer.x
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Parser/PostProcess/Haddock.hs
- compiler/GHC/Parser/String.hs
- compiler/GHC/Parser/Types.hs
- compiler/GHC/Platform.hs
- compiler/GHC/Platform/Reg/Class.hs
- compiler/GHC/Platform/Reg/Class/NoVectors.hs
- compiler/GHC/Platform/Reg/Class/Separate.hs
- compiler/GHC/Platform/Reg/Class/Unified.hs
- compiler/GHC/Rename/Bind.hs
- compiler/GHC/Rename/Env.hs
- compiler/GHC/Rename/Expr.hs
- compiler/GHC/Rename/Expr.hs-boot
- compiler/GHC/Rename/HsType.hs
- compiler/GHC/Rename/Module.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Pat.hs
- compiler/GHC/Rename/Splice.hs
- compiler/GHC/Rename/Unbound.hs
- compiler/GHC/Rename/Utils.hs
- compiler/GHC/Runtime/Eval.hs
- compiler/GHC/Runtime/Heap/Layout.hs
- compiler/GHC/Runtime/Interpreter.hs
- compiler/GHC/Runtime/Interpreter/JS.hs
- compiler/GHC/Runtime/Interpreter/Process.hs
- compiler/GHC/Runtime/Interpreter/Types.hs
- compiler/GHC/Runtime/Interpreter/Types/SymbolCache.hs
- compiler/GHC/Settings/IO.hs
- compiler/GHC/Stg/Debug.hs
- compiler/GHC/Stg/EnforceEpt.hs
- compiler/GHC/Stg/EnforceEpt/Rewrite.hs
- compiler/GHC/Stg/EnforceEpt/TagSig.hs
- compiler/GHC/Stg/EnforceEpt/Types.hs
- compiler/GHC/Stg/FVs.hs
- compiler/GHC/Stg/Lift/Analysis.hs
- compiler/GHC/Stg/Lift/Monad.hs
- compiler/GHC/Stg/Lift/Types.hs
- compiler/GHC/Stg/Lint.hs
- compiler/GHC/Stg/Pipeline.hs
- compiler/GHC/Stg/Syntax.hs
- compiler/GHC/Stg/Unarise.hs
- compiler/GHC/Stg/Utils.hs
- compiler/GHC/StgToByteCode.hs
- compiler/GHC/StgToCmm.hs
- compiler/GHC/StgToCmm/ArgRep.hs
- compiler/GHC/StgToCmm/CgUtils.hs
- compiler/GHC/StgToCmm/Closure.hs
- compiler/GHC/StgToCmm/ExtCode.hs
- compiler/GHC/StgToCmm/Lit.hs
- compiler/GHC/StgToCmm/Monad.hs
- compiler/GHC/StgToCmm/Prim.hs
- compiler/GHC/StgToCmm/Utils.hs
- compiler/GHC/StgToJS/Apply.hs
- compiler/GHC/StgToJS/Arg.hs
- compiler/GHC/StgToJS/CodeGen.hs
- compiler/GHC/StgToJS/DataCon.hs
- compiler/GHC/StgToJS/Deps.hs
- compiler/GHC/StgToJS/Expr.hs
- compiler/GHC/StgToJS/ExprCtx.hs
- compiler/GHC/StgToJS/FFI.hs
- compiler/GHC/StgToJS/Heap.hs
- compiler/GHC/StgToJS/Linker/Linker.hs
- compiler/GHC/StgToJS/Linker/Opt.hs
- compiler/GHC/StgToJS/Linker/Types.hs
- compiler/GHC/StgToJS/Literal.hs
- compiler/GHC/StgToJS/Monad.hs
- compiler/GHC/StgToJS/Object.hs
- compiler/GHC/StgToJS/Rts/Rts.hs
- compiler/GHC/StgToJS/Rts/Types.hs
- compiler/GHC/StgToJS/Sinker/Collect.hs
- compiler/GHC/StgToJS/Sinker/Sinker.hs
- compiler/GHC/StgToJS/Sinker/StringsUnfloat.hs
- compiler/GHC/StgToJS/Types.hs
- compiler/GHC/StgToJS/Utils.hs
- compiler/GHC/SysTools.hs
- compiler/GHC/SysTools/Ar.hs
- compiler/GHC/SysTools/BaseDir.hs
- compiler/GHC/SysTools/Cpp.hs
- compiler/GHC/SysTools/Tasks.hs
- compiler/GHC/SysTools/Terminal.hs
- compiler/GHC/Tc/Deriv.hs
- compiler/GHC/Tc/Deriv/Functor.hs
- compiler/GHC/Tc/Deriv/Generate.hs
- compiler/GHC/Tc/Deriv/Generics.hs
- compiler/GHC/Tc/Errors.hs
- compiler/GHC/Tc/Errors/Hole.hs
- compiler/GHC/Tc/Errors/Hole/FitTypes.hs
- compiler/GHC/Tc/Errors/Hole/Plugin.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Errors/Types.hs
- compiler/GHC/Tc/Errors/Types/PromotionErr.hs
- compiler/GHC/Tc/Gen/Annotation.hs
- compiler/GHC/Tc/Gen/App.hs
- compiler/GHC/Tc/Gen/Arrow.hs
- compiler/GHC/Tc/Gen/Bind.hs
- compiler/GHC/Tc/Gen/Default.hs
- compiler/GHC/Tc/Gen/Do.hs
- compiler/GHC/Tc/Gen/Export.hs
- compiler/GHC/Tc/Gen/Expr.hs
- compiler/GHC/Tc/Gen/Foreign.hs
- compiler/GHC/Tc/Gen/Head.hs
- compiler/GHC/Tc/Gen/HsType.hs
- compiler/GHC/Tc/Gen/Match.hs
- compiler/GHC/Tc/Gen/Pat.hs
- compiler/GHC/Tc/Gen/Splice.hs
- compiler/GHC/Tc/Instance/Family.hs
- compiler/GHC/Tc/Instance/FunDeps.hs
- compiler/GHC/Tc/Instance/Typeable.hs
- compiler/GHC/Tc/Module.hs
- compiler/GHC/Tc/Solver.hs
- compiler/GHC/Tc/Solver/Equality.hs
- compiler/GHC/Tc/Solver/InertSet.hs
- compiler/GHC/Tc/Solver/Irred.hs
- compiler/GHC/Tc/Solver/Monad.hs
- compiler/GHC/Tc/Solver/Types.hs
- compiler/GHC/Tc/TyCl.hs
- compiler/GHC/Tc/TyCl/Instance.hs
- compiler/GHC/Tc/TyCl/PatSyn.hs
- compiler/GHC/Tc/TyCl/Utils.hs
- compiler/GHC/Tc/Types.hs
- compiler/GHC/Tc/Types/Constraint.hs
- compiler/GHC/Tc/Types/ErrCtxt.hs
- compiler/GHC/Tc/Types/Evidence.hs
- compiler/GHC/Tc/Types/Origin.hs
- compiler/GHC/Tc/Utils/Backpack.hs
- compiler/GHC/Tc/Utils/Env.hs
- compiler/GHC/Tc/Utils/Instantiate.hs
- compiler/GHC/Tc/Utils/TcMType.hs
- compiler/GHC/Tc/Utils/TcType.hs
- compiler/GHC/Tc/Utils/Unify.hs
- compiler/GHC/Tc/Validity.hs
- compiler/GHC/Tc/Zonk/Monad.hs
- compiler/GHC/Tc/Zonk/Type.hs
- compiler/GHC/ThToHs.hs
- compiler/GHC/Types/Annotations.hs
- compiler/GHC/Types/Avail.hs
- compiler/GHC/Types/Basic.hs
- compiler/GHC/Types/CompleteMatch.hs
- compiler/GHC/Types/CostCentre.hs
- compiler/GHC/Types/CostCentre/State.hs
- compiler/GHC/Types/DefaultEnv.hs
- compiler/GHC/Types/Demand.hs
- compiler/GHC/Types/Error.hs
- compiler/GHC/Types/Error/Codes.hs
- compiler/GHC/Types/FieldLabel.hs
- compiler/GHC/Types/Fixity.hs
- compiler/GHC/Types/ForeignCall.hs
- compiler/GHC/Types/ForeignStubs.hs
- compiler/GHC/Types/GREInfo.hs
- compiler/GHC/Types/Hint.hs
- compiler/GHC/Types/Hint/Ppr.hs
- compiler/GHC/Types/Id/Info.hs
- compiler/GHC/Types/Id/Make.hs
- compiler/GHC/Types/Literal.hs
- compiler/GHC/Types/Name.hs
- compiler/GHC/Types/Name/Cache.hs
- compiler/GHC/Types/Name/Occurrence.hs
- compiler/GHC/Types/Name/Reader.hs
- compiler/GHC/Types/Name/Set.hs
- compiler/GHC/Types/PkgQual.hs
- compiler/GHC/Types/RepType.hs
- compiler/GHC/Types/SaneDouble.hs
- compiler/GHC/Types/SourceText.hs
- compiler/GHC/Types/SrcLoc.hs
- compiler/GHC/Types/Tickish.hs
- compiler/GHC/Types/TyThing.hs
- compiler/GHC/Types/Unique/DFM.hs
- compiler/GHC/Types/Unique/DSet.hs
- compiler/GHC/Types/Unique/FM.hs
- compiler/GHC/Types/Unique/Map.hs
- compiler/GHC/Types/Unique/SDFM.hs
- compiler/GHC/Types/Unique/Set.hs
- compiler/GHC/Types/Var.hs
- compiler/GHC/Unit.hs
- compiler/GHC/Unit/Env.hs
- compiler/GHC/Unit/Finder.hs
- compiler/GHC/Unit/Home/PackageTable.hs
- compiler/GHC/Unit/Info.hs
- compiler/GHC/Unit/Module.hs
- compiler/GHC/Unit/Module/Deps.hs
- compiler/GHC/Unit/Module/Graph.hs
- compiler/GHC/Unit/Module/ModIface.hs
- compiler/GHC/Unit/Module/ModSummary.hs
- compiler/GHC/Unit/Module/Status.hs
- compiler/GHC/Unit/Module/Warnings.hs
- compiler/GHC/Unit/Module/WholeCoreBindings.hs
- compiler/GHC/Unit/State.hs
- compiler/GHC/Unit/Types.hs
- compiler/GHC/Unit/Types.hs-boot
- compiler/GHC/Utils/Binary.hs
- compiler/GHC/Utils/Binary/Typeable.hs
- compiler/GHC/Utils/Exception.hs
- compiler/GHC/Utils/Json.hs
- compiler/GHC/Utils/Logger.hs
- compiler/GHC/Utils/Misc.hs
- compiler/GHC/Utils/Monad/Codensity.hs
- compiler/GHC/Utils/Outputable.hs
- compiler/GHC/Utils/Panic.hs
- compiler/GHC/Utils/Panic/Plain.hs
- compiler/GHC/Wasm/ControlFlow.hs
- compiler/GHC/Wasm/ControlFlow/FromCmm.hs
- compiler/Language/Haskell/Syntax.hs
- compiler/Language/Haskell/Syntax/Basic.hs
- compiler/Language/Haskell/Syntax/Binds.hs
- compiler/Language/Haskell/Syntax/Decls.hs
- compiler/Language/Haskell/Syntax/Expr.hs
- compiler/Language/Haskell/Syntax/Expr.hs-boot
- compiler/Language/Haskell/Syntax/Extension.hs
- compiler/Language/Haskell/Syntax/ImpExp.hs
- compiler/Language/Haskell/Syntax/Lit.hs
- compiler/Language/Haskell/Syntax/Pat.hs
- compiler/Language/Haskell/Syntax/Pat.hs-boot
- compiler/Language/Haskell/Syntax/Type.hs
- compiler/ghc.cabal.in
- docs/users_guide/ghci.rst
- docs/users_guide/wasm.rst
- ghc/GHC/Driver/Session/Lint.hs
- ghc/GHC/Driver/Session/Mode.hs
- ghc/GHCi/Leak.hs
- ghc/GHCi/UI.hs
- ghc/GHCi/UI/Exception.hs
- ghc/GHCi/UI/Info.hs
- ghc/GHCi/UI/Monad.hs
- ghc/Main.hs
- ghc/ghc-bin.cabal.in
- libraries/base/changelog.md
- libraries/ghc-internal/src/GHC/Internal/Data/OldList.hs
- testsuite/tests/interface-stability/base-exports.stdout
- testsuite/tests/interface-stability/base-exports.stdout-javascript-unknown-ghcjs
- testsuite/tests/interface-stability/base-exports.stdout-mingw32
- testsuite/tests/interface-stability/base-exports.stdout-ws-32
- testsuite/tests/jsffi/all.T
- + testsuite/tests/jsffi/bytearrayarg.hs
- + testsuite/tests/jsffi/bytearrayarg.mjs
- + testsuite/tests/jsffi/bytearrayarg.stdout
- testsuite/tests/perf/should_run/all.T
- utils/haddock/haddock-api/haddock-api.cabal
- − utils/haddock/haddock-api/src/Haddock/Backends/HaddockDB.hs
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/8dddfef275db6ff3af0d410fbae45b…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/8dddfef275db6ff3af0d410fbae45b…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/ghc-9.14-final] 2 commits: rel-notes: updates for final 9.14.1 release
by Zubin (@wz1000) 18 Dec '25
by Zubin (@wz1000) 18 Dec '25
18 Dec '25
Zubin pushed to branch wip/ghc-9.14-final at Glasgow Haskell Compiler / GHC
Commits:
9589591f by Zubin Duggal at 2025-12-18T02:13:34+05:30
rel-notes: updates for final 9.14.1 release
- - - - -
b6175085 by Zubin Duggal at 2025-12-18T02:13:34+05:30
Prepare final 9.14.1 release
- - - - -
3 changed files:
- configure.ac
- docs/users_guide/9.14.1-notes.rst
- libraries/base/changelog.md
Changes:
=====================================
configure.ac
=====================================
@@ -22,7 +22,7 @@ AC_INIT([The Glorious Glasgow Haskell Compilation System], [9.14.0], [glasgow-ha
AC_CONFIG_MACRO_DIRS([m4])
# Set this to YES for a released version, otherwise NO
-: ${RELEASE=NO}
+: ${RELEASE=YES}
# The primary version (e.g. 7.5, 7.4.1) is set in the AC_INIT line
# above. If this is not a released version, then we will append the
=====================================
docs/users_guide/9.14.1-notes.rst
=====================================
@@ -110,6 +110,9 @@ Language
- Explicit level import support, allowing ``import`` declarations to explicitly
state which compilation stages they are are visible to.
+- Fix handling of tabs in string gaps (:ghc-ticket:`26415`). Tabs are now
+ correctly treated as whitespace in string gaps, matching the Haskell Report.
+
Compiler
~~~~~~~~
@@ -160,6 +163,23 @@ Compiler
- Initial native code generator support for the LoongArch CPU architecture.
+- Several fixes to :extension:`DeepSubsumption` type checking, improving handling
+ of higher-rank types in various contexts (:ghc-ticket:`26225`, :ghc-ticket:`26255`,
+ :ghc-ticket:`26277`, :ghc-ticket:`26331`, :ghc-ticket:`26332`).
+
+- Fix a scoping error in the Specialiser that could cause incorrect code generation
+ with :ghc-flag:`-fpolymorphic-specialisation` (:ghc-ticket:`26329`).
+
+- Fix a long-standing bug in the coercion optimiser that could produce invalid
+ coercions for ``ForAllCo`` (:ghc-ticket:`26345`).
+
+- Fix the type-family occurs check in unification (:ghc-ticket:`26457`).
+
+- Fix solving of forall-constraints (quantified constraints) to avoid infinite
+ loops in certain cases (:ghc-ticket:`26314`, :ghc-ticket:`26315`, :ghc-ticket:`26376`).
+
+- Fix reporting of redundant constraints on default-method declarations
+ (:ghc-ticket:`25992`).
GHCi
~~~~
@@ -188,6 +208,12 @@ GHCi
debugging clients
* Internal refactorings towards making the debugger multi-thread aware (:ghc-ticket:`26064`)
+- Fix bytecode generation for unsaturated applications of data constructor
+ workers (:ghc-ticket:`23210`).
+
+- Fix bytecode to use 32 bits for breakpoint indices, allowing more breakpoints
+ in large modules (:ghc-ticket:`26325`).
+
WebAssembly backend
~~~~~~~~~~~~~~~~~~~
@@ -201,6 +227,18 @@ See the blog post on `Tweag's blog
<https://www.tweag.io/blog/2025-04-17-wasm-ghci-browser/>`_ for more
information.
+- Fix handling of forward declared ``GOT.func`` items in the wasm dynamic
+ linker (:ghc-ticket:`26430`).
+
+- Fix ``setKeepCAFs()`` to be properly called during wasm GHCi initialization
+ (:ghc-ticket:`26106`).
+
+- Fix JSFFI initialization constructor code to avoid clashing with user-defined
+ main functions.
+
+- Improve error handling in the JavaScript linker when library directories
+ are misconfigured (:ghc-ticket:`26383`).
+
Runtime system
~~~~~~~~~~~~~~
@@ -212,17 +250,44 @@ Runtime system
- Reorganise how certain symbols are linked to avoid a bootstrapping failure
with the linker shipping newer macOS versions (:ghc-ticket:`26166`)
+- Fix eager black holes handling: properly record mutated closures and fix
+ an incorrect assertion that could cause issues with multiple threads racing
+ to claim a black hole (:ghc-ticket:`26495`)
+
+- Fix the Windows runtime linker to copy DLL path strings before inserting
+ them into the cache, preventing use-after-free issues (:ghc-ticket:`26613`)
+
+- Fix lost wakeups in ``threadPaused`` for threads blocked on black holes,
+ which could cause hangs in concurrent programs (:ghc-ticket:`26324`).
+
+- Fix heap reservation logic on POSIX systems to avoid infinite loops when
+ the OS repeatedly returns low memory addresses (:ghc-ticket:`26151`).
+
+- Fix handling of ``WHITEHOLE`` closures in ``scavenge_one`` when using the
+ non-moving garbage collector (:ghc-ticket:`26204`).
+
+- Fix alignment for ``gen_workspace`` on s390x to allow bootstrap on that
+ platform (:ghc-ticket:`26334`).
+
+- Push the correct update frame type in ``stg_AP_STACK`` for eager black holes.
+
``base`` library
~~~~~~~~~~~~~~~~
- Updated to `Unicode 17.0.0 <https://www.unicode.org/versions/Unicode17.0.0>`_.
+- Removed unstable heap representation details from ``GHC.Exts`` (:ghc-ticket:`25110`).
+
``ghc-prim`` library
~~~~~~~~~~~~~~~~~~~~
``ghc-prim`` is now a legacy interface providing access to primitive operations
and types which are now also exposed via the ``ghc-experimental`` package.
+- A new primop ``annotateStack#`` has been added, allowing arbitrary data to be
+ pushed onto the call stack for later extraction when decoding stack traces
+ (:ghc-ticket:`26218`).
+
``ghc`` library
~~~~~~~~~~~~~~~
@@ -263,6 +328,16 @@ and types which are now also exposed via the ``ghc-experimental`` package.
reading of the relevant Closure attributes without reliance on incomplete
selectors.
+* Fix a race condition with profiling builds (:ghc-ticket:`15197`, :ghc-ticket:`26407`).
+
+* Fix stack decoding when using the profiled runtime (:ghc-ticket:`26507`).
+
+``ghc-internal`` library
+~~~~~~~~~~~~~~~~~~~~~~~~
+
+* Fix ``naturalAndNot`` for the ``NB``/``NS`` (native bignum) case
+ (:ghc-ticket:`26230`).
+
``ghc-experimental`` library
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
=====================================
libraries/base/changelog.md
=====================================
@@ -1,6 +1,6 @@
# Changelog for [`base` package](http://hackage.haskell.org/package/base)
-## 4.22.0.0 *TBA*
+## 4.22.0.0 *December 2025*
* Shipped with GHC 9.14.1
* The internal `GHC.Weak.Finalize.runFinalizerBatch` function has been deprecated ([CLC proposal #342](https://github.com/haskell/core-libraries-committee/issues/342))
* Define `displayException` of `SomeAsyncException` to unwrap the exception.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/b75850afff8c5c8ac8ed5775ead6a4…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/b75850afff8c5c8ac8ed5775ead6a4…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/terrorjack/asan] 2 commits: rts: add ASAN instrumentation to mblock allocator
by Cheng Shao (@TerrorJack) 18 Dec '25
by Cheng Shao (@TerrorJack) 18 Dec '25
18 Dec '25
Cheng Shao pushed to branch wip/terrorjack/asan at Glasgow Haskell Compiler / GHC
Commits:
54e1c714 by Cheng Shao at 2025-12-17T21:24:57+01:00
rts: add ASAN instrumentation to mblock allocator
- - - - -
bc23bc7a by Cheng Shao at 2025-12-17T21:25:05+01:00
rts: add ASAN instrumentation to per-Task InCall free list
- - - - -
5 changed files:
- rts/Task.c
- rts/include/Stg.h
- + rts/include/rts/ASANUtils.h
- rts/rts.cabal
- rts/sm/MBlock.c
Changes:
=====================================
rts/Task.c
=====================================
@@ -183,6 +183,7 @@ freeTask (Task *task)
stgFree(incall);
}
for (incall = task->spare_incalls; incall != NULL; incall = next) {
+ __ghc_asan_unpoison_memory_region(incall, sizeof(InCall));
next = incall->next;
stgFree(incall);
}
@@ -252,6 +253,7 @@ newInCall (Task *task)
if (task->spare_incalls != NULL) {
incall = task->spare_incalls;
+ __ghc_asan_unpoison_memory_region(incall, sizeof(InCall));
task->spare_incalls = incall->next;
task->n_spare_incalls--;
} else {
@@ -283,6 +285,7 @@ endInCall (Task *task)
stgFree(incall);
} else {
incall->next = task->spare_incalls;
+ __ghc_asan_poison_memory_region(incall, sizeof(InCall));
task->spare_incalls = incall;
task->n_spare_incalls++;
}
=====================================
rts/include/Stg.h
=====================================
@@ -335,6 +335,7 @@ external prototype return neither of these types to workaround #11395.
#include "stg/MachRegsForHost.h"
#include "stg/Regs.h"
#include "stg/Ticky.h"
+#include "rts/ASANUtils.h"
#include "rts/TSANUtils.h"
#if IN_STG_CODE
=====================================
rts/include/rts/ASANUtils.h
=====================================
@@ -0,0 +1,33 @@
+#pragma once
+
+#if defined(__SANITIZE_ADDRESS__)
+#define ASAN_ENABLED
+#elif defined(__has_feature)
+#if __has_feature(address_sanitizer)
+#define ASAN_ENABLED
+#endif
+#endif
+
+#if defined(ASAN_ENABLED)
+#include <sanitizer/asan_interface.h>
+#define USED_IF_ASAN
+#else
+#include <stdlib.h>
+#define USED_IF_ASAN __attribute__((unused))
+#endif
+
+static inline void
+__ghc_asan_poison_memory_region(void const volatile *addr USED_IF_ASAN,
+ size_t size USED_IF_ASAN) {
+#if defined(ASAN_ENABLED)
+ __asan_poison_memory_region(addr, size);
+#endif
+}
+
+static inline void
+__ghc_asan_unpoison_memory_region(void const volatile *addr USED_IF_ASAN,
+ size_t size USED_IF_ASAN) {
+#if defined(ASAN_ENABLED)
+ __asan_unpoison_memory_region(addr, size);
+#endif
+}
=====================================
rts/rts.cabal
=====================================
@@ -289,6 +289,7 @@ library
-- ^ generated
rts/ghc_ffi.h
rts/Adjustor.h
+ rts/ASANUtils.h
rts/ExecPage.h
rts/BlockSignals.h
rts/Bytecodes.h
=====================================
rts/sm/MBlock.c
=====================================
@@ -579,6 +579,8 @@ getMBlocks(uint32_t n)
ret = getCommittedMBlocks(n);
+ __ghc_asan_unpoison_memory_region(ret, (W_)n * MBLOCK_SIZE);
+
debugTrace(DEBUG_gc, "allocated %d megablock(s) at %p",n,ret);
mblocks_allocated += n;
@@ -611,6 +613,8 @@ freeMBlocks(void *addr, uint32_t n)
mblocks_allocated -= n;
+ __ghc_asan_poison_memory_region(addr, (W_)n * MBLOCK_SIZE);
+
decommitMBlocks(addr, n);
}
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d8793b80e396108d886d7fa99361a6…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d8793b80e396108d886d7fa99361a6…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/marge_bot_batch_merge_job] 13 commits: X86 CodeGen: fix assign_eax_sse_regs
by Marge Bot (@marge-bot) 18 Dec '25
by Marge Bot (@marge-bot) 18 Dec '25
18 Dec '25
Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC
Commits:
fc207593 by sheaf at 2025-12-17T14:59:34-05:00
X86 CodeGen: fix assign_eax_sse_regs
We must set %al to the number of SSE2 registers that contain arguments
(in case we are dealing with a varargs function). The logic for counting
how many arguments reside in SSE2 registers was incorrect, as it used
'isFloatFormat', which incorrectly ignores vector registers.
We now instead do case analysis on the register class:
is_sse_reg r =
case targetClassOfReg platform r of
RcFloatOrVector -> True
RcInteger -> False
This change is necessary to prevent segfaults in T20030_test1j, because
subsequent commits change the format calculations, resulting in vector
formats more often.
- - - - -
a430c6cf by sheaf at 2025-12-17T14:59:34-05:00
X86 regUsageOfInstr: fix format for IMUL
When used with 8-bit operands, the IMUL instruction returns the result
in the lower 16 bits of %rax (also known as %ax). This is different
than for the other sizes, where an input at 16, 32 or 64 bits will
result in 16, 32 or 64 bits of output in both %rax and %rdx.
This doesn't affect the behaviour of the compiler, because we don't
allow partial writes at sub-word sizes. The rationale is explained
in Wrinkle [Don't allow scalar partial writes] in Note [Register formats in liveness analysis],
in GHC.CmmToAsm.Reg.Liveness.
- - - - -
0c801264 by sheaf at 2025-12-17T14:59:34-05:00
Liveness analysis: consider register formats
This commit updates the register allocator to be a bit more careful in
situations in which a single register is used at multiple different
formats, e.g. when xmm1 is used both to store a Double# and a DoubleX2#.
This is done by introducing the 'Regs' newtype around 'UniqSet RegWithFormat',
for which the combining operations take the larger of the two formats
instead of overriding the format.
Operations on 'Regs' are defined in 'GHC.CmmToAsm.Reg.Regs'. There is
a modest compile-time cost for the additional overhead for tracking
register formats, which causes the metric increases of this commit.
The subtle aspects of the implementation are outlined in
Note [Register formats in liveness analysis] in GHC.CmmToAsm.Reg.Liveness.
Fixes #26411 #26611
-------------------------
Metric Increase:
T12707
T26425
T3294
-------------------------
- - - - -
1f1fc7f0 by sheaf at 2025-12-17T14:59:34-05:00
Register allocator: reload at same format as spill
This commit ensures that if we spill a register onto the stack at a
given format, we then always reload the register at this same format.
This ensures we don't end up in a situation where we spill F64x2 but end
up only reloading the lower F64. This first reload would make us believe
the whole data is in a register, thus silently losing the upper 64 bits
of the spilled register's contents.
Fixes #26526
- - - - -
b1a5dcc3 by sheaf at 2025-12-17T14:59:34-05:00
Register allocation: writes redefine format
As explained in Note [Allocated register formats] in GHC.CmmToAsm.Reg.Linear,
we consider all writes to redefine the format of the register.
This ensures that in a situation such as
movsd .Ln6m(%rip),%v1
shufpd $0,%v1,%v1
we properly consider the broadcast operation to change the format of %v1
from F64 to F64x2.
This completes the fix to #26411 (test in T26411b).
- - - - -
177d9a60 by Vladislav Zavialov at 2025-12-17T14:59:35-05:00
Parser: improve mkModuleImpExp, remove checkImportSpec
1. The `mkModuleImpExp` helper now knows whether it is processing an import or
export list item, and uses this information to produce a more accurate error
message for `import M (T(..,x))` with PatternSynonyms disabled.
The old message incorrectly referred to this case as an export form.
2. The `checkImportSpec` helper is removed in favor of more comprehensive error
checking in `mkModuleImpExp`.
3. Additionaly, the invariants of `ImpExpList` and `ImpExpAllWith` have been
made more explicit in the comments and assertions (calls to 'panic').
Test case: import-syntax-no-ext
- - - - -
e669d00e by Vladislav Zavialov at 2025-12-17T14:59:36-05:00
Subordinate namespace-specified wildcards (#25901)
Add support for subordinate namespace-specified wildcards
`X(type ..)` and `X(data ..)` to import and export lists.
Examples:
import M (Cls(type ..)) -- imports Cls and all its associated types
import M (Cls(data ..)) -- imports Cls and all its methods
module M (R(data ..), C(type ..)) where
-- exports R and all its data constructors and record fields;
-- exports C and all its associated types, but not its methods
The scope of this change is limited to the case where the wildcard is the only
subordinate import/export item, whereas the more complex forms `X(type .., f)`
or `X(type .., data ..)` are unsupported and raise the newly introduced
PsErrUnsupportedExplicitNamespace error. This restriction may be lifted later.
Summary of the changes:
1. Refactor IEThingAll to store its extension field XIEThingAll as a record
IEThingAllExt instead of a tuple.
2. Extend the AST by adding a NamespaceSpecifier field to IEThingAllExt,
representing an optional namespace specifier `type` or `data` in front
of a subordinate wildcard `X(..)`.
3. Extend the grammar in Parser.y with productions for `type ..` and `data ..`
in subordinate import/export items.
4. Introduce `filterByNamespaceGREs` to filter [GlobalRdrElt] by a
NamespaceSpecifier; use it in `filterImports` and `exports_from_avail`
to account for the namespace specifier in IEThingAll.
5. Improve diagnostics by storing more information in DodgyImportsEmptyParent
and DodgyExportsEmptyParent.
Test cases:
T25901_sub_e T25901_sub_f T25901_sub_g T25901_sub_a
T25901_sub_b T25901_sub_c T25901_sub_d T25901_sub_w
DodgyImports02 DodgyImports03 DodgyImports04
- - - - -
1f12bb67 by Recursion Ninja at 2025-12-17T14:59:36-05:00
Removing the 'Data' instance for 'InstEnv'.
The 'Data' instance is blocking work on Trees that Grow, and the
'Data' instance seem to have been added without a clear purpose.
- - - - -
5f6f8b7b by Recursion Ninja at 2025-12-17T14:59:37-05:00
'Decouple Language.Haskell.Syntax.Decls' from 'GHC.Unit.Module.Warnings'
- - - - -
0cea194b by Sylvain Henry at 2025-12-17T14:59:59-05:00
Doc: document -pgmi "" (#26634)
- - - - -
bffb177e by Cheng Shao at 2025-12-17T15:00:02-05:00
rts: use __builtin_mul_overflow for hs_mulIntMayOflo
This patch uses `__builtin_mul_overflow` to implement
`hs_mulIntMayOflo`. This is a GNU C checked arithmetic builtin
function supported by gcc/clang, is type-generic so works for both
32-bit/64-bit, and makes the code both more efficient and easier to
read/maintain than the previous hand rolled logic.
- - - - -
a9de370a by Cheng Shao at 2025-12-17T15:00:03-05:00
compiler/rts: fix ABI mismatch in barf() invocations
This patch fixes a long-standing issue of ABI mismatch in `barf()`
invocations, both in compiler-emitted code and in hand written Cmm
code:
- In RTS, we have `barf()` which reports a fatal internal error
message and exits the program.
- `barf()` is a variadic C function! When used as a callee of a
foreign call with `ccall` calling convention instead of `capi`,
there is an ABI mismatch between the caller and the callee!
- Unfortunately, both the compiler and the Cmm sources contain many
places where we call `barf()` via `ccall` convention!! Like, when
you write `foreign "C" barf("foo object (%p) entered!", R1)`, it
totally doesn't do what you think it'll do at all!! The second
argument `R1` is not properly passed in `va_list`, and the behavior
is completely undefined!!
- Even more unfortunately, this issue has been sitting around long
enough because the ABI mismatch is subtle enough on normie platforms
like x64 and arm64.
- But there are platforms like wasm32 that are stricter about ABI, and
the broken `barf()` invocations already causes trouble for wasm
backend: we had to use ugly hacks like `barf(errmsg, NULL)` to make
`wasm-ld` happy, and even with this band-aid, compiler-generated
`barf()` invocations are still broken, resulting in regressions in
certain debug-related functionality, e.g. `-dtag-inference-checks`
is broken on wasm32 (#22882).
This patch properly fixes the issue:
- We add non-variadic `barf` wrappers in the RTS that can be used as
`ccall` callees
- Both the compiler `emitBarf` logic and the hand-written Cmm are
changed to call these wrappers
- `emitBarf` now also properly annotates the foreign call as
`CmmNeverReturns` to indicate it's a noreturn call to enable more
efficient code generation
`-dtag-inference-checks` now works on wasm. Closes #22882.
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
71846e5e by Vilim Lendvaj at 2025-12-17T15:00:07-05:00
Remove outdated comment
The Traversable instance for ZipList is no longer in
GHC.Internal.Data.Traversable. In fact, it is right below this very comment.
- - - - -
105 changed files:
- compiler/GHC/Builtin/Utils.hs
- compiler/GHC/CmmToAsm/Reg/Graph.hs
- compiler/GHC/CmmToAsm/Reg/Graph/Coalesce.hs
- compiler/GHC/CmmToAsm/Reg/Graph/Spill.hs
- compiler/GHC/CmmToAsm/Reg/Graph/SpillCost.hs
- compiler/GHC/CmmToAsm/Reg/Linear.hs
- compiler/GHC/CmmToAsm/Reg/Linear/Base.hs
- compiler/GHC/CmmToAsm/Reg/Linear/JoinToTargets.hs
- compiler/GHC/CmmToAsm/Reg/Liveness.hs
- + compiler/GHC/CmmToAsm/Reg/Regs.hs
- compiler/GHC/CmmToAsm/Reg/Target.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/Core/InstEnv.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/Hs/Instances.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/Iface/Warnings.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/Errors/Ppr.hs
- compiler/GHC/Parser/Errors/Types.hs
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Rename/Module.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Utils.hs
- compiler/GHC/StgToCmm/Bind.hs
- compiler/GHC/StgToCmm/Utils.hs
- compiler/GHC/Tc/Deriv.hs
- compiler/GHC/Tc/Deriv/Utils.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Errors/Types.hs
- compiler/GHC/Tc/Gen/Export.hs
- compiler/GHC/Tc/Types/Origin.hs
- compiler/GHC/Tc/Utils/Instantiate.hs
- compiler/GHC/Types/DefaultEnv.hs
- compiler/GHC/Types/Error/Codes.hs
- compiler/GHC/Types/Name/Reader.hs
- compiler/GHC/Types/Unique/FM.hs
- compiler/GHC/Types/Unique/Set.hs
- compiler/GHC/Unit/Module/Warnings.hs
- compiler/Language/Haskell/Syntax/Decls.hs
- compiler/Language/Haskell/Syntax/Extension.hs
- compiler/ghc.cabal.in
- docs/users_guide/phases.rst
- libraries/ghc-internal/src/GHC/Internal/Functor/ZipList.hs
- rts/Apply.cmm
- rts/Compact.cmm
- rts/ContinuationOps.cmm
- rts/Exception.cmm
- rts/Jumps.h
- rts/PrimOps.cmm
- rts/RtsMessages.c
- rts/StgMiscClosures.cmm
- rts/StgStartup.cmm
- rts/include/Stg.h
- rts/include/rts/Messages.h
- rts/prim/mulIntMayOflo.c
- testsuite/tests/diagnostic-codes/codes.stdout
- testsuite/tests/haddock/should_compile_flag_haddock/T17544_kw.stderr
- testsuite/tests/patsyn/should_fail/all.T
- + testsuite/tests/patsyn/should_fail/import-syntax-no-ext.hs
- + testsuite/tests/patsyn/should_fail/import-syntax-no-ext.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_e.hs
- + testsuite/tests/rename/should_compile/T25901_sub_f.hs
- + testsuite/tests/rename/should_compile/T25901_sub_f.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_g.hs
- + testsuite/tests/rename/should_compile/T25901_sub_g.stderr
- + testsuite/tests/rename/should_compile/T25901_sub_g_helper.hs
- testsuite/tests/rename/should_compile/all.T
- testsuite/tests/rename/should_fail/T23570b.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_a.hs
- + testsuite/tests/rename/should_fail/T25901_sub_a.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_b.hs
- + testsuite/tests/rename/should_fail/T25901_sub_b.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_c.hs
- + testsuite/tests/rename/should_fail/T25901_sub_c.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_c_helper.hs
- + testsuite/tests/rename/should_fail/T25901_sub_d.hs
- + testsuite/tests/rename/should_fail/T25901_sub_d.stderr
- + testsuite/tests/rename/should_fail/T25901_sub_d_helper.hs
- + testsuite/tests/rename/should_fail/T25901_sub_w.hs
- + testsuite/tests/rename/should_fail/T25901_sub_w.stderr
- testsuite/tests/rename/should_fail/all.T
- + testsuite/tests/simd/should_run/T26411.hs
- + testsuite/tests/simd/should_run/T26411.stdout
- + testsuite/tests/simd/should_run/T26411b.hs
- + testsuite/tests/simd/should_run/T26411b.stdout
- testsuite/tests/simd/should_run/all.T
- testsuite/tests/simplStg/should_compile/all.T
- testsuite/tests/warnings/should_compile/DodgyExports03.stderr
- testsuite/tests/warnings/should_compile/DodgyImports.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports02.hs
- + testsuite/tests/warnings/should_compile/DodgyImports02.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports03.hs
- + testsuite/tests/warnings/should_compile/DodgyImports03.stderr
- + testsuite/tests/warnings/should_compile/DodgyImports03_helper.hs
- + testsuite/tests/warnings/should_compile/DodgyImports04.hs
- + testsuite/tests/warnings/should_compile/DodgyImports04.stderr
- testsuite/tests/warnings/should_compile/DodgyImports_hiding.stderr
- testsuite/tests/warnings/should_compile/all.T
- utils/check-exact/ExactPrint.hs
- utils/genapply/Main.hs
- utils/haddock/haddock-api/src/Haddock/Interface/Create.hs
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d4fa9bfdf1619c07b7fa9f357bd445…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/d4fa9bfdf1619c07b7fa9f357bd445…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/fix-26670] Correcting some suspicious bits of code, removing dead code
by recursion-ninja (@recursion-ninja) 18 Dec '25
by recursion-ninja (@recursion-ninja) 18 Dec '25
18 Dec '25
recursion-ninja pushed to branch wip/fix-26670 at Glasgow Haskell Compiler / GHC
Commits:
f0e98a45 by Recursion Ninja at 2025-12-17T14:43:49-05:00
Correcting some suspicious bits of code, removing dead code
- - - - -
15 changed files:
- compiler/GHC/Core/Opt/Simplify/Iteration.hs
- compiler/GHC/Core/Opt/WorkWrap.hs
- compiler/GHC/Hs/Binds.hs
- compiler/GHC/Hs/Decls.hs
- compiler/GHC/HsToCore/Binds.hs
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Rename/Bind.hs
- compiler/GHC/ThToHs.hs
- compiler/GHC/Types/Basic.hs
- compiler/GHC/Types/Id/Info.hs
- compiler/GHC/Types/InlinePragma.hs
- compiler/GHC/Utils/Binary.hs
- compiler/GHC/Utils/Outputable.hs
- compiler/Language/Haskell/Syntax/Binds.hs
- compiler/Language/Haskell/Syntax/Binds/InlinePragma.hs
Changes:
=====================================
compiler/GHC/Core/Opt/Simplify/Iteration.hs
=====================================
@@ -657,8 +657,8 @@ tryCastWorkerWrapper env _ _ bndr rhs -- All other bindings
mkCastWrapperInlinePrag :: forall p. IsPass p => InlinePragma (GhcPass p) -> InlinePragma (GhcPass p)
-- See Note [Cast worker/wrapper]
-mkCastWrapperInlinePrag (InlinePragma { inl_src = inTag, inl_inline = fn_inl, inl_act = fn_act, inl_rule = rule_info })
- = InlinePragma { inl_src = outTag
+mkCastWrapperInlinePrag (InlinePragma { inl_ext = inTag, inl_inline = fn_inl, inl_act = fn_act, inl_rule = rule_info })
+ = InlinePragma { inl_ext = outTag
, inl_inline = fn_inl -- See Note [Worker/wrapper for INLINABLE functions]
, inl_act = wrap_act -- See Note [Wrapper activation]
, inl_rule = rule_info } -- in GHC.Core.Opt.WorkWrap
=====================================
compiler/GHC/Core/Opt/WorkWrap.hs
=====================================
@@ -834,7 +834,7 @@ mkWWBindPair ww_opts fn_id fn_info fn_args fn_body work_uniq div
_ -> inl_act wrap_prag
srcTxt = SourceText $ fsLit "{-# INLINE"
- work_prag = InlinePragma { inl_src = InlinePragmaGhcTag srcTxt arity
+ work_prag = InlinePragma { inl_ext = InlinePragmaGhcTag srcTxt arity
, inl_inline = fn_inline_spec
, inl_act = work_act
, inl_rule = FunLike }
@@ -901,7 +901,7 @@ mkStrWrapperInlinePrag :: InlinePragma (GhcPass p) -> [CoreRule] -> Arity -> Inl
mkStrWrapperInlinePrag (InlinePragma { inl_inline = fn_inl
, inl_act = fn_act
, inl_rule = rule_info }) rules arity
- = InlinePragma { inl_src = InlinePragmaGhcTag srcTxt arity
+ = InlinePragma { inl_ext = InlinePragmaGhcTag srcTxt arity
, inl_inline = fn_inl
-- See Note [Worker/wrapper for INLINABLE functions]
=====================================
compiler/GHC/Hs/Binds.hs
=====================================
@@ -819,26 +819,20 @@ ppr_sig (ClassOpSig _ is_deflt vars ty)
| otherwise = pprVarSig (map unLoc vars) (ppr ty)
ppr_sig (FixSig _ fix_sig) = ppr fix_sig
-ppr_sig (SpecSig _ var ty inl@(InlinePragma { inl_src = src, inl_inline = spec }))
+ppr_sig (SpecSig _ var ty inl@(InlinePragma { inl_inline = spec }))
= pragSrcBrackets srcTxt pragmaSrc $
pprSpec (unLoc var) (interpp'SP ty) inl
- where
- srcTxt = case ghcPass @p of
- GhcPs -> src
- GhcRn -> inl_ghcrn_src src
- GhcTc -> inl_ghcrn_src src
- pragmaSrc = case spec of
- NoUserInlinePrag -> "{-# " ++ extractSpecPragName srcTxt
- _ -> "{-# " ++ extractSpecPragName srcTxt ++ "_INLINE"
-
-ppr_sig (SpecSigE _ bndrs spec_e inl@(InlinePragma { inl_src = src, inl_inline = spec }))
+ where
+ srcTxt = inlinePragmaSource inl
+ pragmaSrc = case spec of
+ NoUserInlinePrag -> "{-# " ++ extractSpecPragName srcTxt
+ _ -> "{-# " ++ extractSpecPragName srcTxt ++ "_INLINE"
+
+ppr_sig (SpecSigE _ bndrs spec_e inl@(InlinePragma { inl_inline = spec }))
= pragSrcBrackets srcTxt pragmaSrc $
pp_inl <+> hang (ppr bndrs) 2 (pprLExpr spec_e)
where
- srcTxt = case ghcPass @p of
- GhcPs -> src
- GhcRn -> inl_ghcrn_src src
- GhcTc -> inl_ghcrn_src src
+ srcTxt = inlinePragmaSource inl
-- SPECIALISE or SPECIALISE_INLINE
pragmaSrc = case spec of
NoUserInlinePrag -> "{-# " ++ extractSpecPragName srcTxt
@@ -849,13 +843,8 @@ ppr_sig (SpecSigE _ bndrs spec_e inl@(InlinePragma { inl_src = src, inl_inline =
ppr_sig (InlineSig _ var inl)
= ppr_pfx <+> pprInline inl <+> pprPrefixOcc (unLoc var) <+> text "#-}"
- where
- srcTxt = case ghcPass @p of
- GhcPs -> inl_src inl
- GhcRn -> inl_ghcrn_src $ inl_src inl
- GhcTc -> inl_ghcrn_src $ inl_src inl
-
- ppr_pfx = case srcTxt of
+ where
+ ppr_pfx = case inlinePragmaSource inl of
SourceText src -> ftext src
NoSourceText -> text "{-#" <+> inlinePragmaName (inl_inline inl)
=====================================
compiler/GHC/Hs/Decls.hs
=====================================
@@ -157,13 +157,6 @@ type instance XDocD (GhcPass _) = NoExtField
type instance XRoleAnnotD (GhcPass _) = NoExtField
type instance XXHsDecl (GhcPass _) = DataConCantHappen
-{-
-type instance XInlinePragma GhcPs = SourceText
-type instance XInlinePragma GhcRn = (SourceText, Arity)
-type instance XInlinePragma GhcTc = (SourceText, Arity)
-type instance XXInlinePragma (GhcPass _) = DataConCantHappen
--}
-
-- | Partition a list of HsDecls into function/pattern bindings, signatures,
-- type family declarations, type family instances, and documentation comments.
--
=====================================
compiler/GHC/HsToCore/Binds.hs
=====================================
@@ -457,19 +457,14 @@ makeCorePair dflags gbl_id is_default_method dict_arity rhs
simpl_opts = initSimpleOpts dflags
InlinePragma (InlinePragmaGhcTag _ arity) inl_spec _ _ = idInlinePragma gbl_id
inlinable_unf = mkInlinableUnfolding simpl_opts StableUserSrc rhs
- inline_pair
- | arity > 0
- -- Add an Unfolding for an INLINE (but not for NOINLINE)
- -- And eta-expand the RHS; see Note [Eta-expanding INLINE things]
- , let real_arity = dict_arity + arity
- -- NB: The arity passed to mkInlineUnfoldingWithArity
- -- must take account of the dictionaries
- = ( gbl_id `setIdUnfolding` mkInlineUnfoldingWithArity simpl_opts StableUserSrc real_arity rhs
- , etaExpand real_arity rhs)
-
- | otherwise
- = pprTrace "makeCorePair: arity missing" (ppr gbl_id) $
- (gbl_id `setIdUnfolding` mkInlineUnfoldingNoArity simpl_opts StableUserSrc rhs, rhs)
+ inline_pair =
+ -- Add an Unfolding for an INLINE (but not for NOINLINE)
+ -- And eta-expand the RHS; see Note [Eta-expanding INLINE things]
+ let real_arity = dict_arity + arity
+ -- NB: The arity passed to mkInlineUnfoldingWithArity
+ -- must take account of the dictionaries
+ in ( gbl_id `setIdUnfolding` mkInlineUnfoldingWithArity simpl_opts StableUserSrc real_arity rhs
+ , etaExpand real_arity rhs)
dictArity :: [Var] -> Arity
-- Don't count coercion variables in arity
@@ -1022,7 +1017,7 @@ dsSpec_help poly_nm poly_id poly_rhs spec_inl orig_bndrs ds_call
fn_unf = realIdUnfolding poly_id
spec_unf = specUnfolding simpl_opts spec_bndrs mk_spec_body rule_lhs_args fn_unf
spec_info = vanillaIdInfo
- `setInlinePragInfo` specFunInlinePrag poly_id (unsetInlinePragmaArity id_inl) (unsetInlinePragmaArity spec_inl)
+ `setInlinePragInfo` specFunInlinePrag poly_id id_inl spec_inl
`setUnfoldingInfo` spec_unf
spec_id = mkLocalVar (idDetails poly_id) spec_name ManyTy spec_ty spec_info
-- Specialised binding is toplevel, hence Many.
@@ -1192,17 +1187,19 @@ getCastedVar (Var v) = Just (v, MRefl)
getCastedVar (Cast (Var v) co) = Just (v, MCo co)
getCastedVar _ = Nothing
-specFunInlinePrag :: Id -> InlinePragma GhcPs
- -> InlinePragma GhcPs -> InlinePragma GhcPs
+specFunInlinePrag :: Id -> InlinePragma GhcTc
+ -> InlinePragma GhcTc -> InlinePragma GhcTc
-- See Note [Activation pragmas for SPECIALISE]
specFunInlinePrag poly_id id_inl spec_inl
| not (isDefaultInlinePragma spec_inl) = spec_inl
| isGlobalId poly_id -- See Note [Specialising imported functions]
-- in OccurAnal
- , isStrongLoopBreaker (idOccInfo poly_id) = neverInlinePragma
+ , isStrongLoopBreaker (idOccInfo poly_id) = neverInlinePragma `setInlinePragmaArity` arity
| otherwise = id_inl
-- Get the INLINE pragma from SPECIALISE declaration, or,
-- failing that, from the original Id
+ where
+ arity = arityInfo $ idInfo poly_id
dsWarnOrphanRule :: CoreRule -> DsM ()
dsWarnOrphanRule rule
=====================================
compiler/GHC/Parser/PostProcess.hs
=====================================
@@ -3045,7 +3045,7 @@ mkInlinePragma :: SourceText -> (InlineSpec, RuleMatchInfo) -> Maybe Activation
-- The (Maybe Activation) is because the user can omit
-- the activation spec (and usually does)
mkInlinePragma src (inl, match_info) mb_act
- = InlinePragma { inl_src = src -- See Note [Pragma source text] in "GHC.Types.SourceText"
+ = InlinePragma { inl_ext = src -- See Note [Pragma source text] in "GHC.Types.SourceText"
, inl_inline = inl
, inl_act = act
, inl_rule = match_info }
@@ -3060,7 +3060,7 @@ mkInlinePragma src (inl, match_info) mb_act
mkOpaquePragma :: SourceText -> InlinePragma GhcPs
mkOpaquePragma src
- = InlinePragma { inl_src = src
+ = InlinePragma { inl_ext = src
, inl_inline = Opaque
-- By marking the OPAQUE pragma NeverActive we stop
-- (constructor) specialisation on OPAQUE things.
=====================================
compiler/GHC/Rename/Bind.hs
=====================================
@@ -1103,7 +1103,7 @@ renameSig ctxt sig@(SpecSig _ v tys inl)
TopSigCtxt {} -> lookupLocatedOccRn WL_TermVariable v
_ -> lookupSigOccRn ctxt sig v
; (new_ty, fvs) <- foldM do_one ([],emptyFVs) tys
- ; return (SpecSig noAnn new_v new_ty (inl `setInlinePragmaArity` 0), fvs) }
+ ; return (SpecSig noAnn new_v new_ty (inl `setInlinePragmaArity` 0), fvs) } -- TODO: setting arity to 0 is likely wrong
where
do_one (tys,fvs) ty
= do { (new_ty, fvs_ty) <- rnHsSigType (SpecialiseSigCtx v) TypeLevel ty
=====================================
compiler/GHC/ThToHs.hs
=====================================
@@ -892,7 +892,7 @@ cvtPragmaD (InlineP nm inline rm phases)
; let src TH.NoInline = fsLit "{-# NOINLINE"
src TH.Inline = fsLit "{-# INLINE"
src TH.Inlinable = fsLit "{-# INLINABLE"
- ; let ip = InlinePragma { inl_src = toSrcTxt inline
+ ; let ip = InlinePragma { inl_ext = toSrcTxt inline
, inl_inline = cvtInline inline
, inl_rule = cvtRuleMatch rm
, inl_act = cvtPhases phases dflt }
@@ -902,7 +902,7 @@ cvtPragmaD (InlineP nm inline rm phases)
cvtPragmaD (OpaqueP nm)
= do { nm' <- vNameN nm
- ; let ip = InlinePragma { inl_src = srcTxt
+ ; let ip = InlinePragma { inl_ext = srcTxt
, inl_inline = Opaque
, inl_rule = Hs.FunLike
, inl_act = NeverActive }
@@ -1017,7 +1017,7 @@ cvtInlinePhases inline phases =
SourceText $ fsLit "{-# SPECIALISE")
where
toSrcTxt a = SourceText $ src a
- in InlinePragma { inl_src = srcText
+ in InlinePragma { inl_ext = srcText
, inl_inline = inline'
, inl_rule = Hs.FunLike
, inl_act = cvtPhases phases dflt }
=====================================
compiler/GHC/Types/Basic.hs
=====================================
@@ -1338,12 +1338,12 @@ dfunInlinePragma = defaultInlinePragma { inl_act = AlwaysActive
, inl_rule = ConLike }
setInlinePragmaArity :: InlinePragma GhcPs -> Arity -> InlinePragma GhcTc
-setInlinePragmaArity prag@(InlinePragma { inl_src = srcTxt }) arity =
- prag { inl_src = InlinePragmaGhcTag srcTxt arity }
+setInlinePragmaArity prag@(InlinePragma { inl_ext = srcTxt }) arity =
+ prag { inl_ext = InlinePragmaGhcTag srcTxt arity }
inlinePragmaSource :: forall p. IsPass p => InlinePragma (GhcPass p) -> SourceText
-inlinePragmaSource (InlinePragma { inl_src = src }) = srcTxt
+inlinePragmaSource (InlinePragma { inl_ext = src }) = srcTxt
where
srcTxt = case ghcPass @p of
GhcPs -> src
=====================================
compiler/GHC/Types/Id/Info.hs
=====================================
@@ -557,7 +557,7 @@ setRuleInfo info sp = sp `seq` info { ruleInfo = sp }
--setInlinePragInfo :: IdInfo -> InlinePragma GhcTc -> IdInfo
--setInlinePragInfo info pr = pr `seq` info { inlinePragInfo = pr }
setInlinePragInfo :: forall p. IsPass p => IdInfo -> InlinePragma (GhcPass p) -> IdInfo
-setInlinePragInfo info pr@(InlinePragma { inl_src = src }) = pr `seq` info { inlinePragInfo = pr { inl_src = tag } }
+setInlinePragInfo info pr@(InlinePragma { inl_ext = src }) = pr `seq` info { inlinePragInfo = pr { inl_ext = tag } }
where
tag :: InlinePragmaGhcTag
tag = case ghcPass @p of
=====================================
compiler/GHC/Types/InlinePragma.hs
=====================================
@@ -59,6 +59,12 @@ module GHC.Types.InlinePragma
-- ** Extensible record type for GhcRn & GhcTc
, InlinePragmaGhcTag(..)
+ -- ** InlineSpec
+ -- *** Data-type
+ , InlineSpec(..)
+ -- *** Queries
+ , noUserInlineSpec
+
-- ** RuleMatchInfo
-- *** Data-type
, RuleMatchInfo(..)
@@ -66,12 +72,6 @@ module GHC.Types.InlinePragma
, isConLike
, isFunLike
- -- ** InlineSpec
- -- *** Data-type
- , InlineSpec(..)
- -- *** Queries
- , noUserInlineSpec
-
-- * Phase Activation
-- ** Activation
-- *** Data-type
@@ -133,7 +133,7 @@ type instance XXInlinePragma (GhcPass _) = DataConCantHappen
defaultInlinePragma, alwaysInlinePragma, neverInlinePragma, dfunInlinePragma
:: InlinePragma GhcPs
-defaultInlinePragma = InlinePragma { inl_src = SourceText $ fsLit "{-# INLINE"
+defaultInlinePragma = InlinePragma { inl_ext = SourceText $ fsLit "{-# INLINE"
, inl_act = AlwaysActive
, inl_rule = FunLike
, inl_inline = NoUserInlinePrag }
@@ -161,26 +161,25 @@ isDefaultInlinePragma (InlinePragma { inl_act = activation
setInlinePragmaArity :: forall p q. (IsPass p, XInlinePragma (GhcPass q) ~ InlinePragmaGhcTag)
=> InlinePragma (GhcPass p) -> Arity -> InlinePragma (GhcPass q)
setInlinePragmaArity prag arity =
- prag { inl_src = InlinePragmaGhcTag (inlinePragmaSource prag) arity }
+ prag { inl_ext = InlinePragmaGhcTag (inlinePragmaSource prag) arity }
unsetInlinePragmaArity :: forall p. IsPass p => InlinePragma (GhcPass p) -> InlinePragma GhcPs
unsetInlinePragmaArity prag =
- prag { inl_src = inlinePragmaSource prag }
+ prag { inl_ext = inlinePragmaSource prag }
inlinePragmaSource :: forall p. IsPass p => InlinePragma (GhcPass p) -> SourceText
-inlinePragmaSource (InlinePragma { inl_src = src }) = srcTxt
+inlinePragmaSource (InlinePragma { inl_ext = src }) = srcTxt
where
srcTxt = case ghcPass @p of
GhcPs -> src
GhcRn -> inl_ghcrn_src src
GhcTc -> inl_ghcrn_src src
--- TODO: Should we use coerce here?
promoteInlinePragmaRn :: InlinePragma GhcRn -> InlinePragma GhcTc
-promoteInlinePragmaRn prag@(InlinePragma { inl_src = src }) = prag { inl_src = src }
+promoteInlinePragmaRn prag@(InlinePragma { inl_ext = src }) = prag { inl_ext = src }
demoteInlinePragmaRn :: InlinePragma GhcTc -> InlinePragma GhcRn
-demoteInlinePragmaRn prag@(InlinePragma { inl_src = src }) = prag { inl_src = src }
+demoteInlinePragmaRn prag@(InlinePragma { inl_ext = src }) = prag { inl_ext = src }
inlinePragmaSpec :: InlinePragma p -> InlineSpec
inlinePragmaSpec = inl_inline
@@ -192,7 +191,7 @@ inlinePragmaRuleMatchInfo :: InlinePragma (GhcPass p) -> RuleMatchInfo
inlinePragmaRuleMatchInfo (InlinePragma { inl_rule = info }) = info
setInlinePragmaTag :: InlinePragma (GhcPass p) -> XInlinePragma (GhcPass q) -> InlinePragma (GhcPass q)
-setInlinePragmaTag prag tag = prag { inl_src = tag }
+setInlinePragmaTag prag tag = prag { inl_ext = tag }
setInlinePragmaActivation :: InlinePragma (GhcPass p) -> Activation -> InlinePragma (GhcPass p)
setInlinePragmaActivation prag activation = prag { inl_act = activation }
=====================================
compiler/GHC/Utils/Binary.hs
=====================================
@@ -2087,14 +2087,6 @@ instance Binary Activation where
_ -> do ab <- get bh
return (ActiveAfter ab)
-instance Binary RuleMatchInfo where
- put_ bh FunLike = putByte bh 0
- put_ bh ConLike = putByte bh 1
- get bh = do
- h <- getByte bh
- if h == 1 then return ConLike
- else return FunLike
-
instance Binary InlineSpec where
put_ bh = putByte bh . \case
NoUserInlinePrag -> 0
@@ -2110,3 +2102,11 @@ instance Binary InlineSpec where
2 -> Inlinable
3 -> NoInline
_ -> Opaque
+
+instance Binary RuleMatchInfo where
+ put_ bh FunLike = putByte bh 0
+ put_ bh ConLike = putByte bh 1
+ get bh = do
+ h <- getByte bh
+ if h == 1 then return ConLike
+ else return FunLike
=====================================
compiler/GHC/Utils/Outputable.hs
=====================================
@@ -2049,10 +2049,6 @@ instance Outputable Activation where
ppr (ActiveAfter n) = brackets (int n)
ppr FinalActive = text "[final]"
-instance Outputable RuleMatchInfo where
- ppr ConLike = text "CONLIKE"
- ppr FunLike = text "FUNLIKE"
-
instance Outputable InlineSpec where
ppr Inline = text "INLINE"
ppr NoInline = text "NOINLINE"
@@ -2060,5 +2056,9 @@ instance Outputable InlineSpec where
ppr Opaque = text "OPAQUE"
ppr NoUserInlinePrag = empty
+instance Outputable RuleMatchInfo where
+ ppr ConLike = text "CONLIKE"
+ ppr FunLike = text "FUNLIKE"
+
instance Outputable (InlinePragma (GhcPass p)) where
ppr = pprInline
=====================================
compiler/Language/Haskell/Syntax/Binds.hs
=====================================
@@ -802,7 +802,7 @@ no harm.
data InlinePragma pass -- Note [InlinePragma]
= InlinePragma
- { inl_src :: (XInlinePragma pass) -- See Note [Pragma source text]
+ { inl_ext :: (XInlinePragma pass) -- See Note [Pragma source text]
, inl_inline :: InlineSpec -- See Note [inl_inline and inl_act]
, inl_act :: Activation -- Says during which phases inlining is allowed
-- See Note [inl_inline and inl_act]
@@ -1021,7 +1021,7 @@ inlinePragmaRuleMatchInfo :: InlinePragma p -> RuleMatchInfo
inlinePragmaRuleMatchInfo (InlinePragma { inl_rule = info }) = info
setInlinePragmaTag :: InlinePragma p -> XInlinePragma q -> InlinePragma q
-setInlinePragmaTag prag tag = prag { inl_src = tag }
+setInlinePragmaTag prag tag = prag { inl_ext = tag }
setInlinePragmaActivation :: InlinePragma p -> Activation -> InlinePragma p
setInlinePragmaActivation prag activation = prag { inl_act = activation }
=====================================
compiler/Language/Haskell/Syntax/Binds/InlinePragma.hs
=====================================
@@ -25,6 +25,12 @@ module Language.Haskell.Syntax.Binds.InlinePragma
, isNoInlinePragma
, isOpaquePragma
+ -- ** InlineSpec
+ -- *** Data-type
+ , InlineSpec(..)
+ -- *** Queries
+ , noUserInlineSpec
+
-- ** RuleMatchInfo
-- *** Data-type
, RuleMatchInfo(..)
@@ -32,12 +38,6 @@ module Language.Haskell.Syntax.Binds.InlinePragma
, isConLike
, isFunLike
- -- ** InlineSpec
- -- *** Data-type
- , InlineSpec(..)
- -- *** Queries
- , noUserInlineSpec
-
-- * Phase Activation
-- ** Activation
-- *** Data-type
@@ -68,7 +68,7 @@ import Prelude -- (Eq, Int, Show, ($), seq)
data InlinePragma pass -- Note [InlinePragma]
= InlinePragma
- { inl_src :: (XInlinePragma pass) -- See Note [Pragma source text]
+ { inl_ext :: (XInlinePragma pass) -- See Note [Pragma source text]
, inl_inline :: InlineSpec -- See Note [inl_inline and inl_act]
, inl_act :: Activation -- Says during which phases inlining is allowed
-- See Note [inl_inline and inl_act]
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/f0e98a453f10634acc0400bad3eca41…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/f0e98a453f10634acc0400bad3eca41…
You're receiving this email because of your account on gitlab.haskell.org.
1
0
[Git][ghc/ghc][wip/foundation-improve-coverage] testsuite: improve coverage of foundation test
by Cheng Shao (@TerrorJack) 18 Dec '25
by Cheng Shao (@TerrorJack) 18 Dec '25
18 Dec '25
Cheng Shao pushed to branch wip/foundation-improve-coverage at Glasgow Haskell Compiler / GHC
Commits:
facda723 by Cheng Shao at 2025-12-17T20:33:03+01:00
testsuite: improve coverage of foundation test
This patch refactors the `foundation` test a bit to improve coverage:
- Instead of using a hard-coded seed, a random seed is now taken from
the command line, and printed upon test failure. This improves test
coverage over many future CI runs, and shall a failure occur, the
seed is available in the CI log for local reproduction.
- The iterations count is bumped to 1000 instead of 100, similar to
the bump in `test-primops`. Runtime timeout is bumped 2x just to be
safe.
- Improve `newLCGGen` by using non-atomic loads/stores on a
`MutableByteArray#` for storing mutable `Word64`, this test doesn't
use parallelism in the first place
- Fixed a few compiler warnings and removed redundant pragmas and
imports
Co-authored-by: Codex <codex(a)openai.com>
- - - - -
3 changed files:
- testsuite/tests/numeric/should_run/all.T
- testsuite/tests/numeric/should_run/foundation.hs
- testsuite/tests/numeric/should_run/foundation.stdout
Changes:
=====================================
testsuite/tests/numeric/should_run/all.T
=====================================
@@ -3,6 +3,8 @@
# extra run flags
# expected process return value, if not zero
+import random
+
test('arith001', normal, compile_and_run, [''])
test('arith002', normal, compile_and_run, [''])
test('arith003', normal, compile_and_run, [''])
@@ -82,7 +84,7 @@ test('IntegerToFloat', normal, compile_and_run, [''])
test('T20291', normal, compile_and_run, [''])
test('T22282', normal, compile_and_run, [''])
test('T22671', js_fragile(24259), compile_and_run, [''])
-test('foundation', [when(js_arch(), run_timeout_multiplier(2)), js_fragile(24259), extra_ways(['optasm','ghci','ghci-opt'])], compile_and_run, ['-package transformers -fno-break-points'])
+test('foundation', [run_timeout_multiplier(2), js_fragile(24259), extra_ways(['optasm','ghci','ghci-opt']), extra_run_opts(str(random.getrandbits(64)))], compile_and_run, ['-fno-break-points'])
test('T24066', normal, compile_and_run, [''])
test('div01', normal, compile_and_run, [''])
test('T24245', normal, compile_and_run, [''])
=====================================
testsuite/tests/numeric/should_run/foundation.hs
=====================================
@@ -10,9 +10,7 @@
compare the result of the primop wrappers with the results of interpretation.
-}
-{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE OverloadedStrings #-}
-{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TypeAbstractions #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE DerivingStrategies #-}
@@ -25,28 +23,23 @@ module Main
( main
) where
+import Data.Array.Byte
import Data.Bits (Bits((.&.), bit), FiniteBits, finiteBitSize)
import Data.Word
import Data.Int
import GHC.Natural
import Data.Typeable
-import Data.Proxy
import GHC.Int
import GHC.Word
-import GHC.Word
import Data.Function
import GHC.Prim
import Control.Monad.Reader
-import System.IO
-import Foreign.Marshal.Alloc
-import Foreign.Storable
-import Foreign.Ptr
import Data.List (intercalate)
-import Data.IORef
+import System.Environment (getArgs)
+import Text.Read (readMaybe)
import Unsafe.Coerce
import GHC.Types
import Data.Char
-import Data.Semigroup
import System.Exit
import qualified GHC.Internal.PrimopWrappers as Wrapper
@@ -194,11 +187,16 @@ newtype LCGGen = LCGGen { randomWord64 :: IO Word64 }
data LCGParams = LCGParams { seed :: Word64, a :: Word64, c :: Word64, m :: Word64 }
newLCGGen :: LCGParams -> IO LCGGen
-newLCGGen LCGParams{..} = do
- var <- newIORef (fromIntegral seed)
- return $ LCGGen $ do
- atomicModifyIORef' var (\old_v -> let new_val = (old_v * a + c) `mod` m in (new_val, new_val))
-
+newLCGGen LCGParams {seed = W64# seed#, ..} = do
+ MutableByteArray mba# <- IO $ \s0 -> case newByteArray# 8# s0 of
+ (# s1, mba# #) -> case writeWord64Array# mba# 0# seed# s1 of
+ s2 -> (# s2, MutableByteArray mba# #)
+ pure $ LCGGen $ IO $ \s0 -> case readWord64Array# mba# 0# s0 of
+ (# s1, old_val# #) ->
+ let old_val = W64# old_val#
+ !new_val@(W64# new_val#) = (old_val * a + c) `mod` m
+ in case writeWord64Array# mba# 0# new_val# s1 of
+ s2 -> (# s2, new_val #)
runPropertyCheck (PropertyBinaryOp res desc s1 s2) =
if res then return Success
@@ -211,7 +209,7 @@ runPropertyCheck (PropertyAnd a1 a2) = (<>) <$> runPropertyCheck a1 <*> runPrope
runProperty :: Property -> ReaderT RunS IO Result
runProperty (Prop p) = do
- let iterations = 100
+ let iterations = 1000 :: Int
loop iterations iterations
where
loop iterations 0 = do
@@ -257,14 +255,15 @@ runTestInternal (Property name p) = do
nest label $ runProperty (property p)
-runTests :: Test -> IO ()
-runTests t = do
+runTests :: Word64 -> Test -> IO ()
+runTests seed t = do
-- These params are the same ones as glibc uses.
- h <- newLCGGen (LCGParams { seed = 1238123213, m = 2^31, a = 1103515245, c = 12345 })
+ h <- newLCGGen (LCGParams { seed, m = 2 ^ (31 :: Int), a = 1103515245, c = 12345 })
res <- runReaderT (runTestInternal t) (RunS 0 h [])
case res of
Success -> return ()
Failure tests -> do
+ putStrLn $ "Seed: " ++ show seed
putStrLn $ "These tests failed: \n" ++ intercalate " \n" (map (showStack 0 . reverse) tests)
exitFailure
@@ -455,7 +454,19 @@ instance TestPrimop LowerBitsAreDefined where
twoNonZero :: (a -> a -> b) -> a -> NonZero a -> b
twoNonZero f x (NonZero y) = f x y
-main = runTests (Group "ALL" [testNumberRefs, testPrimops])
+getSeedFromArgs :: IO Word64
+getSeedFromArgs = do
+ args <- getArgs
+ case args of
+ [arg] -> case readMaybe arg of
+ Just seed -> pure seed
+ Nothing -> die $ "Invalid seed (expected Word64): " ++ show arg
+ _ -> die "Usage: foundation <seed>"
+
+main :: IO ()
+main = do
+ seed <- getSeedFromArgs
+ runTests seed (Group "ALL" [testNumberRefs, testPrimops])
-- Test an interpreted primop vs a compiled primop
testPrimops = Group "primop"
=====================================
testsuite/tests/numeric/should_run/foundation.stdout
=====================================
@@ -3,1048 +3,1048 @@ Group ALL
Group Int
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Int8
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Int16
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Int32
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Int64
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Integer
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Word
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Word8
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Word16
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Word32
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group Word64
Group Integral
Running FromIntegral(Integer(a)) == a
- Passed 100 iterations
+ Passed 1000 iterations
Group Property
Running Eq
- Passed 100 iterations
+ Passed 1000 iterations
Running Show
- Passed 100 iterations
+ Passed 1000 iterations
Running Ord
- Passed 100 iterations
+ Passed 1000 iterations
Running <
- Passed 100 iterations
+ Passed 1000 iterations
Group Additive
Running a + azero == a
- Passed 100 iterations
+ Passed 1000 iterations
Running azero + a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running a + b == b + a
- Passed 100 iterations
+ Passed 1000 iterations
Group Multiplicative
Running a * 1 == a
- Passed 100 iterations
+ Passed 1000 iterations
Running 1 * a == a
- Passed 100 iterations
+ Passed 1000 iterations
Running multiplication commutative
- Passed 100 iterations
+ Passed 1000 iterations
Running a * b == Integer(a) * Integer(b)
- Passed 100 iterations
+ Passed 1000 iterations
Group Divisible
Running (x `div` y) * y + (x `mod` y) == x
- Passed 100 iterations
+ Passed 1000 iterations
Group Precedence
Running + and - (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and - (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running + and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running - and * (2)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (1)
- Passed 100 iterations
+ Passed 1000 iterations
Running * and ^ (2)
- Passed 100 iterations
+ Passed 1000 iterations
Group primop
Running gtChar#
- Passed 100 iterations
+ Passed 1000 iterations
Running geChar#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqChar#
- Passed 100 iterations
+ Passed 1000 iterations
Running neChar#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltChar#
- Passed 100 iterations
+ Passed 1000 iterations
Running leChar#
- Passed 100 iterations
+ Passed 1000 iterations
Running ord#
- Passed 100 iterations
+ Passed 1000 iterations
Running int8ToInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running intToInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running negateInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running subInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running remInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftLInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRAInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRLInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running int8ToWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running geInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running leInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running neInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running word8ToWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running wordToWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running subWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running remWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running andWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running orWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running xorWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running notWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftLWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRLWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running word8ToInt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running geWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running leWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running neWord8#
- Passed 100 iterations
+ Passed 1000 iterations
Running int16ToInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running intToInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running negateInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running subInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running remInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftLInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRAInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRLInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running int16ToWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running geInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running leInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running neInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running word16ToWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running wordToWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running subWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running remWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running andWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running orWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running xorWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running notWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftLWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRLWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running word16ToInt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running geWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running leWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running neWord16#
- Passed 100 iterations
+ Passed 1000 iterations
Running int32ToInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running intToInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running negateInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running subInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running remInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftLInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRAInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRLInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running int32ToWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running geInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running leInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running neInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running word32ToWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running wordToWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running subWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running remWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running andWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running orWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running xorWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running notWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftLWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRLWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running word32ToInt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running geWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running leWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running neWord32#
- Passed 100 iterations
+ Passed 1000 iterations
Running int64ToInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running intToInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running negateInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running subInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running remInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedIShiftL64#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedIShiftRA64#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedIShiftRL64#
- Passed 100 iterations
+ Passed 1000 iterations
Running int64ToWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running geInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running leInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running neInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running word64ToWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running wordToWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running subWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running remWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running and64#
- Passed 100 iterations
+ Passed 1000 iterations
Running or64#
- Passed 100 iterations
+ Passed 1000 iterations
Running xor64#
- Passed 100 iterations
+ Passed 1000 iterations
Running not64#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftL64#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRL64#
- Passed 100 iterations
+ Passed 1000 iterations
Running word64ToInt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running geWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running leWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running neWord64#
- Passed 100 iterations
+ Passed 1000 iterations
Running +#
- Passed 100 iterations
+ Passed 1000 iterations
Running -#
- Passed 100 iterations
+ Passed 1000 iterations
Running *#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesInt2#
- Passed 100 iterations
+ Passed 1000 iterations
Running mulIntMayOflo#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running remInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running andI#
- Passed 100 iterations
+ Passed 1000 iterations
Running orI#
- Passed 100 iterations
+ Passed 1000 iterations
Running xorI#
- Passed 100 iterations
+ Passed 1000 iterations
Running notI#
- Passed 100 iterations
+ Passed 1000 iterations
Running negateInt#
- Passed 100 iterations
+ Passed 1000 iterations
Running addIntC#
- Passed 100 iterations
+ Passed 1000 iterations
Running subIntC#
- Passed 100 iterations
+ Passed 1000 iterations
Running >#
- Passed 100 iterations
+ Passed 1000 iterations
Running >=#
- Passed 100 iterations
+ Passed 1000 iterations
Running ==#
- Passed 100 iterations
+ Passed 1000 iterations
Running /=#
- Passed 100 iterations
+ Passed 1000 iterations
Running <#
- Passed 100 iterations
+ Passed 1000 iterations
Running <=#
- Passed 100 iterations
+ Passed 1000 iterations
Running chr#
- Passed 100 iterations
+ Passed 1000 iterations
Running int2Word#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedIShiftL#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedIShiftRA#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedIShiftRL#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running addWordC#
- Passed 100 iterations
+ Passed 1000 iterations
Running subWordC#
- Passed 100 iterations
+ Passed 1000 iterations
Running plusWord2#
- Passed 100 iterations
+ Passed 1000 iterations
Running minusWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running timesWord2#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running remWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running quotRemWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running and#
- Passed 100 iterations
+ Passed 1000 iterations
Running or#
- Passed 100 iterations
+ Passed 1000 iterations
Running xor#
- Passed 100 iterations
+ Passed 1000 iterations
Running not#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftL#
- Passed 100 iterations
+ Passed 1000 iterations
Running uncheckedShiftRL#
- Passed 100 iterations
+ Passed 1000 iterations
Running word2Int#
- Passed 100 iterations
+ Passed 1000 iterations
Running gtWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running geWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running eqWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running neWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running ltWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running leWord#
- Passed 100 iterations
+ Passed 1000 iterations
Running popCnt8#
- Passed 100 iterations
+ Passed 1000 iterations
Running popCnt16#
- Passed 100 iterations
+ Passed 1000 iterations
Running popCnt32#
- Passed 100 iterations
+ Passed 1000 iterations
Running popCnt64#
- Passed 100 iterations
+ Passed 1000 iterations
Running popCnt#
- Passed 100 iterations
+ Passed 1000 iterations
Running pdep8#
- Passed 100 iterations
+ Passed 1000 iterations
Running pdep16#
- Passed 100 iterations
+ Passed 1000 iterations
Running pdep32#
- Passed 100 iterations
+ Passed 1000 iterations
Running pdep64#
- Passed 100 iterations
+ Passed 1000 iterations
Running pdep#
- Passed 100 iterations
+ Passed 1000 iterations
Running pext8#
- Passed 100 iterations
+ Passed 1000 iterations
Running pext16#
- Passed 100 iterations
+ Passed 1000 iterations
Running pext32#
- Passed 100 iterations
+ Passed 1000 iterations
Running pext64#
- Passed 100 iterations
+ Passed 1000 iterations
Running pext#
- Passed 100 iterations
+ Passed 1000 iterations
Running clz8#
- Passed 100 iterations
+ Passed 1000 iterations
Running clz16#
- Passed 100 iterations
+ Passed 1000 iterations
Running clz32#
- Passed 100 iterations
+ Passed 1000 iterations
Running clz64#
- Passed 100 iterations
+ Passed 1000 iterations
Running clz#
- Passed 100 iterations
+ Passed 1000 iterations
Running ctz8#
- Passed 100 iterations
+ Passed 1000 iterations
Running ctz16#
- Passed 100 iterations
+ Passed 1000 iterations
Running ctz32#
- Passed 100 iterations
+ Passed 1000 iterations
Running ctz64#
- Passed 100 iterations
+ Passed 1000 iterations
Running ctz#
- Passed 100 iterations
+ Passed 1000 iterations
Running byteSwap16#
- Passed 100 iterations
+ Passed 1000 iterations
Running byteSwap32#
- Passed 100 iterations
+ Passed 1000 iterations
Running byteSwap64#
- Passed 100 iterations
+ Passed 1000 iterations
Running byteSwap#
- Passed 100 iterations
+ Passed 1000 iterations
Running bitReverse8#
- Passed 100 iterations
+ Passed 1000 iterations
Running bitReverse16#
- Passed 100 iterations
+ Passed 1000 iterations
Running bitReverse32#
- Passed 100 iterations
+ Passed 1000 iterations
Running bitReverse64#
- Passed 100 iterations
+ Passed 1000 iterations
Running bitReverse#
- Passed 100 iterations
+ Passed 1000 iterations
Running narrow8Int#
- Passed 100 iterations
+ Passed 1000 iterations
Running narrow16Int#
- Passed 100 iterations
+ Passed 1000 iterations
Running narrow32Int#
- Passed 100 iterations
+ Passed 1000 iterations
Running narrow8Word#
- Passed 100 iterations
+ Passed 1000 iterations
Running narrow16Word#
- Passed 100 iterations
+ Passed 1000 iterations
Running narrow32Word#
- Passed 100 iterations
+ Passed 1000 iterations
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/facda7233b59fcaa93e4626ee8efebd…
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/facda7233b59fcaa93e4626ee8efebd…
You're receiving this email because of your account on gitlab.haskell.org.
1
0