summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Factor fields of `CoreDoSimplify` into separate data typewip/core-opt-less-partialJohn 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.
* 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.
* Identify the extistence of the `runhaskell` command and that it is ↵Mike Pilgrem2022-07-021-1/+2
| | | | equivalent to the `runghc` command. Add an entry to the index for `runhaskell`. See https://gitlab.haskell.org/ghc/ghc/-/issues/21411
* ci: Fix definition of slow-validate flavour (so that -dlint) is passedMatthew Pickering2022-07-011-2/+1
| | | | | In this embarassing sequence of events we were running slow-validate without -dlint.
* desugar: Look through ticks when warning about possible literal overflowMatthew Pickering2022-07-014-3/+46
| | | | | | | | | | Enabling `-fhpc` or `-finfo-table-map` would case a tick to end up between the appliation of `neg` to its argument. This defeated the special logic which looks for `NegApp ... (HsOverLit` to warn about possible overflow if a user writes a negative literal (without out NegativeLiterals) in their code. Fixes #21701
* rts: gc stats: account properly for copied bytes in sequential collectionsDouglas Wilson2022-07-012-0/+13
| | | | | | | | | | | We were not updating the [copied,any_work,scav_find_work, max_n_todo_overflow] counters during sequential collections. As well, we were double counting for parallel collections. To fix this we add an `else` clause to the `if (is_par_gc())`. The par_* counters do not need to be updated in the sequential case because they must be 0.
* Fix panic with UnliftedFFITypes+CApiFFI (#14624)nineonine2022-07-017-12/+191
| | | | | | | | | | When declaring foreign import using CAPI calling convention, using unlifted unboxed types would result in compiler panic. There was an attempt to fix the situation in #9274, however it only addressed some of the ByteArray cases. This patch fixes other missed cases for all prims that may be used as basic foreign types.
* Remove `CoreOccurAnal` constructor of the `CoreToDo` typeDominik Peteler2022-06-293-4/+0
| | | | | It was dead code since the last occurence in an expression context got removed in 71916e1c018dded2e68d6769a2dbb8777da12664.
* Tiny tweak to `IOPort#` documentation Emily Bourke2022-06-291-1/+1
| | | | | The exclamation mark and bracket don’t seem to make sense here. I’ve looked through the history, and I don’t think they’re deliberate – possibly a copy-and-paste error.
* template-haskell: Bump version to 2.19.0.0Ben Gamari2022-06-286-4/+4
| | | | Bumps text and exceptions submodules due to bounds.
* Cleanup BuiltInSyntax vs UserSyntaxMatthew Pickering2022-06-2817-48/+45
| | | | | | | | | | | | There was some confusion about whether FUN/TYPE/One/Many should be BuiltInSyntax or UserSyntax. The answer is certainly UserSyntax as BuiltInSyntax is for things which are directly constructed by the parser rather than going through normal renaming channels. I fixed all the obviously wrong places I could find and added a test for the original bug which was caused by this (#21752) Fixes #21752 #20695 #18302
* Comments only, about join pointsSimon Peyton Jones2022-06-282-3/+38
| | | | | This MR just adds some documentation about why casts destroy join points, following #21716.
* ghc.mk: fix 'make install' (`mk/system-cxx-std-lib-1.0.conf.install` does ↵Sergei Trofimovich2022-06-281-1/+1
| | | | | | | | | | | | | | | | | | not exist) before the change `make install` was failing as: ``` "mv" "/<<NIX>>/ghc-9.3.20220406/lib/ghc-9.5.20220625/bin/ghc-stage2" "/<<NIX>>/ghc-9.3.20220406/lib/ghc-9.5.20220625/bin/ghc" make[1]: *** No rule to make target 'mk/system-cxx-std-lib-1.0.conf.install', needed by 'install_packages'. Stop. ``` I think it's a recent regression caused by 0ef249aa where `system-cxx-std-lib-1.0.conf` is created (somewhat manually), but not the .install varianlt of it. The fix is to consistently use `mk/system-cxx-std-lib-1.0.conf` everywhere. Closes: https://gitlab.haskell.org/ghc/ghc/-/issues/21784
* integer-gmp: Fix cabal fileBen Gamari2022-06-281-4/+5
| | | | Evidently fields may not come after sections in a cabal file.
* testsuite: Add test for #20735Ben Gamari2022-06-284-0/+64
|
* CmmToAsm/AArch64: Sign-extend narrow C argumentsBen Gamari2022-06-281-2/+14
| | | | | | | | The AArch64/Darwin ABI requires that function arguments narrower than 32-bits must be sign-extended by the caller. We neglected to do this, resulting in #20735. Fixes #20735.
* CmmToAsm/AArch64: Re-format argument handling logicBen Gamari2022-06-281-5/+19
| | | | Previously there were very long, hard to parse lines. Fix this.
* -ddump-llvm shouldn't imply -fllvmBen Gamari2022-06-282-2/+3
| | | | | | | | Previously -ddump-llvm would change the backend used, which contrasts with all other dump flags. This is quite surprising and cost me quite a bit of time. Dump flags should not change compiler behavior. Fixes #21776.
* Mark AArch64/Darwin as requiring sign-extensionBen Gamari2022-06-281-0/+5
| | | | | | | Apple's AArch64 ABI requires that the caller sign-extend small integer arguments. Set platformCConvNeedsExtension to reflect this fact. Fixes #21773.
* `.hs-boot` make rules: add missing order-only dependency on target directorySergei Trofimovich2022-06-271-2/+2
| | | | | | | | | | | | | | | | | | | | Noticed missing target directory dependency as a build failure in `make --shuffle` mode (added in https://savannah.gnu.org/bugs/index.php?62100): "cp" libraries/base/./GHC/Stack/CCS.hs-boot libraries/base/dist-install/build/GHC/Stack/CCS.hs-boot cp: cannot create regular file 'libraries/base/dist-install/build/GHC/Stack/CCS.hs-boot': No such file or directory libraries/haskeline/ghc.mk:4: libraries/haskeline/dist-install/build/.depend-v-p-dyn.haskell: No such file or directory make[1]: *** [libraries/base/ghc.mk:4: libraries/base/dist-install/build/GHC/Stack/CCS.hs-boot] Error 1 shuffle=1656129254 make: *** [Makefile:128: all] Error 2 shuffle=1656129254 Note that `cp` complains about inability to create target file. The change adds order-only dependency on a target directory (similar to the rest of rules in that file). The bug is lurking there since 2009 commit 34cc75e1a (`GHC new build system megapatch`.) where upfront directory creation was never added to `.hs-boot` files.
* configure: Only probe for LD in FIND_LDBen Gamari2022-06-271-1/+2
| | | | | | | | | Since 6be2c5a7e9187fc14d51e1ec32ca235143bb0d8b we would probe for LD rather early in `configure`. However, it turns out that this breaks `configure`'s `ld`-override logic, which assumes that `LD` was set by the user and aborts. Fixes #21778.
* testsuite: Hide output from test compilations with verbosity==2Ben Gamari2022-06-271-1/+1
| | | | | | | | | Previously the output from test compilations used to determine whether, e.g., profiling libraries are available was shown with verbosity levels >= 2. However, the default level is 2, meaning that most users were often spammed with confusing errors. Fix this by bumping the verbosity threshold for this output to >=3. Fixes #21760.
* hadrian: Update main README pageMatthew Pickering2022-06-271-43/+39
| | | | | | This README had some quite out-of-date content about the build system so I did a complete pass deleting old material. I also made the section about flavours more prominent and mentioned flavour transformers.
* add tests for addrToAny# levityNaomi Liu2022-06-272-0/+45
|
* add levity polymorphism to addrToAny#Naomi Liu2022-06-271-1/+1
|
* Add Foldable1 and Bifoldable1 type classesBodigrim2022-06-274-1/+566
| | | | | | | | | | | | Approved by CLC in https://github.com/haskell/core-libraries-committee/issues/9 Instances roughly follow https://hackage.haskell.org/package/semigroupoids-5.3.7/docs/Data-Semigroup-Foldable-Class.html#t:Foldable1 but the API of `Foldable1` was expanded in comparison to `semigroupoids`. Compatibility shim is available from https://github.com/phadej/foldable1 (to be released). Closes #13573.
* Remove the traces of i386-*-openbsd, long live amd64Greg Steuck2022-06-273-4/+2
| | | | | | | | | | | OpenBSD will not ship any ghc packages on i386 starting with 7.2 release. This means there will not be a bootstrap compiler easily available. The last available binaries are ghc-8.10.6 which is already not supported as bootstrap for HEAD. See here for more information: https://marc.info/?l=openbsd-ports&m=165060700222580&w=2
* Add suggestions for unrecognised pragmas (#21589)Tony Zorman2022-06-2712-13/+71
| | | | | | | In case of a misspelled pragma, offer possible corrections as to what the user could have meant. Fixes: https://gitlab.haskell.org/ghc/ghc/-/issues/21589
* Don't mark lambda binders as OtherConAndreas Klebinger2022-06-2733-405/+717
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We used to put OtherCon unfoldings on lambda binders of workers and sometimes also join points/specializations with with the assumption that since the wrapper would force these arguments once we execute the RHS they would indeed be in WHNF. This was wrong for reasons detailed in #21472. So now we purge evaluated unfoldings from *all* lambda binders. This fixes #21472, but at the cost of sometimes not using as efficient a calling convention. It can also change inlining behaviour as some occurances will no longer look like value arguments when they did before. As consequence we also change how we compute CBV information for arguments slightly. We now *always* determine the CBV convention for arguments during tidy. Earlier in the pipeline we merely mark functions as candidates for having their arguments treated as CBV. As before the process is described in the relevant notes: Note [CBV Function Ids] Note [Attaching CBV Marks to ids] Note [Never put `OtherCon` unfoldigns on lambda binders] ------------------------- Metric Decrease: T12425 T13035 T18223 T18223 T18923 MultiLayerModulesTH_OneShot Metric Increase: WWRec -------------------------
* hadrian: Improve haddocks for ghcDebugAssertionsAndreas Klebinger2022-06-271-1/+1
|
* linters: Fix lint-submodule-refs when crashing trying to find plausible branchesMatthew Pickering2022-06-271-1/+1
|
* testsuite: Use normalise_version more consistentlyBen Gamari2022-06-278-16/+16
| | | | | Previously several tests' output were unnecessarily dependent on version numbers, particularly of `base`. Fix this.
* Bump ghc-prim and base versionsBen Gamari2022-06-2743-56/+57
| | | | | | | | | To 0.9.0 and 4.17.0 respectively. Bumps array, deepseq, directory, filepath, haskeline, hpc, parsec, stm, terminfo, text, unix, haddock, and hsc2hs submodules. (cherry picked from commit ba47b95122b7b336ce1cc00896a47b584ad24095)
* Bump nofib submodule.Andreas Klebinger2022-06-221-0/+0
| | | | | | Allows the shake runner to build with 9.2.3 among other things. Fixes #21772
* Use correct arch for the FreeBSD triple in gen-data-layout.shGleb Popov2022-06-221-1/+1
| | | | | Downstream bug for reference: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=261798 Relevant upstream issue: #15718
* TagCheck.hs: Properly check if arguments are boxed types.Andreas Klebinger2022-06-222-7/+6
| | | | | | | | | | | For one by mistake I had been checking against the kind of runtime rep instead of the boxity. This uncovered another bug, namely that we tried to generate the checking code before we had associated the function arguments with a register, so this could never have worked to begin with. This fixes #21729 and both of the above issues.
* When specialising, look through floatable ticks.Gergo ERDI2022-06-221-5/+22
| | | | Fixes #21697.