[Git][ghc/ghc][master] 10 commits: Memory usage fixes for Haddock

Ben Gamari (@bgamari) gitlab at gitlab.haskell.org
Wed Jun 21 19:35:16 UTC 2023



Ben Gamari pushed to branch master at Glasgow Haskell Compiler / GHC


Commits:
3d1d42b7 by Finley McIlwaine at 2023-06-21T12:04:58-04:00
Memory usage fixes for Haddock

- Do not include `mi_globals` in the `NoBackend` backend. It was only included
  for Haddock, but Haddock does not actually need it. This causes a 200MB
  reduction in max residency when generating haddocks on the Agda codebase
  (roughly 1GB to 800MB).

- Make haddock_{parser,renamer}_perf tests more accurate by forcing docs to
  be written to interface files using `-fwrite-interface`

Bumps haddock submodule.

Metric Decrease:
    haddock.base

- - - - -
8185b1c2 by Finley McIlwaine at 2023-06-21T12:04:58-04:00
Fix associated data family doc structure items

Associated data families were being given their own export DocStructureItems,
which resulted in them being documented separately from their classes in
haddocks. This commit fixes it.

- - - - -
4d356ea3 by Sylvain Henry at 2023-06-21T12:04:59-04:00
JS: implement TH support

- Add ghc-interp.js bootstrap script for the JS interpreter
- Interactively link and execute iserv code from the ghci package
- Incrementally load and run JS code for splices into the running iserv

Co-authored-by: Luite Stegeman <stegeman at gmail.com>

- - - - -
3249cf12 by Sylvain Henry at 2023-06-21T12:04:59-04:00
Don't use getKey

- - - - -
f84ff161 by Sylvain Henry at 2023-06-21T12:04:59-04:00
Stg: return imported FVs

This is used to determine what to link when using the interpreter.
For now it's only used by the JS interpreter but it could easily be used
by the native interpreter too (instead of extracting names from compiled BCOs).

- - - - -
fab2ad23 by Sylvain Henry at 2023-06-21T12:04:59-04:00
Fix some recompilation avoidance tests

- - - - -
a897dc13 by Sylvain Henry at 2023-06-21T12:04:59-04:00
TH_import_loop is now broken as expected

- - - - -
dbb4ad51 by Sylvain Henry at 2023-06-21T12:04:59-04:00
JS: always recompile when TH is enabled (cf #23013)

- - - - -
95152283 by Ben Gamari at 2023-06-21T12:04:59-04:00
Add support for deprecating exported items (proposal #134)

This is an implementation of the deprecated exports proposal #134.
The proposal introduces an ability to introduce warnings to exports.
This allows for deprecating a name only when it is exported from a specific
module, rather than always depreacting its usage. In this example:

    module A ({-# DEPRECATED "do not use" #-} x) where
    x = undefined
    ---
    module B where
    import A(x)

`x` will emit a warning when it is explicitly imported.

Like the declaration warnings, export warnings are first accumulated within
the `Warnings` struct, then passed into the ModIface, from which they are
then looked up and warned about in the importing module in the `lookup_ie`
helpers of the `filterImports` function (for the explicitly imported names)
and in the `addUsedGRE(s)` functions where they warn about regular usages
of the imported name.

In terms of the AST information, the custom warning is stored in the
extension field of the variants of the `IE` type (see Trees that Grow for
more information).

The commit includes a bump to the haddock submodule added in MR #28

Signed-off-by: Bartłomiej Cieślar <bcieslar2001 at gmail.com>

- - - - -
cc2f3ecf by Ben Gamari at 2023-06-21T12:04:59-04:00
configure: Bump version to 9.8

Bumps Haddock submodule

- - - - -


30 changed files:

- compiler/GHC.hs
- compiler/GHC/Builtin/Names.hs
- compiler/GHC/Driver/Backend.hs
- compiler/GHC/Driver/Flags.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Driver/Make.hs
- compiler/GHC/Driver/Pipeline.hs
- compiler/GHC/Driver/Session.hs
- compiler/GHC/Hs/Doc.hs
- compiler/GHC/Hs/ImpExp.hs
- compiler/GHC/HsToCore/Docs.hs
- compiler/GHC/Iface/Make.hs
- compiler/GHC/Iface/Recomp.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/Linker/Loader.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Rename/Env.hs
- compiler/GHC/Rename/Module.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Pat.hs
- compiler/GHC/Runtime/Context.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/Loader.hs
- + compiler/GHC/Runtime/Utils.hs
- compiler/GHC/Stg/FVs.hs
- compiler/GHC/Stg/Pipeline.hs


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/0ff1c5017d7d32cc92ac1ac6f54e12471658d167...cc2f3ecf2914d97b4ade3f5339c4a97fec082d2a

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/0ff1c5017d7d32cc92ac1ac6f54e12471658d167...cc2f3ecf2914d97b4ade3f5339c4a97fec082d2a
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230621/5b3d1d89/attachment-0001.html>


More information about the ghc-commits mailing list