ghc-hetmet.git
25 years ago[project @ 1999-04-27 10:59:29 by sewardj]
sewardj [Tue, 27 Apr 1999 10:59:31 +0000 (10:59 +0000)]
[project @ 1999-04-27 10:59:29 by sewardj]
Minor mods to make STG Hugs compile out-of-the-box.

25 years ago[project @ 1999-04-27 10:06:47 by sewardj]
sewardj [Tue, 27 Apr 1999 10:07:25 +0000 (10:07 +0000)]
[project @ 1999-04-27 10:06:47 by sewardj]
Changes to improve runtime performance of STG Hugs.
-- Reorganisation of the evaluator (Evaluator.c).
-- Changes to code emission (Assembler.c) to support peephole opts
-- An experimental simplifier (optimise.c).
-- Many supporting bug fixes and minor changes.
-- Experimental implementation of integer for standalone hugs (sainteger.c).

25 years ago[project @ 1999-04-27 09:37:04 by simonm]
simonm [Tue, 27 Apr 1999 09:37:04 +0000 (09:37 +0000)]
[project @ 1999-04-27 09:37:04 by simonm]
- Don't add -DCOMPILING_RTS twice

- *set* SRC_CC_OPTS rather than appending to it: we're using ghc as
  the C compiler, so normal gcc flags probably won't work.  eg. if
  you put SRC_CC_OPTS += -g in your build.mk, it'll fall over here.

25 years ago[project @ 1999-04-26 16:08:12 by simonm]
simonm [Mon, 26 Apr 1999 16:08:12 +0000 (16:08 +0000)]
[project @ 1999-04-26 16:08:12 by simonm]
add getTag#

25 years ago[project @ 1999-04-26 16:06:27 by simonm]
simonm [Mon, 26 Apr 1999 16:06:37 +0000 (16:06 +0000)]
[project @ 1999-04-26 16:06:27 by simonm]
- New Wired-in Id: getTag# :: a -> Int#
for a data type, returns the tag of the constructor.
for a function, returns a spurious number probably.
dataToTag# is the name of the underlying primitive which
pulls out the tag (its argument is assumed to be
evaluated).

- Generate constructor tables for enumerated types, so we
  can do tagToEnum#.

- Remove hacks in CoreToStg for dataToTag#.

25 years ago[project @ 1999-04-26 15:19:28 by simonm]
simonm [Mon, 26 Apr 1999 15:19:28 +0000 (15:19 +0000)]
[project @ 1999-04-26 15:19:28 by simonm]
Add simple high-level interface to Regex (snaffled from my nofib log
analyser).

25 years ago[project @ 1999-04-26 11:09:48 by simonm]
simonm [Mon, 26 Apr 1999 11:09:48 +0000 (11:09 +0000)]
[project @ 1999-04-26 11:09:48 by simonm]
oops, forgot to add dataToTag#.

25 years ago[project @ 1999-04-26 10:16:25 by simonm]
simonm [Mon, 26 Apr 1999 10:16:25 +0000 (10:16 +0000)]
[project @ 1999-04-26 10:16:25 by simonm]
Reduce (dataToTag# x) where x is bound to a known constructor.

25 years ago[project @ 1999-04-26 09:39:21 by simonm]
simonm [Mon, 26 Apr 1999 09:39:21 +0000 (09:39 +0000)]
[project @ 1999-04-26 09:39:21 by simonm]
Add note about needing -optCrts before RTS options for the compiler itself.

25 years ago[project @ 1999-04-23 13:54:12 by simonm]
simonm [Fri, 23 Apr 1999 13:54:12 +0000 (13:54 +0000)]
[project @ 1999-04-23 13:54:12 by simonm]
dataToTag# support.

25 years ago[project @ 1999-04-23 13:53:28 by simonm]
simonm [Fri, 23 Apr 1999 13:53:35 +0000 (13:53 +0000)]
[project @ 1999-04-23 13:53:28 by simonm]
Support for

dataToTag# :: a -> Int#  (if a is a data type)

and (partial) support for

tagToEnum# :: Int# -> a  (if a is an enumerated type)

The con2tag functions generated by derived Eq,Ord and Enum instances
are now replaced by dataToTag# for data types with a large number of
constructors.

25 years ago[project @ 1999-04-23 13:33:23 by sof]
sof [Fri, 23 Apr 1999 13:33:23 +0000 (13:33 +0000)]
[project @ 1999-04-23 13:33:23 by sof]
createPipe docfix

25 years ago[project @ 1999-04-23 09:51:24 by simonm]
simonm [Fri, 23 Apr 1999 09:51:26 +0000 (09:51 +0000)]
[project @ 1999-04-23 09:51:24 by simonm]
Remove hack to force setting the CCCS when we enter a function closure
defined inside a lambda.  We use a more general solution now.

25 years ago[project @ 1999-04-23 09:47:30 by simonm]
simonm [Fri, 23 Apr 1999 09:47:33 +0000 (09:47 +0000)]
[project @ 1999-04-23 09:47:30 by simonm]
More profiling fixes.  Profiles looking more reasonable, but for best
results add the -caf-all switch to GHC.

25 years ago[project @ 1999-04-23 09:45:27 by simonm]
simonm [Fri, 23 Apr 1999 09:45:27 +0000 (09:45 +0000)]
[project @ 1999-04-23 09:45:27 by simonm]
Don't forget to set the CCCS from the thunk when entering std thunks.

25 years ago[project @ 1999-04-20 12:59:51 by simonpj]
simonpj [Tue, 20 Apr 1999 12:59:54 +0000 (12:59 +0000)]
[project @ 1999-04-20 12:59:51 by simonpj]
Better typechecker error message when a type-signature variable is unified with a type

25 years ago[project @ 1999-04-19 16:30:51 by simonm]
simonm [Mon, 19 Apr 1999 16:30:55 +0000 (16:30 +0000)]
[project @ 1999-04-19 16:30:51 by simonm]
Allow a worker to be present for functions with no strictness info in
an interface file.  This is useful for functions which get hit by CPR
but not the strictness analyser.

25 years ago[project @ 1999-04-19 13:57:21 by simonm]
simonm [Mon, 19 Apr 1999 13:57:23 +0000 (13:57 +0000)]
[project @ 1999-04-19 13:57:21 by simonm]
Fixes to the unbox-strict-fields stuff for existential constructors.

25 years ago[project @ 1999-04-14 04:07:57 by kglynn]
kglynn [Wed, 14 Apr 1999 04:07:57 +0000 (04:07 +0000)]
[project @ 1999-04-14 04:07:57 by kglynn]
(keving)

Sigh,  No point w/w pass storing the worker id in wrapper's info
field,  because later simplifications may change the worker id. I've
restored the original code which looks in the wrapper function and
guesses the worker id.  With the addition of CPR transf. this looks a
bit fragile. thinks, thinks, ....

25 years ago[project @ 1999-04-13 15:50:29 by sof]
sof [Tue, 13 Apr 1999 15:50:35 +0000 (15:50 +0000)]
[project @ 1999-04-13 15:50:29 by sof]
The {Int,Word}{8,16,32,64} types are no longer 'wired-in', just names
with a known key.

25 years ago[project @ 1999-04-13 15:46:49 by sof]
sof [Tue, 13 Apr 1999 15:46:49 +0000 (15:46 +0000)]
[project @ 1999-04-13 15:46:49 by sof]
Adjusted Id import to avoid module cycle; removed some unused helpers

25 years ago[project @ 1999-04-13 08:55:33 by kglynn]
kglynn [Tue, 13 Apr 1999 08:55:54 +0000 (08:55 +0000)]
[project @ 1999-04-13 08:55:33 by kglynn]
(keving)

Big Bang introduction of CPR Analysis Pass.  Note that now
-fstrictness only does the strictness analysis phase,  it is necessary
to follow this with -fworker-wrapper to actually do the required Core
transformations. The -O option in the ghc driver script has been
modified appropriately.

For now,  CPR analysis is turned off.  To try it,  insert a
-fcpr_analyse between the -fstrictness and the -fworker-wrapper
options.

Misc. comments:

- The worker flag has been removed from an ID's StrictnessInfo field.
Now the worker info is an extra field in the Id's prag info.

- We do a nested CPR analysis,  but worker-wrapper only looks at the
info for the outermost constructor,  else laziness can be lost.

- Id's CPR Info in traces and interfaces file follows __M

- Worker-wrappery transformation now accounts for both strictness and
CPR analysis results.

25 years ago[project @ 1999-04-13 06:57:28 by kglynn]
kglynn [Tue, 13 Apr 1999 06:57:28 +0000 (06:57 +0000)]
[project @ 1999-04-13 06:57:28 by kglynn]
(keving) The CPR Analysis Pass Module

25 years ago[project @ 1999-04-12 18:32:17 by sof]
sof [Mon, 12 Apr 1999 18:32:17 +0000 (18:32 +0000)]
[project @ 1999-04-12 18:32:17 by sof]
Added Haskell wrapper for freeHaskellFunctionPtr()

25 years ago[project @ 1999-04-12 18:29:05 by sof]
sof [Mon, 12 Apr 1999 18:29:05 +0000 (18:29 +0000)]
[project @ 1999-04-12 18:29:05 by sof]
changed to generate tail-jumping code for ccall thunks

25 years ago[project @ 1999-04-09 01:55:15 by kglynn]
kglynn [Fri, 9 Apr 1999 01:55:15 +0000 (01:55 +0000)]
[project @ 1999-04-09 01:55:15 by kglynn]
(keving)

Test Update: Re-instate support for -fprint-core

25 years ago[project @ 1999-04-08 15:46:12 by simonm]
simonm [Thu, 8 Apr 1999 15:46:17 +0000 (15:46 +0000)]
[project @ 1999-04-08 15:46:12 by simonm]
Profiling fixes:

Function closures which are inside a lambda now *set* the CCCS,
instead of possibly appending to it.

In Simplify.lhs: allow inlining imported functions when profiling.
What we really want to do is allow any top-level binding to be
inlined, but there doesn't seem to be an easy way to tell whether a
binding is top-level or not.

25 years ago[project @ 1999-04-08 15:43:44 by simonm]
simonm [Thu, 8 Apr 1999 15:43:46 +0000 (15:43 +0000)]
[project @ 1999-04-08 15:43:44 by simonm]
Don't set the cost centre when entering a PAP.  Either:

-  it's fully applied, in which case we're about to
   set the CCS in the function anyway, or

-  we're about to build another PAP in which case the
   costs get attributed to the current CCS.

This avoids appending CCSs twice in some cases.

25 years ago[project @ 1999-04-07 09:23:51 by simonm]
simonm [Wed, 7 Apr 1999 09:23:51 +0000 (09:23 +0000)]
[project @ 1999-04-07 09:23:51 by simonm]
GHC 3.02 doesn't have Maybe.isNothing; switch to using isJust instead.

25 years ago[project @ 1999-04-06 09:52:03 by simonm]
simonm [Tue, 6 Apr 1999 09:52:03 +0000 (09:52 +0000)]
[project @ 1999-04-06 09:52:03 by simonm]
-funbox-strict-fields test.

25 years ago[project @ 1999-04-06 09:48:01 by simonm]
simonm [Tue, 6 Apr 1999 09:48:01 +0000 (09:48 +0000)]
[project @ 1999-04-06 09:48:01 by simonm]
Document -funbox-strict-fields.

25 years ago[project @ 1999-04-06 09:46:36 by simonm]
simonm [Tue, 6 Apr 1999 09:46:36 +0000 (09:46 +0000)]
[project @ 1999-04-06 09:46:36 by simonm]
Add -funbox-strict-fields

25 years ago[project @ 1999-04-06 09:44:27 by simonm]
simonm [Tue, 6 Apr 1999 09:44:43 +0000 (09:44 +0000)]
[project @ 1999-04-06 09:44:27 by simonm]
Add -funbox-strict-fields flag.

25 years ago[project @ 1999-04-02 08:50:23 by simonm]
simonm [Fri, 2 Apr 1999 08:50:23 +0000 (08:50 +0000)]
[project @ 1999-04-02 08:50:23 by simonm]
Hack from Simon: put abstract type decls (i.e. from an hi-boot file)
on the defferred list, just in case we happen to pull in the real one
as well.

25 years ago[project @ 1999-03-31 09:52:05 by sof]
sof [Wed, 31 Mar 1999 09:52:05 +0000 (09:52 +0000)]
[project @ 1999-03-31 09:52:05 by sof]
On Win32 platforms, provide a (IOError.ComError Int) constructor for
handling HRESULTs conveniently.

25 years ago[project @ 1999-03-31 09:47:40 by sof]
sof [Wed, 31 Mar 1999 09:47:40 +0000 (09:47 +0000)]
[project @ 1999-03-31 09:47:40 by sof]
The bugfix that time forgot

25 years ago[project @ 1999-03-30 11:26:18 by sof]
sof [Tue, 30 Mar 1999 11:26:24 +0000 (11:26 +0000)]
[project @ 1999-03-30 11:26:18 by sof]
New compiler option -fignore-asserts: Causes

    (PrelGHC.assert pred expr)

to be rewritten to (expr).

25 years ago[project @ 1999-03-29 14:09:36 by keithw]
keithw [Mon, 29 Mar 1999 14:09:36 +0000 (14:09 +0000)]
[project @ 1999-03-29 14:09:36 by keithw]
Useful comment added.
(this is really a CVS checkin test, please ignore...)  --keithw

25 years ago[project @ 1999-03-29 11:33:29 by sof]
sof [Mon, 29 Mar 1999 11:33:29 +0000 (11:33 +0000)]
[project @ 1999-03-29 11:33:29 by sof]
Fixed to allow desugaring of lit-lits with unboxed types.

25 years ago[project @ 1999-03-29 10:35:28 by simonm]
simonm [Mon, 29 Mar 1999 10:35:28 +0000 (10:35 +0000)]
[project @ 1999-03-29 10:35:28 by simonm]
Overhauled by Sven Panne.

25 years ago[project @ 1999-03-27 16:16:19 by sof]
sof [Sat, 27 Mar 1999 16:16:19 +0000 (16:16 +0000)]
[project @ 1999-03-27 16:16:19 by sof]
updated to reflect what lib now provides

25 years ago[project @ 1999-03-27 16:15:22 by sof]
sof [Sat, 27 Mar 1999 16:15:22 +0000 (16:15 +0000)]
[project @ 1999-03-27 16:15:22 by sof]
Generalised the {read,write}{Int,Word}{8,16,32,64}Array operations
to ST, plus the arrays are indexed using Ix.

25 years ago[project @ 1999-03-27 12:48:25 by sof]
sof [Sat, 27 Mar 1999 12:48:25 +0000 (12:48 +0000)]
[project @ 1999-03-27 12:48:25 by sof]
Look inside build tree too for happy binary

25 years ago[project @ 1999-03-26 19:50:31 by sof]
sof [Fri, 26 Mar 1999 19:50:31 +0000 (19:50 +0000)]
[project @ 1999-03-26 19:50:31 by sof]
Acknowledge the existence of both literal-literals and assertions.

25 years ago[project @ 1999-03-26 19:45:51 by sof]
sof [Fri, 26 Mar 1999 19:45:51 +0000 (19:45 +0000)]
[project @ 1999-03-26 19:45:51 by sof]
assertError: raise an AssertionFailed exception

25 years ago[project @ 1999-03-26 19:43:43 by sof]
sof [Fri, 26 Mar 1999 19:43:43 +0000 (19:43 +0000)]
[project @ 1999-03-26 19:43:43 by sof]
re-export PrelGHC.assert

25 years ago[project @ 1999-03-26 15:17:45 by simonm]
simonm [Fri, 26 Mar 1999 15:17:45 +0000 (15:17 +0000)]
[project @ 1999-03-26 15:17:45 by simonm]
Fix for parsing __scc expressions.

25 years ago[project @ 1999-03-26 14:55:05 by simonm]
simonm [Fri, 26 Mar 1999 14:55:05 +0000 (14:55 +0000)]
[project @ 1999-03-26 14:55:05 by simonm]
profiling-related sanity checker fixes.

25 years ago[project @ 1999-03-26 14:54:43 by simonm]
simonm [Fri, 26 Mar 1999 14:54:43 +0000 (14:54 +0000)]
[project @ 1999-03-26 14:54:43 by simonm]
Fix bug in allocGroup() when allocating an entire megablock in one go.

25 years ago[project @ 1999-03-26 10:29:02 by simonm]
simonm [Fri, 26 Mar 1999 10:29:08 +0000 (10:29 +0000)]
[project @ 1999-03-26 10:29:02 by simonm]
More profiling fixes.

25 years ago[project @ 1999-03-25 13:13:51 by simonm]
simonm [Thu, 25 Mar 1999 13:14:08 +0000 (13:14 +0000)]
[project @ 1999-03-25 13:13:51 by simonm]
Profiling fixes.

- top-level CAF CCSs now *append* themselves to the
  current CCS when called.

- remove DICT stuff.

- fixes to the auto-scc annotating in the desugarer.

25 years ago[project @ 1999-03-25 13:10:32 by simonm]
simonm [Thu, 25 Mar 1999 13:10:32 +0000 (13:10 +0000)]
[project @ 1999-03-25 13:10:32 by simonm]
Remove #ifdef __CONCURRENT_HASKELL__, update for H98.

25 years ago[project @ 1999-03-25 13:08:17 by simonm]
simonm [Thu, 25 Mar 1999 13:08:17 +0000 (13:08 +0000)]
[project @ 1999-03-25 13:08:17 by simonm]
enable __CONCURRENT_HASKELL__

25 years ago[project @ 1999-03-25 13:01:44 by simonm]
simonm [Thu, 25 Mar 1999 13:01:44 +0000 (13:01 +0000)]
[project @ 1999-03-25 13:01:44 by simonm]
RET_DYN doesn't have a proper header, just an info pointer.

25 years ago[project @ 1999-03-24 18:21:21 by sof]
sof [Wed, 24 Mar 1999 18:21:21 +0000 (18:21 +0000)]
[project @ 1999-03-24 18:21:21 by sof]
In case the desugaring of a lit-lit should fail, give a more informative error msg

25 years ago[project @ 1999-03-24 18:19:08 by sof]
sof [Wed, 24 Mar 1999 18:19:08 +0000 (18:19 +0000)]
[project @ 1999-03-24 18:19:08 by sof]
tidied up the error handling defs.

25 years ago[project @ 1999-03-24 16:52:30 by kw]
kw [Wed, 24 Mar 1999 16:52:30 +0000 (16:52 +0000)]
[project @ 1999-03-24 16:52:30 by kw]
Fix pretty-printing of FunTys to not throw away NoteTys (eg type synonyms).
(re-commit because first mail message didn't get sent)

25 years ago[project @ 1999-03-24 12:29:05 by kw217]
kw217 [Wed, 24 Mar 1999 12:29:05 +0000 (12:29 +0000)]
[project @ 1999-03-24 12:29:05 by kw217]
Fix pretty-printing of FunTys to not throw away NoteTys (eg type synonyms).

25 years ago[project @ 1999-03-24 08:46:04 by sof]
sof [Wed, 24 Mar 1999 08:46:04 +0000 (08:46 +0000)]
[project @ 1999-03-24 08:46:04 by sof]
Pragmas, Haskell (98) report style.

25 years ago[project @ 1999-03-23 08:57:19 by sof]
sof [Tue, 23 Mar 1999 08:57:19 +0000 (08:57 +0000)]
[project @ 1999-03-23 08:57:19 by sof]
Int and Word have to be treated like other Prelude modules in a DLLish
world.

25 years ago[project @ 1999-03-23 08:34:07 by sof]
sof [Tue, 23 Mar 1999 08:34:07 +0000 (08:34 +0000)]
[project @ 1999-03-23 08:34:07 by sof]
*_SECTION_END_MARKER_DECLs are now void*

25 years ago[project @ 1999-03-22 16:58:19 by simonm]
simonm [Mon, 22 Mar 1999 16:58:20 +0000 (16:58 +0000)]
[project @ 1999-03-22 16:58:19 by simonm]
Fix cost centres on PAPs.

25 years ago[project @ 1999-03-22 16:57:10 by simonm]
simonm [Mon, 22 Mar 1999 16:57:11 +0000 (16:57 +0000)]
[project @ 1999-03-22 16:57:10 by simonm]
Previous commit broke let-no-escape.  Fix it up again.

25 years ago[project @ 1999-03-22 16:56:09 by simonm]
simonm [Mon, 22 Mar 1999 16:56:09 +0000 (16:56 +0000)]
[project @ 1999-03-22 16:56:09 by simonm]
PAPs are ReEntrant, not SingleEntry.

25 years ago[project @ 1999-03-22 13:01:38 by simonm]
simonm [Mon, 22 Mar 1999 13:01:38 +0000 (13:01 +0000)]
[project @ 1999-03-22 13:01:38 by simonm]
decodeFloat and decodeDouble were accidentally allocating too much
due to a StgWord/byte confusion.

25 years ago[project @ 1999-03-22 12:59:32 by simonm]
simonm [Mon, 22 Mar 1999 12:59:32 +0000 (12:59 +0000)]
[project @ 1999-03-22 12:59:32 by simonm]
Fix cost centre restores for unboxed tuple alternatives.

25 years ago[project @ 1999-03-22 11:26:03 by simonm]
simonm [Mon, 22 Mar 1999 11:26:03 +0000 (11:26 +0000)]
[project @ 1999-03-22 11:26:03 by simonm]
raise# now prints "uncaught exception" if it finds a STOP_FRAME.

25 years ago[project @ 1999-03-22 10:39:59 by simonpj]
simonpj [Mon, 22 Mar 1999 10:39:59 +0000 (10:39 +0000)]
[project @ 1999-03-22 10:39:59 by simonpj]
Fix the HsForAll case in TcMonoType.tc_type_kind so that it
permits types like

f :: forall a. Num a => (# a->a, a->a #)

Previously it insisted that the body of a for-all was a boxed
type, but 'f' makes perfect sense, and indeed occurs in interface
files as a result of CPR analysis.

25 years ago[project @ 1999-03-22 10:06:27 by simonm]
simonm [Mon, 22 Mar 1999 10:06:27 +0000 (10:06 +0000)]
[project @ 1999-03-22 10:06:27 by simonm]
Update from autoheader.

25 years ago[project @ 1999-03-22 09:24:45 by simonm]
simonm [Mon, 22 Mar 1999 09:24:45 +0000 (09:24 +0000)]
[project @ 1999-03-22 09:24:45 by simonm]
Missing ';'.

25 years ago[project @ 1999-03-20 17:33:07 by sof]
sof [Sat, 20 Mar 1999 17:33:07 +0000 (17:33 +0000)]
[project @ 1999-03-20 17:33:07 by sof]
cpp wibble

25 years ago[project @ 1999-03-18 17:57:19 by simonm]
simonm [Thu, 18 Mar 1999 17:57:24 +0000 (17:57 +0000)]
[project @ 1999-03-18 17:57:19 by simonm]
Some fixes to profiling stuff.

25 years ago[project @ 1999-03-18 14:16:00 by kw217]
kw217 [Thu, 18 Mar 1999 14:16:00 +0000 (14:16 +0000)]
[project @ 1999-03-18 14:16:00 by kw217]
Minor documentation fixes, and addition of SRT explanation.

25 years ago[project @ 1999-03-18 11:53:34 by simonm]
simonm [Thu, 18 Mar 1999 11:53:34 +0000 (11:53 +0000)]
[project @ 1999-03-18 11:53:34 by simonm]
egcs sometimes leaves a 'popl %ecx' in the epilogue, it seems.

25 years ago[project @ 1999-03-18 09:46:44 by simonm]
simonm [Thu, 18 Mar 1999 09:46:44 +0000 (09:46 +0000)]
[project @ 1999-03-18 09:46:44 by simonm]
Add infixr 1 =<<

25 years ago[project @ 1999-03-17 16:28:34 by sewardj]
sewardj [Wed, 17 Mar 1999 16:28:34 +0000 (16:28 +0000)]
[project @ 1999-03-17 16:28:34 by sewardj]
Make mut_link field be NULL when removing CAF_{UN}ENTERED from
mut_once_list.  Convention is to have the field be NULL iff
the caf is not on a mut_once_list.  This gives a O(1) cost way
to avoid putting a caf onto a mut_once_list more than once.

25 years ago[project @ 1999-03-17 16:25:07 by sewardj]
sewardj [Wed, 17 Mar 1999 16:25:07 +0000 (16:25 +0000)]
[project @ 1999-03-17 16:25:07 by sewardj]
Add missing semicolon

25 years ago[project @ 1999-03-17 13:19:19 by simonm]
simonm [Wed, 17 Mar 1999 13:19:28 +0000 (13:19 +0000)]
[project @ 1999-03-17 13:19:19 by simonm]
- Stack overflow now generates an (AsyncException StackOverflow)
  exception, which can be caught as normal.

- Add a stack overflow handler to the top-level mainIO handler, with
  the standard behaviour (i.e. call the stack overflow hook and then
  exit).

- Add a test for stack overflow catching.

- Fix a couple of bugs in async exception support.

25 years ago[project @ 1999-03-17 11:03:36 by simonm]
simonm [Wed, 17 Mar 1999 11:03:36 +0000 (11:03 +0000)]
[project @ 1999-03-17 11:03:36 by simonm]
Ignore type lambdas for the purposes of occurrence analysis.

25 years ago[project @ 1999-03-17 11:02:35 by simonm]
simonm [Wed, 17 Mar 1999 11:02:35 +0000 (11:02 +0000)]
[project @ 1999-03-17 11:02:35 by simonm]
Print (ICanSafelyBeINLINEd InsideLam _) as "__Ul".

25 years ago[project @ 1999-03-17 10:06:21 by simonpj]
simonpj [Wed, 17 Mar 1999 10:06:22 +0000 (10:06 +0000)]
[project @ 1999-03-17 10:06:21 by simonpj]
Make it so that Local (i.e. non-top-level) names record
whether they originally came from an interface file.  This
means that when unifying two type variables we can readily
choose one that occurred in the source, rather than one
imported from an interface file.  That in turn improves
compiler error messages.  E.g.

  rd :: (RealFloat a, RealFrac b) => b -> Transformation a
  rd degrees  = r ((degrees / 180.0) * pi)

used to say

    Could not deduce `Floating a'
(arising from use of `pi' at Foo.hs:11)
from the context: (RealFloat a1, RealFrac a)
    Probable cause: missing `Floating a' in type signature for `rd'

[here the 'a' came from the signature for 'pi' in PrelBase;
 the 'a1' is a renamed version of the 'a' in the source pgm]

but now says

    Could not deduce `Floating b'
(arising from use of `pi' at Foo.hs:11)
from the context: (RealFloat a, RealFrac b)
    Probable cause: missing `Floating b' in type signature for `rd'

25 years ago[project @ 1999-03-17 09:50:08 by simonm]
simonm [Wed, 17 Mar 1999 09:50:08 +0000 (09:50 +0000)]
[project @ 1999-03-17 09:50:08 by simonm]
When resizing a stack, set the Sp and Su of the old, dead, TSO to be just
beyond the end of its stack so we don't attempt to scavenge any part of
the stack in case we come across this TSO during GC.

25 years ago[project @ 1999-03-17 08:26:30 by simonpj]
simonpj [Wed, 17 Mar 1999 08:26:30 +0000 (08:26 +0000)]
[project @ 1999-03-17 08:26:30 by simonpj]
Complete the hack that lets us give 'error' the type

error :: forall a:?. String -> a

The kind '?' (also known as 'Type AnyBox') means that
error can be applied to unboxed types too.  unsafeCoerce is
similar.  But the 'real' type of error is:

error :: forall bv. forall a:Type bv. String -> a

That is, it's really polymorphic in the boxity of a; that's
different to saying that the type bound to 'a' must have
kind '?'.

The fix was in TcType.inst_tyvar, where we look for the kind '?'
and generate a boxity variable instead.  Sigh.

25 years ago[project @ 1999-03-16 17:07:21 by simonm]
simonm [Tue, 16 Mar 1999 17:07:23 +0000 (17:07 +0000)]
[project @ 1999-03-16 17:07:21 by simonm]
- Document the pragmas we support
- Fix some lies in the vs. Haskell section.

25 years ago[project @ 1999-03-16 13:20:07 by simonm]
simonm [Tue, 16 Mar 1999 13:20:23 +0000 (13:20 +0000)]
[project @ 1999-03-16 13:20:07 by simonm]
Improvements to the threading model.

   - asynchronous exceptions supported.

- killThread# can now raise an exception in the specified
  thread.  It's new type is

killThread# :: ThreadId# -> Exception -> IO ()

  High-level versions:

killThread :: ThreadId -> IO ()
raiseInThread :: ThreadId -> Exception -> IO ()

  (killThread raises a 'ThreadKilled' exception in the
   specified thread).

  If the thread has no exception handler, it is killed
  as before.  Otherwise, the exception is passed to
  the innermost CATCH_FRAME and the thread is woken up
  if it was blocked.  The current computation is
  suspended, instead of being replaced by the exception
  (as is the case with throw).

  Sending an exception to the current thread works too.

   - new primitive: myThreadId# :: IO ThreadId# and corresponding
     high-level version myThreadId :: IO ThreadId.

   - new primitive: yield# :: IO (), and yield :: IO ().

   - the TSO now contains a pointer to the resource currently blocked
     on (MVAR or BLACKHOLE_BQ).

  - Add a giant comment to TSO.h about what the various link fields
    are supposed to do, and invariants etc.

25 years ago[project @ 1999-03-16 12:36:15 by simonpj]
simonpj [Tue, 16 Mar 1999 12:36:15 +0000 (12:36 +0000)]
[project @ 1999-03-16 12:36:15 by simonpj]
Bring up to 4.02 interface file syntax

25 years ago[project @ 1999-03-16 12:31:55 by simonpj]
simonpj [Tue, 16 Mar 1999 12:31:55 +0000 (12:31 +0000)]
[project @ 1999-03-16 12:31:55 by simonpj]
Make it only a warning if you have a type like this:

forall a. Int -> Int

These show up in interface files occasionally, just because
the simplifier is a bit blase about adding type arguments.

But it's an error to have

forall a. Eq a => Int -> Int

The flag -fwarn-unused-matches reports a warning for these
redundant for-alls.

25 years ago[project @ 1999-03-15 17:11:27 by simonm]
simonm [Mon, 15 Mar 1999 17:11:27 +0000 (17:11 +0000)]
[project @ 1999-03-15 17:11:27 by simonm]
Remove a couple of stgcasts.

25 years ago[project @ 1999-03-15 16:53:10 by simonm]
simonm [Mon, 15 Mar 1999 16:53:11 +0000 (16:53 +0000)]
[project @ 1999-03-15 16:53:10 by simonm]
Specialise STATIC_LINK() for {FUN,THUNK,IND}_STATIC.

25 years ago[project @ 1999-03-15 16:31:02 by simonm]
simonm [Mon, 15 Mar 1999 16:31:02 +0000 (16:31 +0000)]
[project @ 1999-03-15 16:31:02 by simonm]
Reduce alignment for info tables on x86 to 1 word.  It was previously
4 words, which meant that the entry code was wrongly aligned all the
time (because info tables are either 2 or 3 words).  At least this way
we've got a 1 in 4 chance of being properly aligned.

25 years ago[project @ 1999-03-15 16:30:24 by simonm]
simonm [Mon, 15 Mar 1999 16:30:29 +0000 (16:30 +0000)]
[project @ 1999-03-15 16:30:24 by simonm]
Remove flags field from info tables; create a separate table of flags
indexed by the closure type in the RTS.

25 years ago[project @ 1999-03-15 15:11:03 by simonpj]
simonpj [Mon, 15 Mar 1999 15:11:11 +0000 (15:11 +0000)]
[project @ 1999-03-15 15:11:03 by simonpj]
Make clear in HsType whether a for-all is explicit
in the source program or not.  Implicit for-alls now
look like
HsForAllTy Nothing ctxt ty
while explicit ones look like
HsForAllTy (Just tvs) ctxt ty

Before this, the scope analysis stuff in RnSource was
actually wrong (not that anyone had noticed), but Alex Ferguson
did notice a bogus (sort-of-duplicate) error message on types
like
f :: Eq a => Int -> Int
which led me to spot the deeper problem.  Anyway, it's all
cool now.

25 years ago[project @ 1999-03-15 13:25:04 by simonm]
simonm [Mon, 15 Mar 1999 13:25:04 +0000 (13:25 +0000)]
[project @ 1999-03-15 13:25:04 by simonm]
Move mkdependHS to lib.

25 years ago[project @ 1999-03-11 17:39:18 by simonpj]
simonpj [Thu, 11 Mar 1999 17:39:18 +0000 (17:39 +0000)]
[project @ 1999-03-11 17:39:18 by simonpj]
Fix loadInterface to avoid repeated loading of PrelPack.hi-boot

25 years ago[project @ 1999-03-11 11:32:22 by simonm]
simonm [Thu, 11 Mar 1999 11:32:29 +0000 (11:32 +0000)]
[project @ 1999-03-11 11:32:22 by simonm]
Save a few bytes by ommitting the static link field on closures with
an empty SRT.

25 years ago[project @ 1999-03-11 11:21:45 by simonm]
simonm [Thu, 11 Mar 1999 11:21:47 +0000 (11:21 +0000)]
[project @ 1999-03-11 11:21:45 by simonm]
HPUX fixes.

25 years ago[project @ 1999-03-11 10:26:56 by sof]
sof [Thu, 11 Mar 1999 10:26:56 +0000 (10:26 +0000)]
[project @ 1999-03-11 10:26:56 by sof]
Pass -fcompiling-prelude through.

25 years ago[project @ 1999-03-11 09:46:30 by sof]
sof [Thu, 11 Mar 1999 09:46:31 +0000 (09:46 +0000)]
[project @ 1999-03-11 09:46:30 by sof]
-fcompiling-prelude is back!

When compiling the Prelude we need to distinguish between wired-in
module references that are DLL-bound or not. (Just having -static
didn't cut it in the end, since it also encompasses RTS references.)

On platforms that don't use Win32 DLLs, Preludes compiled with and
without -fcompiling-prelude will be observationally equivalent.

25 years ago[project @ 1999-03-11 09:31:53 by simonm]
simonm [Thu, 11 Mar 1999 09:31:53 +0000 (09:31 +0000)]
[project @ 1999-03-11 09:31:53 by simonm]
Fix a small bug in weak ptr support.

25 years ago[project @ 1999-03-11 09:11:38 by sof]
sof [Thu, 11 Mar 1999 09:11:38 +0000 (09:11 +0000)]
[project @ 1999-03-11 09:11:38 by sof]
After 'make install' has completed, make sure we regenerate the
script in a state that's useable.