summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Add IDE support for several utilswip/utils_ide_supportSven Tennie2021-01-172-4/+14
| | | | | These depend on the GHC version to be built, so we can not simply create a hie.yaml and use the boot-GHC.
* Update expected-undocumented-flags.txtBenjamin Maurer2021-01-101-1/+0
|
* Document flag -dasm-lint in debugging.rstBenjamin Maurer2021-01-101-0/+7
|
* WorkWrap: Use SysLocal Name for Thunk Splitting (#19180)Sebastian Graf2021-01-103-13/+67
| | | | | | | | | | | | | | | | | | Since !4493 we annotate top-level bindings with demands, which leads to novel opportunities for thunk splitting absent top-level thunks. It turns out that thunk splitting wasn't quite equipped for that, because it re-used top-level, `External` Names for local helper Ids. That triggered a CoreLint error (#19180), reproducible with `T19180`. Fixed by adjusting the thunk splitting code to produce `SysLocal` names for the local bindings. Fixes #19180. Metric Decrease: T12227 T18282
* Fix `not32Word#` -> `notWord32#`John Ericson2021-01-101-1/+1
| | | | | | This is is correcting a mistake I unfortunately missed in !4698. But that is a recent PR so this fix is not a compatibility hazard with released versions of GHC.
* Correct more doctestsOleg Grenrus2021-01-109-20/+33
|
* Fix calls to varargs C function fcntlNick Erdmann2021-01-091-1/+2
| | | | | | The ccall calling convention doesn't support varargs functions, so switch to capi instead. See https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/ffi.html#varargs-not-supported-by-ccall-calling-convention
* testsuite: Increase delay in conc059Ben Gamari2021-01-093-26/+37
| | | | | | | | | | | | As noted in #19179, conc059 can sometimes fail due to too short of a delay in the its Haskell threads. Address this by increasing the delay by an order of magnitude to 5 seconds. While I'm in town I refactored the test to eliminate a great deal of unnecessary platform dependence, eliminate use of the deprecated usleep, and properly handle interruption by signals. Fixes #19179.
* Natural: fix left shift of 0 (fix #19170)Sylvain Henry2021-01-094-1/+17
|
* gone_wrong.rst: remove duplicate termGreg Steuck2021-01-091-1/+1
|
* intro.rst: remove duplication of release references and fix a linkGreg Steuck2021-01-091-6/+1
|
* gitlab-ci: Don't attempt to push perf notes in cross buildBen Gamari2021-01-091-0/+5
| | | | | We don't run the testsuite in cross-compiled builds so there is nothing to push.
* rts/PEi386: Fix reentrant lock usageBen Gamari2021-01-094-4/+1
| | | | | | | | | | | | Previously lookupSymbol_PEi386 would call lookupSymbol while holding linker_mutex. Fix this by rather calling `lookupDependentSymbol`. This is safe because lookupSymbol_PEi386 unconditionally holds linker_mutex. Happily, this un-breaks `T12771`, `T13082_good`, and `T14611`, which were previously marked as broken due to #18718. Closes #19155.
* rts/Capability: Use relaxed load in findSparkBen Gamari2021-01-091-1/+2
| | | | When checking n_returning_tasks.
* rts: Use SEQ_CST accesses when touching `wakeup`Ben Gamari2021-01-093-4/+4
| | | | | These are the two remaining non-atomic accesses to `wakeup` which were missed by the original TSAN patch.
* rts: Use relaxed load when checking for cap ownershipBen Gamari2021-01-091-1/+4
| | | | This check is merely a service to the user; no reason to synchronize.
* rts: stats: Fix calculation for fragmentationDouglas Wilson2021-01-091-1/+1
|
* rts: stats: Some fixes to stats for sequential gcsDouglas Wilson2021-01-092-14/+37
| | | | | | | | Solves #19147. When n_capabilities > 1 we were not correctly accounting for gc time for sequential collections. In this case par_n_gcthreads == 1, however it is not guaranteed that the single gc thread is capability 0. A similar issue for copied is addressed as well.
* More tidy synopses, and new generative recursionViktor Dukhovni2021-01-091-69/+260
| | | | | | | | - Further correction and reconcialation with new overview of the existing synopses. Restored some "Tree" examples. - New section on generative recursion via Church encoding of lists.
* Reconcile extant synopses with new overview proseViktor Dukhovni2021-01-091-186/+323
| | | | | | | | | | | - Renamed new "update function" to "operator" from synopses - More accurate divergence conditions. - Fewer references to the Tree structure in examples, which may not have the definition close-by in context in other modules, e.g. Prelude. - Improved description of foldlM and foldrM - More detail on Tree instance construction - Misc fixes
* More truthful synopsis examplesViktor Dukhovni2021-01-091-11/+14
|
* New overview of Foldable classViktor Dukhovni2021-01-092-53/+750
| | | | Also updated stale external URL in Traversable
* Never Anyify during kind inferenceRichard Eisenberg2021-01-0930-91/+462
| | | | | | | | | See Note [Error on unconstrained meta-variables] in TcMType. Close #17301 Close #17567 Close #17562 Close #15474
* hadrian: Add missing dependenciesBen Gamari2021-01-091-1/+5
| | | | | | ghcconfig.h, which depends upon ghcautoconf.h, and is a runtime dependency of deriveConstants. This is essentially a continuation of #18290.
* Remove errShortString, cleanup error-related functionsAlfredo Di Napoli2021-01-0923-211/+237
| | | | | | | | | | | This commit removes the errShortString field from the ErrMsg type, allowing us to cleanup a lot of dynflag-dependent error functions, and move them in a more specialised 'GHC.Driver.Errors' closer to the driver, where they are actually used. Metric Increase: T4801 T9961
* Hadrian: show default ghc-bignum backend (fix #18912)Sylvain Henry2021-01-071-2/+2
|
* docs: Various release notes changesBen Gamari2021-01-071-9/+20
| | | | | | * Mention changed in profiler's treatment of PINNED closures * Fix formatting * Move plugins-relevant changes to GHC API section
* rts/Sanity: Allow DEAD_WEAKs in weak pointer listBen Gamari2021-01-071-1/+1
| | | | | | | The weak pointer check in `checkGenWeakPtrList` previously failed to account for dead weak pointers. This caused `fptr01` to fail in the `sanity` way. Fixes #19162.
* rts/Linker: Add noreturn to loadNativeObj on non-ELF platformsBen Gamari2021-01-071-2/+6
|
* testsuite: Add test for #19149Ben Gamari2021-01-074-0/+51
|
* compiler: Initialize ForeignExportsList.n_entriesBen Gamari2021-01-071-1/+4
| | | | | | | | | | The refactoring in ed57c3a9eb9286faa222f98e484a9ef3432b2025 failed to initialize this field, resulting in no exports being registered. A very silly bug and yet somehow none of our tests caught it. See #18548. Fixes #19149.
* GHCi: Fill field `DynFlags.dumpPrefix`. (Fixes #17500)Roland Senn2021-01-078-6/+45
| | | | | | | | | | | For interactive evaluations set the field `DynFlags.dumpPrefix` to the GHCi internal module name. The GHCi module name for an interactive evaluation is something like `Ghci9`. To avoid user confusion, don't dump any data for GHCi internal evaluations. Extend the comment for `DynFlags.dumpPrefix` and fix a little typo in a comment about the GHCi internal module names.
* Make primops for `{Int,Word}32#`John Ericson2021-01-0722-18/+843
| | | | | | | | | | | | | Progress towards #19026. The type was added before, but not its primops. We follow the conventions in 36fcf9edee31513db2ddbf716ee0aa79766cbe69 and 2c959a1894311e59cd2fd469c1967491c1e488f3 for names and testing. Along with the previous 8- and 16-bit primops, this will allow us to avoid many conversions for 8-, 16-, and 32-bit sized numeric types. Co-authored-by: Sylvain Henry <hsyl20@gmail.com>
* users-guide: Remove space from -ol documentationBen Gamari2021-01-071-2/+2
| | | | This flag requires that there be no space between the filename and the argument.
* rts: Enforce that mark-region isn't used with -hBen Gamari2021-01-072-0/+21
| | | | | | | As noted in #9666, the mark-region GC is not compatible with heap profiling. Also add documentation for this flag. Closes #9666.
* rts: Zero shrunk array slop in vanilla RTSBen Gamari2021-01-073-5/+16
| | | | | | But only when profiling or DEBUG are enabled. Fixes #17572.
* Storage: Unconditionally enable zeroing of alignment slopBen Gamari2021-01-071-11/+11
| | | | This is necessary since the user may enable `+RTS -hT` at any time.
* rts: Implement heap census support for pinned objectsBen Gamari2021-01-071-29/+21
| | | | | It turns out that this was fairly straightforward to implement since we are now pretty careful about zeroing slop.
* rts: Break up census logicBen Gamari2021-01-071-176/+187
| | | | | Move the logic for taking censuses of "normal" and pinned blocks to their own functions.
* Implement Unique supply with Addr# atomic primopSylvain Henry2021-01-0510-184/+101
| | | | | | | | Before this patch the compiler depended on the RTS way (threaded or not) to use atomic incrementation or not. This is wrong because the RTS is supposed to be switchable at link time, without recompilation. Now we always use atomic incrementation of the unique counter.
* Rename internal primpos ahead of !4492John Ericson2021-01-033-58/+58
| | | | | I'm not sure how long the submodule dance is going to take, sadly, so I'd like to chip away at things in the meantime / avoid conflicts.
* Maintain invariant: MVars on mut_list are dirtyViktor Dukhovni2021-01-032-0/+3
| | | | | | | | | | | | The fix for 18919 was somewhat incomplete: while the MVars were correctly added to the mut_list via dirty_MVAR(), their info table remained "clean". While this is mostly harmless in non-debug builds, but trips an assertion in the debug build, and may result in the MVar being needlessly being added to the mut_list multiple times. Resolves: #19145
* Add the Data.Foldable strictness optimisations to base's changelogHécate2021-01-031-0/+3
|
* Add regression test for #18467wip/T18467Simon Peyton Jones2021-01-023-0/+31
|
* Don't use absentError thunks for strict constructor fieldsSimon Peyton Jones2021-01-027-77/+172
| | | | | | | | | | | | | | | | This patch fixes #19133 by using LitRubbish for strict constructor fields, even if they are of lifted types. Previously LitRubbish worked only for unlifted (but boxed) types. The change is very easy, although I needed a boolean field in LitRubbish to say whether or not it is lifted. (That seemed easier than giving it another type argument. This is preparing for Andreas's work on establishing the invariant that strict constructor fields are always tagged and evaluated (see #16970). Meanwhile, nothing was actually wrong before, so there are no tests.
* Use EmptyCase instead of undefined in Generics exampleAsad Saeeduddin2021-01-021-6/+6
| | | | Fixes #19124
* Correct doctestsOleg Grenrus2021-01-0224-38/+117
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's simpler to assume that base is NoImplicitPrelude, otherwise running doctest on `GHC.*` modules would be tricky. OTOH, most `GHC.List` (where the most name clashes are) examples could be changed to use `import qualified Data.List as L`. (GHC.List examples won't show for Foldable methods...). With these changes majority of doctest examples are GHCi-"faithful", my WIP GHC-independent doctest runner reports nice summary: Examples: 582; Tried: 546; Skipped: 34; Success: 515; Errors: 33; Property Failures 2 Most error cases are *Hangs forever*. I have yet to figure out how to demonstrate that in GHCi. Some of divergences are actually stack overflows, i.e. caught by runtime. Few errorful cases are examples of infinite output, e.g. >>> cycle [42] [42,42,42,42,42,42,42,42,42,42... while correct, they confuse doctest. Another erroneous cases are where expected output has line comment, like >>> fmap show (Just 1) -- (a -> b) -> f a -> f b Just "1" -- (Int -> String) -> Maybe Int -> Maybe String I think I just have to teach doctest to strip comments from expected output. This is a first patch in a series. There is plenty of stuff already.
* Upstream the strictness optimisation for GHC.List.{maximum,minimum}Hécate2021-01-021-2/+2
|
* Upstream the strictness optimisation for GHC.List.{sum,product}Hécate2021-01-021-2/+2
|
* rts: update usage text for new -A defaultDouglas Wilson2021-01-021-1/+1
|