summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Make keepAlive# out-of-linewip/T21708Ben Gamari2022-07-157-36/+31
| | | | | | | | | | | | | | This is a naive approach to fixing the unsoundness noticed in #21708. Specifically, we remove the lowering of `keepAlive#` via CorePrep and instead turn it into an out-of-line primop. This is simple, inefficient (since the continuation must now be heap allocated), but good enough for 9.4.1. We will revisit this (particiularly via #16098) in a future release. Metric Increase: T4978 T7257 T9203
* Document RuntimeRep polymorphism limitations of catch#, et alBen Gamari2022-07-152-7/+69
| | | | | | | As noted in #21868, several primops accepting continuations producing RuntimeRep-polymorphic results aren't nearly as polymorphic as their types suggest. Document this limitation and adapt the `UnliftedWeakPtr` test to avoid breaking this limitation in `keepAlive#`.
* rts: Fix AdjustorPool bitmap manipulationBen Gamari2022-07-131-14/+14
| | | | | | | | | | | | | | Previously the implementation of bitmap_first_unset assumed that `__builtin_clz` would accept `uint8_t` however it apparently rather extends its argument to `unsigned int`. To fix this we simply revert to a naive implementation since handling the various corner cases with `clz` is quite tricky. This should be fine given that AdjustorPool isn't particularly hot. Ideally we would have a single, optimised bitmap implementation in the RTS but I'll leave this for future work. Fixes #21838.
* Fix potential space leak that arise from ModuleGraphs retaining referencesZubin Duggal2022-07-131-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | to previous ModuleGraphs, in particular the lazy `mg_non_boot` field. This manifests in `extendMG`. Solution: Delete `mg_non_boot` as it is only used for `mgLookupModule`, which is only called in two places in the compiler, and should only be called at most once for every home unit: GHC.Driver.Make: mainModuleSrcPath :: Maybe String mainModuleSrcPath = do ms <- mgLookupModule mod_graph (mainModIs hue) ml_hs_file (ms_location ms) GHCI.UI: listModuleLine modl line = do graph <- GHC.getModuleGraph let this = GHC.mgLookupModule graph modl Instead `mgLookupModule` can be a linear function that looks through the entire list of `ModuleGraphNodes` Fixes #21816
* Hadrian: update documentation of settingssheaf2022-07-133-102/+117
| | | | | | | | | | The documentation for key-value settings was a bit out of date. This patch updates it to account for `cabal.configure.opts` and `hsc2hs.run.opts`. The user-settings document was also re-arranged, to make the key-value settings more prominent (as it doesn't involve changing the Hadrian source code, and thus doesn't require any recompilation of Hadrian).
* testsuite: Factor out common parts from hiefile testsZubin Duggal2022-07-138-145/+104
|
* hie-files: Record location of filled in default method bindingsZubin Duggal2022-07-136-44/+190
| | | | | This is useful for hie files to reconstruct the evidence that default methods depend on.
* hie-files: Fix scopes for deriving clauses and instance signatures (#18425)Zubin Duggal2022-07-135-7/+29
|
* tarballEric Lindblad2022-07-131-3/+6
|
* fix bootstrapEric Lindblad2022-07-131-4/+12
|
* fix readmeEric Lindblad2022-07-131-3/+3
|
* Tiny documentation wibbles (comments only)wip/T21452Simon Peyton Jones2022-07-123-5/+5
|
* Edit Note [idArity varies independently of dmdTypeDepth]Simon Peyton Jones2022-07-124-24/+34
| | | | | | ...and refer to it in GHC.Core.Lint.lintLetBind. Fixes #21452
* Fix a scoping bug in the SpecialiserSimon Peyton Jones2022-07-092-17/+19
| | | | | | | | | | | | In the call to `specLookupRule` in `already_covered`, in `specCalls`, we need an in-scope set that includes the free vars of the arguments. But we simply were not guaranteeing that: did not include the `rule_bndrs`. Easily fixed. I'm not sure how how this bug has lain for quite so long without biting us. Fixes #21828.
* Enable :edit command in ghci multi-mode.Matthew Pickering2022-07-091-1/+1
| | | | | | This works after the last change to isLoaded. Ticket #20888
* ghci: Fix most calls to isLoaded to work in multi-modeMatthew Pickering2022-07-092-4/+15
| | | | | | | The most egrarious thing this fixes is the report about the total number of loaded modules after starting a session. Ticket #20889
* Bump unix submoduleBen Gamari2022-07-071-0/+0
| | | | Adds `config.sub` to unix's `.gitignore`, fixing #19574.
* RTS: Add stack marker to StgCRunAsm.SAndreas Schwab2022-07-071-6/+5
| | | | | Every object file must be properly marked for non-executable stack, even if it contains no code.
* rts: allow NULL to be used as an invalid StgStablePtrAdam Sandberg Ericsson2022-07-076-6/+41
|
* winio: make consoleReadNonBlocking not wait for any events at all.Tamar Christina2022-07-071-9/+30
|
* Remove a bogus #define from ClosureMacros.hAndreas Klebinger2022-07-061-1/+0
|
* driver: Fix issue with module loops and multiple home unitsMatthew Pickering2022-07-068-4/+40
| | | | | | | | | | We were attempting to rehydrate all dependencies of a particular module, but we actually only needed to rehydrate those of the current package (as those are the ones participating in the loop). This fixes loading GHC into a multi-unit session. Fixes #21814
* Fix exact printing of the HsRule nameAlan Zimmerman2022-07-062-4/+2
| | | | | | | | | | | | | | | Prior to this branch, the HsRule name was XRec pass (SourceText,RuleName) and there is an ExactPrint instance for (SourceText, RuleName). The SourceText has moved to a different location, so synthesise the original to trigger the correct instance when printing. We need both the SourceText and RuleName when exact printing, as it is possible to have a NoSourceText variant, in which case we fall back to the FastString.
* Remove many GHC dependencies from L.H.Sromes2022-07-0646-475/+493
| | | | | | | | | | | | | | | | | | Continue to prune the `Language.Haskell.Syntax.*` modules out of GHC imports according to the plan in the linked issue. Moves more GHC-specific declarations to `GHC.*` and brings more required GHC-independent declarations to `Language.Haskell.Syntax.*` (extending e.g. `Language.Haskell.Syntax.Basic`). Progress towards #21592 Bump haddock submodule for !8308 ------------------------- Metric Decrease: hard_hole_fits -------------------------
* TTG for HsTyLitromes2022-07-067-15/+39
| | | | | | | Add TTG parameter to `HsTyLit` to move the GHC-specific `SourceText` fields to the extension point and out of the base AST. Progress towards #21592
* TTG for ForeignImport/Exportromes2022-07-0618-216/+236
| | | | | | | Add a TTG parameter to both `ForeignImport` and `ForeignExport` and, according to #21592, move the GHC-specific bits in them and in the other AST data types related to foreign imports and exports to the TTG extension point.
* TTG: Move CoreTickish out of LHS.Bindsromes2022-07-0613-55/+68
| | | | | | Remove the `[CoreTickish]` fields from datatype `HsBindLR idL idR` and move them to the extension point instance, according to the plan outlined in #21592 to separate the base AST from the GHC specific bits.
* Prune L.H.S modules of GHC dependenciesromes2022-07-0629-329/+403
| | | | | | | | | | Move around datatypes, functions and instances that are GHC-specific out of the `Language.Haskell.Syntax.*` modules to reduce the GHC dependencies in them -- progressing towards #21592 Creates a module `Language.Haskell.Syntax.Basic` to hold basic definitions required by the other L.H.S modules (and don't belong in any of them)
* Restore Eq instance of ImportDeclQualifiedStyleromes2022-07-061-1/+1
| | | | Fixes #21819
* Fix lint warnings in bootstrap.pyMatthew Pickering2022-07-061-4/+3
|
* sourcesEric Lindblad2022-07-061-2/+3
|
* grammarEric Lindblad2022-07-061-1/+1
|
* options and typosEric Lindblad2022-07-061-5/+5
|
* https urlsEric Lindblad2022-07-061-2/+2
|
* Factor fields of `CoreDoSimplify` into separate data typeJohn Ericson2022-07-053-20/+28
| | | | | This avoids some partiality. The work @mmhat is doing cleaning up and modularizing `Core.Opt` will build on this nicely.
* Vendor filepath inside template-haskellMatthew Pickering2022-07-056-23/+39
| | | | | | | | | | | | | Adding filepath as a dependency of template-haskell means that it can't be reinstalled if any build-plan depends on template-haskell. This is a temporary solution for the 9.4 release. A longer term solution is to split-up the template-haskell package into the wired-in part and a non-wired-in part which can be reinstalled. This was deemed quite risky on the 9.4 release timescale. Fixes #21738
* ghci: Support :set prompt in multi replMatthew Pickering2022-07-043-2/+6
| | | | | | | This adds supports for various :set commands apart from `:set <FLAG>` in multi repl, this includes `:set prompt` and so-on. Fixes #21796
* Add nightly job for generating docs suitable for hackage uploadMatthew Pickering2022-07-043-3/+197
|
* hadrian: Add --haddock-base-url option for specifying base-url when ↵Matthew Pickering2022-07-0410-15/+53
| | | | | | | | | | | | | | | | | | | generating docs The motiviation for this flag is to be able to produce documentation which is suitable for uploading for hackage, ie, the cross-package links work correctly. There are basically three values you want to set this to: * off - default, base_url = ../%pkg% which works for local browsing * on - no argument , base_url = https:://hackage.haskell.org/package/%pkg%/docs - for hackage docs upload * on - argument, for example, base_url = http://localhost:8080/package/%pkg%/docs for testing the documentation. The `%pkg%` string is a template variable which is replaced with the package identifier for the relevant package. This is one step towards fixing #21749
* docs-upload: Fix upload script when no packages are listedMatthew Pickering2022-07-041-3/+4
|
* upload-docs: propagate publish correctly in upload_sdistMatthew Pickering2022-07-041-1/+1
|
* Add docs:<pkg> command to hadrian to build docs for just one packageMatthew Pickering2022-07-042-0/+8
|
* Ticky:Make json info a separate field.Andreas Klebinger2022-07-044-36/+40
| | | | Fixes #21233
* hadrian: Don't read package environments in ghc-stage1 wrapperMatthew Pickering2022-07-041-0/+1
| | | | | | | | | | The stage1 compiler may be on the brink of existence and not have even a working base library. You may have installed packages globally with a similar stage2 compiler which will then lead to arguments such as --show-iface not even working because you are passing too many package flags. The solution is simple, don't read these implicit files. Fixes #21803
* Add applyWhen to Data.Function per CLC propAnselm Schüler2022-07-042-0/+30
| | | | Approved by CLC in https://github.com/haskell/core-libraries-committee/issues/71#issuecomment-1165830233
* Expand `Ord` instance for `Down`konsumlamm2022-07-031-0/+6
| | | | Approved by CLC in https://github.com/haskell/core-libraries-committee/issues/23#issuecomment-1172932610
* Refactor ModuleName to L.H.S.Module.Nameromes2022-07-0331-89/+80
| | | | | | | | | | | | | | | ModuleName used to live in GHC.Unit.Module.Name. In this commit, the definition of ModuleName and its associated functions are moved to Language.Haskell.Syntax.Module.Name according to the current plan towards making the AST GHC-independent. The instances for ModuleName for Outputable, Uniquable and Binary were moved to the module in which the class is defined because these instances depend on GHC. The instance of Eq for ModuleName is slightly changed to no longer depend on unique explicitly and instead uses FastString's instance of Eq.
* TTG: Move ImpExp client-independent bits to L.H.S.ImpExpromes2022-07-0354-989/+1154
| | | | | | | | | | | Move the GHC-independent definitions from GHC.Hs.ImpExp to Language.Haskell.Syntax.ImpExp with the required TTG extension fields such as to keep the AST independent from GHC. This is progress towards having the haskell-syntax package, as described in #21592 Bumps haddock submodule
* TTG: Move HsModule to L.H.Sromes2022-07-0322-112/+160
| | | | | | | | | Move the definition of HsModule defined in GHC.Hs to Language.Haskell.Syntax with an added TTG parameter and corresponding extension fields. This is progress towards having the haskell-syntax package, as described in #21592
* Data.Foldable1: Remove references to Foldable-specific noteSimon Jakobi2022-07-021-4/+0
| | | | | ...as discussed in https://gitlab.haskell.org/ghc/ghc/-/merge_requests/8495#note_439455.