Ticket #2759: fix2759.patch

File fix2759.patch, 89.7 KB (added by dreixel, 9 years ago)
2New patches:
4[Fix #2759: add ability to serialize Rational
5'Jose Pedro Magalhaes <jpm@cs.uu.nl>'**20081209125551] {
6hunk ./compiler/utils/Serialized.hs 89
7-serializeConstr (FloatConstr d)  = serializeWord8 3 . serializeDouble d
8+serializeConstr (FloatConstr r)  = serializeWord8 3 . serializeRational r
9hunk ./compiler/utils/Serialized.hs 95
10-                                1 -> deserializeInt     bytes $ \ix -> k (AlgConstr ix)
11-                                2 -> deserializeInteger bytes $ \i  -> k (IntConstr i)
12-                                3 -> deserializeDouble  bytes $ \d  -> k (FloatConstr d)
13-                                4 -> deserializeString  bytes $ \s  -> k (StringConstr s)
14+                                1 -> deserializeInt      bytes $ \ix -> k (AlgConstr ix)
15+                                2 -> deserializeInteger  bytes $ \i  -> k (IntConstr i)
16+                                3 -> deserializeRational bytes $ \r  -> k (FloatConstr r)
17+                                4 -> deserializeString   bytes $ \s  -> k (StringConstr s)
18hunk ./compiler/utils/Serialized.hs 143
19-serializeDouble :: Double -> [Word8] -> [Word8]
20-serializeDouble = serializeString . show
21+serializeRational :: (Real a) => a -> [Word8] -> [Word8]
22+serializeRational = serializeString . show . toRational
23hunk ./compiler/utils/Serialized.hs 146
24-deserializeDouble :: [Word8] -> (Double -> [Word8] -> a) -> a
25-deserializeDouble bytes k = deserializeString bytes (k . read)
26+deserializeRational :: (Fractional a) => [Word8] -> (a -> [Word8] -> b) -> b
27+deserializeRational bytes k = deserializeString bytes (k . fromRational . read)
28hunk ./compiler/utils/Serialized.hs 175
35[Inject implicit bindings after CoreTidy, not before Simplify
38 Originally I inject the "implicit bindings" (record selectors, class
39 method selectors, data con wrappers...) after CoreTidy.  However, in a
40 misguided attempt to fix Trac #2070, I moved the injection point to
41 before the Simplifier, so that record selectors would be optimised by
42 the simplifier.
44 This was misguided because record selectors (indeed all implicit bindings)
45 are GlobalIds, whose IdInfo is meant to be frozen.  But the Simplifier,
46 and other Core-to-Core optimisations, merrily change the IdInfo.  That
47 ultimately made Trac #2844 happen, where a record selector got arity 2,
48 but the GlobalId (which importing scopes re-construct from the class decl
49 rather than reading from the interface file) has arity 1.
51 So this patch moves the injection back to CoreTidy. Happily #2070 should
52 still be OK because we now use CoreSubst.simpleOptExpr on the unfoldings
53 for implict things, which gets rid of the most gratuitous infelicities.
55 Still, there's a strong case for stoppping record selectors from being
56 GlobalIds, and treating them much more like dict-funs.  I'm thinking
57 about that.  Meanwhile, #2844 is ok now.
60[Add assertion for arity match (checks Trac #2844)
63 The exported arity of a function must match the arity for the
64 STG function.  Trac #2844 was a pretty obscure manifestation of
65 the failure of this invariant. This patch doesn't cure the bug;
66 rather it adds an assertion to CoreToStg to check the invariant
67 so we should get an earlier and less obscure warning if this
68 fails in future.
71[Use CoreSubst.simpleOptExpr in place of the ad-hoc simpleSubst (reduces code too)
73[Move simpleOptExpr from CoreUnfold to CoreSubst
75[White space only
77[Comments only
79[Completely new treatment of INLINE pragmas (big patch)
82 This is a major patch, which changes the way INLINE pragmas work.
83 Although lots of files are touched, the net is only +21 lines of
84 code -- and I bet that most of those are comments!
86 HEADS UP: interface file format has changed, so you'll need to
87 recompile everything.
89 There is not much effect on overall performance for nofib,
90 probably because those programs don't make heavy use of INLINE pragmas.
92         Program           Size    Allocs   Runtime   Elapsed
93             Min         -11.3%     -6.9%     -9.2%     -8.2%
94             Max          -0.1%     +4.6%     +7.5%     +8.9%
95  Geometric Mean          -2.2%     -0.2%     -1.0%     -0.8%
97 (The +4.6% for on allocs is cichelli; see other patch relating to
98 -fpass-case-bndr-to-join-points.)
100 The old INLINE system
101 ~~~~~~~~~~~~~~~~~~~~~
102 The old system worked like this. A function with an INLINE pragam
103 got a right-hand side which looked like
104      f = __inline_me__ (\xy. e)
105 The __inline_me__ part was an InlineNote, and was treated specially
106 in various ways.  Notably, the simplifier didn't inline inside an
107 __inline_me__ note. 
109 As a result, the code for f itself was pretty crappy. That matters
110 if you say (map f xs), because then you execute the code for f,
111 rather than inlining a copy at the call site.
113 The new story: InlineRules
114 ~~~~~~~~~~~~~~~~~~~~~~~~~~
115 The new system removes the InlineMe Note altogether.  Instead there
116 is a new constructor InlineRule in CoreSyn.Unfolding.  This is a
117 bit like a RULE, in that it remembers the template to be inlined inside
118 the InlineRule.  No simplification or inlining is done on an InlineRule,
119 just like RULEs. 
121 An Id can have an InlineRule *or* a CoreUnfolding (since these are two
122 constructors from Unfolding). The simplifier treats them differently:
124   - An InlineRule is has the substitution applied (like RULES) but
125     is otherwise left undisturbed.
127   - A CoreUnfolding is updated with the new RHS of the definition,
128     on each iteration of the simplifier.
130 An InlineRule fires regardless of size, but *only* when the function
131 is applied to enough arguments.  The "arity" of the rule is specified
132 (by the programmer) as the number of args on the LHS of the "=".  So
133 it makes a difference whether you say
134        {-# INLINE f #-}
135        f x = \y -> e     or     f x y = e
136 This is one of the big new features that InlineRule gives us, and it
137 is one that Roman really wanted.
139 In contrast, a CoreUnfolding can fire when it is applied to fewer
140 args than than the function has lambdas, provided the result is small
141 enough.
144 Consequential stuff
145 ~~~~~~~~~~~~~~~~~~~
146 * A 'wrapper' no longer has a WrapperInfo in the IdInfo.  Instead,
147   the InlineRule has a field identifying wrappers.
149 * Of course, IfaceSyn and interface serialisation changes appropriately.
151 * Making implication constraints inline nicely was a bit fiddly. In
152   the end I added a var_inline field to HsBInd.VarBind, which is why
153   this patch affects the type checker slightly
155 * I made some changes to the way in which eta expansion happens in
156   CorePrep, mainly to ensure that *arguments* that become let-bound
157   are also eta-expanded.  I'm still not too happy with the clarity
158   and robustness fo the result.
160 * We now complain if the programmer gives an INLINE pragma for
161   a recursive function (prevsiously we just ignored it).  Reason for
162   change: we don't want an InlineRule on a LoopBreaker, because then
163   we'd have to check for loop-breaker-hood at occurrence sites (which
164   isn't currenlty done).  Some tests need changing as a result.
166 This patch has been in my tree for quite a while, so there are
167 probably some other minor changes.
170[Add -fpass-case-bndr-to-join-points
173 See Note [Passing the case binder to join points] in Simplify.lhs
174 The default now is *not* to pass the case binder.  There are some
175 nofib results with the above note; the effect is almost always
176 negligible.
178 I don't expect this flag to be used by users (hence no docs). It's just
179 there to let me try the performance effects of switching on and off.
182[Add static flag -fsimple-list-literals
185 The new static flag -fsimple-list-literals makes ExplicitList literals
186 be desugared in the straightforward way, rather than using 'build' as
187 now.  See SLPJ comments with Note [Desugaring explicit lists].
189 I don't expect this flag to be used by users (hence no docs). It's just
190 there to let me try the performance effects of switching on and off.
193[Comments only in OccurAnal
195[Comments only
197[Layout only
199[Comments only (Note [Entering error thunks])
201[Make CoreToStg a little more robust to eta expansion
203[Add no-op case for addIdSpecialisations (very minor optimisation)
205[Trim redundant import
207[Make CoreTidy retain deadness info (better -ddump-simpl)
210 GHC now retains more robust information about dead variables; but
211 CoreTidy was throwing it away.  This patch makes CoreTidy retain it,
212 which gives better output for -ddump-simpl.
214 New opportunity: shrink interface files by using wildcards for dead variables.
218[Remove INLINE pragmas on recursive functions
221 INLINE pragmas on recursive functions are ignored; and this
222 is checked in my upcoming patch for inlinings.
225[Comments only (on Activation)
227[We need to tell cabal-bin which version of Cabal to use
228Ian Lynagh <igloo@earth.li>**20081203123208
229 Otherwise, if the bootstrapping compiler has a newer version, we get
230 a mismatch between the version used to compile ghc-prim's Setup.hs and
231 the version that installPackage uses.
233[Document 'loadModule'.
234Thomas Schilling <nominolo@googlemail.com>**20081202154800]
235[Add 'needsTemplateHaskell' utility function and document why one might
236Thomas Schilling <nominolo@googlemail.com>**20081202152358
237 want to use it.
239[Documentation only.
240Thomas Schilling <nominolo@googlemail.com>**20081202150158]
241[Export 'succeeded' and 'failed' helper functions.
242Thomas Schilling <nominolo@googlemail.com>**20081202144451]
243[Put full ImportDecls in ModSummary instead of just ModuleNames
244Simon Marlow <marlowsd@gmail.com>**20081202133736
245 ... and use it to make ghc -M generate correct cross-package
246 dependencies when using package-qualified imports (needed for the new
247 build system).  Since we're already parsing the ImportDecl from the
248 source file, there seems no good reason not to keep it in the
249 ModSummary, it might be useful for other things too.
251[ghc -M: need to add a dep on Prelude unless -fno-implicit-prelude is on
252Simon Marlow <marlowsd@gmail.com>**20081128165707]
253[make -include-pkg-deps work (not sure when this got lost)
254Simon Marlow <marlowsd@gmail.com>**20081128135746]
255[Fix more problems caused by padding in the Capability structure
256Simon Marlow <marlowsd@gmail.com>**20081202120735
257 Fixes crashes on Windows and Sparc
259[add missing case to Ord GlobalReg (EagerBlackhole == EagerBlackhole)
260Simon Marlow <marlowsd@gmail.com>**20081128130106]
261[Better error message for fundep conflict
263[Fix typo in quasi-quote documentation's sample.
264shelarcy <shelarcy@gmail.com>**20081129024344]
265[Remove the v_Split_info global variable and use a field of dflags instead
266Ian Lynagh <igloo@earth.li>**20081130152403]
267[Document the --machine-readable RTS flag
268Ian Lynagh <igloo@earth.li>**20081130152311]
269[Let 'loadModule' generate proper code depending on the 'hscTarget'.
270Thomas Schilling <nominolo@googlemail.com>**20081128164412
272 With this change it should be possible to perform something similar to
273 'load' by traversing the module graph in dependency order and calling
274 '{parse,typecheck,load}Module' on each.  Of course, if you want smart
275 recompilation checking you should still use 'load'.
277[Expose a separate 'hscBackend' phase for 'HsCompiler' and change
278Thomas Schilling <nominolo@googlemail.com>**20081128163746
279 parameter to 'InteractiveStatus' to a 'Maybe'.
281[Whoops, *don't* reset the complete session in 'withLocalCallbacks'.
282Thomas Schilling <nominolo@googlemail.com>**20081128150727]
283[Use a record instead of a typeclass for 'HsCompiler'.  This is mostly
284Thomas Schilling <nominolo@googlemail.com>**20081128121947
285 equivalent to a typeclass implementation that uses a functional
286 dependency from the target mode to the result type.
288[Remove dead code
289Ian Lynagh <igloo@earth.li>**20081128193831]
290[Update docs not to talk about deprecated -optdep-* flags; fixes trac #2773
291Ian Lynagh <igloo@earth.li>**20081128193633]
292[Use relative URLs in the GHC API haddock docs; fixes #2755
293Ian Lynagh <igloo@earth.li>**20081128184511]
294[Teach runghc about --help; fixes trac #2757
295Ian Lynagh <igloo@earth.li>**20081128191706]
296[Use a per-session data structure for callbacks.  Make 'WarnErrLogger'
297Thomas Schilling <nominolo@googlemail.com>**20081128103628
298 part of it.
300 Part of the GHC API essentially represents a compilation framework.
301 The difference of a *framework* as opposed to a *library* is that the
302 overall structure of the functionality is pre-defined but certain
303 details can be customised via callbacks.  (Also known as the Hollywood
304 Principle: "Don't call us, we'll call you.")
306 This patch introduces a per-session data structure that contains all
307 the callbacks instead of adding lots of small function arguments
308 whenever we want to give the user more control over certain parts of
309 the API.  This should also help with future changes: Adding a new
310 callback doesn't break old code since code that doesn't know about the
311 new callback will use the (hopefully sane) default implementation.
313 Overall, however, we should try and keep the number of callbacks small
314 and well-defined (and provide useful defaults) and use simple library
315 routines for the rest.
317[Improve error message for #2739 (but no fix).
318Thomas Schilling <nominolo@googlemail.com>**20081127135725
320 This patch changes 'loadModule' to define a fake linkable.  The
321 previous implementation of providing no linkable at all violated a
322 pre-condition in the ByteCode linker.  This doesn't fix #2739, but it
323 improves the error message a bit.
325[Remove the packing I added recently to the Capability structure
326Simon Marlow <marlowsd@gmail.com>**20081128105046
327 The problem is that the packing caused some unaligned loads, which
328 lead to bus errors on Sparc (and reduced performance elsewhere,
329 presumably).
331[don't emit CmmComments for now
332Simon Marlow <marlowsd@gmail.com>**20081127090145
333   - if the string contains */, we need to fix it (demonstrated by
334     building Cabal with -fvia-C)
335   - the strings can get quite large, so we probably only want to
336     inject comments when some debugging option is on.
338[Collect instead of print warnings in 'warnUnnecessarySourceImports'.
339Thomas Schilling <nominolo@googlemail.com>**20081127102534]
340[Force recompilation of BCOs when they were compiled in HscNothing mode.
341Thomas Schilling <nominolo@googlemail.com>**20081126183402
343 Previously, loading a set of modules in HscNothing mode and then
344 switching to HscInterpreted could lead to crashes since modules
345 compiled with HscNothing were thought to be valid bytecode objects.
347 This patch forces recompilation in these cases, hence switching between
348 HscNothing and HscInterpreted should be safe now.
350[Documentation only: Add module description for HscMain.
351Thomas Schilling <nominolo@googlemail.com>**20081126134344]
352[Include GHCi files in ctags/etags.
353Thomas Schilling <nominolo@googlemail.com>**20081126122801]
354[drop some debugging traces and use only one flag for new codegen
356[one more missing patch from new codegen path
358[Fix Trac #2817 (TH syntax -> HsSyn conversion)
360[Fix Trac #2756: CorePrep strictness bug
362[Format output for :t more nicely
364[Fix Trac #2766: printing operator type variables
366[Fix build following codegen patch
368[Removed warnings, made Haddock happy, added examples in documentation
370 The interesting examples talk about our story with heap checks in
371 case alternatives and our story with the case scrutinee as a Boolean.
373[Fixed linear regalloc bug, dropped some tracing code
375 o The linear-scan register allocator sometimes allocated a block
376   before allocating one of its predecessors, which could lead
377   to inconsistent allocations. Now, we allocate a block only
378   if a predecessor has set the "incoming" assignments for the block
379   (or if it's the procedure's entry block).
380 o Also commented out some tracing code on the new codegen path.
382[Keep update frames live even in functions that never return
384 An unusual case, but without it:
385 (a) we had an assertion failure
386 (b) we can overwrite the caller's infotable, which might cause
387     the garbage collector to collect live data.
388 Better to keep the update frame live at all call sites,
389 not just at returns.
391[Removed space and time inefficiency in procpoint splitting
393 I was adding extra jumps to every procpoint, even when the split-off graph
394 referred to only some of the procpoints. No effect on correctness,
395 but a big effect on space/time efficiency when there are lots of procpoints...
397[Clarify the SRT building process
399 Before: building a closure that would build an SRT given the top-level
400 SRT. It was somewhat difficult to understand the control flow, and it
401 may have had held onto some data structures long after they should be dead.
402 Now, I just bundle the info we need about CAFs along with the procedure
403 and directly call a new top-level function to build the SRTs later.
405[Don't adjust hp up when the case scrutinee won't allocate
408 If the case scrutinee can't allocate, we don't need to do a heap
409 check in the case alternatives. (A previous patch got that right.)
410 In that case, we had better not adjust the heap pointer to recover
411 unused stack space before evaluating the scrutinee -- because we
412 aren't going to reallocate for the case alternative.
414[Floating infotables were reversed in C back end
416[forgot a few files
418[Big collection of patches for the new codegen branch.
420 o Fixed bug that emitted the copy-in code for closure entry
421   in the wrong place -- at the initialization of the closure.
422 o Refactored some of the closure entry code.
423 o Added code to check that no LocalRegs are live-in to a procedure
424    -- trip up some buggy programs earlier
425 o Fixed environment bindings for thunks
426    -- we weren't (re)binding the free variables in a thunk
427 o Fixed a bug in proc-point splitting that dropped some updates
428   to the entry block in a procedure.
429 o Fixed improper calls to code that generates CmmLit's for strings
430 o New invariant on cg_loc in CgIdInfo: the expression is always tagged
431 o Code to load free vars on entry to a thunk was (wrongly) placed before
432   the heap check.
433 o Some of the StgCmm code was redundantly passing around Id's
434   along with CgIdInfo's; no more.
435 o Initialize the LocalReg's that point to a closure before allocating and
436   initializing the closure itself -- otherwise, we have problems with
437   recursive closure bindings
438 o BlockEnv and BlockSet types are now abstract.
439 o Update frames:
440   - push arguments in Old call area
441   - keep track of the return sp in the FCode monad
442   - keep the return sp in every call, tail call, and return
443       (because it might be different at different call sites,
444        e.g. tail calls to the gc after a heap check are performed
445             before pushing the update frame)
446   - set the sp appropriately on returns and tail calls
447 o Reduce call, tail call, and return to a single LastCall node
448 o Added slow entry code, using different calling conventions on entry and tail call
449 o More fixes to the calling convention code.
450   The tricky stuff is all about the closure environment: it must be passed in R1,
451   but in non-closures, there is no such argument, so we can't treat all arguments
452   the same way: the closure environment is special. Maybe the right step forward
453   would be to define a different calling convention for closure arguments.
454 o Let-no-escapes need to be emitted out-of-line -- otherwise, we drop code.
455 o Respect RTS requirement of word alignment for pointers
456   My stack allocation can pack sub-word values into a single word on the stack,
457   but it wasn't requiring word-alignment for pointers. It does now,
458   by word-aligning both pointer registers and call areas.
459 o CmmLint was over-aggresively ruling out non-word-aligned memory references,
460   which may be kosher now that we can spill small values into a single word.
461 o Wrong label order on a conditional branch when compiling switches.
462 o void args weren't dropped in many cases.
463   To help prevent this kind of mistake, I defined a NonVoid wrapper,
464   which I'm applying only to Id's for now, although there are probably
465   other good candidates.
466 o A little code refactoring: separate modules for procpoint analysis splitting,
467   stack layout, and building infotables.
468 o Stack limit check: insert along with the heap limit check, using a symbolic
469   constant (a special CmmLit), then replace it when the stack layout is known.
470 o Removed last node: MidAddToContext
471 o Adding block id as a literal: means that the lowering of the calling conventions
472   no longer has to produce labels early, which was inhibiting common-block elimination.
473   Will also make it easier for the non-procpoint-splitting path.
474 o Info tables: don't try to describe the update frame!
475 o Over aggressive use of NonVoid!!!!
476   Don't drop the non-void args before setting the type of the closure!!!
477 o Sanity checking:
478   Added a pass to stub dead dead slots on the stack
479   (only ~10 lines with the dataflow framework)
480 o More sanity checking:
481   Check that incoming pointer arguments are non-stubbed.
482   Note: these checks are still subject to dead-code removal, but they should
483   still be quite helpful.
484 o Better sanity checking: why stop at function arguments?
485   Instead, in mkAssign, check that _any_ assignment to a pointer type is non-null
486   -- the sooner the crash, the easier it is to debug.
487   Still need to add the debugging flag to turn these checks on explicitly.
488 o Fixed yet another calling convention bug.
489   This time, the calls to the GC were wrong. I've added a new convention
490   for GC calls and invoked it where appropriate.
491   We should really straighten out the calling convention stuff:
492     some of the code (and documentation) is spread across the compiler,
493     and there's some magical use of the node register that should really
494     be handled (not avoided) by calling conventions.
495 o Switch bug: the arms in mkCmmLitSwitch weren't returning to a single join point.
496 o Environment shadowing problem in Stg->Cmm:
497   When a closure f is bound at the top-level, we should not bind f to the
498   node register on entry to the closure.
499   Why? Because if the body of f contains a let-bound closure g that refers
500   to f, we want to make sure that it refers to the static closure for f.
501   Normally, this would all be fine, because when we compile a closure,
502   we rebind free variables in the environment. But f doesn't look like
503   a free variable because it's a static value. So, the binding for f
504   remains in the environment when we compile g, inconveniently referring
505   to the wrong thing.
506   Now, I bind the variable in the local environment only if the closure is not
507   bound at the top level. It's still okay to make assumptions about the
508   node holding the closure environment; we just won't find the binding
509   in the environment, so code that names the closure will now directly
510   get the label of the static closure, not the node register holding a
511   pointer to the static closure.
512 o Don't generate bogus Cmm code containing SRTs during the STG -> Cmm pass!
513   The tables made reference to some labels that don't exist when we compute and
514   generate the tables in the back end.
515 o Safe foreign calls need some special treatment (at least until we have the integrated
516   codegen). In particular:
517   o they need info tables
518   o they are not procpoints -- the successor had better be in the same procedure
519   o we cannot (yet) implement the calling conventions early, which means we have
520     to carry the calling-conv info all the way to the end
521 o We weren't following the old convention when registering a module.
522   Now, we use update frames to push any new modules that have to be registered
523   and enter the youngest one on the stack.
524   We also use the update frame machinery to specify that the return should pop
525   the return address off the stack.
526 o At each safe foreign call, an infotable must be at the bottom of the stack,
527   and the TSO->sp must point to it.
528 o More problems with void args in a direct call to a function:
529   We were checking the args (minus voids) to check whether the call was saturated,
530   which caused problems when the function really wasn't saturated because it
531   took an extra void argument.
532 o Forgot to distinguish integer != from floating != during Stg->Cmm
533 o Updating slotEnv and areaMap to include safe foreign calls
534   The dataflow analyses that produce the slotEnv and areaMap give
535   results for each basic block, but we also need the results for
536   a safe foreign call, which is a middle node.
537   After running the dataflow analysis, we have another pass that
538   updates the results to includ any safe foreign calls.
539 o Added a static flag for the debugging technique that inserts
540   instructions to stub dead slots on the stack and crashes when
541   a stubbed value is loaded into a pointer-typed LocalReg.
542 o C back end expects to see return continuations before their call sites.
543   Sorted the flowgraphs appropriately after splitting.
544 o PrimOp calling conventions are special -- unlimited registers, no stack
545   Yet another calling convention...
546 o More void value problems: if the RHS of a case arm is a void-typed variable,
547   don't try to return it.
548 o When calling some primOp, they may allocate memory; if so, we need to
549   do a heap check when we return from the call.
552[Merging in the new codegen branch
554 This merge does not turn on the new codegen (which only compiles
555 a select few programs at this point),
556 but it does introduce some changes to the old code generator.
558 The high bits:
559 1. The Rep Swamp patch is finally here.
560    The highlight is that the representation of types at the
561    machine level has changed.
562    Consequently, this patch contains updates across several back ends.
563 2. The new Stg -> Cmm path is here, although it appears to have a
564    fair number of bugs lurking.
565 3. Many improvements along the CmmCPSZ path, including:
566    o stack layout
567    o some code for infotables, half of which is right and half wrong
568    o proc-point splitting
570[Major clean-up of HscMain.
571Thomas Schilling <nominolo@googlemail.com>**20081125153201
573 This patch entails a major restructuring of HscMain and a small bugfix
574 to MkIface (which required the restructuring in HscMain).
576 In MkIface:
578   - mkIface* no longer outputs orphan warnings directly and also no
579     longer quits GHC when -Werror is set.  Instead, errors are
580     reported using the common IO (Messages, Maybe result) scheme.
582 In HscMain:
584   - Get rid of the 'Comp' monad.  This monad was mostly GhcMonad + two
585     reader arguments, a ModSummary for the currently compiled module
586     and a possible old interface.  The latter actually lead to a small
587     space-leak since only its hash was needed (to check whether the
588     newly-generated interface file was the same as the original one).
590     Functions originally of type 'Comp' now only take the arguments
591     that they actually need.  This leads to slighly longer argument
592     lists in some places, however, it is now much easier to see what
593     is actually going on.
595   - Get rid of 'myParseModule'.  Rename 'parseFile' to 'hscParse'.
597   - Join 'deSugarModule' and 'hscDesugar' (keeping the latter).
599   - Rename 'typecheck{Rename}Module{'}' to 'hscTypecheck{Rename}'.
600     One variant keeps the renamed syntax, the other doesn't.
602   - Parameterise 'HscStatus', so that 'InteractiveStatus' is just a
603     different parameterisation of 'HscStatus'.
605   - 'hscCompile{OneShot,Batch,Nothing,Interactive}' are now
606     implemented using a (local) typeclass called 'HsCompiler'.  The
607     idea is to make the common structure more obvious.  Using this
608     typeclass we now have two functions 'genericHscCompile' (original
609     'hscCompiler') and 'genericHscRecompile' (original 'genComp')
610     describing the default pipeline.  The methods of the typeclass
611     describe a sort of "hook" interface (in OO-terms this would be
612     called the "template method" pattern).
614     One problem with this approach is that we parameterise over the
615     /result/ type which, in fact, is not actually different for
616     "nothing" and "batch" mode.  To avoid functional dependencies or
617     associated types, we use type tags to make them artificially
618     different and parameterise the type class over the result type.
619     A perhaps better approach might be to use records instead.
621   - Drop some redundant 'HscEnv' arguments.  These were likely
622     different from what 'getSession' would return because during
623     compilation we temporarily set the module's DynFlags as well as a
624     few other fields.  We now use the 'withTempSession' combinator to
625     temporarily change the 'HscEnv' and automatically restore the
626     original session after the enclosed action has returned (even in
627     case of exceptions).
629   - Rename 'hscCompile' to 'hscGenHardCode' (since that is what it
630     does).
632 Calls in 'GHC' and 'DriverPipeline' accordingly needed small
633 adaptions.
635[Fix Trac #2799: TcType.isOverloadedTy
638 A missing case (for equality predicates) in isOverloadedTy make
639 bindInstsOfLocalFuns/Pats do the wrong thing.  Core Lint nailed it.
641 Merge to 6.10 branch.
644[Fix #2740: we were missing the free variables on some expressions
645Simon Marlow <marlowsd@gmail.com>**20081125103113
646 Particularly boolean expresions: the conditional of an 'if', and
647 guards, were missing their free variables.
649[Fix symbol macro names in Linker.c
650Thorkil Naur <naur@post11.tele.dk>**20081121160149]
651[Add a --machine-readable RTS flag
652Ian Lynagh <igloo@earth.li>**20081123152127
653 Currently it only affects the -t flag output
655[Return errors instead of dying in myParseModule.
656Thomas Schilling <nominolo@googlemail.com>**20081122154151]
657[Comments/Haddockification only.
658Thomas Schilling <nominolo@googlemail.com>**20081122143018]
659[Report source span instead of just source location for unused names.
660Thomas Schilling <nominolo@googlemail.com>**20081122142641]
661[Change 'handleFlagWarnings' to throw exceptions instead of dying.
662Thomas Schilling <nominolo@googlemail.com>**20081122130658
664 It now uses the standard warning log and error reporting mechanism.
666[Document exported functions in main/HeaderInfo.
667Thomas Schilling <nominolo@googlemail.com>**20081121145307]
668[Remove warning supression klugde in main/HeaderInfo
669Thomas Schilling <nominolo@googlemail.com>**20081121144155]
670[Use mutator threads to do GC, instead of having a separate pool of GC threads
671Simon Marlow <marlowsd@gmail.com>**20081121151233
673 Previously, the GC had its own pool of threads to use as workers when
674 doing parallel GC.  There was a "leader", which was the mutator thread
675 that initiated the GC, and the other threads were taken from the pool.
677 This was simple and worked fine for sequential programs, where we did
678 most of the benchmarking for the parallel GC, but falls down for
679 parallel programs.  When we have N mutator threads and N cores, at GC
680 time we would have to stop N-1 mutator threads and start up N-1 GC
681 threads, and hope that the OS schedules them all onto separate cores.
682 It practice it doesn't, as you might expect.
684 Now we use the mutator threads to do GC.  This works quite nicely,
685 particularly for parallel programs, where each mutator thread scans
686 its own spark pool, which is probably in its cache anyway.
688 There are some flag changes:
690   -g<n> is removed (-g1 is still accepted for backwards compat).
691   There's no way to have a different number of GC threads than mutator
692   threads now.
694   -q1       Use one OS thread for GC (turns off parallel GC)
695   -qg<n>    Use parallel GC for generations >= <n> (default: 1)
697 Using parallel GC only for generations >=1 works well for sequential
698 programs.  Compiling an ordinary sequential program with -threaded and
699 running it with -N2 or more should help if you do a lot of GC.  I've
700 found that adding -qg0 (do parallel GC for generation 0 too) speeds up
701 some parallel programs, but slows down some sequential programs.
702 Being conservative, I left the threshold at 1.
704 ToDo: document the new options.
707[we shouldn't update topBound in discardSparks()
708Simon Marlow <marlowsd@gmail.com>**20081121113539]
709[Throw SourceErrors instead of ProgramErrors in main/HeaderInfo.
710Thomas Schilling <nominolo@googlemail.com>**20081121141339
712 Parse errors during dependency analysis or options parsing really
713 shouldn't kill GHC; this is particularly annoying for GHC API clients.
715[fix the build when !USE_MMAP
716Simon Marlow <marlowsd@gmail.com>**20081121085418]
717[round the size up to a page in mmapForLinker() instead of in the caller
718Simon Marlow <marlowsd@gmail.com>**20081120154014]
719[Fix a race in the deadlock-detection code
720Simon Marlow <marlowsd@gmail.com>**20081120112438
721 After a deadlock it was possible for the timer signal to remain off,
722 which meant that the next deadlock would not be detected, and the
723 system would hang.  Spotted by conc047(threaded2).
725[error message wibble
726Simon Marlow <marlowsd@gmail.com>**20081120084901]
727[Fix flag name -XDisambiguateRecordFields
729[Fix regTableToCapability() if gcc introduces padding
730Simon Marlow <marlowsd@gmail.com>**20081119162910
731 Also avoid padding if possible using __attribute__((packed))
732 Fixes the Windows build
734[Fix 32-bit breakage
735Simon Marlow <marlowsd@gmail.com>**20081119145429]
736[Small refactoring, and add comments
737Simon Marlow <marlowsd@gmail.com>**20081119143702
738 I discovered a new invariant while experimenting (blackholing is not
739 optional when using parallel GC), so documented it.
741[Fix some unsigned comparisions that should be signed
742Simon Marlow <marlowsd@gmail.com>**20081119143205
743 Fixes crashes when using reclaimSpark() (not used currently, but may
744 be in the future).
746[Remove incorrect assertions in steal()
747Simon Marlow <marlowsd@gmail.com>**20081119143043]
748[don't run sparks if there are other threads on this Capability
749Simon Marlow <marlowsd@gmail.com>**20081114121022]
750[Fix typo (HAVE_LIBGMP => HAVE_LIB_GMP); omit local gmp includes if HAVE_LIB_GMP
751Simon Marlow <marlowsd@gmail.com>**20081119131056
752 If we're using the system's installed GMP, we don't want to be picking
753 up the local gmp.h header file.
755 Fixes 2469(ghci) for me, because it turns out the system's GMP is more
756 up-to-date than GHC's version and has a fix for more recent versions
757 of gcc.  We also need to pull in a more recent GMP, but that's a
758 separte issue.
760[Fix some more shutdown races
761Simon Marlow <marlowsd@gmail.com>**20081119124848
762 There were races between workerTaskStop() and freeTaskManager(): we
763 need to be sure that all Tasks have exited properly before we start
764 tearing things down.  This isn't completely straighforward, see
765 comments for details.
767[Add help messages about --with-editline-(includes,libraries) to the ghc configure script.
768Judah Jacobson <judah.jacobson@gmail.com>**20081114183334]
769[Add optional eager black-holing, with new flag -feager-blackholing
770Simon Marlow <marlowsd@gmail.com>**20081118142442
772 Eager blackholing can improve parallel performance by reducing the
773 chances that two threads perform the same computation.  However, it
774 has a cost: one extra memory write per thunk entry. 
776 To get the best results, any code which may be executed in parallel
777 should be compiled with eager blackholing turned on.  But since
778 there's a cost for sequential code, we make it optional and turn it on
779 for the parallel package only.  It might be a good idea to compile
780 applications (or modules) with parallel code in with
781 -feager-blackholing.
783 ToDo: document -feager-blackholing.
785[Fix #2783: detect black-hole loops properly
786Simon Marlow <marlowsd@gmail.com>**20081117144515
787 At some point we regressed on detecting simple black-hole loops.  This
788 happened due to the introduction of duplicate-work detection for
789 parallelism: a black-hole loop looks very much like duplicate work,
790 except it's duplicate work being performed by the very same thread.
791 So we have to detect and handle this case.
793[Fix warning on Windows (use deleteThread() not deleteThread_())
794Simon Marlow <marlowsd@gmail.com>**20081117143047]
795[fix compile breakage on Windows
796Simon Marlow <marlowsd@gmail.com>**20081117142831]
797[Attempt to fix #2512 and #2063;  add +RTS -xm<address> -RTS option
798Simon Marlow <marlowsd@gmail.com>**20081117120556
799 On x86_64, the RTS needs to allocate memory in the low 2Gb of the
800 address space.  On Linux we can do this with MAP_32BIT, but sometimes
801 this doesn't work (#2512) and other OSs don't support it at all
802 (#2063).  So to work around this:
804   - Try MAP_32BIT first, if available.
806   - Otherwise, try allocating memory from a fixed address (by default
807     1Gb)
809   - We now provide an option to configure the address to allocate
810     from.  This allows a workaround on machines where the default
811     breaks, and also provides a way for people to test workarounds
812     that we can incorporate in future releases.
814[Another shutdown fix
815Simon Marlow <marlowsd@gmail.com>**20081117094350
816 If we encounter a runnable thread during shutdown, just kill it.  All
817 the threads are supposed to be dead at this stage, but this catches
818 threads that might have just returned from a foreign call, or were
819 finalizers created by the GC.
821 Fixes memo002(threaded1)
823[Correct an example in the users guide
824Ian Lynagh <igloo@earth.li>**20081116174938]
825[Fix gen_contents_index when not run inplace; trac #2764
826Ian Lynagh <igloo@earth.li>**20081116174122
827 Based on a patch from juhpetersen.
829[close the temporary Handle before removing the file
830Simon Marlow <marlowsd@gmail.com>**20081114130958]
831[refactor: move unlockClosure() into SMPClosureOps() where it should be
832Simon Marlow <marlowsd@gmail.com>**20081114095817]
833[Omit definitions of cas() and xchg() in .hc code
834Simon Marlow <marlowsd@gmail.com>**20081114095738
835 They cause compilation errors (correctly) with newer gccs
836 Shows up compiling the RTS via C, which happens on Windows
838[Don't put stdin into non-blocking mode (#2778, #2777)
839Simon Marlow <marlowsd@gmail.com>**20081114130546
840 This used to be necessary when our I/O library needed all FDs in
841 O_NONBLOCK mode, and readline used to put stdin back into blocking
842 mode.  Nowadays the I/O library can cope with FDs in blocking mode,
843 and #2778/#2777 show why this is important.
845[Rmoeve --enable-dotnet
846Simon Marlow <marlowsd@gmail.com>**20081114124929]
847[#2751: disourage --enable-shared in ./configure --help
848Simon Marlow <marlowsd@gmail.com>**20081114124748]
849[add a warning that --enable-shared is experimental
850Simon Marlow <marlowsd@gmail.com>**20081114104034]
851[lookupSymbol: revert to looking up both with and without the @N suffix
852Simon Marlow <marlowsd@gmail.com>**20081113122927]
853[#2768: fix compatibility problem with newer version of mingw
854Simon Marlow <marlowsd@gmail.com>**20081113114626]
855[notice ^C exceptions when waiting for I/O
856Simon Marlow <marlowsd@gmail.com>**20081113114342]
857[Fix a bug in the recompilation checking logic.
858Thomas Schilling <nominolo@googlemail.com>**20081113162653
860 Previously, using target HscNothing resulted in unnessesary
861 recompilation because 'upsweep_mod' treated HscInterface specially.
862 This patch changes relaxes this.
864 When running GHC with debug level 5, 'upsweep_mod' will now also be
865 more verbose about what it is doing.
867 There is (at least) one possible remaining problem, though: When using
868 target 'HscNothing' we generate a fake linkable to signal that we have
869 processed a module.  When switching to 'HscInterpreted' this may cause
870 objects to not be recompiled.  Switching from HscNothing to
871 HscInterpreted is therefore only safe if we unload everything first.
873[Fix another subtle shutdown deadlock
874Simon Marlow <marlowsd@gmail.com>**20081113160005
875 The problem occurred when a thread tries to GC during shutdown.  In
876 order to GC it has to acquire all the Capabilities in the system, but
877 during shutdown, some of the Capabilities have already been closed and
878 can never be acquired.
880[Fix an extremely subtle deadlock bug on x86_64
881Simon Marlow <marlowsd@gmail.com>**20081113155730
882 The recent_activity flag was an unsigned int, but we sometimes do a
883 64-bit xchg() on it, which overwrites the next word in memory.  This
884 happened to contain the sched_state flag, which is used to control the
885 orderly shutdown of the system.  If the xchg() happened during
886 shutdown, the scheduler would get confused and deadlock.  Don't you
887 just love C?
889[move an assertion
890Simon Marlow <marlowsd@gmail.com>**20081113154542]
891[Always zap the trailing @N from symbols when looking up in a DLL
892Simon Marlow <marlowsd@gmail.com>**20081112111518
894 Fixes win32002(ghci)
896 Previously we only did this for references from object files, but we
897 should do it for all symbols, including those that GHCi looks up due
898 to FFI calls from bytecode.
900[Only allocate a mark stack if we're actually doing marking
901Simon Marlow <marlowsd@gmail.com>**20081112112144
902 saves a bit of memory in major GCs
904[Fix parse error with older gccs (#2752)
905Simon Marlow <marlowsd@gmail.com>**20081111135344]
906[Fix to i386_insert_ffrees (#2724, #1944)
907Simon Marlow <marlowsd@gmail.com>**20081111125619
908 The i386 native code generator has to arrange that the FPU stack is
909 clear on exit from any function that uses the FPU.  Unfortunately it
910 was getting this wrong (and has been ever since this code was written,
911 I think): it was looking for basic blocks that used the FPU and adding
912 the code to clear the FPU stack on any non-local exit from the block.
913 In fact it should be doing this on a whole-function basis, rather than
914 individual basic blocks.
916[Fix bootstrap with 6.10.1 on Windows
917Simon Marlow <marlowsd@gmail.com>**20081110134318
918 ghc-pkg doesn't understand the old syntax any more, so 'ghc-pkg -l' fails
920[Perform case-insensitive matching of path components in getBaseDir on Windows (Fixes bug 2743)
921Neil Mitchell <ndmitchell@gmail.com>**20081105134315]
922[Documentation only.  Clarify that 'load*' may indeed throw SourceErrors.
923Thomas Schilling <nominolo@googlemail.com>**20081110175614
925 I don't think errors during dependency analysis should be passed to
926 the logger.
928[Fix documentation (to say the opposite).
929Thomas Schilling <nominolo@googlemail.com>**20081110153819]
930[Fix line numbers in TAGS files.
931Thomas Schilling <nominolo@googlemail.com>**20081110153621]
932[Documentation only.
933Thomas Schilling <nominolo@googlemail.com>**20081110153456]
934[Add 'packageDbModules' function to GHC API.
935Thomas Schilling <nominolo@googlemail.com>**20081110143510
937 This function returns a list of all modules available through the
938 package DB.
940 MERGE TO 6.10
942[We now require GHC 6.6, so we always have Applicative
943Ian Lynagh <igloo@earth.li>**20081108144723]
944[Remove a CPP test that's always true (__GLASGOW_HASKELL__ >= 605)
945Ian Lynagh <igloo@earth.li>**20081108144544]
946[Remove some dead code now that __GLASGOW_HASKELL__ >= 606
947Ian Lynagh <igloo@earth.li>**20081108144459]
948[Remove some flag duplication from a Makefile
949Ian Lynagh <igloo@earth.li>**20081108144412]
950[ghc_ge_605 is now always YES
951Ian Lynagh <igloo@earth.li>**20081108144328]
952[Remove the GHC 6.4 unicode compat stuff; we can now just use Data.Char
953Ian Lynagh <igloo@earth.li>**20081108143423]
954[Fix libffi bindist
955Clemens Fruhwirth <clemens@endorphin.org>**20081108094725]
956[Replace couple of fromJust with expectJust
957Clemens Fruhwirth <clemens@endorphin.org>**20081107160735]
958[Bugfix for patch "Do not filter the rts from linked libraries..." (#2745)
959Simon Marlow <marlowsd@gmail.com>**20081107092925
960 The sense of the #ifdef was wrong
962[fix via-C compilation: import ghczmprim_GHCziBool_False_closure
963Simon Marlow <marlowsd@gmail.com>**20081107090432]
964[disable instance MonadPlus CoreM for GHC <= 6.6
965Simon Marlow <marlowsd@gmail.com>**20081107085250]
966[re-instate counting of sparks converted
967Simon Marlow <marlowsd@gmail.com>**20081106160810
968 lost in patch "Run sparks in batches"
970[fix ASSERT_SPARK_POOL_INVARIANTS(): top>bottom is valid
971Simon Marlow <marlowsd@gmail.com>**20081106155826]
972[pruneSparkQueue(): fix bug when top>bottom
973Simon Marlow <marlowsd@gmail.com>**20081106155648]
974[don't yield if the system is shutting down
975Simon Marlow <marlowsd@gmail.com>**20081106155356]
976[leave out ATTRIBUTE_ALIGNED on Windows, it gives a warning
977Simon Marlow <marlowsd@gmail.com>**20081106132105]
978[Cope with ThreadRelocated when traversing the blocked_queue
979Simon Marlow <marlowsd@gmail.com>**20081106114045
980 Fixes "invalid what_next field" in ioref001 on Windows, and perhaps others
982[Remove dead code.
983Thomas Schilling <nominolo@googlemail.com>**20081031162036]
984[Run sparks in batches, instead of creating a new thread for each one
985Simon Marlow <marlowsd@gmail.com>**20081106113639
986 Signficantly reduces the overhead for par, which means that we can
987 make use of paralellism at a much finer granularity.
989[allocateInGen(): increase alloc_blocks (#2747)
990Simon Marlow <marlowsd@gmail.com>**20081106113714]
991[disable MonadPlus instance that doesn't compile with 6.6
992Simon Marlow <marlowsd@gmail.com>**20081106100411]
993[don't yield the Capability if blackholes_need_checking
994Simon Marlow <marlowsd@gmail.com>**20081105154928]
995[deadlock fix: reset the flag *after* checking the blackhole queue
996Simon Marlow <marlowsd@gmail.com>**20081105150542]
997[retreat the top/bottom fields of the spark pool in pruneSparkPool()
998Simon Marlow <marlowsd@gmail.com>**20081105150359]
999[fix the :help docs for :set stop (#2737)
1000Simon Marlow <marlowsd@gmail.com>**20081104092929]
1001[bugfix: don't ingore the return value from rts_evalIO()
1002Simon Marlow <marlowsd@gmail.com>**20081104142147]
1003[Document the new SPARKS statistic, and xref from the parallelism section
1004Simon Marlow <marlowsd@gmail.com>**20081024120236]
1005[Move the freeing of Capabilities later in the shutdown sequence
1006Simon Marlow <marlowsd@gmail.com>**20081024104301
1007 Fixes a bug whereby the Capability has been freed but other
1008 Capabilities are still trying to steal sparks from its pool.
1010[Pad Capabilities and Tasks to 64 bytes
1011Simon Marlow <marlowsd@gmail.com>**20081023080749
1012 This is just good practice to avoid placing two structures heavily
1013 accessed by different CPUs on the same cache line
1015[Fix desugaring of record update (fixes Trac #2735)
1017[Refuse to register packages with unversioned dependencies; trac #1837
1018Ian Lynagh <igloo@earth.li>**20081031181746]
1019[We now require GHC 6.6 to build the HEAD (and thus 6.12)
1020Ian Lynagh <igloo@earth.li>**20081031171506]
1021[:set prompt now understand Haskell String syntax; trace #2652
1022Ian Lynagh <igloo@earth.li>**20081031145227]
1023[Comments only
1025[Quickfix for warning.
1026Thomas Schilling <nominolo@googlemail.com>**20081031113125]
1027[Export typeclasses for accessing compiler results.
1028Thomas Schilling <nominolo@googlemail.com>**20081028182310
1030 MERGE TO 6.10.
1032[Minor refactoring.
1033Thomas Schilling <nominolo@googlemail.com>**20081028182202]
1034[Include record fields in tags.
1035Thomas Schilling <nominolo@googlemail.com>**20081028180538]
1036[Fix imports
1038[Improve error reporting for non-rigid GADT matches
1041 Following suggestions from users, this patch improves the error message
1042 when a GADT match needs a rigid type:
1044  tcfail172.hs:19:10:
1045      GADT pattern match in non-rigid context for `Nil'
1046 -      Solution: add a type signature
1047 +      Probable solution: add a type signature for `is_normal'
1048      In the pattern: Nil
1049      In the definition of `is_normal': is_normal Nil = True
1051 Now GHC tries to tell you what to give a type signature *for*.
1052 Thanks to Daniel Gorin and others for the suggestions.
1055[Add (a) CoreM monad, (b) new Annotations feature
1058 This patch, written by Max Bolingbroke,  does two things
1060 1.  It adds a new CoreM monad (defined in simplCore/CoreMonad),
1061     which is used as the top-level monad for all the Core-to-Core
1062     transformations (starting at SimplCore).  It supports
1063        * I/O (for debug printing)
1064        * Unique supply
1065        * Statistics gathering
1066        * Access to the HscEnv, RuleBase, Annotations, Module
1067     The patch therefore refactors the top "skin" of every Core-to-Core
1068     pass, but does not change their functionality.
1070 2.  It adds a completely new facility to GHC: Core "annotations".
1071     The idea is that you can say
1072        {#- ANN foo (Just "Hello") #-}
1073     which adds the annotation (Just "Hello") to the top level function
1074     foo.  These annotations can be looked up in any Core-to-Core pass,
1075     and are persisted into interface files.  (Hence a Core-to-Core pass
1076     can also query the annotations of imported things.)  Furthermore,
1077     a Core-to-Core pass can add new annotations (eg strictness info)
1078     of its own, which can be queried by importing modules.
1080 The design of the annotation system is somewhat in flux.  It's
1081 designed to work with the (upcoming) dynamic plug-ins mechanism,
1082 but is meanwhile independently useful.
1084 Do not merge to 6.10! 
1087[Fix Trac #2674: in TH reject empty case expressions and function definitions
1089[Change naming conventions for compiler-generated dictionaries and type functions
1092 Up to now, the data constructor dictionary for class C as been called
1093 ":DC". But there is no reason for the colon to be at the front; indeed
1094 it confuses the (simple-minded) pretty-printer for types.  So this
1095 patch changes it to be "D:C".  This makes Core a lot easier to read.
1096 Having a colon in the middle ensures that it can't clash with a user-written
1097 data type.
1099 Similarly I changed
1101   T:C     Data type corresponding a class dictionary (was :TC)
1102   D:C     Data constructor for class dictionary (was :DC)
1104   NTCo:T   Coercion mapping from a newtype T to its representation type
1105                (was :CoT)
1107   TFCo:R   Coercion mapping from a data family to its respresentation type R
1108                (was :CoFR)
1110   Rn:T     The n'th respresentation data type for a data type T
1111                (was :RnT)
1114 Do not merge to 6.10.
1116 HEADS-UP: you'll need to recompile libraries from scratch. 
1118 ROMAN: you could do the same for OccName.mkVectTyConOcc etc, if you wanted.
1122[Fix tcrun031: yet more tidying up in TcDeriv
1124[Add Outputable instance for CoercionI
1126[Fix Trac #2720: inlining and casts
1129 The issue here is what happens when we have
1131        (f |> co) x
1133 where f is itself marked INLINE.  We want callSiteInline to "see"
1134 the fact that the function is applied, and hence have some incentive
1135 to inline.  I've done this by extending CoreUnfold.CallCtxt with
1136 ValAppCtxt.  I think that should catch this case without messing up
1137 any of the others.
1140[Clarify documentatoin
1142[Update library version numbers in the release notes
1143Ian Lynagh <igloo@earth.li>**20081023144018]
1144[various updates to the release notes
1145Simon Marlow <marlowsd@gmail.com>**20081007151647]
1146[Add library release notes
1147Ian Lynagh <igloo@earth.li>**20080920155722]
1148[Add release notes for the compiler
1149Ian Lynagh <igloo@earth.li>**20080920114857]
1150[Doc fix
1151Ian Lynagh <igloo@earth.li>**20081028150534]
1152[Rename some variables in docs
1153Ian Lynagh <igloo@earth.li>**20081028150447]
1154[Fix typos
1155Ian Lynagh <igloo@earth.li>**20081028144655]
1156[Mostly-fix Trac #2595: updates for existentials
1159 Ganesh wanted to update records that involve existentials.  That
1160 seems reasonable to me, and this patch covers existentials, GADTs,
1161 and data type families.
1163 The restriction is that
1164   The types of the updated fields may mention only the
1165   universally-quantified type variables of the data constructor
1167 This doesn't allow everything in #2595 (it allows 'g' but not 'f' in
1168 the ticket), but it gets a lot closer.
1170 Lots of the new lines are comments!
1173[Fix Trac #2723: keep track of record field names in the renamer
1176 The idea here is that with -XNamedFieldPuns and -XRecordWildCards we don't
1177 want to report shadowing errors for
1178        let fld = <blah> in C { .. }
1179 But to suppress such shadowing errors, the renamer needs to know that
1180 'fld' *is* a record selector.  Hence the new NameSet in
1181 TcRnFypes.RecFieldEnv
1184[Remove dead code
1186[Fix Trac #2713: refactor and tidy up renaming of fixity decls
1189 In fixing #2713, this patch also eliminates two almost-unused
1190 functions from RnEnv (lookupBndr and lookupBndr_maybe).  The
1191 net lines of code is prety much unchanged, but more of them
1192 are comments!
1195[Fix Trac #2701: make deriving check better for unlifted args
1198 Getting the automatic deriving mechanism to work really smoothly
1199 is surprisingly hard.  I keep finding myself in TcDeriv!
1201 Anyway, this is a nice clean fix to Trac #2701.
1204[Use pdflatex rather than latex for building
1205Ian Lynagh <igloo@earth.li>**20081024112400
1206 The Windows builder is having problems running ps2pdf, so this works
1207 aroudn the problem.
1209[Remove an unmatched } in core.tex
1210Ian Lynagh <igloo@earth.li>**20081024111750]
1211[Add a usepackage{url}
1212Ian Lynagh <igloo@earth.li>**20081024111458]
1213[Update ANNOUNCE
1214Ian Lynagh <igloo@earth.li>**20081022164423]
1215[Fix a bug in the new scheduler
1216Simon Marlow <marlowsd@gmail.com>**20081023155017
1217 If the current thread blocks, we should yield the Capability
1218 immediately, because the thread and hence possibly the current Task
1219 are now owned by someone else.  This worked in the old scheduler, but
1220 we moved where the yield happens in the new scheduler which broke it.
1222[add an assertion
1223Simon Marlow <marlowsd@gmail.com>**20081023154551]
1224[fix a warning
1225Simon Marlow <marlowsd@gmail.com>**20081023082213]
1226[traverse the spark pools only once during GC rather than twice
1227Simon Marlow <marlowsd@gmail.com>**20081022115233]
1228[Refactoring and reorganisation of the scheduler
1229Simon Marlow <marlowsd@gmail.com>**20081022092744
1231 Change the way we look for work in the scheduler.  Previously,
1232 checking to see whether there was anything to do was a
1233 non-side-effecting operation, but this has changed now that we do
1234 work-stealing.  This lead to a refactoring of the inner loop of the
1235 scheduler.
1237 Also, lots of cleanup in the new work-stealing code, but no functional
1238 changes.
1240 One new statistic is added to the +RTS -s output:
1242   SPARKS: 1430 (2 converted, 1427 pruned)
1244 lets you know something about the use of `par` in the program.
1246[Work stealing for sparks
1249    Spark stealing support for PARALLEL_HASKELL and THREADED_RTS versions of the RTS.
1251   Spark pools are per capability, separately allocated and held in the Capability
1252   structure. The implementation uses Double-Ended Queues (deque) and cas-protected
1253   access.
1255   The write end of the queue (position bottom) can only be used with
1256   mutual exclusion, i.e. by exactly one caller at a time.
1257   Multiple readers can steal()/findSpark() from the read end
1258   (position top), and are synchronised without a lock, based on a cas
1259   of the top position. One reader wins, the others return NULL for a
1260   failure.
1262   Work stealing is called when Capabilities find no other work (inside yieldCapability),
1263   and tries all capabilities 0..n-1 twice, unless a theft succeeds.
1265   Inside schedulePushWork, all considered cap.s (those which were idle and could
1266   be grabbed) are woken up. Future versions should wake up capabilities immediately when
1267   putting a new spark in the local pool, from newSpark().
1269 Patch has been re-recorded due to conflicting bugfixes in the sparks.c, also fixing a
1270 (strange) conflict in the scheduler.
1273[include an elapsed time table
1274Simon Marlow <marlowsd@gmail.com>**20081023080648]
1275[generate a valid summary for older GHC versions too
1276Simon Marlow <marlowsd@gmail.com>**20081023080629]
1277[Fix Trac #2714 (a minor wibble)
1280 In boxy_match (which is a pure function used by preSubType) we can
1281 encounter TyVars not just TcTyVars; this patch takes account of that.
1284[Reject programs with superclass equalities for now
1285Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081021131721
1286 - The current implementation of type families cannot properly deal
1287   with superclass equalities.  Instead of making a half-hearted attempt at
1288   supporting them, which mostly ends in cryptic error message, rejecting
1289   right away with an appropriate message.
1291   MERGE TO 6.10
1293[Fix doc syntax
1294Ian Lynagh <igloo@earth.li>**20081021183317]
1295[Don't put the README file in the Windows installer; fixes trac #2698
1296Ian Lynagh <igloo@earth.li>**20081021162543
1297 The README file talks about getting and building the sources, which
1298 doesn't make sense for the installer.
1300[Comments and parens only
1302[Do proper cloning in worker/wrapper splitting
1305 See Note [Freshen type variables] in WwLib.  We need to clone type
1306 variables when building a worker/wrapper split, else we simply get
1307 bogus code, admittedly in rather obscure situations.  I can't quite
1308 remember what program showed this up, unfortunately, but there
1309 definitely *was* one!  (You get a Lint error.)
1312[Don't float an expression wrapped in a cast
1315 There is no point in floating out an expression wrapped in a coercion;
1316 If we do we'll transform 
1317        lvl = e |> co [_$_]
1318 to     
1319        lvl' = e; lvl = lvl' |> co
1320 and then inline lvl.  Better just to float out the payload (e).
1323[Fix Trac #2668, and refactor TcDeriv
1326 TcDeriv deals with both standalone and ordinary 'deriving';
1327 and with both data types and 'newtype deriving'.  The result
1328 is really rather compilcated and ad hoc.  Ryan discovered
1329 #2668; this patch fixes that bug, and makes the internal interfces
1330 #more uniform.  Specifically, the business of knocking off
1331 type arguments from the instance type until it matches the kind of the
1332 class, is now done by derivTyData, not mkNewTypeEqn, because the
1333 latter is shared with standalone derriving, whree the trimmed
1334 type application is what the user wrote.
1337[Spelling error in comment
1339[White space only
1341[Comments to explain strict overlap checking for type family instances
1343[Allow type families to use GADT syntax (and be GADTs)
1346 We've always intended to allow you to use GADT syntax for
1347 data families:
1348        data instance T [a] where
1349          T1 :: a -> T [a]
1350 and indeed to allow data instances to *be* GADTs
1351        data intsance T [a] where
1352          T1 :: Int -> T [Int]
1353          T2 :: a -> b -> T [(a,b)]
1355 This patch fixes the renamer and type checker to allow this.
1358[Improve crash message from applyTys and applyTypeToArgs
1360[Wibble to ungrammatical error message
1362[Comments only: replace ":=:" by "~" (notation for equality predicates)
1364[FIX #2693
1365Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081021120107
1366 - As long as the first reduceContext in tcSimplifyRestricted potentially
1367   performs improvement, we need to zonk again before the second reduceContext.
1368   It would be better to prevent the improvement in the first place, but given
1369   the current situation zonking is definitely the right thing to do.
1371   MERGE TO 6.10
1373[Restore the terminal attributes even if ghci does not exit normally.
1374Judah Jacobson <judah.jacobson@gmail.com>**20081020164109]
1375[FIX #2688
1376Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081021044213
1377 - Change in TcSimplify.reduceContext:
1379      We do *not* go around for new extra_eqs.  Morally, we should,
1380      but we can't without risking non-termination (see #2688).  By
1381      not going around, we miss some legal programs mixing FDs and
1382      TFs, but we never claimed to support such programs in the
1383      current implementation anyway.
1385   MERGE TO 6.10
1387[Move documentation within 80 column boundary.
1388Thomas Schilling <nominolo@googlemail.com>**20081014134016]
1389[Improve haddock documentation for 'GHC.topSortModuleGraph'.
1390Thomas Schilling <nominolo@googlemail.com>**20081014133833]
1391[Improve haddock documentation for HsExpr module.
1392Thomas Schilling <nominolo@googlemail.com>**20081014133740]
1393[Improve Haddock-markup for HsDecls module.
1394Thomas Schilling <nominolo@googlemail.com>**20081014133556]
1395[Run Haddock with compacting GC and show RTS statistics.
1396Thomas Schilling <nominolo@googlemail.com>**20081020111410]
1397[FIX (partially) #2703: bug in stack overflow handling when inside block
1398Simon Marlow <marlowsd@gmail.com>**20081020121103
1399 As a result of a previous ticket (#767) we disabled the generation of
1400 StackOverflow exceptions when inside a Control.Exception.block, on the
1401 grounds that StackOverflow is like an asynchronous exception.  Instead
1402 we just increase the stack size.  However, the stack size calculation
1403 was wrong, and ended up not increasing the size of the stack, with the
1404 result that the runtime just kept re-allocating the stack and filling
1405 up memory.
1407[Re-export Located(..) and related functions
1408Simon Marlow <marlowsd@gmail.com>**20081020102422
1409 So that clients don't need to import SrcLoc
1411[whitespace fix
1412Simon Marlow <marlowsd@gmail.com>**20081020101241]
1413[FIX #2691: Manually reset the terminal to its initial settings; works around a bug in libedit.
1414Judah Jacobson <judah.jacobson@gmail.com>**20081016024838]
1415[Eliminate duplicate flags in the tab completion of ghci's :set command.
1416Judah Jacobson <judah.jacobson@gmail.com>**20081016015721]
1417[Add dph haddock docs to the doc index
1418Ian Lynagh <igloo@earth.li>**20081019133208]
1419[Clean the bootstrapping extensible-exceptions package
1420Ian Lynagh <igloo@earth.li>**20081017195942]
1421[Fix trac #2687
1422Ian Lynagh <igloo@earth.li>**20081015163412
1423 OtherPunctuation, ConnectorPunctuation and DashPunctuation are now
1424 treated as symbols, rather than merely graphic characters.
1426[Fix trac #2680; avoid quadratic behaviour from (++)
1427Ian Lynagh <igloo@earth.li>**20081015163235]
1428[Fix the build when the bootstrapping compiler has a newer Cabal than us
1429Ian Lynagh <igloo@earth.li>**20081015144023
1430 We need to forcibly use the in-tree Cabal, or we get version mismatch errors
1432[Fix the name of prologue.txt when making bindists
1433Ian Lynagh <igloo@earth.li>**20081014114714]
1434[Comments only
1436[Fix Trac #2497; two separate typos in Lexer.x
1439 The patch to switch on lexing of 'forall' inside a RULES pragma
1440 wasn't working.  This fixes it so that it does.
1443[Update manual: tidy up instances, say more about type families in instance decls
1445[Make tags work on Unices, too.
1446Thomas Schilling <nominolo@googlemail.com>**20081014211236]
1447[Undefine __PIC__ before defining it to work around "multiple definitions of __PIC__" warnings
1448Clemens Fruhwirth <clemens@endorphin.org>**20081014143206]
1449[Add "dyn" to GhcRTSWays when compiling --enable-shared
1450Clemens Fruhwirth <clemens@endorphin.org>**20081014125123]
1451[Fill out the ghc package's cabal file
1452Ian Lynagh <igloo@earth.li>**20081013235817]
1453[Patching libffi so it can be built as DLL
1454Clemens Fruhwirth <clemens@endorphin.org>**20081014103459
1456 libffi-dllize-3.0.6.patch should be pushed upstream
1458[Add 'etags' makefile target.
1459Thomas Schilling <nominolo@googlemail.com>**20081013170927
1461 This only works with stage2 since `ghctags' is built against stage1
1462 but not against the bootstrapping compiler.  Also note that all of GHC
1463 must typecheck for this target to succeed.  Perhaps we should not
1464 overwrite the old TAGS file by default then.
1466[Use cabal information to get GHC's flags to `ghctags'.
1467Thomas Schilling <nominolo@googlemail.com>**20081013170658
1469 By giving the dist-directory to ghctags we can get all the GHC API
1470 flags we need in order to load the required modules.  The flag name
1471 could perhaps be improved, but apart from that it seems to work well.
1473[Version bump for libffi to 3.0.6
1474Clemens Fruhwirth <clemens@endorphin.org>**20081014081300]
1475[Encode shared/static configuration into stamps to do the right thing when rebuilding
1476Clemens Fruhwirth <clemens@endorphin.org>**20081013221530]
1477[Add a link to the GHC API docs from the library haddock index
1478Ian Lynagh <igloo@earth.li>**20081013195943]
1479[Link to the GHC API documentation from the main doc page
1480Ian Lynagh <igloo@earth.li>**20081013200927]
1481[Whitespace only in docs/index.html
1482Ian Lynagh <igloo@earth.li>**20081013200625]
1483[Tweak gen_contents_index
1484Ian Lynagh <igloo@earth.li>**20081013192548
1485 It now works again after it has been installed, as well as while it is
1486 in a source tree.
1487 After it's been installed it filters out the ghc package, as that
1488 currently swamps everything else in the index.
1490[Build fixes for DLLized rts
1491Clemens Fruhwirth <clemens@endorphin.org>**20081013201608]
1492[Do not filter the rts from linked libraries in linkDynLib as Windows does not allow unresolved symbols
1493Clemens Fruhwirth <clemens@endorphin.org>**20081013201426]
1494[Add HsFFI.o to INSTALL_LIBS
1495Clemens Fruhwirth <clemens@endorphin.org>**20081013200945]
1496[Rename symbol macros to a consistant naming scheme
1497Clemens Fruhwirth <clemens@endorphin.org>**20081013162433]
1498[Fix #2685: two Bool arguments to tidyTypeEnv were the wrong way around
1499Simon Marlow <marlowsd@gmail.com>**20081013121339
1500 So -XTemplateHaskell was behaving like -fomit-interface-file-pragmas,
1501 and vice versa.
1503[Simplify the "is $bindir in $PATH" test
1504Ian Lynagh <igloo@earth.li>**20081011191008]
1505[Correct the "is $bindir in $PATH" test
1506Ian Lynagh <igloo@earth.li>**20081011191030
1507 We were testing neq instead of eq
1509[Fix a typo which was causing ghci to quit on commands errors
1510pepe <mnislaih@gmail.com>**20081011114720]
1511[Drop libm from the linker dependencies for libffi
1512Clemens Fruhwirth <clemens@endorphin.org>**20081011074524]
1513[Do not generate haddock documentation when running install-docs in libffi
1514Clemens Fruhwirth <clemens@endorphin.org>**20081010192318]
1515[When waking up thread blocked on TVars, wake oldest first (#2319)
1516Josef Svenningsson <josef.svenningsson@gmail.com>**20081010150322
1517 StgTVarWatchQueue contains the threads blocked on a TVar in order
1518 youngest first. The list has to be traversed backwards to unpark the threads
1519 oldest first.
1521 This improves the fairness when using STM in some situations.
1523[add readTVarIO :: TVar a -> IO a
1524Simon Marlow <marlowsd@gmail.com>**20081010131545]
1525[fix #2636: throw missing module errors as SourceErrors, not ErrMsg
1526Simon Marlow <marlowsd@gmail.com>**20081010131535]
1527[atomicModifyIORef: use a local cas() instead of the global lock
1528Simon Marlow <simonmar@microsoft.com>**20081008154702
1529 This should improve scaling when using atomicModifyIORef
1531[Delay building libffi until package.conf is created and fix bindist
1532Clemens Fruhwirth <clemens@endorphin.org>**20081010073106]
1533[Install a versioned ghc-pkg script; fixes trac #2662
1534Ian Lynagh <igloo@earth.li>**20081009164946]
1535[Fix bindist creation: Only the main RTS was being put in the bindists
1536Ian Lynagh <igloo@earth.li>**20081009163451]
1537[pushAtom: add missing case for MachNullAddr (#2589)
1538Simon Marlow <marlowsd@gmail.com>**20081009091118]
1539[undo incorrect assertion, and fix comments
1540Simon Marlow <marlowsd@gmail.com>**20081009085118]
1541[remove old GRAN/PARALLEL_HASKELL code
1542Simon Marlow <marlowsd@gmail.com>**20081009085051]
1543[FIX #2639
1544Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081009132328
1546   MERGE TO 6.10
1548[Cover PredTy case in Type.tyFamInsts
1549Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081009061435
1551   MERGE TO 6.10
1553[Drop ghcconfig.h/RtsConfig.h from libffi's package.conf.in
1554Clemens Fruhwirth <clemens@endorphin.org>**20081009071342]
1555[Don't use sed's -i flag as Solaris doesn't know it in libffi/Makefile
1556Clemens Fruhwirth <clemens@endorphin.org>**20081008234455]
1557[Don't use /dev/null trick to create empty object files in libffi/Makefile
1558Clemens Fruhwirth <clemens@endorphin.org>**20081008232902]
1559[Turn libffi into a Haskell package
1560Clemens Fruhwirth <clemens@endorphin.org>**20081008170443]
1561[Make 'getModSummary' deterministic.
1562Thomas Schilling <nominolo@googlemail.com>**20081008144032]
1563[Add accessors to 'HsModule' and haddockify it.
1564Thomas Schilling <nominolo@googlemail.com>**20081007235656]
1565[fix syntax errors in src-dist publish rules
1566Simon Marlow <marlowsd@gmail.com>**20081008103432]
1567[add comments and an ASSERT_LOCK_HELD()
1568Simon Marlow <marlowsd@gmail.com>**20081008112627]
1569[Fix #2663: we had a hard-wired capabilities[0]
1570Simon Marlow <marlowsd@gmail.com>**20081008112609
1571 For some unknown reason in schedulePostRunThread() we were always
1572 passing capabilities[0] rather than the current Capability to
1573 throwToSingleThreaded().  This caused all kinds of weird failures and
1574 crashes in STM code when running on multiple processors.
1576[Fix #1955 for heap profiles generated by +RTS -hT
1577Simon Marlow <marlowsd@gmail.com>**20081003150745]
1578[add a section id for +RTS -hT
1579Simon Marlow <marlowsd@gmail.com>**20081007151007]
1580[update documentation for PostfixOperators
1581Simon Marlow <marlowsd@gmail.com>**20081007150957]
1582[fix markup
1583Simon Marlow <marlowsd@gmail.com>**20081007150943]
1584[Fix bug in DPH docs
1585Roman Leshchinskiy <rl@cse.unsw.edu.au>**20081008101618]
1586[Add short DPH section to users guide
1587Roman Leshchinskiy <rl@cse.unsw.edu.au>**20081008064754
1589 MERGE TO 6.10
1591[Users Guide: added type family documentation
1592Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081008061927
1594   MERGE TO 6.10
1596[Track changes to package dph
1597Roman Leshchinskiy <rl@cse.unsw.edu.au>**20081008032859
1599 MERGE TO 6.10
1601[Build a profiled GHC API by default if p is in GhcLibWays
1602Ian Lynagh <igloo@earth.li>**20081007152318]
1603[Check whether mk/validate.mk defines anything after validating
1604Ian Lynagh <igloo@earth.li>**20081007144855]
1605[Remove #define _BSD_SOURCE from Stg.h
1606Ian Lynagh <igloo@earth.li>**20081006101959
1607 It's no longer needed, as base no longer #includes it
1609[Make ghctags compile again.
1610Thomas Schilling <nominolo@googlemail.com>**20081007135705]
1611[Revert AutoLinkPackages change for dynamic libraries. Cabal handles that now.
1612Clemens Fruhwirth <clemens@endorphin.org>**20081007100417]
1613[Change suffix for dyn. linked executables from _real to .dyn
1614Clemens Fruhwirth <clemens@endorphin.org>**20081007100750]
1615[Add accessors to 'Target' fields and haddockify.
1616Thomas Schilling <nominolo@googlemail.com>**20081006222940
1618 MERGE TO 6.10
1620[Make 'gblock' and 'gunblock' part of 'ExceptionMonad'.  This way the
1621Thomas Schilling <nominolo@googlemail.com>**20081006222831
1622 default implementations of 'gbracket' and 'gfinally' just work.
1624 MERGE TO 6.10
1626[Add Word8 support to vectoriser
1627Roman Leshchinskiy <rl@cse.unsw.edu.au>**20081007004416
1629 MERGE TO 6.10
1631[Fix generating OS X installers: Set COMMAND_MODE=unix2003
1632Ian Lynagh <igloo@earth.li>**20081005222715
1633 If we don't specify COMMAND_MODE=unix2003 then xcodebuild defaults
1634 to setting it to legacy, which means that ar builds archives
1635 without a table of contents. That makes the build fail later on.
1637[We need to set datadir = $(libdir) in bindists
1638Ian Lynagh <igloo@earth.li>**20081005143307
1639 We already do in the normal Makefiles.
1641 This is because GHC needs package.conf and unlit to be in the same place
1642 (and things like ghc-pkg need to agree on where package.conf is, so we
1643 just set it globally).
1645[prep-bin-dist-mingw complains if it finds a bad version of windres
1646Ian Lynagh <igloo@earth.li>**20081004175351]
1647[Fix a build problem with GHC 6.4.2
1648Ian Lynagh <igloo@earth.li>**20081003195700]
1649[No AutoLinkPackages for dynamic library linking
1650Clemens Fruhwirth <clemens@endorphin.org>**20081003185304]
1651[use ghcError for error in command line
1652Clemens Fruhwirth <clemens@endorphin.org>**20081001125648]
1653[Fix warnings
1655[Always use extensible exceptions in ghc-pkg, rather than using ifdefs
1656Ian Lynagh <igloo@earth.li>**20081003161247]
1657[Use a proper exception for IOEnvFailure, not just a UserError
1658Ian Lynagh <igloo@earth.li>**20081003160129]
1659[Use an extensible-exceptions package when bootstrapping
1660Ian Lynagh <igloo@earth.li>**20081003140216
1661 Ifdefs for whether we had extensible exceptions or not were spreading
1662 through GHC's source, and things would only have got worse for the next
1663 2-3 years, so instead we now use an implementation of extensible
1664 exceptions built on top of the old exception type.
1666[Expunge ThFake, cure Trac #2632
1669 This patch fixes a dirty hack (the fake ThFake module), which in turn
1670 was causing Trac #2632.
1672 The new scheme is that the top-level binders in a TH [d| ... |] decl splice
1673 get Internal names.  That breaks a previous invariant that things like
1674 TyCons always have External names, but these TyCons are never long-lived;
1675 they live only long enough to typecheck the TH quotation; the result is
1676 discarded.  So it seems cool.
1678 Nevertheless -- Template Haskell folk: please test your code.  The testsuite
1679 is OK but it's conceivable that I've broken something in TH.  Let's see.
1682[Make a debug check more refined
1684[Add ASSERTs to all calls of nameModule
1687 nameModule fails on an InternalName.  These ASSERTS tell you
1688 which call failed.
1691[Let parseModule take a ModSummary like checkAndLoadModule did.
1692Thomas Schilling <nominolo@googlemail.com>**20081002230412
1694 To get the ModSummary for a ModuleName getModSummary can be used.
1695 It's not called find* or lookup* because it assumes that the module is
1696 in the module graph and throws an exception if it cannot be found.
1697 Overall, I'm not quite sure about the usefulness of this function
1698 since the user has no control about which filetype to grab (hs or
1699 hs-boot).
1701[Remove some out-of-date entries from .darcs-boring
1702Ian Lynagh <igloo@earth.li>**20081002201519]
1703[TFs: Allow repeated variables in left-hand sides of instances
1704Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081002134539
1706   MERGE TO 6.10
1708[Clean up some comments
1709Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081002074642
1711   MERGE TO 6.10
1713[Make the new binder-swap stuff in OccurAnal work right for GlobalIds
1716 See Note [Binder swap on GlobalId scrutinees].  I hadn't got this
1717 right before, so repeated cases on imported Ids weren't getting optimised.
1721[Minor refactoring only
1723[Comments only
1725[Zap dead-ness info appropriately in SpecConstr
1728 SpecConstr can make pattern binders come alive, so we must remember
1729 to zap their dead-variable annotation.  See extendCaseBndrs.
1731 (This was triggering a Core Lint failure in DPH.)
1734[Suppress invalid Core Lint complaint about lack of constructors
1736[add some more GC roots (fixes conc048, and possibly some others)
1737Simon Marlow <marlowsd@gmail.com>**20081001164427]
1738[Document +RTS -hT
1739Simon Marlow <marlowsd@gmail.com>**20081001163222
1740 We forgot to document this in GHC 6.8
1742[fix new-qualified-operators link
1743Simon Marlow <marlowsd@gmail.com>**20081001163105]
1744[Proper error message for unsupported pattern signatures
1745Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081001144339
1746 - Pattern signatures must be identical to the type expected for the pattern;
1747   see Note [Pattern coercions]
1748 - We now signal an appropriate error if an equality coercion would be needed
1749   (instead of just generating Core that doesn't typecheck)
1751   MERGE TO 6.10
1753[Prevent excessive inlining with DPH
1754Roman Leshchinskiy <rl@cse.unsw.edu.au>**20081002012055
1756 This adds a new flag -finline-if-enough-args which disables inlining for
1757 partially applied functions. It is automatically set by -Odph. This is a
1758 temporary hack and should remain undocumented.
1760 MERGE TO 6.10
1763[On Windows, check that we have a good version of windres when configuring
1764Ian Lynagh <igloo@earth.li>**20081001171133]
1765[Call $(PERL) rather than perl when making the manpage
1766Ian Lynagh <igloo@earth.li>**20080930155054]
1767[don't install the installPackage program
1768Ian Lynagh <igloo@earth.li>**20080930145714]
1769[Fix #2637: conc032(threaded2) failure
1770Simon Marlow <marlowsd@gmail.com>**20081001135549
1771 There was a race condition whereby a thread doing throwTo could be
1772 blocked on a thread that had finished, and the GC would detect this
1773 as a deadlock rather than raising the pending exception.  We can't
1774 close the race, but we can make the right thing happen when the GC
1775 runs later.
1777[Remove outdated link to OGI webpage
1778Simon Marlow <marlowsd@gmail.com>**20080930150912]
1779[TFs: Fixed InstContextNorm (and simplification of IPs)
1780Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081001131303
1782   MERGE TO 6.10
1784[TcSimplify.reduceImplication: clean up
1785Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081001091315
1786 - This cleans up some of the mess in reduceImplication and documents the
1787   precondition on the form of wanted equalities properly.
1788 - I also made the back off test a bit smarter by allowing to back off in the
1789   presence of wanted equalities as long as none of them got solved in the
1790   attempt.  (That should save generating some superfluous bindings.)
1792   MERGE TO 6.10
1794[Make sure to zonk the kind of coercion variables
1795Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20081001053243
1797   MERGE TO 6.10
1799[Remover PROT_EXEC flag from mmap()
1800Simon Marlow <marlowsd@gmail.com>**20080930141842
1801 Needed for #738 fix
1803[Fix #2410: carefully generate unique names for CAF CCs
1804Simon Marlow <marlowsd@gmail.com>**20080930141812]
1805[fix #2594: we were erroneously applying masks, as the reporter suggested
1806Simon Marlow <marlowsd@gmail.com>**20080930115611
1807 My guess is that this is left over from when we represented Int8 and
1808 friends as zero-extended rather than sign-extended.  It's amazing it hasn't
1809 been noticed earlier.
1811[Unconditionalize definition of DYNAMIC_* so that libffi.so/.dll is removed even when BuildSharedLibs is reset to NO
1812Clemens Fruhwirth <clemens@endorphin.org>**20080930085449]
1813[Type families: need to instantiate flexible skolems before other flexibles
1814Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20080930053559
1816 MERGE TO 6.10
1818[Fix warnings
1819Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20080929142227]
1820[Type families: consider subst rules both way
1821Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20080929141040
1822 - applySubstFam, applySubstVarVar & applySubstVarFam need to return their
1823   second argument -to be put into the todo list- if the rule would be
1824   applicable if the equalities would be supplied in the opposite order.
1826 MERGE TO 6.10
1828[removed Data.Generics.Basics, added Data.Data
1829'Jose Pedro Magalhaes <jpm@cs.uu.nl>'**20081002082808]
1830[Clean up a bit and improve an error message
1832[Don't capture error calls in tryUser
1835 A previous patch slightly changed the semantics of tryUser.
1836 This patch restores the original behaviour
1837 (as expected in :print)
1840[tweaks to this section of the docs
1841Simon Marlow <simonmar@microsoft.com>**20080927141834]
1842[Add -outputdir flag (#2295)
1843Simon Marlow <simonmar@microsoft.com>**20080927141822]
1844[oops, forgot to add -XNewQualifiedOperators to the flags table
1845Simon Marlow <simonmar@microsoft.com>**20080923140449]
1846[Fix making OS X installers from source tarballs
1847Ian Lynagh <igloo@earth.li>**20080927150507
1848 I'm not sure why it works in the HEAD, but when making an installer
1849 from the 6.10.1 beta configure hangs when doing the CHECK_HIST_ERRORS
1850 test (during rl_initialize, I believe). Giving make /dev/null as stdin
1851 fixes it.
1853[Make the matching of the filename ghc.exe case insensitive, fixes bug #2603
1854Neil Mitchell <ndmitchell@gmail.com>**20080916160311]
1855[Fix #2411: missing case for CATCH_STM_FRAME in raiseAsync()
1856Simon Marlow <simonmar@microsoft.com>**20080926232806]
1857[Fix parsing of -ignore-package flag.
1858Bertram Felgenhauer <int-e@gmx.de>**20080925053820]
1859[Add an example of how to use SCCs to the user guide
1860Ian Lynagh <igloo@earth.li>**20080926203832]
1861[Add some description of the +RTS -t/-s/-S output
1862Ian Lynagh <igloo@earth.li>**20080926200203]
1863[Remove a redundant options pragma
1864Ian Lynagh <igloo@earth.li>**20080926152731]
1865[Split ShowVersion etc off into a different type to DoInteractive etc
1866Ian Lynagh <igloo@earth.li>**20080926140539
1867 This fixes trac #1348 (ghci --help gave ghc's help), and also tidies
1868 things up a bit. Things would be even tidier if the usage.txt files were
1869 put into a .hs file, so that ShowUsage wouldn't need to be able to find
1870 the libdir.
1872[Pass SRC_HC_OPTS to GHC when building GHC's Main.hs
1873Ian Lynagh <igloo@earth.li>**20080926131609]
1874[Improve runghc docs; fixes trac #2477
1875Ian Lynagh <igloo@earth.li>**20080926124425]
1876[Type families: fixes in flattening & finalisation
1877Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20080925225324
1878 * Finalisation didn't do the right thing for equalities x ~ y, where
1879   x was instantiated, but not zonked and y flexible (need to do y := x)
1880 * During flattening we weren't careful enough when turning wanteds
1881   intermediates into locals
1883 Both bugs showed up in a small example of SPJ:
1885   linear :: HasTrie (Basis v) => (Basis v, v)
1886   linear =  basisValue
1888   class HasTrie a where
1890   type family Basis u :: *
1892   basisValue :: (Basis v,v)
1893   basisValue = error "urk"
1896[Fix the behaviour of flags like --help and --version; fixes trac #2620
1897Ian Lynagh <igloo@earth.li>**20080925165618
1898 They should override other mode flags, not conflict with them
1900[Follow the integer package changes
1901Ian Lynagh <igloo@earth.li>**20080925133855]
1902[Type families: fix decomposition problem
1903Manuel M T Chakravarty <chak@cse.unsw.edu.au>**20080925084139
1904 * Fixes the problem reported in
1905   <http://www.haskell.org/pipermail/haskell-cafe/2008-July/044911.html>
1907[Don't exit ghci if :info is called on an undefined identifier.
1908Judah Jacobson <judah.jacobson@gmail.com>**20080924212422]
1909[Fix maintainer-clean
1910Ian Lynagh <igloo@earth.li>**20080924230553]
1911[Use -f when making the runhaskell symlink
1912Ian Lynagh <igloo@earth.li>**20080924124255
1913 Otherwise installation fails if runhaskell already exists.
1915[Use -perm -100 rather than -perm /a+x when looking for executable files
1916Ian Lynagh <igloo@earth.li>**20080924124137
1917 /a+x doesn't work on some Solaris and OS X machines. Spotted by
1918 Christian Maeder.
1920[Use $(FIND) rather than find, as the former may be gfind
1921Ian Lynagh <igloo@earth.li>**20080924123323]
1922[Look for gfind as well as find
1923Ian Lynagh <igloo@earth.li>**20080924123046]
1924[In configure, don't call FPTOOLS_HADDOCK
1925Ian Lynagh <igloo@earth.li>**20080924122558
1926 We now use the in-tree haddock, so we don't need to look for it.
1928[Use $(TAR) rather than tar
1929Ian Lynagh <igloo@earth.li>**20080924121759
1930 Fixes problems on Solaris, where we need to use gtar instead of tar
1932[Add $(strip) to a Makefile test
1933Ian Lynagh <igloo@earth.li>**20080924120940
1934 Fixes making bindists on solaris. Patch from Christian Maeder.
1936[Use test -f rather than test -e, for portability (Solaris)
1937Ian Lynagh <igloo@earth.li>**20080924120840]
1938[Remove some dependencies on bootstrapping.conf from libraries/Makefile
1939Ian Lynagh <igloo@earth.li>**20080923205755
1940 They were causing some unnecessary work:
1941 Running make in a built tree reregisters the GHC package in
1942 bootstrapping.conf, and the build system thought that this updated
1943 timestamp meant that the configure stamps were out of date. This is
1944 particularly bad for the libraries with configure scripts, as those
1945 take a while to run.
1947 The bootstrapping.conf is built in an earlier phase ("make boot") so
1948 one shouldn't rely on the dependencies anyway.
1950[Bump the version number to 6.11
1951Ian Lynagh <igloo@earth.li>**20080923165613]
1952[Generalise type of 'defaultErrorHandler' so it can be used inside a Ghc session.
1953Thomas Schilling <nominolo@googlemail.com>**20080921085647]
1954[Make "sh -e boot" work
1955Ian Lynagh <igloo@earth.li>**20080921111508]
1956[Use -f rather than -e for portability
1957Ian Lynagh <igloo@earth.li>**20080921111436]
1958[Add some special cases for putting dph in bindists
1959Ian Lynagh <igloo@earth.li>**20080921000406]
1960[Escape a hash in the Makefile (it was breaking source dist creation)
1961Ian Lynagh <igloo@earth.li>**20080920232945]
1962[Disallow package flags in OPTIONS_GHC pragmas (#2499)
1963Simon Marlow <simonmar@microsoft.com>**20080923173904]
1964[#2566: emit a warning for 'ghc -c foo.bar'
1965Simon Marlow <simonmar@microsoft.com>**20080923144956
1967 $ ghc -c foo.bar
1968 Warning: the following files would be used as linker inputs, but linking is not being done: foo.bar
1969 ghc: no input files
1970 Usage: For basic information, try the `--help' option.
1972[Fix to new executable allocation code (fixed print002 etc.)
1973Simon Marlow <simonmar@microsoft.com>**20080922210915
1974 The problem here is caused by the fact that info tables include a
1975 relative offset to the string naming the constructor.  Executable
1976 memory now resides at two places in the address space: one for writing
1977 and one for executing.  In the info tables generated by GHCi, we were
1978 calculating the offset relative to the writable instance, rather than
1979 the executable instance, which meant that the GHCi debugger couldn't
1980 find the names for constructors it found in the heap.
1982[clean sm/Evac_thr.c and sm/Scav_thr.c
1983Simon Marlow <simonmar@microsoft.com>**20080922152827]
1984[add -XNewQualifiedOperators (Haskell' qualified operator syntax)
1985Simon Marlow <simonmar@microsoft.com>**20080922152340]
1986[Fix Trac #2597 (first bug): correct type checking for empty list
1989 The GHC front end never generates (ExplicitList []), but TH can.
1990 This patch makes the typechecker robust to such programs.
1993[Fix Trac #2597 (second bug): complain about an empty DoE block
1996 When converting an empty do-block from TH syntax to HsSyn,
1997 complain rather than crashing.
2000[Update dependencies
2001Ian Lynagh <igloo@earth.li>**20080920183534]
2002[Fix building with GHC 6.6
2003Ian Lynagh <igloo@earth.li>**20080920162918]
2004[Remove fno-method-sharing from the list of static flags
2005Ian Lynagh <igloo@earth.li>**20080920010635
2006 It is now a dynamic flag
2008[Tidy up the treatment of dead binders
2011 This patch does a lot of tidying up of the way that dead variables are
2012 handled in Core.  Just the sort of thing to do on an aeroplane.
2014 * The tricky "binder-swap" optimisation is moved from the Simplifier
2015   to the Occurrence Analyser.  See Note [Binder swap] in OccurAnal.
2016   This is really a nice change.  It should reduce the number of
2017   simplifier iteratoins (slightly perhaps).  And it means that
2018   we can be much less pessimistic about zapping occurrence info
2019   on binders in a case expression. 
2021 * For example:
2022        case x of y { (a,b) -> e }
2023   Previously, each time around, even if y,a,b were all dead, the
2024   Simplifier would pessimistically zap their OccInfo, so that we
2025   can't see they are dead any more.  As a result virtually no
2026   case expression ended up with dead binders.  This wasn't Bad
2027   in itself, but it always felt wrong.
2029 * I added a check to CoreLint to check that a dead binder really
2030   isn't used.  That showed up a couple of bugs in CSE. (Only in
2031   this sense -- they didn't really matter.)
2033 * I've changed the PprCore printer to print "_" for a dead variable.
2034   (Use -dppr-debug to see it again.)  This reduces clutter quite a
2035   bit, and of course it's much more useful with the above change.
2037 * Another benefit of the binder-swap change is that I could get rid of
2038   the Simplifier hack (working, but hacky) in which the InScopeSet was
2039   used to map a variable to a *different* variable. That allowed me
2040   to remove VarEnv.modifyInScopeSet, and to simplify lookupInScopeSet
2041   so that it doesn't look for a fixpoint.  This fixes no bugs, but
2042   is a useful cleanup.
2044 * Roman pointed out that Id.mkWildId is jolly dangerous, because
2045   of its fixed unique.  So I've
2047      - localied it to MkCore, where it is private (not exported)
2049      - renamed it to 'mkWildBinder' to stress that you should only
2050        use it at binding sites, unless you really know what you are
2051        doing
2053      - provided a function MkCore.mkWildCase that emodies the most
2054        common use of mkWildId, and use that elsewhere
2056    So things are much better
2058 * A knock-on change is that I found a common pattern of localising
2059   a potentially global Id, and made a function for it: Id.localiseId
2062[Gix the ghcii script
2063Ian Lynagh <igloo@earth.li>**20080919174651
2064 The ghc executable name doesn't have a version number on Windows, so
2065 don't put one in the script.
2067[Create runhaskell as well as runghc
2068Ian Lynagh <igloo@earth.li>**20080919153010]
2069[On Linux use libffi for allocating executable memory (fixed #738)
2070Simon Marlow <marlowsd@gmail.com>**20080919134602]
2071[Move the context_switch flag into the Capability
2072Simon Marlow <marlowsd@gmail.com>**20080919102601
2073 Fixes a long-standing bug that could in some cases cause sub-optimal
2074 scheduling behaviour.
2076[Fix building the extralibs tarball
2077Ian Lynagh <igloo@earth.li>**20080919133555
2078 We now need to dig the appropriate lines out of packages, rather than
2079 just catting libraries/extra-packages, in order to find out what the
2080 extralibs are.
2082[Install libffi when installing frmo a bindist
2083Ian Lynagh <igloo@earth.li>**20080919130332]
2084[Fix how we put libffi into bindists
2085Ian Lynagh <igloo@earth.li>**20080919125528]
2086[TAG 6.10 branch has been forked
2087Ian Lynagh <igloo@earth.li>**20080919123437]
2088Patch bundle hash: