1. 30 Apr, 2001 1 commit
  2. 26 Apr, 2001 3 commits
  3. 21 Apr, 2001 1 commit
  4. 20 Apr, 2001 1 commit
  5. 18 Apr, 2001 1 commit
  6. 05 Apr, 2001 1 commit
  7. 03 Apr, 2001 1 commit
  8. 29 Mar, 2001 1 commit
  9. 28 Mar, 2001 2 commits
    • simonmar's avatar
      [project @ 2001-03-28 16:51:02 by simonmar] · da25d580
      simonmar authored
      Cleaning up error reporting, 2nd attempt.
      
        - The UserError name is already bagged by Exception (for
          userErrors).  So we use ProgramError instead, which is
          more appropriate.
      
        - some previously UserErrors are now CmdLineErrors.  GHCi
          catches CmdLineErrors and prints them without the "ghc: "
          prefix.
      da25d580
    • simonmar's avatar
      [project @ 2001-03-28 11:01:19 by simonmar] · f4eba96b
      simonmar authored
      Clean up GHC's error reporting.
      
        - the GhcException type has some more constructors: CmdLineError,
          UserError, and InstallationError.  OtherError has gone.
      
        - most error messages should begin with "<location>:".  When the
          error is on the command-line or in GHC itself, <location> is
          "ghc", for consistency with std Unix semantics.
      
        - GHCi no longer prints a superfluous "ghc: " before certain error
          messages.
      f4eba96b
  10. 27 Mar, 2001 4 commits
  11. 26 Mar, 2001 1 commit
    • simonmar's avatar
      [project @ 2001-03-26 12:28:15 by simonmar] · 7d6569fb
      simonmar authored
      Simplify the foreign-export stub processing.
      
        - DynFlags now has fields for the stub.h and stub.c filenames, for
          consistency with the normal hsc output file name.
      
        - codeOutput puts the stubs into these files rather than dreaming
          up new temporary names for them
      
        - now we don't have to move the stubs into the right place in
          DriverPipeline.
      
        - we do however have to inject the correct #includes into the stub.c
          file when it is generated: I'm now injecting the same includes as
          the .hc file gets plus "RtsAPI.h", which is probably more correct
          than the hacky hardcoded "Stg.h" we had before.
      7d6569fb
  12. 23 Mar, 2001 5 commits
  13. 22 Mar, 2001 1 commit
    • hwloidl's avatar
      [project @ 2001-03-22 03:51:08 by hwloidl] · 20fc2f0c
      hwloidl authored
      -*- outline -*-
      Time-stamp: <Thu Mar 22 2001 03:50:16 Stardate: [-30]6365.79 hwloidl>
      
      This commit covers changes in GHC to get GUM (way=mp) and GUM/GdH (way=md)
      working. It is a merge of my working version of GUM, based on GHC 4.06,
      with GHC 4.11. Almost all changes are in the RTS (see below).
      
      GUM is reasonably stable, we used the 4.06 version in large-ish programs for
      recent papers. Couple of things I want to change, but nothing urgent.
      GUM/GdH has just been merged and needs more testing. Hope to do that in the
      next weeks. It works in our working build but needs tweaking to run.
      GranSim doesn't work yet (*sigh*). Most of the code should be in, but needs
      more debugging.
      
      ToDo: I still want to make the following minor modifications before the release
      - Better wrapper skript for parallel execution [ghc/compiler/main]
      - Update parallel docu: started on it but it's minimal [ghc/docs/users_guide]
      - Clean up [nofib/parallel]: it's a real mess right now (*sigh*)
      - Update visualisation tools (minor things only IIRC) [ghc/utils/parallel]
      - Add a Klingon-English glossary
      
      * RTS:
      
      Almost all changes are restricted to ghc/rts/parallel and should not
      interfere with the rest. I only comment on changes outside the parallel
      dir:
      
      - Several changes in Schedule.c (scheduling loop; createThreads etc);
        should only affect parallel code
      - Added ghc/rts/hooks/ShutdownEachPEHook.c
      - ghc/rts/Linker.[ch]: GUM doesn't know about Stable Names (ifdefs)!!
      - StgMiscClosures.h: END_TSO_QUEUE etc now defined here (from StgMiscClosures.hc)
                           END_ECAF_LIST was missing a leading stg_
      - SchedAPI.h: taskStart now defined in here; it's only a wrapper around
                    scheduleThread now, but might use some init, shutdown later
      - RtsAPI.h: I have nuked the def of rts_evalNothing
      
      * Compiler:
      
      - ghc/compiler/main/DriverState.hs
        added PVM-ish flags to the parallel way
        added new ways for parallel ticky profiling and distributed exec
      
      - ghc/compiler/main/DriverPipeline.hs
        added a fct run_phase_MoveBinary which is called with way=mp after linking;
        it moves the bin file into a PVM dir and produces a wrapper script for
        parallel execution
        maybe cleaner to add a MoveBinary phase in DriverPhases.hs but this way
        it's less intrusive and MoveBinary makes probably only sense for mp anyway
      
      * Nofib:
      
      - nofib/spectral/Makefile, nofib/real/Makefile, ghc/tests/programs/Makefile:
        modified to skip some tests if HWL_NOFIB_HACK is set; only tmp to record
        which test prgs cause problems in my working build right now
      20fc2f0c
  14. 20 Mar, 2001 1 commit
  15. 19 Mar, 2001 2 commits
    • simonpj's avatar
      [project @ 2001-03-19 16:17:27 by simonpj] · 82d808ba
      simonpj authored
      -------------------------------
      PS to:	Improve orphan-module resolution
      	-------------------------------
      
      {This comment got missed out of the previous commit.}
      
      I also moved mkFinalIface from HscMain to MkIface, where it is much tidier.
      (This is related, because it's mkFinalIface that now sets mi_orphan.)
      82d808ba
    • simonpj's avatar
      [project @ 2001-03-19 16:13:22 by simonpj] · 17d765ce
      simonpj authored
      -------------------------------
      	Improve orphan-module resolution
      	-------------------------------
      
      Consider the following rule (and there are lots of these in
      the Prelude):
      
      	fromIntegral T = fromIntegral_T
      
      where T is defined in the module being compiled.
      
      is an orphan.  Of course it isn't, an declaring it an orphan would
      make the whole module an orphan module, which is bad.
      
      This commit arranges to determine orphan rules, and the orphan-hood
      of a module, much later than before.  (Before mi_orphan was set by
      the renamer, now it is set by MkIface.)
      17d765ce
  16. 15 Mar, 2001 2 commits
    • simonmar's avatar
      [project @ 2001-03-15 15:53:28 by simonmar] · 6c42179e
      simonmar authored
      Remove package management support into a separate tool (ghc-pkg), and
      don't duplicate the definition of PackageConfig.
      6c42179e
    • simonmar's avatar
      [project @ 2001-03-15 11:26:27 by simonmar] · cf2aab8a
      simonmar authored
      Do a better job of telling the user whether we're interpreting a
      module or using an existing object file.
      
      eg.
      
         Main> :load A
         Skipping  D                ( D.hs, D.o )
         Compiling C                ( C.hs, interpreted )
         Skipping  B                ( B.hs, B.o )
         Compiling Main             ( A.hs, interpreted )
         Main>
      cf2aab8a
  17. 14 Mar, 2001 2 commits
    • sewardj's avatar
      [project @ 2001-03-14 17:53:04 by sewardj] · a4932bcb
      sewardj authored
      Don't try and do `take' of a negative number in compMsg.  The Golden
      Lemon award for 2001 goes to <name_deleted_to_protect_the_guilty_party>.
      a4932bcb
    • simonpj's avatar
      [project @ 2001-03-14 15:26:00 by simonpj] · 506278ab
      simonpj authored
      -------------------------------------
      	Import more rules, and fix usage info
      	-------------------------------------
      
      1. A rule wasn't being slurped in that should have been.
      Reason: wordToWord32# was in the 'TypeEnv', because it's a primop,
      so the renamer thought it was already slurped in, which is true.
      But it forgot to use the TypeEnv as a source of gates when deciding
      which rules to pull in.  Result: a useful rule for the primop wasn't
      making it in.  Thanks to Marcin for isolating this one.
      
      2. RnIfaces.recordTypeEnvSlurp (was recordVSlurp) was blindly adding
      the name to the iVSlurp set, but the iVSlurp set is supposed to contain
      only "big" names (tycons, classes, and Ids that aren't data cons,
      class ops etc).  We need to get the big name from the thing.
      Mildly tiresomely, this means we have to keep the Class inside
      the TyCon derived from that class.   Hence updates to TyCon and Class.
      506278ab
  18. 13 Mar, 2001 4 commits
    • simonmar's avatar
      [project @ 2001-03-13 17:08:36 by simonmar] · e9866166
      simonmar authored
      fix up for GHCi
      e9866166
    • simonpj's avatar
      [project @ 2001-03-13 16:04:07 by simonpj] · ecb42f44
      simonpj authored
      Remove debug print
      ecb42f44
    • simonpj's avatar
      [project @ 2001-03-13 14:58:25 by simonpj] · 788faebb
      simonpj authored
      ----------------
      	Nuke ClassContext
      	----------------
      
      This commit tidies up a long-standing inconsistency in GHC.
      The context of a class or instance decl used to be restricted
      to predicates of the form
      	C t1 .. tn
      with
      	type ClassContext = [(Class,[Type])]
      
      but everywhere else in the compiler we used
      
      	type ThetaType = [PredType]
      where PredType can be any sort of constraint (= predicate).
      
      The inconsistency actually led to a crash, when compiling
      	class (?x::Int) => C a where {}
      
      I've tidied all this up by nuking ClassContext altogether, and using
      PredType throughout.  Lots of modified files, but all in
      more-or-less trivial ways.
      
      I've also added a check that the context of a class or instance
      decl doesn't include a non-inheritable predicate like (?x::Int).
      
      Other things
      
       * rename constructor 'Class' from type TypeRep.Pred to 'ClassP'
         (makes it easier to grep for)
      
       * rename constructor HsPClass  => HsClassP
      		      HsPIParam => HsIParam
      788faebb
    • simonmar's avatar
      [project @ 2001-03-13 12:50:29 by simonmar] · 10cbc75d
      simonmar authored
      Some rearrangements that Simon & I have been working on recently:
      
          - CoreSat is now CorePrep, and is a general "prepare-for-code-
            generation" pass.  It does cloning, saturation of constructors &
            primops, A-normal form, and a couple of other minor fiddlings.
      
          - CoreTidy no longer does cloning, and minor fiddlings.  It doesn't
            need the unique supply any more, so that's removed.
      
          - CoreToStg now collects CafInfo and the list of CafRefs for each
            binding.  The SRT pass is much simpler now.
      
          - IdInfo now has a CgInfo field for "code generator info".  It currently
            contains arity (the actual code gen arity which affects the calling
            convention as opposed to the ArityInfo which is a measure of how
            many arguments the Id can be applied to before it does any work), and
            CafInfo.
      
            Previously we overloaded the ArityInfo field to contain both
            codegen arity and simplifier arity.  Things are cleaner now.
      
          - CgInfo is collected by CoreToStg, and passed back into CoreTidy in
            a loop.  The compiler will complain rather than going into a black
            hole if the CgInfo is pulled on too early.
      
          - Worker info in an interface file now comes with arity info attached.
            Previously the main arity info was overloaded for this purpose, but
            it lead to a few hacks in the compiler, this tidies things up somewhat.
      
      Bottom line: we removed several fragilities, and tidied up a number of
      things.  Code size should be smaller, but we'll see...
      10cbc75d
  19. 12 Mar, 2001 3 commits
  20. 08 Mar, 2001 3 commits
    • qrczak's avatar
      [project @ 2001-03-08 18:05:31 by qrczak] · 0171137c
      qrczak authored
      s/setIdGlobalDetails/sedGlobalIdDetails/, and import it.
      0171137c
    • simonpj's avatar
      [project @ 2001-03-08 12:07:38 by simonpj] · 51a571c0
      simonpj authored
      --------------------
      	A major hygiene pass
      	--------------------
      
      1. The main change here is to
      
      	Move what was the "IdFlavour" out of IdInfo,
      	and into the varDetails field of a Var
      
         It was a mess before, because the flavour was a permanent attribute
         of an Id, whereas the rest of the IdInfo was ephemeral.  It's
         all much tidier now.
      
         Main places to look:
      
      	   Var.lhs	Defn of VarDetails
      	   IdInfo.lhs	Defn of GlobalIdDetails
      
         The main remaining infelicity is that SpecPragmaIds are right down
         in Var.lhs, which seems unduly built-in for such an ephemeral thing.
         But that is no worse than before.
      
      
      2. Tidy up the HscMain story a little.  Move mkModDetails from MkIface
         into CoreTidy (where it belongs more nicely)
      
         This was partly forced by (1) above, because I didn't want to make
         DictFun Ids into a separate kind of Id (which is how it was before).
         Not having them separate means we have to keep a list of them right
         through, rather than pull them out of the bindings at the end.
      
      3. Add NameEnv as a separate module (to join NameSet).
      
      4. Remove unnecessary {-# SOURCE #-} imports from FieldLabel.
      51a571c0
    • simonmar's avatar
      [project @ 2001-03-08 11:44:16 by simonmar] · 41d0a61d
      simonmar authored
      remove cyclic dependency
      41d0a61d