summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Clarify that LLVM upper bound is non-inclusive during configure (#22411)wip/llvm-configure-messageZubin Duggal2022-11-081-3/+3
|
* bump llvm upper boundCarter Schonwald2022-11-071-1/+1
|
* Bump haskeline submodulewip/bump-boot-librariesCheng Shao2022-11-061-0/+0
| | | | Includes a fix for wasm support, doesn't impact other targets.
* Bump gmp-tarballs submoduleCheng Shao2022-11-061-0/+0
| | | | Includes a fix for wasm support, doesn't impact other targets.
* Bump ci-images revisionCheng Shao2022-11-061-1/+1
| | | | ci-images has recently been updated, including changes needed for wasm32-wasi CI.
* Bump Win32 submodule to 2.13.4.0Matthew Pickering2022-11-053-2/+2
| | | | Fixes #22098
* Bump unix submodule to 2.8.0.0Matthew Pickering2022-11-055-4/+9
| | | | | | | | | | Also bumps process and ghc-boot bounds on unix. For hadrian, when cross-compiling, we add -Wwarn=unused-imports -Wwarn=unused-top-binds to validation flavour. Further fixes in unix and/or hsc2hs is needed to make it completely free of warnings; for the time being, this change is needed to unblock other cross-compilation related work.
* Minor refactor around FastStringsKrzysztof Gogolewski2022-11-0536-95/+102
| | | | | | | Pass FastStrings to functions directly, to make sure the rule for fsLit "literal" fires. Remove SDoc indirection in GHCi.UI.Tags and GHC.Unit.Module.Graph.
* CI: Allow hadrian-ghc-in-ghci to run in nightliesBryan Richter2022-11-041-1/+4
| | | | | | | Since lint-submods doesn't run in nightlies, hadrian-ghc-in-ghci needs to mark it as "optional" so it can run if the job doesn't exist. Fixes #22396.
* Export pprTrace and friends from GHC.Prelude.Andreas Klebinger2022-11-0369-127/+146
| | | | | Introduces GHC.Prelude.Basic which can be used in modules which are a dependency of the ppr code.
* Fix haddocks for GHC.IORefBodigrim2022-11-031-2/+2
|
* Clarify status of bindings in WholeCoreBindingsMatthew Pickering2022-11-032-5/+5
| | | | | | | | | Gergo points out that these bindings are tidied, rather than prepd as the variable claims. Therefore we update the name of the variable to reflect reality and add a comment to the data type to try to erase any future confusion. Fixes #22307
* git: ignore HIE files.M Farkas-Dyck2022-11-031-0/+2
| | | | Cleans up git status if one sets -fwrite-ide-info in hadrian/ghci.
* Port foundation numeric tests to GHC testsuiteMatthew Pickering2022-11-033-0/+838
| | | | | | | | | | | | | This commit ports the numeric tests which found a regression in GHC-9.4. https://github.com/haskell-foundation/foundation/issues/571 Included in the commit is a simple random number generator and simplified QuickCheck implementation. In future these could be factored out of this standalone file and reused as a general purpose library which could be used for other QuickCheck style tests in the testsuite. See #22282
* gen-dll: Drop itBen Gamari2022-11-035-562/+0
| | | | | | | | | Currently it is only used by the make build system, which is soon to be retired, and it has not built since 41cf758b. We may need to reintroduce it when dynamic-linking support is introduced on Windows, but we will cross that bridge once we get there. Fixes #21753.
* Move Symbol implementation note out of public haddockOleg Grenrus2022-11-021-1/+2
|
* rts: tag `stgStrndup` as `STG_MALLOC`Nicolas Trangez2022-11-021-1/+2
| | | | See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
* rts: add and use `STG_RETURNS_NONNULL`Nicolas Trangez2022-11-022-2/+19
| | | | | See: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-returns_005fnonnull-function-attribute See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
* rts: use `alloc_size` attributeNicolas Trangez2022-11-022-3/+17
| | | | | | | | This patch adds the `STG_ALLOC_SIZE1` and `STG_ALLOC_SIZE2` macros which allow to set the `alloc_size` attribute on functions, when available. See: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-alloc_005fsize-function-attribute See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
* rts: specify deallocator of allocating functionsNicolas Trangez2022-11-023-6/+50
| | | | | | | | | | | | | This patch adds a new `STG_MALLOC1` macro (and its counterpart `STG_MALLOC2` for completeness) which allows to specify the deallocation function to be used with allocations of allocating functions, and applies it to `stg*allocBytes`. It also fixes a case where `free` was used to free up an `stgMallocBytes` allocation, found by the above change. See: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-malloc-function-attribute See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
* rts: use `STG_UNUSED`Nicolas Trangez2022-11-022-3/+3
|
* rts: introduce (and use) `STG_MALLOC`Nicolas Trangez2022-11-022-2/+4
| | | | | Instead of using `GNUC3_ATTRIBUTE(__malloc__)`, provide a `STG_MALLOC` macro definition and use it instead.
* rts: introduce (and use) `STG_USED`Nicolas Trangez2022-11-022-4/+5
| | | | | Similar to `STG_UNUSED`, have a specific macro for `__attribute__(used)`.
* rts: consistently use `STG_UNUSED`Nicolas Trangez2022-11-022-2/+2
|
* rts: introduce (and use) `STG_NORETURN`Nicolas Trangez2022-11-0217-24/+26
| | | | | | | Instead of sprinkling the codebase with `GNU(C3)_ATTRIBUTE(__noreturn__)`, add a `STG_NORETURN` macro (for, basically, the same thing) similar to `STG_UNUSED` and others, and update the code to use this macro where applicable.
* Add two tests for #17366Simon Peyton Jones2022-11-017-0/+116
|
* Shrink test case for #22357Simon Peyton Jones2022-11-011-678/+12
| | | | | Ryan Scott offered a cut-down repro case (60 lines instead of more than 700 lines)
* Expose UnitEnvGraphKey for user-codeFendor2022-11-011-0/+1
|
* Add accurate skolem info when quantifyingSimon Peyton Jones2022-11-019-64/+139
| | | | | | | Ticket #22379 revealed that skolemiseQuantifiedTyVar was dropping the passed-in skol_info on the floor when it encountered a SkolemTv. Bad! Several TyCons thereby share a single SkolemInfo on their binders, which lead to bogus error reports.
* ThToHs: fix overzealous parenthesizationVladislav Zavialov2022-11-017-13/+29
| | | | | | | | | | | | | | | | | | Before this patch, when converting from TH.Exp to LHsExpr GhcPs, the compiler inserted more parentheses than required: ((f a) (b + c)) d This was happening because the LHS of the function application was parenthesized as if it was the RHS. Now we use funPrec and appPrec appropriately and produce sensibly parenthesized expressions: f a (b + c) d I also took the opportunity to remove the special case for LamE, which was not special at all and simply duplicated code.
* Typo: rename -fwrite-if-simplfied-core to -fwrite-if-simplified-coreKrzysztof Gogolewski2022-11-015-19/+19
|
* rts: fix OS thread naming in tickerNicolas Trangez2022-11-013-26/+20
| | | | | | | | | | | | | | | Since ee0deb805, the use of `pthread_setname_np` on Darwin was fixed when invoking `createOSThread`. However, the 'ticker' has some thread-creation code which doesn't rely on `createOSThread`, yet also uses `pthread_setname_np`. This patch enforces all thread creation to go through a single function, which uses the (correct) thread-naming code introduced in ee0deb805. See: https://gitlab.haskell.org/ghc/ghc/-/commit/ee0deb8054da2a597fc5624469b4c44fd769ada2 See: https://gitlab.haskell.org/ghc/ghc/-/issues/22206 See: https://gitlab.haskell.org/ghc/ghc/-/merge_requests/9066
* rts: fix lifetime of `start_thread`s `name` valueNicolas Trangez2022-11-011-8/+14
| | | | | | | | | | Since, unlike the code in ee0deb8054da2^, usage of the `name` value passed to `createOSThread` now outlives said function's lifetime, and could hence be released by the caller by the time the new thread runs `start_thread`, it needs to be copied. See: https://gitlab.haskell.org/ghc/ghc/-/commit/ee0deb8054da2a597fc5624469b4c44fd769ada2#note_460080 See: https://gitlab.haskell.org/ghc/ghc/-/merge_requests/9066
* rts: `name` argument of `createOSThread` can be `const`Nicolas Trangez2022-11-013-3/+3
| | | | | | | | | | Since we don't intend to ever change the incoming string, declare this to be true. Also, in the POSIX implementation, the argument is no longer `STG_UNUSED` (since ee0deb8054da2a597fc5624469b4c44fd769ada2) in any code path. See: https://gitlab.haskell.org/ghc/ghc/-/commit/ee0deb8054da2a597fc5624469b4c44fd769ada2#note_460080
* Drop a kludge for binutils<2.17, which is now over 10 years old.M Farkas-Dyck2022-11-012-39/+2
|
* Start the deprecation process for GHC.PackHécate Moonlight2022-10-281-0/+5
|
* CI: Don't run lint-submods on nightlywip/T22325Bryan Richter2022-10-281-0/+3
| | | | Fixes #22325
* Minor SDoc-related cleanupKrzysztof Gogolewski2022-10-2822-134/+138
| | | | | | | | | | | * Rename pprCLabel to pprCLabelStyle, and use the name pprCLabel for a function using CStyle (analogous to pprAsmLabel) * Move LabelStyle to the CLabel module, it no longer needs to be in Outputable. * Move calls to 'text' right next to literals, to make sure the text/str rule is triggered. * Remove FastString/String roundtrip in Tc.Deriv.Generate * Introduce showSDocForUser', which abstracts over a pattern in GHCi.UI
* Pass correct package db when testing stage1.Zubin Duggal2022-10-282-2/+2
| | | | It used to pick the db for stage-2 which obviously didn't work.
* Fix broken link to `async` packageEvan Relf2022-10-271-1/+1
|
* Add missing dict binds to specialiserSimon Peyton Jones2022-10-274-14/+741
| | | | | | | | | | I had forgotten to add the auxiliary dict bindings to the /unfolding/ of a specialised function. This caused #22358, which reports failures when compiling Hackage packages fixed-vector indexed-traversable Regression test T22357 is snarfed from indexed-traversable
* Remove source location information from interface filesOwen Shepherd2022-10-278-72/+88
| | | | | | | | | | | | | This change aims to minimize source location information leaking into interface files, which makes ABI hashes dependent on the build location. The `Binary (Located a)` instance has been removed completely. It seems that the HIE interface still needs the ability to serialize SrcSpans, but by wrapping the instances, it should be a lot more difficult to inadvertently add source location information.
* Use TcRnVDQInTermType in noNestedForallsContextsErr (#20115)Vladislav Zavialov2022-10-268-23/+29
| | | | | | | | | | | | | | | | | | | | | When faced with VDQ in the type of a term, GHC generates the following error message: Illegal visible, dependent quantification in the type of a term (GHC does not yet support this) Prior to this patch, there were two ways this message could have been generated and represented: 1. with the dedicated constructor TcRnVDQInTermType (see check_type in GHC.Tc.Validity) 2. with the transitional constructor TcRnUnknownMessage (see noNestedForallsContextsErr in GHC.Rename.Utils) Not only this led to duplication of code generating the final SDoc, it also made it tricky to track the origin of the error message. This patch fixes the problem by using TcRnVDQInTermType exclusively.
* Testsuite: more precise test optionsSylvain Henry2022-10-2647-160/+145
| | | | | Necessary for newer cross-compiling backends (JS, Wasm) that don't support TH yet.
* Introduce TcRnWithHsDocContext (#22346)Vladislav Zavialov2022-10-2638-105/+122
| | | | | | | | | | | | | | | | | Before this patch, GHC used withHsDocContext to attach an HsDocContext to an error message: addErr $ mkTcRnUnknownMessage $ mkPlainError noHints (withHsDocContext ctxt msg) The problem with this approach is that it only works with TcRnUnknownMessage. But could we attach an HsDocContext to a structured error message in a generic way? This patch solves the problem by introducing a new constructor to TcRnMessage: data TcRnMessage where ... TcRnWithHsDocContext :: !HsDocContext -> !TcRnMessage -> TcRnMessage ...
* Broaden the in-scope sets for liftEnvSubst and composeTCvSubstRyan Scott2022-10-264-3/+37
| | | | | | | | | | | | | | | | | This patch fixes two distinct (but closely related) buglets that were uncovered in #22235: * `liftEnvSubst` used an empty in-scope set, which was not wide enough to cover the variables in the range of the substitution. This patch fixes this by populating the in-scope set from the free variables in the range of the substitution. * `composeTCvSubst` applied the first substitution argument to the range of the second substitution argument, but the first substitution's in-scope set was not wide enough to cover the range of the second substutition. We similarly fix this issue in this patch by widening the first substitution's in-scope set before applying it. Fixes #22235.
* Cleanup String/FastString conversionsKrzysztof Gogolewski2022-10-2517-99/+67
| | | | | | | Remove unused mkPtrString and isUnderscoreFS. We no longer use mkPtrString since 1d03d8bef96. Remove unnecessary conversions between FastString and String and back.
* llvm-targets: Add datalayouts for big-endian AArch64 targetsBen Gamari2022-10-252-0/+6
| | | | | | Fixes #22311. Thanks to @zeldin for the patch.
* Add GHC.SysTools.Cpp moduleSylvain Henry2022-10-254-156/+246
| | | | Move doCpp out of the driver to be able to use it in the upcoming JS backend.
* Enable popcount rewrite rule when cross-compilingSylvain Henry2022-10-251-1/+1
| | | | | The comment applies only when host's word size < target's word size. So we can relax the guard.