| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Bye bye STG Hugs!
|
|
|
|
|
|
|
| |
o Adding simple counter for number of enters
o Inc version number
o Adding the start of support for mdo
o Wibble
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I've bitten the bullet and cleaned up the mess around Readline. There
are actually questions to answer by autoconf:
* Are the headers available for compilation?
* Are the libraries (and which) available for linking?
Note that in the second case it should be the libraries on the machine
which GHC is *installed* on, not the ones on which it was compiled.
GhcLibsWithReadline is now automagically set if the headers are found,
but this can still be overridden.
|
|
|
|
| |
/tmp/msg
|
|
|
|
| |
Removing the "import privileged" implementation from hugs.
|
|
|
|
| |
Changing PrimPrel to PrelPrim.
|
|
|
|
|
|
|
| |
Adding in support for split Hugs Prelude.
There are now two preludes.
(1) PrimPrel - the Prelude defintions, and the extra magic datatypes.
(2) Prelude - the external interface for Prelude.
|
|
|
|
|
| |
Reimplement interrupt handling in a way compatible with the
revised module chaser, etc.
|
|
|
|
|
| |
Make Hugs compile on Win32 again after recent changes. Also, rename
prelude.h to hugsbasictypes.h to avoid conflicts with includes/Prelude.h.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Initial commit of major changes to module chasing and storage management:
* Total reimplementation of module chasing (see achieveTargetModules
in hugs.c). Build, maintain and use module dependency graphs
to decide what needs reloading when. The old mechanism with a
stack of scripts, etc, is gone forever. All the rest of these points
are in support of the module-chasing change:
* The result of parsing a module is now a parse tree, rather than a
half-baked parse tree and a bunch of side-effects. Hooray!
* Redo symbol tables for Names, Tycons, Classes, Instances and
Modules. They are now dynamically expandable, doubling in size
automatically when full, and use a freelist system to keep track
of available slots.
* Allow arbitrary modules to be deleted from the system. The
main honcho here is nukeModule().
* Not strictly necessary, but ... unify the address space for all
compile-time entities. See revised whatIs(). Text is part of
the unified address space. This is very convenient for debugging.
print() can now print practically anything. Generally simplify
storage management as much as possible, and zap the years of
elaborate hacks needed to make Hugs work well in 16-bit systems.
Added a load of sanity-checking support to storage.[ch].
* We don't support project files any more. They were useful for a
while, but no longer seem relevant.
* Nuked a large bunch of irrelevant options in rts/options.h.
As of this commit, the system can load and chase modules, both in
standalone and combined modes. The :l (load), :a (also), :r (refresh),
:i (info), :t (show type) and :m (set eval module) commands appear
to work. There are also several temporary limitations which will
be fixed soon:
* Anything to do with external editors, etc, doesn't work.
* The downward-closure-of-object-code (if M is object, all
modules below M must be too) is not enforced nor checked for.
It needs to be.
* Module M _must_ reside in M.hs/M.o (sigh). To be fixed.
* Error handling is probably flaky, and interrupt handling
very likely is.
* Error messages don't have line numbers. (A 5-minute fix).
* Progress messages are all at sea; needs re-thinking now that
the order in which things are done is radically different.
* Compile-time GC is temporarily disabled whilst I figure out how
to stress-test the GC.
* Freed-up symbol table entries are never re-entered on the free
lists -- a debugging measure.
* :% is given a bad type in combined mode. To be investigated.
|
|
|
|
|
| |
Further cleanups of connect.h. Also, zap the Args macro. We really
don't need to support K&R C any more.
|
|
|
|
| |
Update .c files to reflect reorganisation of .h files in this directory.
|
|
|
|
|
|
|
|
|
| |
Changing name of linkPreludeNames to linkPrimitiveNames (cause that
is what it does).
Adding a Hugs extension "import privileged". This will allow us
to remove the many exports from the prelude of the primitive functions
and types, but still allow us to write libraries that use it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Major improvements in interface processing, and minor supporting
improvements to CT-storage management.
* Make the iface parser return the complete interface as a single
tree, which is processed later. Added abs syntax tags
I_INTERFACE .. I_VALUE to support this.
* Add tagged ("z") 2,3,4,5 tuples. Because they are tagged, they can't
be confused with lists, etc. Selectors zfst, zsnd ... zsel45, zsel55
check tags first. Iface processing uses z-tuples wherever it can.
* Add unap as a safe "inverse" of ap; it checks tags. So
unap(TAG1, ap(TAG2,cell)) == cell but only if TAG1==TAG2, else
assertion failure.
* In interface.c, clean up the startGHC*/endGHC* functions.
processInterfaces() is the top-level driver; it makes 4
passes over the supplied iface trees.
* Throw away iface symbols not mentioned in export lists.
* Use iface export lists to construct both the export and
eval environments for a module.
* Don't use Texts to refer to things. Instead use ConId and
VarId. Added ConId and VarId as synonyms for Cell in
storage.h.
* Add findSimpleInstance in storage.c.
|
|
|
|
| |
Only detect (# and #) as special tokens when parsing interface files.
|
|
|
|
|
|
|
|
|
|
| |
Add initial support for loading GHC Prelude (doesn't work yet):
* Command line flag, +c/-c to start up in combined or standalone mode.
In combined mode, looks for GHC's prelude in ghc/interpreter/GhcPrel
(pro tem).
* Parse unboxed tuple types and usage annotations in interface files.
|
|
|
|
| |
Make <readline/history.h> a requirement for use of libreadline.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make StgHugs use the same naming scheme as GHC does for class +
instance machinery.
Add machinery to do Z-encoding/decoding of names extracted from
interface files.
Make the ELF object loader work again. It seemed to have suffered
slight bitrot over the past couple of months. Fix various minor bugs.
Track a small change in interface file syntax.
Make Printer.c print tagged-unboxed stack sections in a decent way
now that Alastair-style stack tags have been abandoned.
|
|
|
|
| |
Change STDCALL to STDKALL to avoid conflict with a header file.
|
|
|
|
| |
Merging in the various changes between Sep99 Hugs and Nov99 Hugs.
|
|
|
|
|
| |
Decide to use or not use readline depending on the top-level
(fptools) configure machinery.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add foreign import/export implementations for x86 stdcall convention.
Make parser notice calling conventions on f-i and f-x declarations,
check they are supported on the platform Hugs is compiled on. Pass
them all the way through the code generator to the interpreter.
Allow f-i/f-x decls to omit the calling convention, in which case
ccall is used. Remove calling convention from all such decls
in the Prelude so it will work on any platform.
|
|
|
|
|
|
|
|
| |
Adding diffs between Hugs98 (Jan99) and Hugs98 (Sep99)
manually to STG Hugs.
These are the changes to input.c, with minor tweeks to
connect.h and parser.y to make this work.
|
|
|
|
| |
Updating all copyright messages to the same as Hugs98.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added basic support for foreign export dynamic.
Many aspects of it are still broken:
* Only supports x86-linux.
* The range of allowable types is small: Char Int Float Double
Addr and Word.
* Adjustor thunks are never freed.
* Returning Doubles or Floats doesn't work at all.
I expect to fix some of these shortly. foreign import also
needs redoing, so it can accept any number of arguments of
any type.
Also:
* Fixed setRtsFlags in Evaluator.c to make it endian-independent.
* Fixed raisePrim in Evaluator.c so things like division by zero,
array index errors, etc, throw an exception instead of
terminating StgHugs. raisePrim is renamed makeErrorCall.
|
|
|
|
|
|
|
| |
Many changes needed to support loading of GHC compiled code. The main
changes are to parser.y and interface.c to load .hi files and create
appropriate symbol table entries. Also, interface.c has the
beginnings of and ELF loader/linker in it.
|
|
|
|
|
|
|
|
|
| |
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).
|
|
|
|
|
| |
Mods to make STG-hugs able to compile and run small examples. This
commit also includes proper implementations of seq, raise and catch.
|
|
|
|
|
| |
Preliminary results of the merge of STG hugs and 990121. These files
will compile and link, but don't work yet.
|
|
Move 4.01 onto the main trunk.
|