ghc-hetmet.git
22 years ago[project @ 2002-01-29 06:15:03 by sof]
sof [Tue, 29 Jan 2002 06:15:03 +0000 (06:15 +0000)]
[project @ 2002-01-29 06:15:03 by sof]
Update comments re: reloc overflow. A careful re-read of the PE
spec did prove useful; Sec 4.1 (last para) describes how overflow
is handled.

22 years ago[project @ 2002-01-29 02:41:21 by sof]
sof [Tue, 29 Jan 2002 02:41:21 +0000 (02:41 +0000)]
[project @ 2002-01-29 02:41:21 by sof]
PEi386/COFF: handle relocation overflows, i.e., if a section is
marked with the flag (MY)IMAGE_SCN_LNK_NRELOC_OVFL, then
the first entry in the relocation table holds the 32-bit
relocation count rather than 16-bit number in the section header.
Apparently, a version of the MS PE spec exists that spells this
out, but haven't been able to locate it (perhaps people on the
'inside' could try to locate an up-to-date version...?) winnt.h
is clear enough about it though (as is the GNU libbfd sources).

This is the Right Way to compute the relocation count, but
unfortunately libbfd / GNU ld is generating bogus output
when the reloc field overflows (causing objdump/nm etc. to
crash when trying to read the generated output!) Looking into it.

Once this has been cleared up/fixed, the splitting up of HSstd.o
(and HSwin32.o) should be a thing of the past. I've taken the
liberty of disabling the suspiciously-large-reloc-section test
already.

22 years ago[project @ 2002-01-28 17:22:45 by sewardj]
sewardj [Mon, 28 Jan 2002 17:22:45 +0000 (17:22 +0000)]
[project @ 2002-01-28 17:22:45 by sewardj]
Generate better code for lets whose RHS is a simple fn or constructor
application.  Details are in comment in code.

22 years ago[project @ 2002-01-28 17:09:05 by simonmar]
simonmar [Mon, 28 Jan 2002 17:09:05 +0000 (17:09 +0000)]
[project @ 2002-01-28 17:09:05 by simonmar]
Catch up with recent changes in the middle end that changed the
assumptions about constructor applications: it is not necessarily the
case any more that constructor applications are always saturated in
the output from CorePrep.

For a non-saturated constructor application there is always a curried
worker function that can be called instead.  This change updates the
byte code generator to use the curried worker when necessary.

Also: a couple of micro-optimisations/cleanups.

22 years ago[project @ 2002-01-28 16:52:37 by simonpj]
simonpj [Mon, 28 Jan 2002 16:52:37 +0000 (16:52 +0000)]
[project @ 2002-01-28 16:52:37 by simonpj]
----------------------
Zero-constructor types
----------------------

If we have

data T
data S = MkS !T

we were getting a crash in the compiler because ctrlRetConvAlg
didn't know what to do for zero-constructor types.

This fix arbitrarily says that they use a non-vectored return,
which fixes the crash.  (Since they only have bottom values,
the return never gets exercised, but GC and exception handling
should work.)

What is still unclear is how we handle data types that are defined
with zero constructors in an hi-boot file.  I think that Bad Things
may well happen if you do a 'seq' on them before we get up to the
definition.  (e.g. as a result of this fix we'll say "unvectored"
whereas the truth may be "vectored".)  This obviously doesn't happen
much (because at present we'd get a compiler crash in ctrlRetConvAlg,
but we should look into it.

22 years ago[project @ 2002-01-28 13:47:05 by simonmar]
simonmar [Mon, 28 Jan 2002 13:47:05 +0000 (13:47 +0000)]
[project @ 2002-01-28 13:47:05 by simonmar]
Never close std file descriptors.  This works around a "problem" in
GHCi: if the program reaches EOF on stdin, it might close it, which in
turn causes the interactive shell to fall over with a "bad file
descriptor" error when it tries to read from stdin.

22 years ago[project @ 2002-01-28 13:34:10 by simonmar]
simonmar [Mon, 28 Jan 2002 13:34:10 +0000 (13:34 +0000)]
[project @ 2002-01-28 13:34:10 by simonmar]
Set stdin to unbuffered, so that GHCi doesn't accidentally buffer any
input that might be intended for the program.

22 years ago[project @ 2002-01-28 12:01:12 by simonmar]
simonmar [Mon, 28 Jan 2002 12:01:12 +0000 (12:01 +0000)]
[project @ 2002-01-28 12:01:12 by simonmar]
Make GHCi silent in "unverbose" mode (-v0).  Now you can get a crude
runhugs-style behaviour like this:

   echo main | ghci -v0 Main

22 years ago[project @ 2002-01-27 10:53:26 by panne]
panne [Sun, 27 Jan 2002 10:53:26 +0000 (10:53 +0000)]
[project @ 2002-01-27 10:53:26 by panne]
Unbreak 2nd stage build by tracking recent RTS naming changes
(ATTENTION: I'm not quite sure what I'm doing here exactly,
 but things seem to work... :-}

22 years ago[project @ 2002-01-26 18:04:48 by rje]
rje [Sat, 26 Jan 2002 18:04:48 +0000 (18:04 +0000)]
[project @ 2002-01-26 18:04:48 by rje]
Minor tweak to use the new names.

X_ret_info -> X_info.

Just so the mangler finds things more easily.

For more info, see the commit to HeapStackCheck.hc

22 years ago[project @ 2002-01-26 18:02:05 by rje]
rje [Sat, 26 Jan 2002 18:02:05 +0000 (18:02 +0000)]
[project @ 2002-01-26 18:02:05 by rje]
Change to declarations of info tables of the form X_ret_info to syncronise with my previous commit to HeapStackCheck.hc

22 years ago[project @ 2002-01-26 17:58:47 by rje]
rje [Sat, 26 Jan 2002 17:58:47 +0000 (17:58 +0000)]
[project @ 2002-01-26 17:58:47 by rje]
This is a simple fix for a rather obscure bug.

In the heap/stack checking code, we were creating info tables with names of the form stg_gc_X_ret_info, and giving them entry points with names of the form stg_gc_X_ret.

Unfortunately, the mangler expects that if an info table is called Y_info, the entry point should be called Y_ret or Y_entry.

In this case, the mangler thus looks for stg_gc_X_ret_ret and stg_gc_X_ret_entry, neither of which exists.

As a result, the entry points aren't placed directly after the info tables.

Fortunately, the code for the entry points was defined emmediately after the info table definition, and so was *usually* in the right place already.

However, in certain circumstances (that can result from some tweaks on my private tree, and might possibly occur by other means), this was not happening, and thus any attempts to enter the entry point for this info table will cause problems.

The fix is quite simple: rename the info tables so that the mangler finds the entry points and puts them in the right places.

I don't think this commit is likely to have a notable effect on anything else.

22 years ago[project @ 2002-01-25 16:46:53 by simonmar]
simonmar [Fri, 25 Jan 2002 16:46:54 +0000 (16:46 +0000)]
[project @ 2002-01-25 16:46:53 by simonmar]
In GHCi, if we are currently using a compiled version of a module and
the user compiles a new version of the module, allow the new version
to be linked in during a :reload.  (as suggested by Koen Claessen).

We can't go all the way and allow a newly compiled module to replace
an existing interpreted version, because the version numbers in the
interface file will be out-of-sync with our internal copy of the
interface.  To link in a newly compiled version of an interpreted
module, you still have to do :load.

22 years ago[project @ 2002-01-25 16:35:29 by simonmar]
simonmar [Fri, 25 Jan 2002 16:35:29 +0000 (16:35 +0000)]
[project @ 2002-01-25 16:35:29 by simonmar]
Fix bit-rot in TICKY_TICKY

22 years ago[project @ 2002-01-25 12:22:27 by simonmar]
simonmar [Fri, 25 Jan 2002 12:22:27 +0000 (12:22 +0000)]
[project @ 2002-01-25 12:22:27 by simonmar]
Fix tryTakeMVar - amazingly it only worked with an empty MVar, and
this was the only case I tested.  oops.

Merge to stable.

22 years ago[project @ 2002-01-25 10:28:12 by simonmar]
simonmar [Fri, 25 Jan 2002 10:28:15 +0000 (10:28 +0000)]
[project @ 2002-01-25 10:28:12 by simonmar]
Convert -fno-monomorphism-restriction into a dynamic flag.  Fixes bug
#508177.

22 years ago[project @ 2002-01-25 09:54:00 by simonpj]
simonpj [Fri, 25 Jan 2002 09:54:00 +0000 (09:54 +0000)]
[project @ 2002-01-25 09:54:00 by simonpj]
Typo

22 years ago[project @ 2002-01-24 16:55:35 by simonmar]
simonmar [Thu, 24 Jan 2002 16:55:37 +0000 (16:55 +0000)]
[project @ 2002-01-24 16:55:35 by simonmar]
Add support for Hugs's :browse (or :b) command.  There are two forms:

- :b M   (interpreted modules only) shows everything
          defined in M - the types of top-level functions,
  and definitions of classes and datatypes.

- :b *M  shows everything exported from module M.
  Available for both compiled and interpreted modules.

The user interface is subject to change, but for now it is consistent
with the new semantics of the :module command.

The implementation is a little tricky, since for a package module we
have to be sure to slurp in all the required declarations first.

22 years ago[project @ 2002-01-24 16:55:04 by sewardj]
sewardj [Thu, 24 Jan 2002 16:55:04 +0000 (16:55 +0000)]
[project @ 2002-01-24 16:55:04 by sewardj]
This is one of those commits where the commit message is hundreds of
times, in bytes, larger than the fix.  If you count pixels, it's
probably more like thousands of times larger, since the fix involves
adding a missing apostrophe.

In compiling let bindings, when filtering the free vars of each RHS
against the supplied on-stack environment p, filter against p after it
has been augmented with the binders in this let (viz, p'), rather than
before.  Without this, letrec-bound binders can never "get started" in
the environment.

This fixes the HEAD crash for [(i,1) | i <- [1]].  Stable branch
is ok since the free-var machinery works a different way there.

22 years ago[project @ 2002-01-24 07:50:01 by sof]
sof [Thu, 24 Jan 2002 07:50:02 +0000 (07:50 +0000)]
[project @ 2002-01-24 07:50:01 by sof]
SMP: misc tasks timing stats fixes

22 years ago[project @ 2002-01-24 02:15:19 by sof]
sof [Thu, 24 Jan 2002 02:15:19 +0000 (02:15 +0000)]
[project @ 2002-01-24 02:15:19 by sof]
SMP: hack-and-slash to bring BaseReg into scope

22 years ago[project @ 2002-01-24 02:06:48 by sof]
sof [Thu, 24 Jan 2002 02:06:49 +0000 (02:06 +0000)]
[project @ 2002-01-24 02:06:48 by sof]
SMP: disable spark support (only a little bit of header file re-jigging is reqd to get it going again, I suspect.)

22 years ago[project @ 2002-01-24 01:45:55 by sof]
sof [Thu, 24 Jan 2002 01:45:55 +0000 (01:45 +0000)]
[project @ 2002-01-24 01:45:55 by sof]
SMP: bunch of triv. changes to account for the fact that a Capability is no longer just a RegTable

22 years ago[project @ 2002-01-24 00:53:18 by sof]
sof [Thu, 24 Jan 2002 00:53:18 +0000 (00:53 +0000)]
[project @ 2002-01-24 00:53:18 by sof]
Way 's': add -DSMP to HC_ and CC_OPTS

22 years ago[project @ 2002-01-24 00:40:28 by sof]
sof [Thu, 24 Jan 2002 00:40:28 +0000 (00:40 +0000)]
[project @ 2002-01-24 00:40:28 by sof]
SMP: move link field from StgRegTable to Capability

22 years ago[project @ 2002-01-23 23:53:54 by sof]
sof [Wed, 23 Jan 2002 23:53:54 +0000 (23:53 +0000)]
[project @ 2002-01-23 23:53:54 by sof]
make it compile when GHCI aint

22 years ago[project @ 2002-01-23 17:51:46 by lewie]
lewie [Wed, 23 Jan 2002 17:51:46 +0000 (17:51 +0000)]
[project @ 2002-01-23 17:51:46 by lewie]
Add special case for installing shared libs (which need the execute bit set).

22 years ago[project @ 2002-01-23 16:50:46 by simonmar]
simonmar [Wed, 23 Jan 2002 16:50:52 +0000 (16:50 +0000)]
[project @ 2002-01-23 16:50:46 by simonmar]
- Implement an alternative :module syntax so we can play around with it.

- Implement ':show bindings' and ':show modules'

- Fix a bug whereby doing :info on a local binding would cause a panic
  (this needs to be merged to STABLE - the change is part of the patch
  to HscMain).

- Some cleanups in InteractiveUI.hs

22 years ago[project @ 2002-01-23 11:29:12 by sewardj]
sewardj [Wed, 23 Jan 2002 11:29:12 +0000 (11:29 +0000)]
[project @ 2002-01-23 11:29:12 by sewardj]
Fix two problems with the ELF linker:

1.  Determine section attributes by examining various bits in the
    section header tables, rather than from the section names.  This
    makes it robust against future changes / additions to the set of
    section names.

2.  Handle local symbols differently.  Do not add them to our own
    local symbol table for this object, since that's

    (a) wrong -- multiple local symbols can have the same name so long
        as each is in a different section, so if we just dump them into
        the local symbol table we'll wind up with apparently duplicate
        symbols

    (b) totally unnecessary, since the relocations against local symbols
        simply specify an index into the ELF symbol table for the object,
        from whence the address can be calculated without reference to the
        name.

TODO: Test on sparc-solaris
      Investigate whether PEi386 linker needs fixing similarly
and then
MERGE TO STABLE

22 years ago[project @ 2002-01-23 11:11:13 by simonmar]
simonmar [Wed, 23 Jan 2002 11:11:13 +0000 (11:11 +0000)]
[project @ 2002-01-23 11:11:13 by simonmar]
Revert to running command-line statements in the context of the
current thread, so that ^C exceptions get delivered to the right
place.

Now that a deadlock generates an exception this is not so bad, but it
would be nice to do it the "right" way so I've left the old code in a
comment for now.

22 years ago[project @ 2002-01-22 16:58:37 by simonmar]
simonmar [Tue, 22 Jan 2002 16:58:37 +0000 (16:58 +0000)]
[project @ 2002-01-22 16:58:37 by simonmar]
More wibbles, sigh.  Must have been typing with my elbows when I made
that change.

22 years ago[project @ 2002-01-22 16:50:29 by simonmar]
simonmar [Tue, 22 Jan 2002 16:50:29 +0000 (16:50 +0000)]
[project @ 2002-01-22 16:50:29 by simonmar]
CmRunDeadlocked no longer exists

22 years ago[project @ 2002-01-22 15:55:59 by simonmar]
simonmar [Tue, 22 Jan 2002 15:55:59 +0000 (15:55 +0000)]
[project @ 2002-01-22 15:55:59 by simonmar]
Fix wibbles in previous commit.

22 years ago[project @ 2002-01-22 14:47:52 by simonmar]
simonmar [Tue, 22 Jan 2002 14:47:52 +0000 (14:47 +0000)]
[project @ 2002-01-22 14:47:52 by simonmar]
Strip whitespace from the beginning of the line when looking for
OPTIONS pragmas.

22 years ago[project @ 2002-01-22 13:54:22 by simonmar]
simonmar [Tue, 22 Jan 2002 13:54:23 +0000 (13:54 +0000)]
[project @ 2002-01-22 13:54:22 by simonmar]
Deadlock is now an exception instead of a return status from
rts_evalIO().

The current behaviour is as follows, and can be changed if necessary:
in the event of a deadlock, the top main thread is taken from the main
thread queue, and if it is blocked on an MVar or an Exception (for
throwTo), then it receives a Deadlock exception.  If it is blocked on
a BLACKHOLE, we instead send it the NonTermination exception.  Note
that only the main thread gets the exception: it is the responsibility
of the main thread to unblock other threads if necessary.

There's a slight difference in the SMP build: *all* the main threads
get an exception, because clearly none of them may make progress
(compared to the non-SMP situation, where all but the top main thread
are usually blocked).

22 years ago[project @ 2002-01-22 13:35:36 by simonmar]
simonmar [Tue, 22 Jan 2002 13:35:37 +0000 (13:35 +0000)]
[project @ 2002-01-22 13:35:36 by simonmar]
Attempt to fix the problems with missing instances once more.

The current problem is that in the case where a ModDetails is being
constructed from its interface (in compilation manager modes) we
weren't getting any instances because the instances are gotten from
the [InstInfo] returned from tcInstDecls1, which only contains
*source* instance declarations.  Fix: return a list of DFuns defined
in the current module from tcInstDecls1, to be plugged into the
ModDetails later.

Also: revert the previous change to the isLocalThing predicate,
because now we really want to know which dfuns come from the current
module.  The comment about the iface_dfuns containing only package and
local instances is incorrect in batch-compile mode, because we also
demand-load stuff from home package interfaces, so I deleted this
comment and fixed up some of the other commentary.

22 years ago[project @ 2002-01-22 13:09:36 by simonmar]
simonmar [Tue, 22 Jan 2002 13:09:37 +0000 (13:09 +0000)]
[project @ 2002-01-22 13:09:36 by simonmar]
Fix for a change in CPP's behaviour in gcc 2.96 relative to 2.95.
Unlit used to inject '# <line> <file>' at the beginning of the output
file, but in gcc 2.96 this is ignored.  Instead we have to inject
'#line <line> <file>', which in turn means that GHC's lexer has to
understand this kind of pragma in addition to the plain '#' form, in
the case when we aren't running CPP after unlitting.

22 years ago[project @ 2002-01-22 13:04:13 by simonmar]
simonmar [Tue, 22 Jan 2002 13:04:13 +0000 (13:04 +0000)]
[project @ 2002-01-22 13:04:13 by simonmar]
Import wibbles

22 years ago[project @ 2002-01-21 19:56:20 by sof]
sof [Mon, 21 Jan 2002 19:56:20 +0000 (19:56 +0000)]
[project @ 2002-01-21 19:56:20 by sof]
assume bash (and not ash) is used with mingw

22 years ago[project @ 2002-01-21 17:18:43 by sof]
sof [Mon, 21 Jan 2002 17:18:43 +0000 (17:18 +0000)]
[project @ 2002-01-21 17:18:43 by sof]
multi-slurp protect

22 years ago[project @ 2002-01-18 07:02:59 by sof]
sof [Fri, 18 Jan 2002 07:02:59 +0000 (07:02 +0000)]
[project @ 2002-01-18 07:02:59 by sof]
tcInstDecls1: partition up interface instances using isHomePackageThing rather than isLocalThing

22 years ago[project @ 2002-01-18 06:44:33 by sof]
sof [Fri, 18 Jan 2002 06:44:33 +0000 (06:44 +0000)]
[project @ 2002-01-18 06:44:33 by sof]
added isHomePackageThing :: NamedThing a => a -> Bool

22 years ago[project @ 2002-01-17 09:52:18 by sof]
sof [Thu, 17 Jan 2002 09:52:19 +0000 (09:52 +0000)]
[project @ 2002-01-17 09:52:18 by sof]
For AR and LD, transform "/cygdrive/<drive>/..." paths to "<drive>:\..." --
enables the use of mingw-based GNU Make.

22 years ago[project @ 2002-01-17 09:15:16 by sof]
sof [Thu, 17 Jan 2002 09:15:16 +0000 (09:15 +0000)]
[project @ 2002-01-17 09:15:16 by sof]
bash behaviour re: quoting and backslashes has changed (win32), cope.

22 years ago[project @ 2002-01-17 08:37:57 by sof]
sof [Thu, 17 Jan 2002 08:38:00 +0000 (08:38 +0000)]
[project @ 2002-01-17 08:37:57 by sof]
- removed KludgedSystem; no longer needed.
- be path separator savvy.

22 years ago[project @ 2002-01-16 23:34:31 by chak]
chak [Wed, 16 Jan 2002 23:34:31 +0000 (23:34 +0000)]
[project @ 2002-01-16 23:34:31 by chak]
Added an intro to the workings of the desugarer and details about the pattern
matching compiler.

22 years ago[project @ 2002-01-15 05:39:14 by sof]
sof [Tue, 15 Jan 2002 05:39:15 +0000 (05:39 +0000)]
[project @ 2002-01-15 05:39:14 by sof]
updates & fixes to hc-bootstrapping story; from Thomas Nordin

22 years ago[project @ 2002-01-11 15:32:05 by sof]
sof [Fri, 11 Jan 2002 15:32:05 +0000 (15:32 +0000)]
[project @ 2002-01-11 15:32:05 by sof]
add HSstd{1,2}.o to INSTALL_LIBS (mingw only)

22 years ago[project @ 2002-01-10 10:46:12 by sof]
sof [Thu, 10 Jan 2002 10:46:12 +0000 (10:46 +0000)]
[project @ 2002-01-10 10:46:12 by sof]
Better off if GhcBinDistShScripts is just empty on mingw plats

22 years ago[project @ 2002-01-10 10:33:48 by sof]
sof [Thu, 10 Jan 2002 10:33:48 +0000 (10:33 +0000)]
[project @ 2002-01-10 10:33:48 by sof]
mingw only: associate FPish icon (nicked from Hugs) with
the GHCi wrapper app.

22 years ago[project @ 2002-01-10 10:29:09 by sof]
sof [Thu, 10 Jan 2002 10:29:09 +0000 (10:29 +0000)]
[project @ 2002-01-10 10:29:09 by sof]
'std' now also needs user32 (under win32)

22 years ago[project @ 2002-01-09 12:41:45 by simonmar]
simonmar [Wed, 9 Jan 2002 12:41:47 +0000 (12:41 +0000)]
[project @ 2002-01-09 12:41:45 by simonmar]
First cut at enhancing the facilities for manipulating the scope in
GHCi.  The scope now consists of

  1. the full top-level scope of zero or more interpreted modules
  2. the exports from zero or more modules
  3. the temporary bindings

The sets 1 & 2 are manipulated using an extended :m command: eg :m +A
will add module A to either set 1 or two depending on whether A is
interpreted, and :m -A will remove it.  The user interface may change,
pending feedback from the punters on the mailing list.

'Prelude' is automatically added to the scope if set 1 is empty and
set 2 doesn't already contain it.

We now cache the GlobalRdrEnv for the current scope between
evaluations in the InteractiveContext, and also the current
PrintUnqualified setting (which also depends on the scope).

Cvs: ----------------------------------------------------------------------

22 years ago[project @ 2002-01-09 10:29:32 by simonmar]
simonmar [Wed, 9 Jan 2002 10:29:32 +0000 (10:29 +0000)]
[project @ 2002-01-09 10:29:32 by simonmar]
Back out previous fix, I've hacked it in a different place which is at
least closer to the source of the problem.

22 years ago[project @ 2002-01-09 10:27:41 by simonmar]
simonmar [Wed, 9 Jan 2002 10:27:41 +0000 (10:27 +0000)]
[project @ 2002-01-09 10:27:41 by simonmar]
Don't add -package-name if $(PACKAGE) == "rts".  THis is a HACK and we
need to fix the mess in ghc/rts/Makefile properly.

22 years ago[project @ 2002-01-08 17:31:30 by simonmar]
simonmar [Tue, 8 Jan 2002 17:31:30 +0000 (17:31 +0000)]
[project @ 2002-01-08 17:31:30 by simonmar]
Fix a problem which lead to home-package instances ending up in the
package instance table in GHCi, which results in strange duplicate
instance errors when reloading modules.  See the comments for details.

22 years ago[project @ 2002-01-08 16:38:27 by sof]
sof [Tue, 8 Jan 2002 16:38:27 +0000 (16:38 +0000)]
[project @ 2002-01-08 16:38:27 by sof]
Make better use of the -M<size> setting under Win32. Use it to guide
the amount of VM to reserve -- the default is (still) 256M, but the
user will now have a way of overriding this setting.

22 years ago[project @ 2002-01-08 15:56:03 by sof]
sof [Tue, 8 Jan 2002 15:56:03 +0000 (15:56 +0000)]
[project @ 2002-01-08 15:56:03 by sof]
Track PrimOp changes.

22 years ago[project @ 2002-01-08 14:55:50 by sof]
sof [Tue, 8 Jan 2002 14:55:50 +0000 (14:55 +0000)]
[project @ 2002-01-08 14:55:50 by sof]
make -split-objs work again

22 years ago[project @ 2002-01-08 14:11:28 by sof]
sof [Tue, 8 Jan 2002 14:11:28 +0000 (14:11 +0000)]
[project @ 2002-01-08 14:11:28 by sof]
adjust pointer to the RTS profiling options section

22 years ago[project @ 2002-01-08 13:52:34 by sof]
sof [Tue, 8 Jan 2002 13:52:34 +0000 (13:52 +0000)]
[project @ 2002-01-08 13:52:34 by sof]
IS setup: remove HDirect com lib reference; no longer bundled

22 years ago[project @ 2002-01-08 10:59:42 by sewardj]
sewardj [Tue, 8 Jan 2002 10:59:42 +0000 (10:59 +0000)]
[project @ 2002-01-08 10:59:42 by sewardj]
merge from stable branch:
  1.46.4.3  +14 -7     fptools/ghc/compiler/nativeGen/AsmCodeGen.lhs
  1.47.4.3  +2 -0      fptools/ghc/compiler/nativeGen/MachMisc.lhs

  Treat literal appearances of BaseReg in Stix trees uniformly.
  This is now taken to mean the &MainCapability.r, regardless of
  whether BaseReg is in a register (x86) or synthesised (sparc).

22 years ago[project @ 2002-01-08 10:42:56 by sewardj]
sewardj [Tue, 8 Jan 2002 10:42:56 +0000 (10:42 +0000)]
[project @ 2002-01-08 10:42:56 by sewardj]
merge from stable branch, rev 1.34.4.1:

   Add missing case to magicIdPrimRep.

22 years ago[project @ 2002-01-08 10:36:24 by sewardj]
sewardj [Tue, 8 Jan 2002 10:36:24 +0000 (10:36 +0000)]
[project @ 2002-01-08 10:36:24 by sewardj]
merge from the stable branch:

  1.70.4.2  fptools/ghc/compiler/nativeGen/StixPrim.lhs
  1.5.10.3  fptools/ghc/includes/mkNativeHdr.c

  Track recent changes to HpLim assignment in load_thread_state.

22 years ago[project @ 2002-01-08 07:29:07 by chak]
chak [Tue, 8 Jan 2002 07:29:07 +0000 (07:29 +0000)]
[project @ 2002-01-08 07:29:07 by chak]
Some docu covering VarSet, NameSet, VarEnv, and NameEnv.

22 years ago[project @ 2002-01-07 22:39:20 by ken]
ken [Mon, 7 Jan 2002 22:39:20 +0000 (22:39 +0000)]
[project @ 2002-01-07 22:39:20 by ken]
Ignore -package-name <package-name> on the command line.
MERGE TO STABLE

22 years ago[project @ 2002-01-07 22:35:55 by ken]
ken [Mon, 7 Jan 2002 22:35:55 +0000 (22:35 +0000)]
[project @ 2002-01-07 22:35:55 by ken]
On the alpha, __divq() in libc.a clobbers $s6, so StgRun() needs to save
$s6.  While we are at it, let us save $f8 and $f9 as well.
MERGE TO STABLE

22 years ago[project @ 2002-01-07 20:52:53 by sof]
sof [Mon, 7 Jan 2002 20:52:53 +0000 (20:52 +0000)]
[project @ 2002-01-07 20:52:53 by sof]
updated

22 years ago[project @ 2002-01-07 20:50:00 by sof]
sof [Mon, 7 Jan 2002 20:50:00 +0000 (20:50 +0000)]
[project @ 2002-01-07 20:50:00 by sof]
Convert PrelPosix from a .hsc file into a
.hs file (that gets its configuration-time info
via config.h).

22 years ago[project @ 2002-01-07 20:46:52 by sof]
sof [Mon, 7 Jan 2002 20:46:52 +0000 (20:46 +0000)]
[project @ 2002-01-07 20:46:52 by sof]
remove debugging bits

22 years ago[project @ 2002-01-07 20:24:22 by sof]
sof [Mon, 7 Jan 2002 20:24:23 +0000 (20:24 +0000)]
[project @ 2002-01-07 20:24:22 by sof]
added feature tests for a bunch of C types we need to know the Haskell equiv. of

22 years ago[project @ 2002-01-07 16:32:54 by sof]
sof [Mon, 7 Jan 2002 16:32:54 +0000 (16:32 +0000)]
[project @ 2002-01-07 16:32:54 by sof]
doc fix - correct example invoc. of 'rc'

22 years ago[project @ 2002-01-07 15:29:56 by sof]
sof [Mon, 7 Jan 2002 15:29:57 +0000 (15:29 +0000)]
[project @ 2002-01-07 15:29:56 by sof]
Ho-hum, readdir() and readdir_r() with GNU libc doesn't
flag the end of the directory stream the same way. Cope.

22 years ago[project @ 2002-01-07 12:26:49 by simonpj]
simonpj [Mon, 7 Jan 2002 12:26:49 +0000 (12:26 +0000)]
[project @ 2002-01-07 12:26:49 by simonpj]
Dont print (Prod [AAA]) same as (Poly Abs)

22 years ago[project @ 2002-01-07 12:25:09 by simonpj]
simonpj [Mon, 7 Jan 2002 12:25:09 +0000 (12:25 +0000)]
[project @ 2002-01-07 12:25:09 by simonpj]
comments only

22 years ago[project @ 2002-01-05 11:28:31 by sof]
sof [Sat, 5 Jan 2002 11:28:31 +0000 (11:28 +0000)]
[project @ 2002-01-05 11:28:31 by sof]
fix pathconf() usage

22 years ago[project @ 2002-01-04 23:21:18 by sof]
sof [Fri, 4 Jan 2002 23:21:18 +0000 (23:21 +0000)]
[project @ 2002-01-04 23:21:18 by sof]
prel_readdir: tidied

22 years ago[project @ 2002-01-04 16:02:03 by simonmar]
simonmar [Fri, 4 Jan 2002 16:02:05 +0000 (16:02 +0000)]
[project @ 2002-01-04 16:02:03 by simonmar]
Some driver cleanups; in particular -fno-code should work in a more
reasonable way (it is now a "mode flag" like -C, -c, --make etc.).

22 years ago[project @ 2002-01-04 11:39:00 by simonpj]
simonpj [Fri, 4 Jan 2002 11:39:01 +0000 (11:39 +0000)]
[project @ 2002-01-04 11:39:00 by simonpj]
-----------------------------
Fix a too-vigorous export bug
-----------------------------

MERGE TO STABLE

[this is the Ian Lynagh -O2 bug]

CoreTidy didn't filter the rules that it exports, so it
exported some that mentioned Ids on the *left* hand side
that are not exported.  So an importing module fell over.

The fix is simple: filter the exposed rules.   On the way
I tidied up CoreFVs a little.

22 years ago[project @ 2002-01-04 11:35:47 by simonpj]
simonpj [Fri, 4 Jan 2002 11:36:28 +0000 (11:36 +0000)]
[project @ 2002-01-04 11:35:47 by simonpj]
Comments only

22 years ago[project @ 2002-01-04 11:35:22 by simonpj]
simonpj [Fri, 4 Jan 2002 11:35:22 +0000 (11:35 +0000)]
[project @ 2002-01-04 11:35:22 by simonpj]
----------------------------------------
Be a bit less gung ho about let-floating
----------------------------------------

Sometimes it's a bad idea to float cheap expressions
outwards, even if they escape a value lambda.

  -- Even if it escapes a value lambda, we only
  -- float if it's not cheap (unless it'll get all the
  -- way to the top).  I've seen cases where we
  -- float dozens of tiny free expressions, which cost
  -- more to allocate than to evaluate.
  -- NB: exprIsCheap is also true of bottom expressions, which
  --     is good; we don't want to share them
  --
  -- It's only Really Bad to float a cheap expression out of a
  -- strict context, because that builds a thunk that otherwise
  -- would never be built.  So another alternative would be to
  -- add
  --  || (strict_ctxt && not (exprIsBottom expr))
  -- to the condition above. We should really try this out.

The relevant function is lvlMFE, which has been subject to a lot
of fiddling over the years.  Probably this isn't the last time.

This all actually showed up when I was compiling IA.lhs from Ian Lynagh.

22 years ago[project @ 2002-01-04 11:35:13 by simonmar]
simonmar [Fri, 4 Jan 2002 11:35:13 +0000 (11:35 +0000)]
[project @ 2002-01-04 11:35:13 by simonmar]
- rename CompManager.cmLoadModule to cmLoadModules and make it take
  a DynFlags argument to be consistent with the rest of the
  CompManager interface.

- split cmLoadModule into two parts: cmDepAnal which takes a list of
  filenames and returns a ModuleGraph, and cmLoadModules which takes
  the ModuleGraph and does the rest.  This lets the consumer know
  whether the dependency analysis step fails before unloading any
  existing modules - i.e. if you :reload and a module is missing, you
  don't lose the modules that are already loaded (bug reported by
  MIchael Weber some time ago).

22 years ago[project @ 2002-01-04 10:56:09 by sof]
sof [Fri, 4 Jan 2002 10:56:10 +0000 (10:56 +0000)]
[project @ 2002-01-04 10:56:09 by sof]
getDirectoryContents: use the re-entrant readdir_r() to get at directory
entries, if available.

22 years ago[project @ 2002-01-04 10:54:20 by sof]
sof [Fri, 4 Jan 2002 10:54:21 +0000 (10:54 +0000)]
[project @ 2002-01-04 10:54:20 by sof]
add feature test for readdir_r()

22 years ago[project @ 2002-01-04 10:44:16 by simonmar]
simonmar [Fri, 4 Jan 2002 10:44:16 +0000 (10:44 +0000)]
[project @ 2002-01-04 10:44:16 by simonmar]
update the rather dated usage message

22 years ago[project @ 2002-01-04 10:25:33 by simonpj]
simonpj [Fri, 4 Jan 2002 10:25:33 +0000 (10:25 +0000)]
[project @ 2002-01-04 10:25:33 by simonpj]
Warn, dont crash, when isIn gets a big list

22 years ago[project @ 2002-01-04 10:18:58 by simonmar]
simonmar [Fri, 4 Jan 2002 10:19:00 +0000 (10:19 +0000)]
[project @ 2002-01-04 10:18:58 by simonmar]
Replace all instances of '--' with '&ndash;&ndash;' since '--' gets
interpreted by JadeTeX to mean a single dash.

22 years ago[project @ 2002-01-04 10:04:44 by simonmar]
simonmar [Fri, 4 Jan 2002 10:04:44 +0000 (10:04 +0000)]
[project @ 2002-01-04 10:04:44 by simonmar]
replace -- with &mdash;

22 years ago[project @ 2002-01-04 09:35:42 by simonmar]
simonmar [Fri, 4 Jan 2002 09:35:42 +0000 (09:35 +0000)]
[project @ 2002-01-04 09:35:42 by simonmar]
oops, unb??rk the export list in the non-GHCI case.

22 years ago[project @ 2002-01-03 17:09:13 by simonmar]
simonmar [Thu, 3 Jan 2002 17:09:15 +0000 (17:09 +0000)]
[project @ 2002-01-03 17:09:13 by simonmar]
- change the mi_globals field of ModIface to be (Maybe GlobalRdrEnv)
  from GlobalRdrEnv.  The idea is that modules which we have
  compiled from source will have a complete GlobalRdrEnv in this field
  containing their top-level environments, whereas modules which we
  have loaded from object files (package modules and pre-compiled home
  modules) will have Nothing and we'll create a fake GlobalRdrEnv on
  demand from the export list.

  Previously we used to create the fake env all the time, but this way
  highlights the fact that we don't really have a proper GlobalRdrEnv
  for these modules (something we'd like to address at some point).

- rename CompManager.cmLoadModule to cmLoadModules and make it take
  a DynFlags argument to be consistent with the rest of the
  CompManager interface.

- split cmLoadModule into two parts: cmDepAnal which takes a list of
  filenames and returns a ModuleGraph, and cmLoadModules which takes
  the ModuleGraph and does the rest.  This lets the consumer know
  whether the dependency analysis step fails before unloading any
  existing modules - i.e. if you :reload and a module is missing, you
  don't lose the modules that are already loaded (bug reported by
  MIchael Weber some time ago).

22 years ago[project @ 2002-01-03 17:05:50 by sewardj]
sewardj [Thu, 3 Jan 2002 17:05:50 +0000 (17:05 +0000)]
[project @ 2002-01-03 17:05:50 by sewardj]
If addDLL returns an error message, actually show it to the user :)

Fixes: Sourceforge [ #482594 ] dlopen() errors reported badly

MERGE TO STABLE

22 years ago[project @ 2002-01-03 14:43:30 by sof]
sof [Thu, 3 Jan 2002 14:43:30 +0000 (14:43 +0000)]
[project @ 2002-01-03 14:43:30 by sof]
prel_sizeof_{termios,sigset_t}: sync up proto and impl

22 years ago[project @ 2002-01-03 11:45:06 by simonmar]
simonmar [Thu, 3 Jan 2002 11:45:06 +0000 (11:45 +0000)]
[project @ 2002-01-03 11:45:06 by simonmar]
Fix for previous commit: use the SRT on the top-level constructor when
deciding whether it has any CAF references, since not all top-level
bindings have CgInfo pinned on.

22 years ago[project @ 2002-01-03 11:44:17 by simonmar]
simonmar [Thu, 3 Jan 2002 11:44:17 +0000 (11:44 +0000)]
[project @ 2002-01-03 11:44:17 by simonmar]
Add comment.

22 years ago[project @ 2002-01-03 11:43:41 by simonmar]
simonmar [Thu, 3 Jan 2002 11:43:41 +0000 (11:43 +0000)]
[project @ 2002-01-03 11:43:41 by simonmar]
Export nonEmptySRT.

22 years ago[project @ 2002-01-02 12:32:18 by simonmar]
simonmar [Wed, 2 Jan 2002 12:32:20 +0000 (12:32 +0000)]
[project @ 2002-01-02 12:32:18 by simonmar]
- Implement a small GC optimisation: when a static constructor has
  been determined to have no (indirect) CAF references, we set its
  static link field to a non-zero value (currently 1).  This prevents
  the garbage collector from traversing this closure and transitively
  everything it points to, and thus should speed up GC a little.

- Omit the static link field from static constructors which have no
  pointer fields (i.e. they are CONSTR_NOCAF_STATIC).

- Add the padding words and the static link field for a static
  constructor at (AbsC) code generation time, rather than in the back
  ends.  This eliminates some duplication between PprAbsC and
  AbsCStixGen.

22 years ago[project @ 2002-01-02 12:27:43 by simonmar]
simonmar [Wed, 2 Jan 2002 12:27:43 +0000 (12:27 +0000)]
[project @ 2002-01-02 12:27:43 by simonmar]
No need for #ifdef around shift primop now.

22 years ago[project @ 2001-12-30 19:52:23 by sof]
sof [Sun, 30 Dec 2001 19:52:23 +0000 (19:52 +0000)]
[project @ 2001-12-30 19:52:23 by sof]
document --update-package option

22 years ago[project @ 2001-12-30 19:51:33 by sof]
sof [Sun, 30 Dec 2001 19:51:33 +0000 (19:51 +0000)]
[project @ 2001-12-30 19:51:33 by sof]
new option: -u / --update-package

22 years ago[project @ 2001-12-29 09:24:42 by sof]
sof [Sat, 29 Dec 2001 09:24:42 +0000 (09:24 +0000)]
[project @ 2001-12-29 09:24:42 by sof]
add raft of missing symbols to RTS_SYMBOLS

22 years ago[project @ 2001-12-28 22:58:17 by sof]
sof [Fri, 28 Dec 2001 22:58:17 +0000 (22:58 +0000)]
[project @ 2001-12-28 22:58:17 by sof]
struct sigset_t -> sigset_t