summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* testsuite: Mark T5611 as broken in ghci waywip/T15336Ben Gamari2019-06-191-1/+4
| | | | As described in #16845.
* testsuite: Add test for #16563Ben Gamari2019-06-193-0/+4
|
* ghci: Don't rely on resolution of System.IO to base moduleBen Gamari2019-06-1913-36/+79
| | | | | | | | | Previously we would hackily evaluate a textual code snippet to compute actions to disable I/O buffering and flush the stdout/stderr handles. This broke in a number of ways (#15336, #16563). Instead we now ship a module (`GHC.GHCi.Helpers`) with `base` containing the needed actions. We can then easily refer to these via `Orig` names.
* Make sure mkSplitUniqSupply stores the precomputed mask only.Andreas Klebinger2019-06-183-1/+27
| | | | | | | | | | | | | | | | | | | | mkSplitUniqSupply was lazy on the boxed char. This caused a bunch of issues: * The closure captured the boxed Char * The mask was recomputed on every split of the supply. * It also caused the allocation of MkSplitSupply to happen in it's own (allocated) closure. The reason of which I did not further investigate. We know force the computation of the mask inside mkSplitUniqSupply. * This way the mask is computed at most once per UniqSupply creation. * It allows ww to kick in, causing the closure to retain the unboxed value. Requesting Uniques in a loop is now faster by about 20%. I did not check the impact on the overall compiler, but I added a test to avoid regressions.
* gitlab-ci: Run alpine builds during nightly jobBen Gamari2019-06-181-3/+12
|
* testsuite: Add test for #16832Ben Gamari2019-06-183-0/+43
|
* hadrian: Compile UserSettings with -O0Ben Gamari2019-06-181-0/+3
| | | | | This guarantees that the interface file for `UserSettings` doesn't contain any unfoldings, ensuring that a change in it requires minimal rebuilds.
* SafeHaskell: Don't throw -Wsafe warning if module is declared SafeBen Gamari2019-06-181-1/+3
| | | | Fixes #16689.
* testsuite: Add testcase for #16689Ben Gamari2019-06-182-0/+6
|
* Add more newtype-derived instances to Data.Ord.DownFumiaki Kinoshita2019-06-182-4/+26
| | | | | Metric Increase: haddock.base
* Data.Ord: give a field name getDown to DownFumiaki Kinoshita2019-06-183-4/+21
|
* gitlab-ci: Run nofib on binary distributionswip/run-nofibBen Gamari2019-06-171-3/+44
| | | | Updates docker images to ensure that the `time` utility is available.
* Add link to mfix.github.io/ghc in HACKING.mdwip/gc/unglobalize-gc-statewip/gc/printer-improvementswip/gc/factor-out-bitmap-walkingSiddharth Bhat2019-06-171-0/+11
|
* make: Clean includes/settings fileBen Gamari2019-06-171-0/+1
| | | | | | | Now since this is generated by the build system we should ensure that it is properly cleaned. [skip ci]
* Use TupleSections in CmmParse.y, simplify a few exprsÖmer Sinan Ağacan2019-06-161-26/+28
|
* gitlab-ci: Don't allow failure of deb9-dwarf jobBen Gamari2019-06-161-2/+1
| | | | This #16741 out of the way this should now pass.
* testsuite: Really fix #16741Ben Gamari2019-06-162-4/+4
| | | | | The previous fix, !1095, didn't work as `--show-iface` ignores `-dsuppress-ticks`. Rework the test instead.
* fix runghc's GHC detection logic to cover the "in-tree Hadrian build" scenarioAlp Mestanogullari2019-06-161-1/+6
| | | | | | | | Before this patch, runghc would only run the GHC detection logic on Windows and assume that it was invoked through a wrapper script on all other platforms. This patch lifts this limitation and makes that logic work for the scenario where someone is calling the runghc executable directly, without passing an explicit path to GHC.
* gitlab-ci: Build alpine release bindistsBen Gamari2019-06-161-0/+24
|
* testsuite: Ensure that ffi005 output order is predictableBen Gamari2019-06-164-6/+14
| | | | | The libc output buffer wasn't being flushed, making the order system-depedent.
* testsuite: Flush conc059's printf bufferBen Gamari2019-06-162-1/+2
| | | | | Otherwise it the order out the Haskell and C output will be system-dependent.
* testsuite: Ensure T5423 flushes C output bufferBen Gamari2019-06-164-3/+15
| | | | | | Previously T5423 would fail to flush the printf output buffer. Consequently it was platform-dependent whether the C or Haskell print output would be emitted first.
* testsuite: Fix T8602 on muslBen Gamari2019-06-161-1/+2
| | | | Musl wants hash-bangs on all executables.
* base/Event/Poll: Drop POLLRDHUP enum itemBen Gamari2019-06-161-12/+0
| | | | | | Previously the Event enumeration produced by hsc2hs would sometimes include a currently-unused POLLRDHUP item. This unused binding would result in a build failure. Drop it.
* Remove dead codeKrzysztof Gogolewski2019-06-155-58/+4
|
* Synchronize ClsInst.doTyConApp with TcTypeable validity checks (#15862)Ryan Scott2019-06-157-35/+116
| | | | | | | | | | | | | | | | | Issue #15862 demonstrated examples of type constructors on which `TcTypeable.tyConIsTypeable` would return `False`, but the `Typeable` constraint solver in `ClsInst` (in particular, `doTyConApp`) would try to generate `Typeable` evidence for anyway, resulting in disaster. This incongruity was caused by the fact that `doTyConApp` was using a weaker validity check than `tyConIsTypeable` to determine if a type constructor warrants `Typeable` evidence or not. The solution, perhaps unsurprisingly, is to use `tyConIsTypeable` in `doTyConApp` instead. To avoid import cycles between `ClsInst` and `TcTypeable`, I factored out `tyConIsTypeable` into its own module, `TcTypeableValidity`. Fixes #15862.
* testsuite: Add assertions that way lists are in fact listsBen Gamari2019-06-1512-24/+30
| | | | | | Previously there were a few cases where operations like `omit_ways` were incorrectly passed a single way (e.g. `omit_ways('threaded2')`). This won't work as the author expected.
* Fix typo in error messageAiken Cairncross2019-06-151-1/+1
|
* testsuite: Skip hDuplicateTo001 in concurrent waysBen Gamari2019-06-151-1/+2
| | | | As noted in #16819, this operation is racy under concurrent execution.
* testsuite: Introduce concurrent_ways setBen Gamari2019-06-152-7/+12
| | | | | | Previously we just tested for the threaded2 when determining whether to skip tests which are fragile under concurrent execution. However, this isn't the only way which is concurrent.
* Disable optimisation when building Cabal in development flavoursBen Gamari2019-06-155-3/+20
| | | | | | | | | | This updates the make and Hadrian build flavours targetting developers to disable optimisation when building the Cabal library. Cabal tends to tickle some very bad compiler performance cases (e.g. #16577) so disabling optimisation here makes a sizeable impact on overall build time. See #16817.
* Disable optimisation when building Cabal lib for stage0Ben Gamari2019-06-152-0/+9
| | | | | | | | This disables optimisation when building Cabal for Hadrian and stage0 `ghc-cabal`. Cabal is performance critical in neither case nor will any performance difference here be visible to the end-user. See #16817.
* Bump unix submoduleBen Gamari2019-06-151-0/+0
| | | | Skips `executeFile001` test in `threaded2` way. Fixes #16814.
* Remove duplicates from 'ghc --info' outputAlp Mestanogullari2019-06-141-5/+0
|
* gitlab-ci: Lint the lintersBen Gamari2019-06-142-15/+28
|
* lint: Only apply --interactive lint to testsuite .T filesBen Gamari2019-06-142-7/+18
|
* gitlab-ci: Lint testsuite for framework failuresBen Gamari2019-06-143-2/+15
| | | | | This introduces a new lint job checking for framework failures and listing broken tests.
* PrelRules: Don't break let/app invariant in shiftRuleBen Gamari2019-06-147-5/+53
| | | | | | | | | | | | | | | | | | | Previously shiftRule would rewrite as invalid shift like ``` let x = I# (uncheckedIShiftL# n 80) in ... ``` to ``` let x = I# (error "invalid shift") in ... ``` However, this breaks the let/app invariant as `error` is not okay-for-speculation. There isn't an easy way to avoid this so let's not try. Instead we just take advantage of the undefined nature of invalid shifts and return zero. Fixes #16742.
* Implement the -XUnliftedNewtypes extension.Andrew Martin2019-06-14113-202/+1522
| | | | | | | | | | | | | | | | | | | | | | | | | | | GHC Proposal: 0013-unlifted-newtypes.rst Discussion: https://github.com/ghc-proposals/ghc-proposals/pull/98 Issues: #15219, #1311, #13595, #15883 Implementation Details: Note [Implementation of UnliftedNewtypes] Note [Unifying data family kinds] Note [Compulsory newtype unfolding] This patch introduces the -XUnliftedNewtypes extension. When this extension is enabled, GHC drops the restriction that the field in a newtype must be of kind (TYPE 'LiftedRep). This allows types like Int# and ByteArray# to be used in a newtype. Additionally, coerce is made levity-polymorphic so that it can be used with newtypes over unlifted types. The bulk of the changes are in TcTyClsDecls.hs. With -XUnliftedNewtypes, getInitialKind is more liberal, introducing a unification variable to return the kind (TYPE r0) rather than just returning (TYPE 'LiftedRep). When kind-checking a data constructor with kcConDecl, we attempt to unify the kind of a newtype with the kind of its field's type. When typechecking a data declaration with tcTyClDecl, we again perform a unification. See the implementation note for more on this. Co-authored-by: Richard Eisenberg <rae@richarde.dev>
* Add Outputable instances for Float, Double.Andreas Klebinger2019-06-131-0/+6
|
* Hadrian: remove superfluous dependencies in Rules.CompileAlp Mestanogullari2019-06-131-2/+0
| | | | | | | | Each package's object files were 'need'ing the library files of all transitive dependencies of the current package, whichi is pointless since the said libraries are not needed until we link those object files together. This fixes #16759.
* Remove unused Unique field from StgFCallOpÖmer Sinan Ağacan2019-06-134-13/+9
| | | | Fixes #16696
* Maintain separate flags for C++ compiler invocationsBen Gamari2019-06-1313-34/+48
| | | | | | | Previously we would pass flags intended for the C compiler to the C++ compiler (see #16738). This would cause, for instance, `-std=gnu99` to be passed to the C++ compiler, causing spurious test failures. Fix this by maintaining a separate set of flags for C++ compilation invocations.
* gitlab-ci: Disable validate-x86_64-linux-deb9 job to reduce loadBen Gamari2019-06-131-2/+6
| | | | Enable artifacts on to ensure we have bindist coverage.
* gitlab-ci: Disable deb9-llvm job, introduce nightly LLVM jobBen Gamari2019-06-131-1/+12
| | | | | This should help alleviate queue times as the LLVM job is one of the longest that we have.
* testsuite: A more portable solution to #9399Ben Gamari2019-06-136-25/+23
| | | | | | | | Previously we used an awful hybrid batch script/Bourne shell script to allow this test to run both on Windows and Linux (fixing #9399). However, this breaks on some libc implementations (e.g. musl). Fix this. Fixes #16798.
* Clean up .circleciBen Gamari2019-06-135-523/+3
| | | | Move prepare-system.sh to .gitlab and remove everything else.
* gitlab-ci: Don't build PDF user's guide on AArch64Ben Gamari2019-06-131-0/+2
| | | | | For reasons I don't understand sphinx seems to fail to produce a .idx file for makeindex.
* users-guide: Fix a few markup issuesBen Gamari2019-06-132-23/+24
| | | | | | | Strangely these were only causing the build to fail in the aarch64-linux job, despite Sphinx throwing errors in all jobs I checked. Also changes some `#ifdef`s to `#if defined` to satisfy the linter.
* Hadrian: Do not allow the Linux jobs to fail anymoreAlp Mestanogullari2019-06-131-1/+0
| | | | | | MR !1151 makes the Hadrian/Linux job pass by fixing the last two test failures, so we can now be stricter and not allow those jobs to fail anymore, easily letting us see when patches introduce test failures.