| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch allows ghc and its dependencies to be built using a normal
invocation of cabal-install. Each componenent which relied on generated
files or additional configuration now has a Setup.hs file.
There are also various fixes to the cabal files to satisfy
cabal-install.
There is a new hadrian command which will build a stage2 compiler and
then a stage3 compiler by using cabal.
```
./hadrian/build build-cabal
```
There is also a new CI job which tests running this command.
For the 9.4 release we will upload all the dependent executables to
hackage and then end users will be free to build GHC and GHC executables
via cabal.
There are still some unresolved questions about how to ensure soundness
when loading plugins into a reinstalled GHC (#20742) which will be
tighted up in due course.
Fixes #19896
|
|
|
|
| |
Like -threaded, stage0 isn't guaranteed to have an event-logging RTS.
|
|
|
|
|
|
|
|
|
|
| |
Previously we would unconditionally provide a declaration for `environ`,
even if `<unistd.h>` already provided one. This would result in
`-Werror` builds failing on some platforms.
Also `#include <unistd.h>` to ensure that the declaration is visible.
Fixes #20861.
|
|
|
|
|
|
| |
We use `git ls-files` to get the list of files to include in the source distribution.
Also implements the `-testsuite` and `-extra-tarballs` distributions.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As noted in #20794 the parts of libiserv and iserv-proxy depend on
network, therefore are never built nor tested during CI.
Due to this iserv-proxy had bitrotted due to the bound on bytestring
being out of date.
Given we don't test this code it seems undesirable to distribute it.
Therefore, it's removed and an external maintainer can be responsible
for testing it (via head.hackage if desired).
Fixes #20794
|
|
|
|
| |
Not all platforms have per-thread locales. NetBSD doesn't have uselocale() in particular. Using setlocale() is of course not a safe thing to do, but it would be better than no GHC at all.
|
|
|
|
|
|
|
| |
Get rid of `USE_INPLACE_MINGW_TOOLCHAIN` and use a settings file entry
instead.
The CPP setting was originally introduced in f065b6b012.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is, rather unintuitively, part of the goal of making the packages
that make of the GHC distribution more freestanding. `ghcversion.h` is
very simple, so we easily can move it out of the main build systems
(make and Hadrian). By doing so, the RTS becomes less of a special case
to those build systems as the header, already existing in the source
tree, appears like any other.
We could do this with the upcomming RTS configure, but it hardly matters
because there is nothing platform-specific here, it is just versioning
information like the other files the top-level configure can be
responsible for.
|
| |
|
| |
|
|
|
|
| |
These will be useful for upcoming RTS configure script.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Primops types were dependent on the target word-size at *compiler*
compilation time. It's an issue for multi-target as GHC may not have the
correct primops types for the target.
This patch fixes some primops types: if they take or return fixed 64-bit
values they now always use `Int64#/Word64#`, even on 64-bit
architectures (where they used `Int#/Word#` before). Users of these
primops may now need to convert from Int64#/Word64# to Int#/Word# (a
no-op at runtime).
This is a stripped down version of !3658 which goes the all way of
changing the underlying primitive types of Word64/Int64. This is left
for future work.
T12545 allocations increase ~4% on some CI platforms and decrease ~3% on
AArch64.
Metric Increase:
T12545
Metric Decrease:
T12545
|
|
|
|
|
|
|
|
|
| |
We should strive to make our includes in terms of the RTS as much as
possible. One place there that is not possible, the llvm version, we
make a new tiny header
Stage numbers are somewhat arbitrary, if we simple need a newer RTS, we
should say so.
|
|
|
|
|
|
|
|
| |
Eventually, the RTS configure alone will need the vast majority of
AC_DEFINE, and the top-level configure will need the most AC_SUBST. By
removing the "side effects" of the macros like this we make them more
reusable so they can be shared between the two configures without doing
too much.
|
|
|
|
|
|
|
| |
This will allow better reuse of it, such as in the upcoming RTS
configure script.
Progress towards #17191
|
| |
|
| |
|
|
|
|
|
|
|
| |
Some platforms (e.g. RISC-V) require linking against libatomic for some
(e.g. sub-word-sized) atomic operations.
Fixes #19119.
|
|
|
|
|
| |
Previously the meaning of this flag was unclear and as a result I
suspect that CabalHaveLibffi could be incorrectly False.
|
|
|
|
|
|
| |
Previously both the --with-system-libffi path and the
non--with-system-libffi path set CabalUseSystemLibFFI=True. This was
wrong.
|
| |
|
| |
|
|
|
|
| |
The compiler should be independent of the target.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In order to make the packages in this repo "reinstallable", we need to
associate source code with a specific packages. Having a top level
`/includes` dir that mixes concerns (which packages' includes?) gets in
the way of this.
To start, I have moved everything to `rts/`, which is mostly correct.
There are a few things however that really don't belong in the rts (like
the generated constants haskell type, `CodeGen.Platform.h`). Those
needed to be manually adjusted.
Things of note:
- No symlinking for sake of windows, so we hard-link at configure time.
- `CodeGen.Platform.h` no longer as `.hs` extension (in addition to
being moved to `compiler/`) so as not to confuse anyone, since it is
next to Haskell files.
- Blanket `-Iincludes` is gone in both build systems, include paths now
more strictly respect per-package dependencies.
- `deriveConstants` has been taught to not require a `--target-os` flag
when generating the platform-agnostic Haskell type. Make takes
advantage of this, but Hadrian has yet to.
|
|
|
|
|
|
|
|
| |
Running the test suite with asserts enabled is somewhat tricky at the
moment as running it with a GHC compiled the DEBUG way has some hundred
failures from the start. These seem to be unrelated to assertions
though. So this provides a toggle to make it easier to debug failing
assertions using the test suite.
|
| |
|
|
|
|
|
| |
Previously the rts's cabal file would claim that it bundled libffi, even
if we are using the system's libffi. Fixes #19869.
|
| |
|
|
|
|
|
|
|
| |
bound.
We use a non-inclusive upper bound so that setting the upper bound to 13 for
example means that all 12.x versions are accepted.
|
|
|
|
|
|
|
|
| |
Previously Hadrian depended implicitly upon whatever `bash` it found in
`PATH`, offerring no way for the user to override. Fix this by detecting
`sh` in `configure` and passing the result to Hadrian.
Fixes #19797.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Also some code cleanup, and a fix for an (extant unrelated) missing
<pthread_np.h> include that should hopefully resolve a failure in the
FreeBSD CI build, since it is best to make sure that this MR actually
builds on FreeBSD systems other than mine.
Some unexpected metric changes on FreeBSD (perhaps because CI had been
failing for a while???):
Metric Decrease:
T3064
T5321Fun
T5642
T9020
T12227
T13253-spj
T15164
T18282
WWRec
Metric Increase:
haddock.compiler
|
|
|
|
|
| |
This requires adding another rewrite to the mangler, to avoid generating
PLT entries.
|
|
|
|
| |
Bumps the `haddock` submodule.
|
|
|
|
|
|
|
| |
Previously we used this non-portable function unconditionally, breaking
FreeBSD.
Fixes #19637.
|
| |
|
|
|
|
| |
and not just the name on the binary on the `$PATH`.
|
|
|
|
|
| |
As noted in my comment on #19058, this comment was previously a bit
misleading in the case of stable branches.
|
|
|
|
|
|
|
| |
Previously we would support only one LLVM major version. Here we
generalize this to accept a range, taking this range to be LLVM 10 to 11,
as 11 is necessary for Apple M1 support. We also accept 12, as that is
what apple ships with BigSur on the M1.
|
|
|
|
|
|
|
| |
Now that GHC 9.0.1 is released, it is time to drop support for bootstrapping
with GHC 8.8, as we only support building with the previous two major GHC
releases. As an added bonus, this allows us to remove several bits of CPP that
are either always true or no longer reachable.
|
|
|
|
| |
This enables a registerised build for the riscv64 architecture.
|
|
|
|
|
|
|
| |
Should fix failures on Windows:
configure.ac:1511: error: `
' is already registered with AC_CONFIG_FILES.
|
| |
|
|
|
|
|
| |
This wraps the existing GHCi wrapper script (driver/ghci/ghci.c) in a
cabal file and adds the package to Hadrian.
|
| |
|
| |
|