simonpj [Thu, 21 Nov 2002 14:59:52 +0000 (14:59 +0000)]
[project @ 2002-11-21 14:59:51 by simonpj]
-------------------------------
Better notion of what a 'value' is
Slightly better eta reduction
-------------------------------
1. At various places we watch out for "values"; the predicate exprIsValue
detects them. It was stupidly treating nullary constructors as non-values
which is exceptionally stupid. This (performance) bug has been there
for ages.
There's an exactly similar bug in SimplUtils.interestingArg, which looks
for an interesting argument to trigger an inlining.
2. The eta reduction in SimplUtils.tryEtaReduce would only eta reduce if
that left us with a variable. That led to slightly tiresome thing like
:DMonad (/\a b -> foo @ s @ a @ b) ...
where this would be neater
:DMonad (foo @ s)
The fix is easy, and there's a little less code too.
simonpj [Thu, 21 Nov 2002 11:32:45 +0000 (11:32 +0000)]
[project @ 2002-11-21 11:32:45 by simonpj]
Add rawSystem back in for benefit of pre-504 compilers on Win32
simonpj [Thu, 21 Nov 2002 11:31:51 +0000 (11:31 +0000)]
[project @ 2002-11-21 11:31:51 by simonpj]
import trimming
simonpj [Thu, 21 Nov 2002 11:31:34 +0000 (11:31 +0000)]
[project @ 2002-11-21 11:31:34 by simonpj]
--------------------------------
Compile instance declarations better
--------------------------------
This commit makes the type checker build better dictionaries
from instance declarations. "Better" in the sense that if a
binding in the instance declaration mentions one of the other
methods of the same class, we use that method directly rather
than going via a (recursive) use of the dictionary.
This makes it easier to unravel recursive knots, and that
makes more inlining happen. There's a long comment in
TcInstDcls.tcMethods
Makes the Monad instance for ST much more inlinable, and that
makes spectral/fibheaps go faster, among other things.
simonmar [Thu, 21 Nov 2002 11:27:05 +0000 (11:27 +0000)]
[project @ 2002-11-21 11:27:05 by simonmar]
these files should be on eval-apply-branch
simonmar [Thu, 21 Nov 2002 10:04:21 +0000 (10:04 +0000)]
[project @ 2002-11-21 10:04:20 by simonmar]
Repair the HEAD after some file adds/removes that were supposed to
happen on the eval-apply-branch yesterday mysteriously happened on the
HEAD instead.
simonpj [Thu, 21 Nov 2002 09:37:25 +0000 (09:37 +0000)]
[project @ 2002-11-21 09:37:24 by simonpj]
More wibbles to improve declaration splicing
simonpj [Thu, 21 Nov 2002 09:36:48 +0000 (09:36 +0000)]
[project @ 2002-11-21 09:36:48 by simonpj]
Less rn-tracing
simonpj [Thu, 21 Nov 2002 09:36:04 +0000 (09:36 +0000)]
[project @ 2002-11-21 09:36:03 by simonpj]
-------------------------------
Fix and tidy the desugaring of
pattern-matching in do-notation
-------------------------------
In the reorgansiation of HsPat, failureFreePat had become incorrect (due to
a catch-all case that caught a constructor that should have been matched). So
pattern-match failure in do-notation wasn't handled right.
As it turned out, DsExpr.dsDo could be made much simpler and more elegant
by using matchSimply instead of matchWrapper, and this had the side benefit
of removing the last call to HsPat.failureFreePat. So it's gone!
chak [Thu, 21 Nov 2002 03:34:07 +0000 (03:34 +0000)]
[project @ 2002-11-21 03:34:07 by chak]
Convert : Added newly required import of `HsSyn.TySynonym'
TcSplice: Adapted `tcRunQ' to new definition of `THSyntax.Q'
chak [Wed, 20 Nov 2002 23:27:37 +0000 (23:27 +0000)]
[project @ 2002-11-20 23:27:37 by chak]
wibble
simonpj [Wed, 20 Nov 2002 15:43:40 +0000 (15:43 +0000)]
[project @ 2002-11-20 15:43:37 by simonpj]
Three Template Haskell improvements
a) Add type synonyms to THSyntax (and DsMeta, Convert)
b) Make Q into a newtype instead of a type synonym
c) Eliminate tiresome and error prone argument to DsMeta.wrapGenSyms
and similarly addTyVarBinds
simonpj [Wed, 20 Nov 2002 15:40:32 +0000 (15:40 +0000)]
[project @ 2002-11-20 15:40:32 by simonpj]
Wibble to fix :info
simonpj [Wed, 20 Nov 2002 15:39:47 +0000 (15:39 +0000)]
[project @ 2002-11-20 15:39:47 by simonpj]
------------------------------------
Improve occurrence analysis a little
------------------------------------
Consider
x1 = a0 : []
x2 = a1 : x1
x3 = a2 : x2
g = f x3
First time round, it looks as if x1 and x2 occur as an arg of a
let(rec)-bound constructor, and hence should not be inlined. (If the
RHS of a let is just (C a b) where C is a constructor, then we like to
keep it that way, with atomic a,b, so that it can be inlined easily at
a 'case'.)
But in this case, x3 is inlined in g's RHS... and now x2 is not an arg
of a let-bound constructor, so it can be inlined, and then x1. Result:
g = f (a2 : a1 : a0 : [])
Which is fine. What is *not* fine is that it has been costing us a
whole simplifier iteration for each element!
This commit adds another little hack to get around the problem: don't treat
constructor RHSs specially if the bound variable looks as if it occurs just
once so it'll be inlined. This catches the common case very nicely.
It's a pain that we have the atomic-args-for-constructor-RHSs invariant.
But I can't see how to do without it.
simonmar [Wed, 20 Nov 2002 14:10:04 +0000 (14:10 +0000)]
[project @ 2002-11-20 14:09:42 by simonmar]
Snapshot of the Eval/Apply changes, c. 15 Nov 2002. This snapshot
should be relatively stable, although GHCi and profiling are currently
known to be broken.
simonmar [Wed, 20 Nov 2002 13:34:20 +0000 (13:34 +0000)]
[project @ 2002-11-20 13:34:20 by simonmar]
Back out rev. 1.233
simonmar [Wed, 20 Nov 2002 13:33:52 +0000 (13:33 +0000)]
[project @ 2002-11-20 13:33:52 by simonmar]
Back out previous change. I remembered why we don't generate .depend
each time the sources chage: it's too annoying :-)
chak [Wed, 20 Nov 2002 12:34:43 +0000 (12:34 +0000)]
[project @ 2002-11-20 12:34:42 by chak]
TH:
- We are forcing importing THSyntax.Q at every top splice now; this suffices
to get simple splices that do not involve reifyDecl or declaration
quasi-quotes to work. NB: This worked already when the construction of the
Dec term and the splice were in separated modules, but not when they are in
the same (see the regression test "TH_spliceDecl1.hs").
- The tests "TH_spliceDecl2.hs" and "TH_spliceDecl3.hs" use toplevel splices
together with quasi-quoted and reifyDecl. These currently still fail, as
importing of some of the required type constructors from THSyntax isn't
forced.
simonpj [Wed, 20 Nov 2002 09:37:48 +0000 (09:37 +0000)]
[project @ 2002-11-20 09:37:45 by simonpj]
-----------------------------------------------
Add -Werror flag, which makes warnings fatal
-----------------------------------------------
-Werror is standard gcc-ism; it makes warnings into fatal errors
so you don't miss them in a batch compile.
Fairly easy to implement, by modifying ErrUtils.errorsFound
Suggested by Ashley Yakeley
chak [Wed, 20 Nov 2002 07:19:13 +0000 (07:19 +0000)]
[project @ 2002-11-20 07:19:12 by chak]
TH: Revised type variable handling in toplevel decls (became necessary due to
recent addition of foralls in type representations).
simonpj [Tue, 19 Nov 2002 15:57:10 +0000 (15:57 +0000)]
[project @ 2002-11-19 15:57:10 by simonpj]
-----------------------------------------------
Fix a terrible and long-standing strictness bug
-----------------------------------------------
MERGE TO STABLE
Simplify.simplifyArg was floating out lets from a lazy argument.
Not only is this unprofitable, but it can actually be wrong it
the floated let has a strict-demand flag on it. (Simplify.simplLazyBind
goes to some trouble to check for this case.)
The situation is this
lazy_fn (let v = <expensive> in str_fn v v)
Here, the strictness analyser may put a 'demanded' flag on
v, and if is is *then* floated we'll get
let v* = <expensive>
in
lazy_fn (str_fn v v)
and then <expensive> will always be evaluated.
This bug has been in the compiler at least a year (since Sept 01), but
in fact it's quite hard to make a test case for it, because the same
bug meant that the let was floated out *before* strictness analysis
giving
let v = <expensive>
in
lazy_fn (str_fn v v)
and now v won't get a strict-demand flag. So it's only if the let
shows up (by inlining) after strictness analysis but not before.
simonpj [Tue, 19 Nov 2002 15:51:17 +0000 (15:51 +0000)]
[project @ 2002-11-19 15:51:16 by simonpj]
Comments
simonmar [Tue, 19 Nov 2002 14:16:45 +0000 (14:16 +0000)]
[project @ 2002-11-19 14:16:43 by simonmar]
- Fix a bug in eta-expansion of an application; it probably never bit
us in practice.
- Change the behaviour of State#-lambdas: previously a State# lambda
was considered to be one-shot for the purposes of inlining and
eta-expansion. Both can lead to unbounded extra work, but inlining
is more likely to kill us, and eta-expansion is the case we mostly
care about (getting the State# lambda to the outside of the function
is often very important). So now we only consider a State# lambda to be
one-shot in eta expansion, not for inlining.
simonmar [Tue, 19 Nov 2002 13:49:30 +0000 (13:49 +0000)]
[project @ 2002-11-19 13:49:30 by simonmar]
Don't recalculate dependencies if none of the source files have changed.
simonmar [Tue, 19 Nov 2002 13:46:26 +0000 (13:46 +0000)]
[project @ 2002-11-19 13:46:26 by simonmar]
Don't recalculate dependencies if none of the source files have
changed.
From: Ian Lynagh <igloo@earth.li>
simonmar [Tue, 19 Nov 2002 13:39:29 +0000 (13:39 +0000)]
[project @ 2002-11-19 13:39:29 by simonmar]
Add some documentation about the new bootstrapping support
simonmar [Tue, 19 Nov 2002 13:08:08 +0000 (13:08 +0000)]
[project @ 2002-11-19 13:08:08 by simonmar]
- If we're building GHC, then default to building+installing stage 2.
simonpj [Tue, 19 Nov 2002 12:34:56 +0000 (12:34 +0000)]
[project @ 2002-11-19 12:34:55 by simonpj]
More newMethod tidying up
simonmar [Tue, 19 Nov 2002 11:14:50 +0000 (11:14 +0000)]
[project @ 2002-11-19 11:14:50 by simonmar]
- Pull in the appropriate $(GhcStageNHcOpts)
- re-instate -I$(GHC_INCLUDE_DIR) in $(SRC_CC_OPTS) that I
accidentally removed in rev. 1.226
simonmar [Tue, 19 Nov 2002 11:10:44 +0000 (11:10 +0000)]
[project @ 2002-11-19 11:10:44 by simonmar]
Add GhcStage{1,2,3}HcOpts, empty by default
simonpj [Tue, 19 Nov 2002 09:37:08 +0000 (09:37 +0000)]
[project @ 2002-11-19 09:37:08 by simonpj]
Wibble
simonpj [Mon, 18 Nov 2002 17:01:03 +0000 (17:01 +0000)]
[project @ 2002-11-18 17:01:01 by simonpj]
-----------------------------
Perl and control-M's on Win32
-----------------------------
If the Cygwin 'perl' processes a file produced by a Mingw program
(such as ghc -M), so that the latter has DOS-style line termination,
the Cygwin 'perl' gets confused and adds extra control-M's.
This affects
a) mkdependC, which processes the .depend file produced by
ghc -M
b) the perl post-procssing step in ghc/compiler/Makefile,
which makes .depend-1 etc from .depend-BASE
The solution is to sprinkle few
binmode( HANDLE );
statements around in the perl scripts.
I think they don't affect the Unix version.
simonpj [Mon, 18 Nov 2002 14:57:09 +0000 (14:57 +0000)]
[project @ 2002-11-18 14:57:09 by simonpj]
Record some known bugs
simonpj [Mon, 18 Nov 2002 14:35:57 +0000 (14:35 +0000)]
[project @ 2002-11-18 14:35:57 by simonpj]
A TH fix; and implicit-parameter documentation
simonpj [Mon, 18 Nov 2002 14:25:55 +0000 (14:25 +0000)]
[project @ 2002-11-18 14:25:50 by simonpj]
----------------------------------------
Class ops that do not introduce for-alls
----------------------------------------
MERGE TO STABLE (if poss)
The handling of class ops that do not add an extra for-all
was utterly bogus. For example:
class C a where
fc :: (?p :: String) => a;
class D a where
fd :: (Ord a) => [a] -> [a]
De-bogus-ing means
a) Being careful when taking apart the class op type in
MkIface.tcClassOpSig
b) Ditto when making the method Id in an instance binding.
Hence new function Inst.tcInstClassOp, and its calls
in TcInstDcls, and TcClassDcls
simonpj [Mon, 18 Nov 2002 14:25:29 +0000 (14:25 +0000)]
[project @ 2002-11-18 14:25:29 by simonpj]
Comments
simonpj [Mon, 18 Nov 2002 14:22:01 +0000 (14:22 +0000)]
[project @ 2002-11-18 14:22:01 by simonpj]
----------------------------------
Ambiguity for implicit parameters
---------------------------------
MERGE TO STABLE
Implicit parameters do not cause amiguity. For example, this is OK:
foo :: (?x :: [a]) => Int -> Int
foo _ = length ?x
Test is tcrun023.hs
simonmar [Mon, 18 Nov 2002 10:45:45 +0000 (10:45 +0000)]
[project @ 2002-11-18 10:45:45 by simonmar]
Don't install HS_PROG in $libexecdir as well as $bindir on Win32.
simonmar [Mon, 18 Nov 2002 10:03:24 +0000 (10:03 +0000)]
[project @ 2002-11-18 10:03:24 by simonmar]
Use -fvia-C when compiling with 4.08.x
panne [Sun, 17 Nov 2002 15:27:08 +0000 (15:27 +0000)]
[project @ 2002-11-17 15:27:07 by panne]
Added RTS entry points as mandated by the FFI addendum to the Haskell
98 report. NOTE: The implementations of hs_init, hs_exit, and
hs_set_argv are still missing.
simonmar [Fri, 15 Nov 2002 11:20:31 +0000 (11:20 +0000)]
[project @ 2002-11-15 11:20:30 by simonmar]
- get rid of $(FptoolsHcOpts), it was ill-conceived. As it was,
$(FptoolsHcOpts) was overriding options in $(GhcHcOpts). Now,
we just use $(SRC_HC_OPTS) instead, which can be overriden
by $(GhcHcOpts).
- Don't bother adding -ldl to $(SRC_HC_OPTS) in config.mk. It is
added to the RTS's package configuration if necessary.
simonmar [Thu, 14 Nov 2002 17:01:17 +0000 (17:01 +0000)]
[project @ 2002-11-14 17:01:17 by simonmar]
wibble
simonmar [Thu, 14 Nov 2002 11:46:30 +0000 (11:46 +0000)]
[project @ 2002-11-14 11:46:30 by simonmar]
Add a new question to the FAQ: "Do I need to recompile all my code if
I upgrade GHC?".
simonmar [Thu, 14 Nov 2002 10:25:26 +0000 (10:25 +0000)]
[project @ 2002-11-14 10:25:26 by simonmar]
The $(shell ...) processing was losing some quoting in $(HC_OPTS), so
hack around it using $(patsubst ...) instead.
simonmar [Wed, 13 Nov 2002 17:02:06 +0000 (17:02 +0000)]
[project @ 2002-11-13 17:02:06 by simonmar]
Add -f to ln -s command
simonmar [Wed, 13 Nov 2002 12:21:09 +0000 (12:21 +0000)]
[project @ 2002-11-13 12:21:08 by simonmar]
Add support for gcc-style "make bootstrap" which will build the stage
1, 2 and 3 compilers in the same build tree.
The idea is to simplify building a stage 2 or 3 compiler (now you only
need one build tree), and also speed up the build: there's no need to
compile the libraries more than once, because the stage 1 libraries
are used for stages 2 & 3.
In ghc/compiler, the objects and .hi files are now placed in
subdirectories: ghc/compiler/stage1 has the stage1 objects,
ghc/compiler/stage2 has the stage2 objects, etc.
The story from the top-level (fptools) is this:
make all works as before (i.e. builds ghc (stage 1),
libraries, etc.)
make stage2 builds the stage 2 compiler
make stage3 builds the stage 3 compiler
make bootstrap does 'make all' followed by 'make stage2'
make bootstrap3 does 'make all' followed by 'make stage2; make stage3'
In ghc/compiler, the story is now:
make all works as before (i.e. builds stage 1 only)
make boot generate build dirs and dependencies for stage 1
make boot stage=N generate build dirs and dependencies for stage N
make stageN
make stage=N builds stage N compiler. Run it in-place using
./stageN/ghc-inplace.
I haven't decided what to do about 'make install' yet, and this still
needs documenting in the Building Guide. Also, you still get the same
$(GhcHcOpts) for each stage.
chak [Wed, 13 Nov 2002 09:57:02 +0000 (09:57 +0000)]
[project @ 2002-11-13 09:57:02 by chak]
Added forall's to the representation of type terms
chak [Wed, 13 Nov 2002 07:17:34 +0000 (07:17 +0000)]
[project @ 2002-11-13 07:17:34 by chak]
More details about the handling of binders in DsMeta
panne [Mon, 11 Nov 2002 18:42:09 +0000 (18:42 +0000)]
[project @ 2002-11-11 18:42:09 by panne]
Warning police: Removed "possibly uninitialized variable" warning.
simonmar [Mon, 11 Nov 2002 15:49:58 +0000 (15:49 +0000)]
[project @ 2002-11-11 15:49:58 by simonmar]
- embelish the documentation for +RTS -xc a bit
- add some more question/answer pairs to the FAQ
simonmar [Mon, 11 Nov 2002 11:18:39 +0000 (11:18 +0000)]
[project @ 2002-11-11 11:18:39 by simonmar]
Increase the size of many of the int variables used in hp2ps to 64
bits on a 32 bit machine, since they can easily overflow if the
program runs for a few seconds.
Fortunately there was a useful typedef to change - I couldn't be
bothered figuring out exactly which variables to make wider, and the
performance of hp2ps isn't really critical anyhow (this change makes
it about 30% slower, but who cares).
simonpj [Mon, 11 Nov 2002 11:04:10 +0000 (11:04 +0000)]
[project @ 2002-11-11 11:04:10 by simonpj]
-----------------
Template Haskell
-----------------
Template Haskell should now work in all modes!
Remove test for --make/--interactive mode.
simonpj [Mon, 11 Nov 2002 11:02:55 +0000 (11:02 +0000)]
[project @ 2002-11-11 11:02:55 by simonpj]
Back out accidental commit
simonpj [Mon, 11 Nov 2002 10:59:09 +0000 (10:59 +0000)]
[project @ 2002-11-11 10:59:07 by simonpj]
Comments only
simonpj [Mon, 11 Nov 2002 10:58:40 +0000 (10:58 +0000)]
[project @ 2002-11-11 10:58:40 by simonpj]
------------------
Improve byte-code compilation of unboxed
tuple returns
------------------
The previous byte-code for returning unboxed tuples was just wrong. It's
a special case for the situation where we return (# s, x #), where s is
a state token, so we can just return the single result 'x' on top of the
stack. Previously we generated an ENTER at the end, which is plain wrong.
We should RETURN.
It still doesn't work, for other tiresome reasons...but rather than fix it
we'll wait for eval-apply. Meanwhile it's less wrong than before.
simonpj [Mon, 11 Nov 2002 10:53:29 +0000 (10:53 +0000)]
[project @ 2002-11-11 10:53:28 by simonpj]
------------------
Fix a newtype-deriving bug
------------------
The new newtype-deriving mechanism was erroneously using the
*representation type* of the newtype. The rep type looks through all
ihtermediate newtypes, so that is wrong. See Note [newtype
representation] in TcDeriv.lhs
deriving/should_run/drvrun013 now tests for this.
chak [Sat, 9 Nov 2002 09:58:57 +0000 (09:58 +0000)]
[project @ 2002-11-09 09:58:56 by chak]
Changed implementation of representation of negation to use function
application instead of a special syntactic form as suggested by SPJ.
chak [Sat, 9 Nov 2002 09:31:37 +0000 (09:31 +0000)]
[project @ 2002-11-09 09:31:36 by chak]
Some documentation covering the extra desugaring that is needed for Template
Haskell.
simonpj [Fri, 8 Nov 2002 15:21:28 +0000 (15:21 +0000)]
[project @ 2002-11-08 15:21:27 by simonpj]
--------------------------------
Expression simplification for TH
--------------------------------
Simplify expressions without any inlining in SimplCore.simplifyExpr.
simplifyExpr is used to simplify a TH splice before running the code,
and simplifyExpr was using (SimplPhase 0) which allows inlining.
Unfortunately, when -O is on (which can happen when compiling a program
with some splices with -O) some inlining can happen which then confuses
the byte-code generator. (Unboxed tuples.)
simonpj [Fri, 8 Nov 2002 15:16:50 +0000 (15:16 +0000)]
[project @ 2002-11-08 15:16:50 by simonpj]
Wibbles
simonmar [Fri, 8 Nov 2002 12:52:51 +0000 (12:52 +0000)]
[project @ 2002-11-08 12:52:51 by simonmar]
oops, should really check for .hi-boot-<version> before .hi-boot
simonpj [Fri, 8 Nov 2002 09:01:07 +0000 (09:01 +0000)]
[project @ 2002-11-08 09:01:06 by simonpj]
------------------
More TH stuff (thanks to Ian L)
------------------
* Make TH Literals have an Integer not an Int
* Desguar TH 'foreign import' a bit better
* Minor documentation changes
simonmar [Thu, 7 Nov 2002 14:42:25 +0000 (14:42 +0000)]
[project @ 2002-11-07 14:42:25 by simonmar]
Put a "warning:" prefix on a DEBUG belch msg to make it clearer that
this isn't an error.
simonpj [Thu, 7 Nov 2002 11:42:48 +0000 (11:42 +0000)]
[project @ 2002-11-07 11:42:48 by simonpj]
------------------
Fix an obscure bug in implicit parameters,
interacting with lazy pattern matching
------------------
MERGE TO STABLE BRANCH
The problem was this:
data UniqueSupply = US Integer
newUnique :: (?uniqueSupply :: UniqueSupply) => Integer
newUnique = r
where US r = ?uniqueSupply
The lazy pattern match in the where clause killed GHC 5.04 because the
SourceType {?uniqueSupply::UniqueSupply} of the RHS of the 'where' didn't
look like a UniqueSupply.
The fix is simple: in DsUtils.mkSelectorBinds, use the pattern, not
the rhs, to get the type reqd. More efficient too.
Test is typecheck/should_compile/tc164.hs
simonpj [Wed, 6 Nov 2002 13:10:47 +0000 (13:10 +0000)]
[project @ 2002-11-06 13:10:46 by simonpj]
------------------
Template Haskell stuff
------------------
a) Pretty printer for TH (thanks to Ian Lynagh)
b) A declaration quote has type Q [Dec], not [Q Dec] as in
the paper
c) Foreign imports are part of THSyntax, and can be spliced in
simonpj [Wed, 6 Nov 2002 12:49:51 +0000 (12:49 +0000)]
[project @ 2002-11-06 12:49:47 by simonpj]
More wibbles to do with export lists
simonpj [Wed, 6 Nov 2002 11:34:34 +0000 (11:34 +0000)]
[project @ 2002-11-06 11:34:34 by simonpj]
Dont bail out quite so fast
wolfgang [Tue, 5 Nov 2002 22:31:53 +0000 (22:31 +0000)]
[project @ 2002-11-05 22:31:53 by wolfgang]
Add the appropriate barf for memory allocation failures on Mac OS X.
simonpj [Tue, 5 Nov 2002 14:10:45 +0000 (14:10 +0000)]
[project @ 2002-11-05 14:10:44 by simonpj]
Formatting and dead code
simonpj [Tue, 5 Nov 2002 11:42:49 +0000 (11:42 +0000)]
[project @ 2002-11-05 11:42:48 by simonpj]
------------------
Fix module exports
------------------
GHC was doing the wrong thing when it came to detecting conflicts
on exports from 'module M' items. This commit fixes it.
There's a test in rename/should_fail/rnfail040
simonpj [Tue, 5 Nov 2002 09:53:22 +0000 (09:53 +0000)]
[project @ 2002-11-05 09:53:22 by simonpj]
Better reporting of unused bindings
simonmar [Tue, 5 Nov 2002 09:31:37 +0000 (09:31 +0000)]
[project @ 2002-11-05 09:31:37 by simonmar]
More wibbles: move the out of memory error message into my_mmap() to
avoid duplication, and add a couple of ToDo comments.
simonmar [Tue, 5 Nov 2002 09:26:04 +0000 (09:26 +0000)]
[project @ 2002-11-05 09:26:04 by simonmar]
Wibble in "out of memory" error message (we actually get to see it
now, rather than "getMBlock: misaligned block...").
simonpj [Tue, 5 Nov 2002 09:01:10 +0000 (09:01 +0000)]
[project @ 2002-11-05 09:01:10 by simonpj]
Wibble when renaming splices
simonpj [Mon, 4 Nov 2002 15:33:30 +0000 (15:33 +0000)]
[project @ 2002-11-04 15:33:29 by simonpj]
Fix reifyDecl
simonmar [Fri, 1 Nov 2002 11:17:29 +0000 (11:17 +0000)]
[project @ 2002-11-01 11:17:29 by simonmar]
warning police: #include <string.h> to get proto for strlen()
simonmar [Fri, 1 Nov 2002 11:16:33 +0000 (11:16 +0000)]
[project @ 2002-11-01 11:16:33 by simonmar]
total_alloc should be a 64-bit couunter.
MERGE TO STABLE
simonmar [Fri, 1 Nov 2002 11:05:47 +0000 (11:05 +0000)]
[project @ 2002-11-01 11:05:46 by simonmar]
Fix the heapCensus crash.
It turned out that after a GC, the small_alloc_list might be non-empty
if a new finalizer thread had been started. The last block on
small_alloc_list doesn't have the free pointer set correctly (as a
small optimisation, we don't normally set the free pointer after each
allocation, only when the block is full). The result was that the
free pointer contains the wrong value, and the heap census traverses
garbage. The fix is to set the free pointer correctly before
traversing small_alloc_list.
The bug doesn't show up when DEBUG is on, because extra DEBUG checks
cause the free pointer to be initialised to a sensible(-ish) value.
Hence my difficulty in reproducing the bug.
To reproduce: compile ghc-regress/lib/should_run/memo002 with
profiling and run it with a sufficiently small sample interval (-i0.02
did it for me).
Thanks to the kind folks at ARM for helping out with the debugging of
this one.
MERGE TO STABLE
simonpj [Thu, 31 Oct 2002 14:10:40 +0000 (14:10 +0000)]
[project @ 2002-10-31 14:10:40 by simonpj]
Print implicit types and bindings in External Core
simonpj [Thu, 31 Oct 2002 13:13:05 +0000 (13:13 +0000)]
[project @ 2002-10-31 13:13:04 by simonpj]
Finish TH exprs with type sigs
simonpj [Wed, 30 Oct 2002 13:17:06 +0000 (13:17 +0000)]
[project @ 2002-10-30 13:16:40 by simonpj]
Add string/rational literals, and e::t form to TH
simonpj [Wed, 30 Oct 2002 11:23:28 +0000 (11:23 +0000)]
[project @ 2002-10-30 11:23:28 by simonpj]
Remove CrossStage from Convert
simonpj [Wed, 30 Oct 2002 09:29:33 +0000 (09:29 +0000)]
[project @ 2002-10-30 09:29:33 by simonpj]
Fix an obscure record-selector-in-newtype bug
chak [Wed, 30 Oct 2002 05:46:49 +0000 (05:46 +0000)]
[project @ 2002-10-30 05:46:48 by chak]
Added support for negation to THSyntax and DsMeta.repE.
simonpj [Tue, 29 Oct 2002 17:56:58 +0000 (17:56 +0000)]
[project @ 2002-10-29 17:56:58 by simonpj]
Oops... add missing free-vars
sof [Tue, 29 Oct 2002 15:48:25 +0000 (15:48 +0000)]
[project @ 2002-10-29 15:48:25 by sof]
err msg wibble
simonmar [Tue, 29 Oct 2002 15:43:12 +0000 (15:43 +0000)]
[project @ 2002-10-29 15:43:12 by simonmar]
Add a note about where the time spent in foreign code is attributed.
chak [Tue, 29 Oct 2002 13:16:46 +0000 (13:16 +0000)]
[project @ 2002-10-29 13:16:46 by chak]
Cleaned up `repE'. Reordered to match order of cases in HsExpr and made an
effort to catch all cases.
simonpj [Tue, 29 Oct 2002 11:58:28 +0000 (11:58 +0000)]
[project @ 2002-10-29 11:58:28 by simonpj]
Wibble to lint-ing unfoldings
chak [Tue, 29 Oct 2002 11:57:41 +0000 (11:57 +0000)]
[project @ 2002-10-29 11:57:41 by chak]
Added a case for HsPar to repE. Also completed the cases in repE to at
least panic for the missing syntactic forms of HsExpr.
Is there any good reason for the semi-random order of the cases in repE?
Using the same order as in the data declaration for HsExpr would make it
easier to spot missing cases.
simonpj [Tue, 29 Oct 2002 10:53:42 +0000 (10:53 +0000)]
[project @ 2002-10-29 10:53:42 by simonpj]
Slight tidy up
simonpj [Tue, 29 Oct 2002 10:50:54 +0000 (10:50 +0000)]
[project @ 2002-10-29 10:50:53 by simonpj]
Make imports work for pre-504
mthomas [Tue, 29 Oct 2002 04:01:01 +0000 (04:01 +0000)]
[project @ 2002-10-29 04:00:59 by mthomas]
Remove unnecessary compiler and linker flags for Mingw32.
simonpj [Mon, 28 Oct 2002 11:21:14 +0000 (11:21 +0000)]
[project @ 2002-10-28 11:21:13 by simonpj]
Track locations for binders better (fixes several rn and mod failures)
simonpj [Mon, 28 Oct 2002 10:11:17 +0000 (10:11 +0000)]
[project @ 2002-10-28 10:11:17 by simonpj]
Use getExecDir, just like in ghc-pkg and SysTools
simonpj [Mon, 28 Oct 2002 09:52:14 +0000 (09:52 +0000)]
[project @ 2002-10-28 09:52:14 by simonpj]
Fix bogon in linker
wolfgang [Sun, 27 Oct 2002 21:47:36 +0000 (21:47 +0000)]
[project @ 2002-10-27 21:47:36 by wolfgang]
Fix a type and a bug for PowerPC.
wolfgang [Sun, 27 Oct 2002 21:46:27 +0000 (21:46 +0000)]
[project @ 2002-10-27 21:46:27 by wolfgang]
For Mac OS X, use the underlying Mach Microkernel calls instead of mmap.
Darwin's mmap doesn't honor the passed-in address without MAP_FIXED,
and MAP_FIXED replaces all existing mappings, so it can't be used.
mthomas [Sun, 27 Oct 2002 10:38:33 +0000 (10:38 +0000)]
[project @ 2002-10-27 10:38:32 by mthomas]
Remove Win32 library dependency.
simonpj [Fri, 25 Oct 2002 21:59:52 +0000 (21:59 +0000)]
[project @ 2002-10-25 21:59:51 by simonpj]
Put findLinkable in Finder.lhs, where it can be found in non-ghci stage1 compilers!