| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Again, the range of gc_type is actually 1-3, which is technically
outside the range of rtsBool.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
|
|
|
|
| |
rtsBool is defined to only have two inhabitants, which are true (1) and
false (0)
But the wakeup flag is set to 4 possible values, outside the range of
rtsBool. This leads Clang to warn about tautological comparisons.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
| |
It's unsupported.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
|
|
|
| |
Now with less Mac-breakage.
With this change, I can get a working stage1/stage2 compiler using
Clang 3.4svn, which can be used to link working executables!
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
| |
This reverts commit 991f285e681e8541632502d05d8a46de2d44b7bd.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
| |
This reverts commit ebf97ad146173afd9e094f4975aa33717ed3a11e.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
| |
This reverts commit 5dc74f385f1bbc9248ed950af255b946677c2ff9.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
| |
Spotted by Clang.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
|
|
| |
Technically, '-u' is an ld option, not a compiler option,
and clang considers this argument unused. Hence, we must
explicitly forward this to the linker.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
Based on a patch from Yuras Shumovich.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The commit replaces mkWeakForeignEnv# with addCFinalizerToWeak#.
This new primop mutates an existing Weak# object and adds a new
C finalizer to it.
This change removes an invariant in MarkWeak.c, namely that the relative
order of Weak# objects in the list needs to be preserved across GC. This
makes it easier to split the list into per-generation structures.
The patch also removes a race condition between two threads calling
finalizeWeak# on the same WEAK object at that same time.
|
|
|
|
|
|
|
|
| |
We only need to apply the write barrier to an MVar when it acquires
a reference to live data; when the MVar is left empty in the case
of a takeMVar/putMVar, we can save a memory reference.
Patch from Edward Z. Yang.
|
| |
|
| |
|
| |
|
|
|
|
| |
Based on a patch from Stephen Blackheath.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This major patch implements the cardinality analysis described
in our paper "Higher order cardinality analysis". It is joint
work with Ilya Sergey and Dimitrios Vytiniotis.
The basic is augment the absence-analysis part of the demand
analyser so that it can tell when something is used
never
at most once
some other way
The "at most once" information is used
a) to enable transformations, and
in particular to identify one-shot lambdas
b) to allow updates on thunks to be omitted.
There are two new flags, mainly there so you can do performance
comparisons:
-fkill-absence stops GHC doing absence analysis at all
-fkill-one-shot stops GHC spotting one-shot lambdas
and single-entry thunks
The big changes are:
* The Demand type is substantially refactored. In particular
the UseDmd is factored as follows
data UseDmd
= UCall Count UseDmd
| UProd [MaybeUsed]
| UHead
| Used
data MaybeUsed = Abs | Use Count UseDmd
data Count = One | Many
Notice that UCall recurses straight to UseDmd, whereas
UProd goes via MaybeUsed.
The "Count" embodies the "at most once" or "many" idea.
* The demand analyser itself was refactored a lot
* The previously ad-hoc stuff in the occurrence analyser for foldr and
build goes away entirely. Before if we had build (\cn -> ...x... )
then the "\cn" was hackily made one-shot (by spotting 'build' as
special. That's essential to allow x to be inlined. Now the
occurrence analyser propagates info gotten from 'build's stricness
signature (so build isn't special); and that strictness sig is
in turn derived entirely automatically. Much nicer!
* The ticky stuff is improved to count single-entry thunks separately.
One shortcoming is that there is no DEBUG way to spot if an
allegedly-single-entry thunk is acually entered more than once. It
would not be hard to generate a bit of code to check for this, and it
would be reassuring. But it's fiddly and I have not done it.
Despite all this fuss, the performance numbers are rather under-whelming.
See the paper for more discussion.
nucleic2 -0.8% -10.9% 0.10 0.10 +0.0%
sphere -0.7% -1.5% 0.08 0.08 +0.0%
--------------------------------------------------------------------------------
Min -4.7% -10.9% -9.3% -9.3% -50.0%
Max -0.4% +0.5% +2.2% +2.3% +7.4%
Geometric Mean -0.8% -0.2% -1.3% -1.3% -1.8%
I don't quite know how much credence to place in the runtime changes,
but movement seems generally in the right direction.
|
|
|
|
| |
See comments for details.
|
|
|
|
|
|
| |
As far as I can tell the bug should be harmless, apart from the
failing assertion. Since the ticket reported crashes, there might be
problems elsewhere that aren't triggered by this test case.
|
| |
|
| |
|
|
|
|
|
| |
It's no longer used by Data.Unique, so there's no need to have it
in rts any more.
|
|
|
|
| |
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
Part of #7841
|
|
|
|
|
|
|
|
|
| |
This means that when the process is shutting down, if we have calls to
foreign exports in progress, they get forcibly terminated as before,
but now they only shut down the calling thread rather than the whole
process (with -threaded).
This came up in a discussion started by Akio Takano on ghc-users.
|
| |
|
|
|
|
|
| |
On Windows, we need to keep the DLL called libffi-6.dll (rather than
libffi.dll) or Windows can't find it.
|
|
|
|
| |
sed on OS X doesn't handle \+
|
| |
|
|
|
|
| |
Based on a patch from Peter Trommler
|
| |
|
|
|
|
| |
Patch from Peter Trommler
|
|\ |
|
| |
| |
| |
| | |
explicitly link against any dependent library
|
|/ |
|
|
|
|
|
|
|
|
|
| |
Based on a patch from PHO, in trac #7813.
We were previously declaring StgRun as a private symbol (in
rts/StgRun.h), but were actually defining it as a public one (in
rts/StgCRun.c). This caused a linkage problem with old binutils. See:
http://www.haskell.org/pipermail/ghc-devs/2013-April/000932.html
|
| |
|
|
|
|
|
| |
On FreeBSD, one needs use "-z origin" in order to enable resolution
of $ORIGIN in RPATH. Part of #7819.
|
|
|
|
|
|
|
|
| |
Previously, stacks were always attributed to CCCS_SYSTEM. Now, we
attribute them to the CCS when the stack was allocated. If a stack
grows, new stack chunks inherit the CCS of the old stack.
Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Patch from Stephen Blackheath.
timer_create doesn't exist and setitimer doesn't fire on iOS, so we're
using a pthreads-based implementation. It may be to do with
interference with the signals of the debugger. Revisit. See #7723.
|