- 22 Feb, 2003 1 commit
-
-
sof authored
Clean up code&interfaces that deals with timers and asynchrony: - Timer.{c,h} now defines the platform-independent interface to the timing services needed by the RTS. Itimer.{c,h} + win32/Ticker.{c,h} defines the OS-specific services that creates/destroys a timer. - For win32 plats, drop the long-standing use of the 'multimedia' API timers and implement the ticking service ourselves. Simpler and more flexible. - Select.c is now solely for platforms that use select() to handle non-blocking I/O & thread delays. win32/AwaitEvent.c provides the same API on the Win32 side. - support threadDelay on win32 platforms via worker threads. Not yet compiled up on non-win32 platforms; will do once checked in.
-
- 21 Feb, 2003 15 commits
-
-
simonpj authored
Typos
-
simonpj authored
Fix buglets in new unused-binding story
-
simonpj authored
Use old-style foreign import for bkwd compatibility
-
simonpj authored
------------------------------------- Improve the "unused binding" warnings ------------------------------------- We've had a succession of hacks for reporting warnings for unused bindings. Consider module M( f ) where f x = x g x = g x + h x h x = x Here, g mentions itself and h, but is not itself mentioned. So really both g and h are dead code. We've been getting this wrong for ages, and every hack so far has failed on some simple programs. This commit does a much better job. The renamer applied to a bunch of bindings returns a NameSet.DefUses, which is a dependency-ordered lists of def/use pairs. It's documented in NameSet. Given this, we can work out precisely what is not used, in a nice tidy way. It's less convenient in the case of type and class declarations, because the strongly-connected-component analysis can span module boundaries. So things are pretty much as they were for these. As usual, there was a lot of chuffing around tidying things up. I havn't tested it at all thoroughly yet. Various unrelated import-decl-pruning has been done too.
-
simonpj authored
Import pruning
-
simonpj authored
Import pruning, use mingw32_TARGET not HOST, use old-style foreign import (for 4.08 compat)
-
simonpj authored
Import pruning
-
simonpj authored
More tidy up
-
simonpj authored
Small fix to a TH bug; this one concerning the constraint-gathering mechanism
-
simonpj authored
Another typo; sigh
-
simonpj authored
Typo
-
simonpj authored
Debugging hook jiggling
-
simonpj authored
Fix a type-error in desugaring TH code
-
sof authored
Asynchronous / non-blocking I/O for Win32 platforms. This commit introduces a Concurrent Haskell friendly view of I/O on Win32 platforms. Through the use of a pool of worker Win32 threads, CH threads may issue asynchronous I/O requests without blocking the progress of other CH threads. The issuing CH thread is blocked until the request has been serviced though. GHC.Conc exports the primops that take care of issuing the asynchronous I/O requests, which the IO implementation now takes advantage of. By default, all Handles are non-blocking/asynchronous, but should performance become an issue, having a per-Handle flag for turning off non-blocking could easily be imagined&introduced. [Incidentally, this thread pool-based implementation could easily be extended to also allow Haskell code to delegate the execution of arbitrary pieces of (potentially blocking) external code to another OS thread. Given how relatively gnarly the locking story has turned out to be with the 'threaded' RTS, that may not be such a bad idea.]
-
sof authored
deja vu all over again
-
- 20 Feb, 2003 18 commits
-
-
panne authored
* Nuked unused --with-glut-api and --with-glut-xlib arguments * Only check for OpenGL headers and libs when --enable-hopengl is given
-
simonpj authored
typo
-
simonpj authored
------------------------------------- Add Core Notes and the {-# CORE #-} pragma ------------------------------------- This is an idea of Hal Daume's. The key point is that Notes in Core are augmented thus: data Note = SCC CostCentre | ... | CoreNote String -- NEW These notes can be injected via a Haskell-source pragma: f x = ({-# CORE "foo" #-} show) ({-# CORE "bar" #-} x) This wraps a (Note (CoreNote "foo")) around the 'show' variable, and a similar note around the argument to 'show'. These notes are basically ignored by GHC, but are emitted into External Core, where they may convey useful information. Exactly how code involving these notes is munged by the simplifier isn't very well defined. We'll see how it pans out. Meanwhile the impact on the rest of the compiler is minimal.
-
simonpj authored
Document {-# CORE #-} pragma (thanks to Hal Daume)
-
simonpj authored
Import pruning
-
simonpj authored
Add comments
-
simonpj authored
Comments and imports only
-
simonmar authored
closureSatisfiesConstraints: check whether the retainer set is valid before attempting to match it against a constraint. It might not be valid if the object is an ex-weak-pointer which was finalized after the last GC. MERGE TO STABLE
-
simonpj authored
------------------------------------- Complete an earlier TH commit ------------------------------------- In this earlier commit: 3. Ensure that a declaration quotation [d| ... |] does not have a permanent effect on the instance environment. (A TH fix.) I had forgotten to do a stage2 compile. This commit just completes the earlier work. I moved some code from TcExpr (long) to TcSplice (shorter) which had the happy effect of bringing related code together.
-
simonpj authored
------------------------------------- Generate correct dependencies when reading External Core ------------------------------------- We have to be more careful than I realised when doing strongly-connected component analysis of type/class decls when reading External Core. Here's the relevant new comment: -- Building edges for SCC analysis -- -- When building the edges, we treat the 'main name' of the declaration as the -- key for the node, but when dealing with External Core we may come across -- references to one of the implicit names for the declaration. For example: -- class Eq a where .... -- data :TSig a = :TSig (:TEq a) .... -- The first decl is sucked in from an interface file; the second -- is in an External Core file, generated from a class decl for Sig. -- We have to recognise that the reference to :TEq represents a -- dependency on the class Eq declaration, else the SCC stuff won't work right. -- -- This complication can only happen when consuming an External Core file -- -- Solution: keep an "EdgeMap" (bad name) that maps :TEq -> Eq. -- Don't worry about data constructors, because we're only building -- SCCs for type and class declarations here. So the tiresome mapping -- is need only to map [class tycon -> class]
-
simonpj authored
Part 2 of fix :i in InteractiveUI
-
simonpj authored
Comments only
-
simonpj authored
Another datacon-naming wibble
-
simonpj authored
Fix :i in InteractiveUI
-
simonpj authored
Eliminate brain-dead outputC pattern-match failure
-
simonpj authored
Eliminate bogus string-literal duplication
-
simonpj authored
Compile binary stuff with -O always
-
simonmar authored
Add -fvia-C to utils/Panic_HC_OPTS, and remove it from main/Main_HC_OPTS.
-
- 19 Feb, 2003 6 commits
-
-
sof authored
odir-ify prelude/PrimOp.o dependency
-
simonpj authored
Document phase control
-
simonpj authored
------------------------------------- Two minor wibbles ------------------------------------- 1. Make the generic toT/fromT Ids for "generic derived classes" into proper ImplicitIds, with their own GlobalIdDetails. This makes it easier to identify them. (The lack of this showed up as a bug when I made an apparently-innocuous other change.) 2. Distinguish ClassOpIds from RecordSelIds in their GlobalIdDetails. They are treated differently here and there, so I made this change as part of (1) 3. Ensure that a declaration quotation [d| ... |] does not have a permanent effect on the instance environment. (A TH fix.)
-
simonpj authored
Wibbles to the new datacon story; fixes ds002
-
simonmar authored
Add note to description of -no-hs-main: it forces linking in --make mode too.
-
simonmar authored
If -no-hs-main is specified in --make mode, attempt linking even when there's no Main module. Fixes bug #686620 MERGE TO STABLE
-