darcs patch: fix non-GHC-specific variant of FastTypes (and 2 more)

Isaac Dupree isaacdupree at charter.net
Mon Apr 30 16:04:21 EDT 2007


A revised version of the patch (that is, more patches added - see their descriptions) :

Sun Apr 29 15:14:22 EDT 2007  Isaac Dupree <id at isaac.cedarswampstudios.org>
  * fix non-GHC-specific variant of FastTypes
  I tested FastTypes.lhs with hugs (manually using cpp) as well as ghc.

Mon Apr 30 15:58:10 EDT 2007  Isaac Dupree <id at isaac.cedarswampstudios.org>
  * FastTypes - note strictness of fast{Or,And} and make the unboxed versions so

Mon Apr 30 15:59:44 EDT 2007  Isaac Dupree <id at isaac.cedarswampstudios.org>
  * FastTypes - delete ugly _signatures, comment on Bool not FastBool where the typechecker will not catch it
-------------- next part --------------

New patches:

[fix non-GHC-specific variant of FastTypes
Isaac Dupree <id at isaac.cedarswampstudios.org>**20070429191422
 I tested FastTypes.lhs with hugs (manually using cpp) as well as ghc.
] {
hunk ./compiler/utils/FastTypes.lhs 62
-_IS_TRUE_ x = x
+isFastTrue x = x
+fastOr = (||)
+fastAnd = (&&)
+
+--These are among the type-signatures necessary for !ghc to compile
+-- but break ghc (can't give a signature for an import...)
+(+#) :: FastInt -> FastInt -> FastInt
+(-#) :: FastInt -> FastInt -> FastInt
+(*#) :: FastInt -> FastInt -> FastInt
+(==#) :: FastInt -> FastInt -> Bool
+(<#) :: FastInt -> FastInt -> Bool
+(<=#) :: FastInt -> FastInt -> Bool
+(>=#) :: FastInt -> FastInt -> Bool
+(>#) :: FastInt -> FastInt -> Bool
hunk ./compiler/utils/FastTypes.lhs 78
+-- however it's still possible to check that these are
+-- valid signatures nonetheless (e.g., ==# returns Bool
+-- not FastBool/Int# !)
+_signatures =
+ ( (+#) :: FastInt -> FastInt -> FastInt
+ , (-#) :: FastInt -> FastInt -> FastInt
+ , (*#) :: FastInt -> FastInt -> FastInt
+ , (==#) :: FastInt -> FastInt -> Bool
+ , (<#) :: FastInt -> FastInt -> Bool
+ , (<=#) :: FastInt -> FastInt -> Bool
+ , (>=#) :: FastInt -> FastInt -> Bool
+ , (>#) :: FastInt -> FastInt -> Bool
+ )
+
+-- type-signatures will improve the non-ghc-specific versions
+-- and keep things accurate (and ABLE to compile!)
+_ILIT :: Int -> FastInt
+iBox :: FastInt -> Int
+iUnbox :: Int -> FastInt
+
+quotFastInt :: FastInt -> FastInt -> FastInt
+negateFastInt :: FastInt -> FastInt
+
+fastBool :: Bool -> FastBool
+isFastTrue :: FastBool -> Bool
+fastOr :: FastBool -> FastBool -> FastBool
+fastAnd :: FastBool -> FastBool -> FastBool
+
}

[FastTypes - note strictness of fast{Or,And} and make the unboxed versions so
Isaac Dupree <id at isaac.cedarswampstudios.org>**20070430195810] {
hunk ./compiler/utils/FastTypes.lhs 37
+-- note that fastOr and fastAnd are strict in both arguments
+-- since they are unboxed
hunk ./compiler/utils/FastTypes.lhs 65
-fastOr = (||)
-fastAnd = (&&)
+-- make sure these are as strict as the unboxed version,
+-- so that the performance characteristics match
+fastOr False False = False
+fastOr _ _ = True
+fastAnd True True = True
+fastAnd _ _ = False
}

[FastTypes - delete ugly _signatures, comment on Bool not FastBool where the typechecker will not catch it
Isaac Dupree <id at isaac.cedarswampstudios.org>**20070430195944] {
hunk ./compiler/utils/FastTypes.lhs 74
+--Note that the comparisons actually do return Bools not FastBools.
hunk ./compiler/utils/FastTypes.lhs 85
--- however it's still possible to check that these are
--- valid signatures nonetheless (e.g., ==# returns Bool
--- not FastBool/Int# !)
-_signatures =
- ( (+#) :: FastInt -> FastInt -> FastInt
- , (-#) :: FastInt -> FastInt -> FastInt
- , (*#) :: FastInt -> FastInt -> FastInt
- , (==#) :: FastInt -> FastInt -> Bool
- , (<#) :: FastInt -> FastInt -> Bool
- , (<=#) :: FastInt -> FastInt -> Bool
- , (>=#) :: FastInt -> FastInt -> Bool
- , (>#) :: FastInt -> FastInt -> Bool
- )
}

Context:

[Fix bat-script generation for MSys
simonpj at microsoft.com**20070418160519
 
 The bat-script generation was using the wrong paths, in
 	ghc-inplace
 	ghc-pkg
 	hsc2hs
 plus there was a double-backslah in the latter two which was wrong.
 This patch fixes both.  See "MSys Note 3" in compiler/Makefile
 
 
] 
[Pass configure arguments to the library configure scripts
Ian Lynagh <igloo at earth.li>**20070418155522] 
[Add support for breaking by function name: ':break foo'
Simon Marlow <simonmar at microsoft.com>**20070418142217
 This is a bit hacky; it grabs the source location from the Name and
 tries to set a breakpoint at that location, which in most cases
 should be the breakpoint covering the whole definition.
] 
[improve completion for debugger commands
Simon Marlow <simonmar at microsoft.com>**20070418142036] 
[unused import
Simon Marlow <simonmar at microsoft.com>**20070418142008] 
[Restore the interactive context when resuming a breakpoint
Simon Marlow <simonmar at microsoft.com>**20070418134116
 So that we don't accumulate bindings from previous breakpoints, which
 could lead to a space leak.
 
] 
[remove dead code
Simon Marlow <simonmar at microsoft.com>**20070418134051] 
[add ':show context' which lists the current stack of breakpoint contexts
Simon Marlow <simonmar at microsoft.com>**20070418133856] 
[handle out-of-range lines in :break more gracefully
Simon Marlow <simonmar at microsoft.com>**20070418133824] 
[small cleanup: showForUser -> printForUser, eliminate some duplicate code
Simon Marlow <simonmar at microsoft.com>**20070418124948] 
[Check we have all the corelibs when we boot
Ian Lynagh <igloo at earth.li>**20070418124536] 
[add missing module
Simon Marlow <simonmar at microsoft.com>**20070418124124] 
[Various cleanups and improvements to the breakpoint support
Simon Marlow <simonmar at microsoft.com>**20070418114700
 
   - move parts of the debugger implementation below the GHC API where
     they belong.  There is still more in Debugger that violates the
     layering, hopefully I'll get to that later.
 
   - instead of returning an IO action from runStmt for resuming,
     return a ResumeHandle that is passed to GHC.resume.
 
   - breakpoints now return [Name] which is displayed in the same
     way as when a binding statement is executed.
 
   - :load, :add, :reload now clear the active breakpoints and context
 
   - :break gives a sensible error when used on a non-interpreted module
 
   - export breakpoint-related types from GHC
 
   - remove a bunch of layer-violating imports from InteractiveUI
 
   - remove some more vestiges of the old breakpoint code (topLevel in
     the GHCi state).
 
   - remove TickTree and use a simple array instead, cached per module
] 
[add module header
Simon Marlow <simonmar at microsoft.com>**20070418112511] 
[remove extraneous "+1"; column numbers start at zero
Simon Marlow <simonmar at microsoft.com>**20070417143512] 
[Add distclean target for libraries/ (== clean target)
Ian Lynagh <igloo at earth.li>**20070418113122] 
[Distinguish between userError (i.e., deliberate failure) and other immediate and embedded exceptions for TH splices for trac #1265
Tyson Whitehead <twhitehe at uwo.ca>**20070410141709] 
[Re-working of the breakpoint support
Simon Marlow <simonmar at microsoft.com>**20070417142458
 
 This is the result of Bernie Pope's internship work at MSR Cambridge,
 with some subsequent improvements by me.  The main plan was to
 
  (a) Reduce the overhead for breakpoints, so we could enable 
      the feature by default without incurrent a significant penalty
  (b) Scatter more breakpoint sites throughout the code
 
 Currently we can set a breakpoint on almost any subexpression, and the
 overhead is around 1.5x slower than normal GHCi.  I hope to be able to
 get this down further and/or allow breakpoints to be turned off.
 
 This patch also fixes up :print following the recent changes to
 constructor info tables.  (most of the :print tests now pass)
 
 We now support single-stepping, which just enables all breakpoints.
 
   :step <expr>     executes <expr> with single-stepping turned on
   :step            single-steps from the current breakpoint
 
 The mechanism is quite different to the previous implementation.  We
 share code with the HPC (haskell program coverage) implementation now.
 The coverage pass annotates source code with "tick" locations which
 are tracked by the coverage tool.  In GHCi, each "tick" becomes a
 potential breakpoint location.
 
 Previously breakpoints were compiled into code that magically invoked
 a nested instance of GHCi.  Now, a breakpoint causes the current
 thread to block and control is returned to GHCi.
 
 See the wiki page for more details and the current ToDo list:
 
   http://hackage.haskell.org/trac/ghc/wiki/NewGhciDebugger
] 
[remove the ITBL_SIZE constants which were wrong, but fortunately unused
Simon Marlow <simonmar at microsoft.com>**20070417092559] 
[con_desc should be an OFFSET_FIELD
Simon Marlow <simonmar at microsoft.com>**20070417092526] 
[fix building with pre-6.4
Simon Marlow <simonmar at microsoft.com>**20070416082732] 
[Change tabs to spaces in string literals
Ian Lynagh <igloo at earth.li>**20070416211342] 
[Remove whitespace, mostly tabs, from string literals
Ian Lynagh <igloo at earth.li>**20070416191524] 
[MERGE: another attempt at a workaround for #1110 (Vista bug)
Simon Marlow <simonmar at microsoft.com>**20070416142223
 now instead of setting GCC_EXEC_PREFIX, we just add the appropriate
 gcc-lib directory to the front of PATH before invoking gcc.
] 
[MERGE: Fix a few uses of the wrong return convention for the scheduler
Simon Marlow <simonmar at microsoft.com>**20070416141902
 We changed the convention a while ago so that BaseReg is returned to
 the scheduler in R1, because BaseReg may change during the run of a
 thread, e.g. during a foreign call.  A few places got missed,
 mostly for very rare events.
 
 Should fix concprog001, although I'm not able to reliably reproduce
 the failure.
] 
[stm doesn't need to be a core-package
Ian Lynagh <igloo at earth.li>**20070416132421] 
[Split objects when building libraries (if SplitObjs is YES)
Ian Lynagh <igloo at earth.li>**20070416132332] 
[tab, verttab, formfeed, and CR are not allowed in strings
Simon Marlow <simonmar at microsoft.com>**20070416110433
 See #1277
] 
[Add missing special case for GHC.Prim
Simon Marlow <simonmar at microsoft.com>**20070416130457
 The special cases for GHC.Prim are a bit fragile.  We were relying on
 (a) the base package to be already registered and (b) the base package
 not to be hidden.  These used to be true with the old library build
 system, but aren't true now.  I'm still not sure why we aren't seeing
 failures at the moment, but this patch at least fixes the build with
 'setup makefile'.
] 
[Don't try to install docs stuff if NO_HADDOCK_DOCS=YES
Ian Lynagh <igloo at earth.li>**20070415162717] 
[Implement ifBuildable
Ian Lynagh <igloo at earth.li>**20070415162315
 ifBuildable only runs a command it is given if the library in . either
 must be built (core-package - readline) or is buildable.
] 
[make opt_HiVersion an Integer instead of Int to prevent overflow
wolfgang.thaller at gmx.net**20070414214027
 
 When a snapshot version number is included, opt_HiVersion tends to exceed the range of a 32bit Int.
 
 MERGE TO STABLE
] 
[Allow ProjectTags to be specified in mk/build.mk
Ian Lynagh <igloo at earth.li>**20070413230555
 ProjectTags is expected to be of the form -tag1-tag2 (i.e. the same as
 Cabal tags). These are appended to the GHC version number.
] 
[Fix a typo related to i386 PIC code generation
wolfgang.thaller at gmx.net**20070412214701
 
 A recent patch accidentally had x86_TARGET_ARCH instead of i386_TARGET_ARCH.
] 
[Darwin/x86_64 linker support
wolfgang.thaller at gmx.net**20070412214515
 
 Initial support for loading x86_64 Mach-O files
] 
[autoreconf -> sh boot
Ian Lynagh <igloo at earth.li>**20070412223636] 
[Darwin/i386 NCG: fix assembly syntax in symbol stubs
wolfgang.thaller at gmx.net**20070412215313
 
 In i386 position-independent symbol stubs, the NCG used to print
 	jmp %edx
 instead of
 	jmp *%edx
 
 Apple's assembler used to silently accept this, but has recently started to print warnings about it.
 
 MERGE TO STABLE.
] 
[Darwin Linker: Do not add local symbols to lochash
wolfgang.thaller at gmx.net**20070412211712
 ... so that GHCi doesn't complain about duplicate symbols when two C modules define the same static variable.
 
 MERGE TO STABLE.
] 
[Handle Weak Definitions in the Darwin Linker
wolfgang.thaller at gmx.net**20070412210155
 
 The __i686.get_pc_thunk symbols generated by gcc's PIC code generator are weak definitions that appear in every object file, so we need to deal with them.
 
 MERGE TO STABLE.
 
] 
[Check boot seems to have been run before we let make proceed
Ian Lynagh <igloo at earth.li>**20070412223014] 
[wibble to prep-bin-dist-mingw target
Simon Marlow <simonmar at microsoft.com>**20070412132115] 
[tidy up the binary-dist targets a bit more
Simon Marlow <simonmar at microsoft.com>**20070412131702] 
[further tweak the comments
Simon Marlow <simonmar at microsoft.com>**20070411145736] 
[fix comment
Simon Marlow <simonmar at microsoft.com>**20070411145155] 
[do the right thing by default with a current mingw
Simon Marlow <simonmar at microsoft.com>**20070411144825
 and hopefully be a bit cleverer about finding things automatically.
] 
[MERGE: add prep-bin-dist-mingw to binary-dist target, and add a separate target for
Simon Marlow <simonmar at microsoft.com>**20070412131327
  publish-binary-dist
] 
[MERGE: fixes to prep-bin-dist-mingw, and add separate rule to tar the bindist
Simon Marlow <simonmar at microsoft.com>**20070412131012] 
[call prep-bin-dist-mingw as part of binary-dist, before we make the tarball
Simon Marlow <simonmar at microsoft.com>**20070411145235] 
[Remove redundant import
Ian Lynagh <igloo at earth.li>**20070411213833] 
[Rationalise GhcMode, HscTarget and GhcLink
Simon Marlow <simonmar at microsoft.com>**20070411101802
 
 This patch cleans up the GHC API, and adds some functionality: we can
 now compile to object code inside GHCi.
 
 Previously we had:
 
   data GhcMode
     = BatchCompile
     | Interactive
     | OneShot
     | JustTypecheck
     | MkDepend
   
   data HscTarget
     = HscC
     | HscAsm
     | HscJava
     | HscInterpreted
     | HscNothing
 
 There was redundancy here; if GhcMode is Interactive, then only
 HscInterpreted makes sense, and JustTypecheck required HscNothing.
 Now we have:
 
   data GhcMode
     = CompManager       -- ^ --make, GHCi, etc.
     | OneShot           -- ^ ghc -c Foo.hs
     | MkDepend          -- ^ ghc -M, see Finder for why we need this
 
 and HscTarget remains as before.
 
 Previously GhcLink looked like this:
 
   data GhcLink = NoLink | StaticLink
 
 Now we have:
 
   data GhcLink = NoLink | LinkBinary | LinkInMemory
 
 The idea being that you can have an HscTarget of HscAsm (for example)
 and still link in memory.
 
 There are two new flags:
 
   -fobject-code selects object code as the target (selects
                 either -fasm or -fvia-C, whichever is the default)
                 This can be usd with ':set' in GHCi, or on the command line.
 
   -fbyte-code   sets byte-code as the target.  Only works in GHCi.
                 One day maybe this could save the byte code in a file
                 when used outside GHCi.
 
   (names chosen for consistency with -fno-code).
 
 Changes to the GHC API: newSession no longer takes the GhcMode
 argument.  The GhcMode defaults to CompManager, which is usually what
 you want.  To do JustTypecheck now, just set hscTarget to HscNothing.
] 
[Use "$@" rather than $* when calling things in darcs-all
Ian Lynagh <igloo at earth.li>**20070411012258] 
[Build library Setup.hs's with -Wall
Ian Lynagh <igloo at earth.li>**20070411002516] 
[parsec, regex-base, regex-compat, regex-posix are no longer core-packages
Ian Lynagh <igloo at earth.li>**20070410220306] 
[Replace genprimopcode's parsec parser with an alex+happy parser
Ian Lynagh <igloo at earth.li>**20070410220015
 This use was the only thing keeping parsec in core-packages, and
 we already have a dependency on alex+happy anyway.
] 
[Don't use regexps in the GHC sources
Ian Lynagh <igloo at earth.li>**20070410215647
 3 small regexps were responsible for pulling 3 packages into core-packages.
 
 The new code should also do a better job of hiding
 "call-clobbered register used" warnings.
] 
[Use a boot script instead of having autoreconf recurse
Ian Lynagh <igloo at earth.li>**20070410215252
 It used to be the case that
     autoreconf
 in the root would also autoreconf in any libraries that need it, and
     ./configure
 in the root would also configure all the libraries.
 
 However, cabal now configures the libraries, so they were getting
 configured twice.
 
 Thus now a small shellscript, boot, autoreconfs the root and all libraries
 that need it, and ./configure in the root doesn't configure the libraries.
] 
[Tweak AC_MSG_RESULTs
Ian Lynagh <igloo at earth.li>**20070409135734] 
[Allow the version date to be overridden with VERSION_DATE
Ian Lynagh <igloo at earth.li>**20070409134640] 
[Use cp -R rather than cp -a for portability reasons
Ian Lynagh <igloo at earth.li>**20070406190459] 
[Fixes for building the libraries with cabal on Windows
Ian Lynagh <igloo at earth.li>**20070406151822
 * configure can be told where ld is
 * make an hsc2hs-inplace.bat
 * tell Setup configure about foo.bar rather than foo on Windows
 * tell Setup configure to pass a --with-cc=$(CC) argument to ./configure
] 
[Fix external core syntax (though not full compilation)
Aaron Tomb <atomb at soe.ucsc.edu>**20061113230132
 
 This patch updates the External Core creator, pretty-printer, and parser to
 agree on a concrete syntax for External Core, including the constructs
 required by the change to System FC. Code to create valid ASTs from External
 Core files will come later, as will bits for renaming, typechecking, and
 desugaring.
 
] 
[Remove code that is dead, as we require __GLASGOW_HASKELL__ >= 504
Ian Lynagh <igloo at earth.li>**20070406001137] 
[Don't break when asked to install-docs
Ian Lynagh <igloo at earth.li>**20070316170003
 (we don't actually do anything useful either, because Cabal doesn't have
 an install-docs option).
] 
[Add a comment
Ian Lynagh <igloo at earth.li>**20070316165957] 
[Make building binary dists work with cabalised libraries
Ian Lynagh <igloo at earth.li>**20070310012558] 
[Build the libraries with cabal
Ian Lynagh <igloo at earth.li>**20070308163247] 
[fix adjustor generation on ia64 (test case ffi009)
red5_2 at hotmail.com**20070401163132
 
 Some fixes to adjustor functions.  The 8-byte address returned by the 
 allocator is adjusted to be aligned to 16-byte boundaries.  Fixed a typo 
 in inserting an immediate address into an instruction.
 
 This fixes the calls to 5-argument and 6-argument functions in ffi009.  
 Some functions still break.  I suspect it's related to passing arguments on 
 the stack.
 
] 
[save two more FP registers on ia64
red5_2 at hotmail.com**20070327041811
 
 Save/restore two more registers in StgCRun().  The extra 
 registers are used by ffi009.hs, when compiling with gcc 4.1.2.
 
] 
[add a safety net to avoid generating bogus code
Simon Marlow <simonmar at microsoft.com>**20070404155001] 
[add comments about ticky RTS ways
Simon Marlow <simonmar at microsoft.com>**20070404141013] 
[slight doc wibble for the -r flag
Simon Marlow <simonmar at microsoft.com>**20070404140805] 
[MERGE: Fix bug exposed by conc052.
Simon Marlow <simonmar at microsoft.com>**20070404103027
 A thread that was blocked on a blackhole but can now be woken up could
 possibly be treated as unreachable by the GC, and sent the
 NonTermination exception.
 
 This can give rise to spurious <<loop>>s in concurrent programs, so
 it's a good one to fix.
] 
[HANDLE --> (void *), we can't rely on having included windows.h here
Simon Marlow <simonmar at microsoft.com>**20070404084018
 HANDLE is defined to be (void *) anyway, so this shouldn't hurt
] 
[Fix C/Haskell type mismatches
Ian Lynagh <igloo at earth.li>**20070404003425] 
[Fix typo
Ian Lynagh <igloo at earth.li>**20070404000347] 
[Fix C/Haskell type mismatches
Ian Lynagh <igloo at earth.li>**20070403195324] 
[Make type-tidying work for coercion variables
simonpj at microsoft.com**20070402073835
 
 When tidying a TyVar binder, we must tidy its kind if it's a coercion
 variable!  I had forgotten to do this, which is a serious bug.  As a
 result some more complicated programs were getting a Lint error when
 reading in interface files.  Score one for Core Lint!
 
 
] 
[Make error message output order consistent
Ian Lynagh <igloo at earth.li>**20070401185741] 
[Fix darcs-all to be usable with shells other than bash
Alec Berryman <alec at thened.net>**20070306173011] 
[Fixed desugaring of parallel array comprehensions
Manuel M T Chakravarty <chak at cse.unsw.edu.au>**20070402082424
 
   ** MERGE into 6.6.1 **
] 
[The ru_local field of a CoreRule is False for implicit Ids
simonpj at microsoft.com**20070330144344
 
 	MERGE to 6.6.1
 
 For class-ops, record selectors, data constructors, we want the ru_local
 field of the Rule to be False.  We do not attach the rule to the binding
 for the Id, because there simply isn't a binding until the code gen stage.
 
 (NB: the ru_local field is different to the orphan-hood of the rule.)
 
 This fixes a bug that meant that RULES on class ops were never exported.
 
] 
[Match the type of an Id during rule matching
simonpj at microsoft.com**20070330140033
 
 	Please MERGE to 6.6.1
 
 Consider this RULE
     forall (c::Char->Int) (x::Char). 
 	f (c x) = "RULE FIRED"
 
 Well, this should only match on arguments of the specified type
 But we simply weren't checking this condition before.  Now we are.
 
 Test is simplrun008
 
 
] 
[Add filepath library
Ian Lynagh <igloo at earth.li>**20070328235154] 
[Fix the type of wgencat
Ian Lynagh <igloo at earth.li>**20070329164238] 
[Document that ghci now adds () to the start of the type defaulting list
Ian Lynagh <igloo at earth.li>**20070329141631] 
[Refactoring in HscMain.lhs
Lemmih <lemmih at gmail.com>**20070328224742
 
 I realized that compiling many files is just like compiling a single file
 several times. This does sound a bit stupid and I wonder why I didn't
 catch it before.
 
] 
[Typo in comment.
Lemmih <lemmih at gmail.com>**20070328220109] 
[remove old library doc link (#1098), and point to HackageDB
Simon Marlow <simonmar at microsoft.com>**20070328102938] 
[Make GHC main program depend on the libHSghc_dyn when GhcBuildDylibs==YES
wolfgang.thaller at gmx.net**20070327210122
 
 When building a dynamic GHC, we obviously want to build the dynamic library
 libHSghc_dyn.[so|dylib] before building the compiler executable.
 
 MERGE TO STABLE
] 
[Use a sensible set of compiler options for building dynamic libraries on Mac OS X
wolfgang.thaller at gmx.net**20070327201700
 
 The official options to use for building a dylib on Mac OS X are now
 -undefined dynamic_lookup -single_module -Wl,-macosx_version_min -Wl,10.3
 ... which should work on all arches (10.3 or later).
 
 MERGE TO STABLE
] 
[make GHCi use base:Prelude, not just Prelude
Simon Marlow <simonmar at microsoft.com>**20070327154554
 The module that GHCi uses for its default scope should be exactly
 base:Prelude, not whatever Prelude is found on the search path.
] 
[more improvements for #1119
Simon Marlow <simonmar at microsoft.com>**20070327153723
 When GHCi compiles its code framgents for setting buffering, it wants
 to refer to base:System.IO rather than whatever System.IO is on the
 search path, unfortunately there's no way to do this in source code,
 so to hack around it we set the search path to empty before compiling
 these expressions (not forgetting to flush the finder cache
 afterward).
] 
[partial fix for #1119
Simon Marlow <simonmar at microsoft.com>**20070327152215
 Unless we're in one-shot mode, emit an error if we attempt to
 demand-load interfaces for home modules.  This can only happen in one
 way (that I'm aware of): typing a qualified name at the GHCi prompt
 that refers to a module that isn't loaded.  Previously you got a
 cryptic message about not finding an interface file, now you get:
 
 Prelude> Foo.a
 
 <interactive>:1:0:
     attempting to use module `Foo' (Foo.hs) which is not loaded
 
 Of course you can still refer to package modules like this without
 loading them explicitly, only home modules are affected, and the
 behaviour is exactly the same as if you try to ':browse Foo' and
 Foo isn't loaded.
] 
[remove docs for unimplemented options
Simon Marlow <simonmar at microsoft.com>**20070326142728
 -optdep--include-module and --optdep--exclude-directory were features
 of the old mkdependHS script but weren't implemented when mkdependHS
 was merged into GHC.
] 
[Add comments about the -include-prelude flag for ghc -M
simonpj at microsoft.com**20070327113612] 
[Remove dead code from rnExpr (Var v); seems to be a leftover from some breakpoint stuff
simonpj at microsoft.com**20070323122354] 
[move "boot :: all" after the include of target.mk to fix #1095
Simon Marlow <simonmar at microsoft.com>**20070326155949] 
[add missing progress message
Simon Marlow <simonmar at microsoft.com>**20070326155233] 
[Emit a decent error message when there is a decl-splice inside a decl-bracket
simonpj at microsoft.com**20070323111912
 
 This fixes Trac #1065.  The fix is just to emit a decent error message
 rather than crash.  The situation is this:
 
   f x = ... [d| $(..stuff..); 
                 f x = v :: T |] ...
 
 TH wants to rename and typecheck the bracket; but it can't run the 
 nested splice yet.  That seems hard, because we know nothing about v, T,
 which are, presumably bound by the splice.
 
 The original TH paper says this isn't allowed, and now it's checked for
 properly (in the parser, in fact) rather than causing a crash.  In the
 fullness of time we might want to do something more flexible, but not now.
 
 
] 
[Wibble fixing overlapped pattern
simonpj at microsoft.com**20070323111850] 
[Tidy up refactoring only 
simonpj at microsoft.com**20070323111821] 
[Documentation for --install-signal-handlers=<yes|no>
Ian Lynagh <igloo at earth.li>**20070322184607] 
[Add an --install-signal-handlers=<yes|no> RTS flag; fixes trac #804
Ian Lynagh <igloo at earth.li>**20070322182900] 
[Make a Functor (IOEnv m) instance so it satisfies the new Quasi requirements
Ian Lynagh <igloo at earth.li>**20070322170114] 
[Warning police: Removed catch-all case which was overlapped
sven.panne at aedion.de**20070322161040] 
[Add -ddump-mod-cycles to -M behaviour
simonpj at microsoft.com**20070322122859
 
 This patch adds a flag -ddump-mod-cycles to the "ghc -M" dependency analyser.
 
 The effect of
 	ghc -M -ddump-mod-cycles
 is to dump a list of cycles foud in the module graph.  The display is
 trimmed so that only dependencies within the cycle are shown; and the
 list of modules in a cycle is itself sorted into dependency order, so that
 it is easy to track the chain of dependencies.
 
 Open question: should the flag be "-ddump-mod-cycles" or "-optdep-dump-mod-cycles"?  For this reason I have not yet added to the documentation.
 
] 
[Improve documentation of instances
simonpj at microsoft.com**20070322110718] 
[Fix checkHiBootIface for instances declared in hs-boot files
simonpj at microsoft.com**20070321140424
 
 Hs-boot files can contain instance declarations, but Duncan used this feature
 for the first time today, and it didn't quite work.  I'm not sure whether
 it worked before; anyway it does now.
 
 The point is that the hs-boot file advertises an instance for, say, Num Int,
 with the arbitrary name $fx1.  The main module declares Num Int, and gives
 it the name, say, $f3.  So we need to generate a declaration
 	$fx1 = $f3
 to make it all line up.  And (this is the bit that was wrong) we need
 to make that new binding visible to imported unfoldings that mention
 $fx1.
 
] 
[mangler and runtime updates for gcc 4 on ia64
red5_2 at hotmail.com**20070318033132
 
 Gcc 4 is doing more clever optimizations than earlier gccs. 
 These changes let ghc compile and run on ia64 with gcc 4.0.3.
 
 Register stack frames are enlarged so that all functions use the 
 same size stack frame.
 The code to mangle tail calls has been cleaned up and made more 
 general.
 Additional floating-point and special-purpose registers used by 
 GCC are saved upon entering the STG runtime.
 More general handling of NOP instructions.
 Handling of functions with multiple epilogues or no epilogue.
 
] 
[ia64 tailcall fix
red5_2 at hotmail.com**20070317025529
 
 Tail-calls now branch to the end of the function after the call.  This 
 stops gcc from trying to move instructions into the space immediately 
 after the call, which confuses the mangler.
 
] 
[Remove bogus export from TcSplice.lhs-boot
simonpj at microsoft.com**20070321112057] 
[Wibble to GHCi part of TcRnDriver
simonpj at microsoft.com**20070321111639] 
[Yet another wibble to checkHiBootIface; it's trickier than it looks!
simonpj at microsoft.com**20070321093733] 
[Improve pretty-printing for IfaceConDecl
simonpj at microsoft.com**20070321093611] 
[Remove redundant exports from a hs-boot file
simonpj at microsoft.com**20070321093525] 
[Further wibbles to checkBootIface (fixed HEAD build)
simonpj at microsoft.com**20070320154126] 
[Use explict layout (fixes breakage when compiling TcSimplify)
simonpj at microsoft.com**20070319151926] 
[Fix typo "lazy y x" -> "lazy y"
Ian Lynagh <igloo at earth.li>**20070317004003] 
[Desugar applications of 'seq' specially; fix Trac #1031
simonpj at microsoft.com**20070316151712
 
 Merge to 6.6 branch.  Test case is dsrun014.
 
 Note [Desugaring seq]  cf Trac #1031
 ~~~~~~~~~~~~~~~~~~~~~
    f x y = x `seq` (y `seq` (# x,y #))
 
 The [CoreSyn let/app invariant] means that, other things being equal, because 
 the argument to the outer 'seq' has an unlifted type, we'll use call-by-value thus:
 
    f x y = case (y `seq` (# x,y #)) of v -> x `seq` v
 
 But that is bad for two reasons: 
   (a) we now evaluate y before x, and 
   (b) we can't bind v to an unboxed pair
 
 Seq is very, very special!  So we recognise it right here, and desugar to
 	case x of _ -> case y of _ -> (# x,y #)
 
 The special case would be valid for all calls to 'seq', but it's only *necessary*
 for ones whose second argument has an unlifted type. So we only catch the latter
 case here, to avoid unnecessary tests.
 
] 
[Improve error messages for 'deriving' clauses
simonpj at microsoft.com**20070316142824
 
 This patch improves the misleading error message reported in Trac #1133.
 
 Please merge the patch to the 6.6.1 branch.
 
] 
[Refactor TcRnDriver, and check exports on hi-boot files
simonpj at microsoft.com**20070316133850
 
 This patch refactors TcRnDriver to make the top-level structure
 easier to understand.  
 
 The change was driven by Trac #924, and this patch fixes that bug.
 When comparing a module against its hs-boot file, we must ensure that
 the module exports everything that the hs-boot file exports.
 
] 
[Comment out debug traces
simonpj at microsoft.com**20070316133822] 
[Use update-alternatives for handling generic tool names
sven.panne at aedion.de**20070315152823
 
 ATTENTION: Packagers should read the following stuff carefully!
 
 GHC, Hugs and nhc come with various tools like runhaskell or hsc2hs. On the
 one hand this is quite handy, avoiding lots of tiny native packages, but OTOH
 this leads to a few problems:
 
    * The tools are not always identical in functionality.
 
    * The tools fight for a global generic name like "/usr/bin/runhaskell".
 
 These problems are not new and not unique to Haskell implementations, so for
 *nix-based system there is a tool called update-alternatives which handles
 those cases. The idea is as follows:
 
    * Each program/man page/etc. installs itself with a very specific name
      like /usr/bin/hsc2hs-ghc or /usr/share/man/man1/lua5.1.1.gz, so nothing
      clashes.
 
    * The (un-)installation scripts call update-alternatives to notify the
      system about new alternatives for a generic tool/manpage/etc.
 
    * Alternatives can be grouped together ("link groups"), so e.g. switching
      from Sun's Java to Kaffe switches compiler, JRE, manpages etc. together.
      Alas, this doesn't work well with the Haskell implementations yet,
      because they come with different sets of tools (in addition to runFOO):
 
        GHC:  hsc2hs
        Hugs: hsc2hs, cpphs
        nhc:  cpphs
 
      Either these tools should be disentangled fromt the Haskell
      implementations or all implementations should offer the same set.
      Opinions and recommendations on this topic are highly welcome.
 
    * This mechanism can be used to easily switch between several versions of
      the same implementation, too, but we are not yet fully prepared for that.
 
 As a first step, GHC now installs hsc2hs as 'hsc2hs-ghc' and does *not*
 install runhaskell directly anymore, only runghc. hsc2hs and runhaskell are
 created via update-alternatives now. What is currently missing is a mechanism
 for platforms like Windows and probably Mac OS X.
] 
[Make the type-defaulting in GHCi use () as the first default type
simonpj at microsoft.com**20070315142812
 
 See Trac #1200
 
 This is a somewhat experimental fix.  I'm not sure we want it in 6.6.1
 
 The idea is explained in Note [Default unitTy] in TcSimplify.  In
 interative mode (or with -fextended-default-rules) we add () as the
 first type we try when defaulting.  This has very little real impact,
 except in the following case.  Consider:
 	Text.Printf.printf "hello"
 This has type (forall a. IO a); it prints "hello", and returns
 'undefined'.  We don't want the GHCi repl loop to try to print that
 'undefined'.  The neatest thing is to default the 'a' to (), rather
 than to Integer (which is what would otherwise happen; and then GHCi
 doesn't attempt to print the ().  So in interactive mode, we add () to
 the list of defaulting types.  
 
 
] 
[Added support for parallel builds
sven.panne at aedion.de**20070315122457
 
 With this patch, one can define the degree of build parallelism via a 'jobs'
 rpm variable. A comfortable way to use this is having a ~/.rpmmacros file with
 a line like:
 
    %jobs 2
 
 Alternatively, one could use a '--define "jobs 2"' command line flag for
 rpmbuild. On a Core 2 Duo using 2 jobs brings down the time for a full build
 including extralibs from 36m to 27m. If 'jobs' is not defined, a normal
 sequential build is done, following the usual conventions on e.g. openSUSE.
] 
[Wibble to type-error-message improvement
simonpj at microsoft.com**20070314164850] 
[Improve error messages slightly, saying "a1...an" instead of "a b c"
simonpj at microsoft.com**20070314162906] 
[Tweak hasktags to cope with abc::def correctly
Ian Lynagh <igloo at earth.li>**20070314160102
 Patch from Marc Weber in
 http://www.haskell.org/pipermail/glasgow-haskell-users/2007-February/011998.html
] 
[Unbreak Haddock markup
sven.panne at aedion.de**20070314151517] 
[Warning police: Avoid name shadowing
sven.panne at aedion.de**20070314140434] 
[Handle primitive types and pseudo ops when generating LaTeX
sven.panne at aedion.de**20070314134328] 
[Warning police: Replace patter matching failures by something more informative
sven.panne at aedion.de**20070314134044] 
[Added LaTeX commands for primitive types and pseudo ops
sven.panne at aedion.de**20070314132703] 
[Fixed LaTeX markup
sven.panne at aedion.de**20070314132521] 
[Warning police: Don't rely on defaulting
sven.panne at aedion.de**20070314123608] 
[Warning police: Removed "Defined but not used" warnings
sven.panne at aedion.de**20070314123021] 
[Warning police: Added type signatures
sven.panne at aedion.de**20070314122316] 
[Use -Wall for compilation of genprimopcode
sven.panne at aedion.de**20070314122233] 
[Improve typechecker error messages; see Trac #1221
simonpj at microsoft.com**20070314121410] 
[Fix the way configure sets the ghc_ge_* variables
Ian Lynagh <igloo at earth.li>**20070313220545] 
[cache the values of ghc_ge_XXX at configure-time
Simon Marlow <simonmar at microsoft.com>**20070313160008
 This avoids recomputing them via $(shell) each time make expands one
 of these variables, which is very expensive (0.3s or so) on Windows.
] 
[Update the wired-in name for Data.String.IsString
Brian Alliet <bja8464 at cs.rit.edu>**20070314052807] 
[Add helpful cross-references
simonpj at microsoft.com**20070313162254] 
[fix #1200: don't evaluate the result of main
Simon Marlow <simonmar at microsoft.com>**20070313144614] 
[Fix a bug in the liveness analysis
Simon Marlow <simonmar at microsoft.com>**20070123104025
 We were being overly conservative, registers that were live only at a
 branch target were not recorded as being dead in the branch-not-taken
 code.
] 
[Be a bit more verbose about what's happening when recursively making in subdirs
Ian Lynagh <igloo at earth.li>**20070312105053] 
[Have configure take arguments telling it where gmp is; fixes trac #957
Ian Lynagh <igloo at earth.li>**20070311175025] 
[Avoid duplication in the binary-dist rules for docs
Ian Lynagh <igloo at earth.li>**20070309174825
 Rather than building complex sh stuff and echoing what we're doing
 ourselves, use make rules to do the looping and let make print things
 out.
] 
[Remove duplication in binary dist rules
Ian Lynagh <igloo at earth.li>**20070309174307
 Rather than building complex sh stuff and echoing what we're doing
 ourselves, use make rules to do the looping and let make print things
 out.
] 
[Make constructor names in info tables position independent
wolfgang.thaller at gmx.net**20070308020503
 
 Info tables, like everything else in the text section, MUST NOT contain
 pointers. A pointer is, by definition, position dependent and is therefore
 fundamentally incompatible with generating position independent code.
 
 Therefore, we have to store an offset from the info label to the string
 instead of the pointer, just as we already did for other things referred
 to by the info table (SRTs, large bitmaps, etc.)
] 
[when invoking gcc, instead of the -B<dir> flag, use GCC_EXEC_PREFIX
Simon Marlow <simonmar at microsoft.com>**20070308154653
 should hopefully fix/workaround #1110, but I haven't had a chance to
 test it yet.
] 
[small cleanups
Simon Marlow <simonmar at microsoft.com>**20070308134543] 
[refactor: use do-notation rather than `thenBc`-style
Simon Marlow <simonmar at microsoft.com>**20070308110619] 
[add missing %ENTRY_CODE()
Simon Marlow <simonmar at microsoft.com>**20070308101921
 fixes unreg way in HEAD
] 
[add noDuplicatezh_fast to symbol table
Simon Marlow <simonmar at microsoft.com>**20070308095717] 
[add declaration for noDuplicatezh_fast
Simon Marlow <simonmar at microsoft.com>**20070307085648] 
[Remove outdated libraries/doc/libraries.xml and libraries/doc/libtable.xml
Ian Lynagh <igloo at earth.li>**20070306152654] 
[add noDuplicate#
Simon Marlow <simonmar at microsoft.com>**20070306143112
 This primop ensures that the current computation is not being
 duplicated, by calling threadPaused().  The idea is to use it inside
 unsafePerformIO/unsafeInterleaveIO (see #986).
] 
[THREADED_RTS: use cas() when claiming thunks
Simon Marlow <simonmar at microsoft.com>**20070306142732
 I guess I forgot to do this the first time around; the upshot is that
 there could be some uncaught duplication of work on a multiprocessor
 (but unlikely).
] 
[workerTaskStop(): set task->cap = NULL
Simon Marlow <simonmar at microsoft.com>**20070306140453
 avoids an assertion failure in newBoundTask()
] 
[disable -Wbad-function-cast; it's hard/impossible to work around
Simon Marlow <simonmar at microsoft.com>**20070306135543] 
[remove vestiges of CCallable/CReturnable
Simon Marlow <simonmar at microsoft.com>**20070306123533] 
[Remove references to the in-tree building guide from teh old commentary
Ian Lynagh <igloo at earth.li>**20070306144724] 
[Remove old references to the in-tree building guide
Ian Lynagh <igloo at earth.li>**20070306144341] 
[fix the timer_create() test
Simon Marlow <simonmar at microsoft.com>**20070306093525] 
[Simple fix for Trac #1199 (pls merge to branch)
simonpj at microsoft.com**20070306065641] 
[forkProcess: startTimer() in the child, because the timer will be reset
Simon Marlow <simonmar at microsoft.com>**20070305144550] 
[better autoconfery for timer_create()
Simon Marlow <simonmar at microsoft.com>**20070305143643] 
[Use Data.String rather than GHC.Base for IsString/fromString
Ian Lynagh <igloo at earth.li>**20070303145315] 
[Use timer_create() for the interval timer, if available
Simon Marlow <simonmar at microsoft.com>**20070302113104
 This lets the threaded RTS use SIGVTALRM rather than SIGALRM for its
 interval timer signal, so the threaded and non-threaded RTS are
 compatible.  It unfortunately doesn't completely fix #850/#1156, for
 that we really have to use a restartable sleep instead of usleep().
 
 Also I cleaned up the timer API a little: instead of returning an
 error value that ultimately gets ignored, we now report errors from
 system calls and exit.
] 
[further improvements to the x86/x86_64 NCG
Simon Marlow <simonmar at microsoft.com>**20070301130628] 
[Fix typo in primops docs
Ian Lynagh <igloo at earth.li>**20070301130339] 
[Do not go into an infinite loop when pretty-printer finds a negative indent (Trac #1176)
simonpj at microsoft.com**20070301114513] 
[Use the most complex form of addressing modes on x86
Simon Marlow <simonmar at microsoft.com>**20070301112625
 We had a pattern that matched (base+(index<<N)), but not
 (base+(index<<N)+M).
] 
[is64BitInteger: truncate to 64 bits before testing
Simon Marlow <simonmar at microsoft.com>**20070301112513
 We weren't catching some literals that actually fit in 32 bits before,
 because e.g. -1 was sometimes represented as 0xffffffffffffffff in CmmInt.
 
] 
[Fix -keep-s-file with --make
Simon Marlow <simonmar at microsoft.com>**20070301095749] 
[some more vectored return stuff to be removed
Simon Marlow <simonmar at microsoft.com>**20070301092250] 
[Fix #839 (Generate documentation for built-in types and primitve operations)
Simon Marlow <simonmar at microsoft.com>**20070228163442
 
 This patch was originally by dinko.tenev at gmail.com, but I re-recorded
 it in order to add a better log message.
 
 The effect of this patch is to add entries for primitive types in the
 documentation: Int#, Char#, etc. and to document the built-in
 identifiers (seq, lazy, inline, unsafeCoerce#).
] 
[Fix #249 (-caf-all bugs)
Simon Marlow <simonmar at microsoft.com>**20070228155009
 There were two bugs:
  * we were generating the symbol name for the CAF
    cost centre from the OccName, which isn't unique enough
    in the case of system-generated non-external names
  * :Main.main caused problems, because we were assuming that
    every top-level CAF was from the current module.
] 
[use -fforce-recomp when compiling Main.hs against the ghc package.
Simon Marlow <simonmar at microsoft.com>**20070228153304
 This is necessary because GHC's recompilation checker doesn't check
 across package boundaries.
] 
[Remove vectored returns.
Simon Marlow <simonmar at microsoft.com>**20070228130714
 We recently discovered that they aren't a win any more, and just cost
 code size.
] 
[Windows: the .hp file is <prog>.exe.hp
Simon Marlow <simonmar at microsoft.com>**20070228120319] 
[Make let-matching work in Rules again
simonpj at microsoft.com**20070227231313
 
 A RULE is supposed to match even if there is an intervening let:
 	RULE f (x:xs) = ....
 	target	   f (let x = thing in x:xs)
 
 It's surprisingly tricky to get this right; in effect we are doing
 let-floating on the fly. I managed to get it wrong before, or at least
 be over-conservative.  And in "fixing" that I got it wrong again in a
 different way, which made it far too conservative. In particular, it
 failed to match	f (let x = y+y in let z=x+y in z:xs)
 because the binder x was cloned and looked "locally-bound". See the
 ever growing comments with the Let rule for details.
 
 That patch reverts to the previous story, which is still a bit too 
 conservative, but not so egregiously so.  Fixes Romans's problem.
 
] 
[Fixes for the mangler on IA64
Ian Lynagh <igloo at earth.li>**20070227174542
 From heatsink, in trac #1150.
] 
[Remove the itbls field of BCO, put itbls in with the literals
Simon Marlow <simonmar at microsoft.com>**20070227134609
 This is a simplification & minor optimisation for GHCi
] 
[fix data con patch for 64-bit architectures
Simon Marlow <simonmar at microsoft.com>**20070227134358] 
[Constructor names in info tables
bjpop at csse.unimelb.edu.au**20070220190731
 
 This patch adds data constructor names into their info tables. 
 This is useful in the ghci debugger. It replaces the old scheme which
 was based on tracking data con names in the linker. 
 
] 
[Doc typo
Ian Lynagh <igloo at earth.li>**20070227125731] 
[Don't hardwire RELEASE into configure.ac
sven.panne at aedion.de**20070224180123
 
 Previously one had to edit configure.ac to build a release version. This is
 evil, so one can now specify this on the configure invocation line like:
 
    RELEASE=YES ./configure
 
 Note that non-released versions are still the default.
] 
[Fix parsing of parallel array literals
Manuel M T Chakravarty <chak at cse.unsw.edu.au>**20070224061150] 
[Tidy up typechecking for newtypes
simonpj at microsoft.com**20070223141032] 
[pthread_key_delete wants the key itself, not a pointer to it
Ian Lynagh <igloo at earth.li>**20070223122312] 
[Wibble
Pepe Iborra <mnislaih at gmail.com>**20070223102957] 
[Moved argument position info of ATs into tycon rhs info
Manuel M T Chakravarty <chak at cse.unsw.edu.au>**20070223033848] 
[Unbreak HEAD
Pepe Iborra <mnislaih at gmail.com>**20070222181201
 
 My previous patch was creating problems with hs-boot files. 
 
] 
[Free thread local storage on shutdown
Ian Lynagh <igloo at earth.li>**20070222144306] 
[upload documentation too
Simon Marlow <simonmar at microsoft.com>**20070222102823] 
[refactoring
Simon Marlow <simonmar at microsoft.com>**20070222100349] 
[refactoring only: remove unused code/imports
Simon Marlow <simonmar at microsoft.com>**20070111091944] 
[Improving the performance of breakpoints up to 50% (by playing with laziness)
Pepe Iborra <mnislaih at gmail.com>**20070221185649
 
 This patch performs several optimizations with the goal of minimizing the cost of building the arguments to breakpointJump:
   - Group them all in a single tuple, to minimize closure creation in heap
   - Wrap this with the GHC.Base.lazy combinator, to induce max laziness
   - Remove as many literal strings as possible 
     * injecting a module-local CAF to store the module name and use that 
     * eliminating the package string (not needed).
 
] 
[Fix the behaviour of :print with functions
Pepe Iborra <mnislaih at gmail.com>**20070221151117
 
 It now outputs "<function>" instead of showing them as thunks
 
 
 
] 
[Fix an incomplete pattern in the code for :print
Pepe Iborra <mnislaih at gmail.com>**20070221150942] 
[Removed unnecessary code
Pepe Iborra <mnislaih at gmail.com>**20070219122134
 
 The breakpointJump functions never show up in the code that the typechecker sees, as they are inserted by the desugarer later.
 
] 
[Allow GADT syntax for newtypes
simonpj at microsoft.com**20070221170401
 
 Fixes Trac #1154.   Please merge.
 Tests are tc225, and tcfail176.
 
] 
[Import trimming
simonpj at microsoft.com**20070221165312] 
[Deal more correctly with orphan instances
simonpj at microsoft.com**20070221163047
 
 Conal Eliott (Trac #1145) exposed a nasty flaw in the way in which
 orphan instances are computed, when there are functional dependencies
 in the class.  It took me some time to figure out what was going on,
 and led to more refactoring.
 
 Briefly:
 
 * Elaborate comments about orphan-hood and versioning added to IfaceSyn
 * The is_orph field vanishes from InstEnv.Instance
 * Similarly ru_orph vanishes from CoreSyn.CoreRule
 * Orphan-hood is computed in MkIface.instanceToIfaceInst, and
 	MkIface.coreRuleToIfaceRule
 
 Elsewhere just tidying up.
 
] 
[Remove dead code from FunDeps
simonpj at microsoft.com**20070221131340
 
 I forgot to to this when refactoring some months ago!
 
] 
[Fix a deriving bug, arising from recent refactoring
simonpj at microsoft.com**20070221124739
 
 This one is a hangover from something I did a month or two ago, but
 didn't get quite right.  tcSimplifyDefault should not check for no-instances;
 instead the checkValidInstance in TcDeriv does so.
 
 Conal's DeepArrow needs this fix.  Test is drv015.
 
 
] 
[Fix defaulting for overloaded strings
simonpj at microsoft.com**20070221103645
 
 This patch fixes the typechecking of the default declaration itself,
 when overloaded strings are involved.  It also documents the behaviour
 in the user manual.
 
 nofib/spectral/power should work again now!
 
] 
[MERGE from 6.6: Windows fix for stdcall foreign-import-wrapper, fixes ffi012(ghci)
Simon Marlow <simonmar at microsoft.com>**20070221092950] 
[Fix case-merge bug that was breaking the HEAD
simonpj at microsoft.com**20070221091123
 
 My re-org of the case-merging transformation introduced a bug, which led
 to incorrect code.   This only showed up occasionally, but it generated
 incorrect code for PprC.pprCastReg in the stage-2 compiler. As a result
 the stage-2 compiler ran without crashing, but itself generated bogus C.
 
 For a change, this is one that Core Lint couldn't find, so the trail was
 a bit longer.  The fix is easy (and commented).
 
 
] 
[Fix obscure bug in reportDeprecations
simonpj at microsoft.com**20070220174714
 
 Fixes Trac #1128
 Please merge to STABLE
 
 A rather obscure bug related to -fno-implicit-prelude.  
 See Note [Used names with interface not loaded] in RnNames.
 
 Easily fixed, however.  Test is rn051
 
 
] 
[describe the Z-encoding for __stginit symbol names (addresses #1014)
Simon Marlow <simonmar at microsoft.com>**20070220132532] 
[freeTaskManager: don't free Tasks that are still in use
Simon Marlow <simonmar at microsoft.com>**20070220095456
 See conc059.
] 
[Fix sleep delay for the non-threaded Windows RTS
Simon Marlow <simonmar at microsoft.com>**20070220090716
 This is the Windows counterpart to "Make the non-threaded-RTS
 threadDelay wait at least as long as asked"
] 
[Signature type variables must not be instantiated with tycons
simonpj at microsoft.com**20070219175248
 
 An egregious bug in the type checker meant that it was possible for a 
 "signature type variable" (a MetaTv of SigTv form) to be instantatiated 
 with a type-constructor application.  This destroys the invariant for
 SigTv.
 
 The fix is easy; adding the predicate TcType.isTyConableTyVar
 
 Fixes Trac #1153
 
] 
[Fixed a bug with the :print command spotted by Bernie Pope.
Pepe Iborra <mnislaih at gmail.com>**20070216201052
 
 Test ghci.debugger/scripts/print018 covers this
 
] 
[Uniform user interface
Pepe Iborra <mnislaih at gmail.com>**20070216195424
 
 Print 
 
 "Breakpoint set at Main:26:13"
 
 instead of
 
 "Breakpoint set at (26,13)"
 
] 
[Taught :breakpoint add to guess the module name if not given
Pepe Iborra <mnislaih at gmail.com>**20070216193810
 
 Now the user can say 
 
 > :break add 13
 
 at the ghci prompt and the debugger will use the first top level module as the target for the breakpoint
 
] 
[Fix left-bias in ghci tab-completion code
Judah Jacobson <judah.jacobson at gmail.com>**20070214034234] 
[Fixed a bug in the datacon names extension in the dynamic linker
Pepe Iborra <mnislaih at gmail.com>**20070215181934
 
 My code was doing unnecessary work when trying to get hold of all the BCOs in order to sniff the datacon names.
 This involved calculating the transitive closure of a relation and was causing a huge performance slowdown in GHCi, as benchmarks uncovered. It turns out that this calculation was unnecessary.
 
] 
[Modify the breakpoint desugaring to introduce more laziness
Pepe Iborra <mnislaih at gmail.com>**20070213203043
 
 Benchmarks have shown that making the formation of the list of locals more lazy can improve performance of -fdebugging up to 50% in some cases
 
] 
[When the pipeline just copies the file, prepend a LINE pragma
Simon Marlow <simonmar at microsoft.com>**20070215115852
 For example, "ghc -E Foo.hs -o Foo.bar" just copies Foo.hs to
 Foo.bar.  This patch adds a LINE pragma to the beginning of Foo.bar so
 that further processing can track the location of the original file.
 
 The motiviation for this is bug #1044.  When generating Haddock docs,
 we preprocess the .hs to a .raw-hs, sometimes this doesn't involve any
 actual preprocessing and in those cases we lose track of the original
 filename.
] 
[add a ToDo, reference bug #1147
Simon Marlow <simonmar at microsoft.com>**20070214144716] 
[fix closure_sizeW_() for AP closures
Simon Marlow <simonmar at microsoft.com>**20070214120401
 Since thunks grew an extra padding word in GHC 6.6, closure_sizeW()
 has been wrong for AP closures because it assumed compatible layout
 between PAPs and APs.  One symptom is that the compacting GC would
 crash if it encountered an AP.  APs conly crop up in GHCi or
 when using asynchronous exceptions.
 
 Fixes #1010
] 
[Fixing bad allocation of tix box breakpointing array.
andy at galois.com**20070213220203] 
[Using RTS debug tracing support inside Hpc.c
andy at galois.com**20070213184402] 
[Major improvement to SpecConstr
simonpj at microsoft.com**20070209173645
 
 This patch improves the SpecConstr pass, by 
   a) making it work with join points
   b) making it generate specialisations transitively
 
 As part of it, SpecConstr now carries a substitution with it, which
 runs over the whole program as it goes.  This turned out to be 
 a big win; simplified the implementation quite a bit.
 
 I have *disabled* the specialisation on lambdas; it's pretty fragile,
 and sometimes generates more and more specialisations. Something to
 come back to, perhaps.
 
 I rejigged the flag-handling a bit.  Now the specification of passes
 in DynFlags is a bit nicer; see
 	- optLevelFlags top-level data structure
 	- runWhen function
 	- CoreDoPasses constructor
 
 There are now command-line flags
 	-fspec-constr
 	-fliberate-case
 	-fspec-threshold=N
 which do the obvious thing.  -O2 switches on both spec-constr and liberate-case.
 You can use -fno-liberate-case, -fno-spec-constr after -O2 to switch them off again.
 
 The spec-threshold applies to both these transformations; default value 200 for now.
 
 
 
 
 
] 
[Refactor the simplifier's treatment of case expressions
simonpj at microsoft.com**20070209172938
 
 (NB: this patch could conceivably require some bits of the 
 following SpecConstr patch to compile cleanly.  It's conceptually
 independent, but I'm not 100% certain that I've included all
 the necessary bits here.)
 
 This patch cleans up the simplifier's handling of various
 otimisations for case expressions, notably
   - case elimination (discarding the case altogether)
   - merging identical alternatives
   - discarding impossible alternative
   - merging nested cases
 
 Previously this was partly handled before, and partly after,
 simplifying the case alternatives. The trouble with that is
 that the dead-ness information on the case binders gets munged
 during simplification, and that turned out to mean that 
 case elmination essentially never happened -- stupid.
 
 Now I've moved it all to before simplifying the alterntives.
 In fact this reduces the amount of code, I think, and it's
 certainly tidier.  I don't think there is any loss.
 
 
] 
[Ticky is an RTS-only way; also fix collateral damage to other ways
Simon Marlow <simonmar at microsoft.com>**20070209140818
 The ticky static flag was being poked too early, which lead to
 breakage in the -prof way amongst other things.  I've installed some
 sanity checking to make sure we catch this earlier if it happens again.
] 
[Make it a warning, not an error, if the version date cannot be determined
Simon Marlow <simonmar at microsoft.com>**20070208151323
 This happens when the build tree is a link-tree to the source tree,
 because lndir will normally omit the _darcs directory.
] 
[make VERSION a dependency of dist
Simon Marlow <simonmar at microsoft.com>**20070208121555] 
[fix cut-and-pasto in code for binary-dist upload
Simon Marlow <simonmar at microsoft.com>**20070208120712] 
[Fixed typo in devel1 flavor
Kirsten Chevalier <chevalier at alum.wellesley.edu>**20070207225957
 
 Under GhcStage2HcOpts, "O" should be "-O"; fixed.
] 
[Type reconstruction/RTTI: improve handling of newtypes
Pepe Iborra <mnislaih at gmail.com>**20070207205947
 
   Newtypes have always been a problem because they are not there at runtime, but we need to take them into account.
   
   Tests ghci.debugger/print011 and ghci.debugger/print012 cover this
 
] 
[Optimize dynamic breakpoints for speed
Pepe Iborra <mnislaih at gmail.com>**20070207082110
 
 Made a bit faster the test which gets done every time a running program hits a dynamic breakpoint. I moved the bounds checking inside a DEBUG pragma and replaced (IArray.!) for unsafeAt
 
] 
[Teach darcs-all how to get testsuite and nofib
Ian Lynagh <igloo at earth.li>**20070207165344] 
[Improved naming of generated HTML files by using nice IDs
sven.panne at aedion.de**20070207163404] 
[Make the User's Guide DocBook XML 4.2 conformant again
sven.panne at aedion.de**20070207161927] 
[update version hack to work on partial repositories
Simon Marlow <simonmar at microsoft.com>**20070207105929
 Instead of asking for the last 100 patches, we just get the first 500
 lines of output from darcs changes (ugh, better ideas welcome).
] 
[Force recompilation on all -ddump flags
simonpj at microsoft.com**20070207100245] 
[Force recompilation with -ddump-minimal-imports
simonpj at microsoft.com**20070207100053] 
[Spelling fix
simonpj at microsoft.com**20070207095153] 
[Fix bug in -ddump-minimal imports Trac #1025
simonpj at microsoft.com**20070207094945
 
 The code for -ddump-minimal-imports was erroneously using loadSrcInterface,
 which looks only for *exposed* modules.  It should instead use loadSysInterface
 which looks for all interfaces.
 
 The fix is straightforward.  MERGE to 6.6 branch.
 
] 
[Update to manual section for ticky-ticky
Kirsten Chevalier <chevalier at alum.wellesley.edu>**20070207084527
 
 I added a slightly more helpful remark in the profiling
 section of the manual about how to use ticky-ticky.
] 
[Lightweight ticky-ticky profiling
Kirsten Chevalier <chevalier at alum.wellesley.edu>**20070207081404
 
 The following changes restore ticky-ticky profiling to functionality
 from its formerly bit-rotted state. Sort of. (It got bit-rotted as part
 of the switch to the C-- back-end.)
 
 The way that ticky-ticky is supposed to work is documented in Section 5.7
 of the GHC manual (though the manual doesn't mention that it hasn't worked
 since sometime around 6.0, alas). Changes from this are as follows (which
 I'll document on the wiki):
 
 * In the past, you had to build all of the libraries with way=t in order to
 use ticky-ticky, because it entailed a different closure layout. No longer.
 You still need to do make way=t in rts/ in order to build the ticky RTS,
 but you should now be able to mix ticky and non-ticky modules.
 
 * Some of the counters that worked in the past aren't implemented yet.
 I was originally just trying to get entry counts to work, so those should
 be correct. The list of counters was never documented in the first place,
 so I hope it's not too much of a disaster that some don't appear anymore.
 Someday, someone (perhaps me) should document all the counters and what 
 they do. For now, all of the counters are either accurate (or at least as
 accurate as they always were), zero, or missing from the ticky profiling
 report altogether.
 
 This hasn't been particularly well-tested, but these changes shouldn't
 affect anything except when compiling with -fticky-ticky (famous last
 words...)
 
 Implementation details:
 
 I got rid of StgTicky.h, which in the past had the macros and declarations 
 for all of the ticky counters. Now, those macros are defined in Cmm.h.
 StgTicky.h was still there for inclusion in C code. Now, any remaining C
 code simply cannot call the ticky macros -- or rather, they do call those
 macros, but from the perspective of C code, they're defined as no-ops. 
 (This shouldn't be too big a problem.)
 
 I added a new file TickyCounter.h that has all the declarations for ticky
 counters, as well as dummy macros for use in C code. Someday, these 
 declarations should really be automatically generated, since they need
 to be kept consistent with the macros defined in Cmm.h.
 
 Other changes include getting rid of the header that was getting added to
 closures before, and getting rid of various code having to do with eager
 blackholing and permanent indirections (the changes under compiler/ 
 and rts/Updates.*).
 
] 
[Detect the snapshot version number using darcs
Simon Marlow <simonmar at microsoft.com>**20070206212536
 For non-release builds, we want to append a date to the version number
 (e.g. 6.7.20070206).  Previously this was done by the nightly build
 script, this new method figures out the snapshot version by querying
 the darcs repository and finding the date of the most recent patch
 (actually it finds the most recent of the last 100 patches, but that
 should be good enough).  This is done by the configure script.
 
 To handle source distributions, we create a file VERSION in the
 top-level directory that contains the version number, and ship this in
 the source distribution.  The configure script picks up the version
 from this file if it doesn't see a _darcs directory.
] 
[Check for escape when unifying forall-types
simonpj at microsoft.com**20070206165456
 
 This egregious omission led to Trac #1128.
 
] 
[Rename local variable (no semantic effect)
simonpj at microsoft.com**20070206122456] 
[Comments and debug output
simonpj at microsoft.com**20070206122435] 
[Improve rule-matching for let expressions
simonpj at microsoft.com**20070206122233] 
[Do more wild-carding in SpecConstr; I'm not quite sure about this, but it does no harm
simonpj at microsoft.com**20070206121552] 
[Fix a small bug when comparing patterns for equality
simonpj at microsoft.com**20070206121518] 
[Expose rnInScopeSet from VarEnv
simonpj at microsoft.com**20070206120737] 
[Don't use compat when compiling utils with stage1
Ian Lynagh <igloo at earth.li>**20070206003232] 
[Fix syntax error
Ian Lynagh <igloo at earth.li>**20070205203125] 
[fix memory leak in allocExec/freeExec (see bug #985)
Simon Marlow <simonmar at microsoft.com>**20070205102102] 
[Implement the PushT rule from the FC paper
simonpj at microsoft.com**20070205174334] 
[Improve handling of partial applications involving casts
simonpj at microsoft.com**20070205174058
 
 This patch improves prepareRhs, so that it deals better with casts.
 
 We want to deal well cases like this
 	v = (f e1 `cast` co) e2
 Here we want to make e1,e2 trivial and get
 	x1 = e1; x2 = e2; v = (f x1 `cast` co) v2
 
 This really happens in parser libraries, which wrap functions in newtypes.
 
] 
[Float casts out of lambdas
simonpj at microsoft.com**20070205173544
 
 See Note [Casts and lambdas] in SimplUtils.  I found this transformation
 when staring at some cast-heavy code generated by
 Language.Haskell.Lexer.hs in the haskell-src library.
 
 The basic transformation is this:
 	(\x. e `cast` g1)  -->  (\x.e) `cast` (tx -> g1)
 where x:tx.
 
] 
[Use exprIsCheap in floating, just as the simplifier does
simonpj at microsoft.com**20070205173456] 
[Establish the CoreSyn let/app invariant
simonpj at microsoft.com**20070205173150
 
 This patch clears up a long-standing wart.   For some time it's been the
 case that 
 	the RHS of a non-recursive let can be unlifed iff 
 	the RHS is ok-for-speculation
 
 This patch extends the invariant to the argument of an App, and 
 establishes it by the smart constructors mkDsApp, mkDsApps in the desugarer.
 
 Once established, it should be maintained by the optimiser.
 
 This tides up some awkward cases, notably in exprIsHNF, and I think it
 fixes a outright strictness bug in Simplify.prepareRhs.
 
] 
[Improve simplification of coercions
simonpj at microsoft.com**20070205163324
 
 At the moment GHC really does very little simplification of coercions.
 This patch improves matters, but it's still not great, especially when
 you have chains linked together with 'trans'. 
 
 I'm also concerned that I have not yet implemented the 'leftc' and 'rightc'
 coercions we added to the paper. 
 
 But at least things are better than they were.  In particular
 	g `trans` sym g
 now cancels to give the identity.
 
 
] 
[Move #ifdef __GLASGOW_HASKELL__ < 604 to cover the CSIDL definitions too
Simon Marlow <simonmar at microsoft.com>**20070205160229
 Fixes bug exposed by compiling base w/ -fasm on Windows
] 
[Make binary-dist tarballs automatically, and add support for uploading
Simon Marlow <simonmar at microsoft.com>**20070205144847
 Moving functionality that was previously in the nightly build scripts
 into the top-level Makefile, so it's easier to use from BuildBot.
] 
[Semi-tagging optimisation
Simon Marlow <simonmar at microsoft.com>*-20070122114016
 In the generated code for case-of-variable, test the tag of the
 scrutinee closure and only enter if it is unevaluated.  Also turn
 *off* vectored returns.
] 
[don't forget to remove html-docs as part of 'make clean'
Simon Marlow <simonmar at microsoft.com>**20070205140800] 
[Simpler, more self-contained, "make dist"
Simon Marlow <simonmar at microsoft.com>**20070205140727
 This version does all its work in a subdirectory (no more destructive
 'make distclean' in the current build tree), and results in the exact
 -src.tar.bz2 distributions that we will put up for download.
] 
[optimisation: shortcut branches when possible (x86/x86_64 only for now)
mrchebas at gmail.com**20070122114201
 This is only turned on with -O, and probably won't make much
 difference at the moment, but it will be important for semi-tagging.
] 
[Semi-tagging optimisation
Simon Marlow <simonmar at microsoft.com>**20070122114016
 In the generated code for case-of-variable, test the tag of the
 scrutinee closure and only enter if it is unevaluated.  Also turn
 *off* vectored returns.
] 
[x86: disable assertion that conditionals are not on I8; they can be
mrchebas at gmail.com**20070119160501
 
] 
[small debugging output cleanup
mrchebas at gmail.com**20070119150800] 
[don't make jump tables for small switches (<= 4 branches)
mrchebas at gmail.com**20070119150749
 Only affects -fasm: gcc makes its own decisions about jump tables
] 
[Small optimisation for comparisons
mrchebas at gmail.com**20070119150433
 Comparison of literal with narrowed/widened operand: perform
 the comparison at a different width, as long as the literal is
 within range.  We only do this on x86/x86_64 at the moment, where
 we have comparisons at different sizes available.
] 
[Extension of testing script to parse PAPI results from GHC programs.
Alexey Rodriguez <mrchebas at gmail.com>**20061221115709] 
[One more PAPI measurement, dropped precise cycle counting and replaced it with instructions.
Alexey Rodriguez <mrchebas at gmail.com>**20061221115615] 
[TAG 2007-02-05
Ian Lynagh <igloo at earth.li>**20070205121210] 
Patch bundle hash:
11f4461064fdfe67334c3be27d859510602631e6



More information about the Cvs-ghc mailing list