1. 31 Jul, 2008 2 commits
  2. 20 Jul, 2008 1 commit
  3. 07 Jul, 2008 1 commit
  4. 04 May, 2008 1 commit
  5. 12 Apr, 2008 1 commit
  6. 29 Mar, 2008 3 commits
  7. 06 Mar, 2008 1 commit
    • simonpj@microsoft.com's avatar
      Don't expose the unfolding of dictionary selectors without -O · 74d5597e
      simonpj@microsoft.com authored
      When compiling without -O we were getting code like this
      
      	f x = case GHC.Base.$f20 of
      		  :DEq eq neq -> eq x x
      
      But because of the -O the $f20 dictionary is not available, so exposing
      the dictionary selector was useless.  Yet it makes the code bigger!
      Better to get
      	f x = GHC.Base.== GHC.Bsae.$f20 x x
      
      This patch suppresses the implicit unfolding for dictionary selectors
      when compiling without -O.  We could do the same for other implicit
      Ids, but this will do for now.
      
      There should be no effect when compiling with -O.  Programs should
      be smaller without -O and may run a tiny bit slower.
      
      74d5597e
  8. 07 Feb, 2008 1 commit
    • Ian Lynagh's avatar
      Convert more UniqFM's back to LazyUniqFM's · d51f42f6
      Ian Lynagh authored
      These fix these failures:
         break008(ghci)
         break009(ghci)
         break026(ghci)
         ghci.prog009(ghci)
         ghci025(ghci)
         print007(ghci)
         prog001(ghci)
         prog002(ghci)
         prog003(ghci)
      at least some of which have this symptom:
          Exception: expectJust prune
      d51f42f6
  9. 17 Jan, 2008 1 commit
  10. 14 Dec, 2007 1 commit
  11. 05 Sep, 2007 1 commit
    • Simon Marlow's avatar
      FIX #1650: ".boot modules interact badly with the ghci debugger" · e2782137
      Simon Marlow authored
      In fact hs-boot files had nothing to do with it: the problem was that
      GHCi would forget the breakpoint information for a module that had
      been reloaded but not recompiled.  It's amazing that we never noticed
      this before.
      
      The ModBreaks were in the ModDetails, which was the wrong place.  When
      we avoid recompiling a module, ModDetails is regenerated from ModIface
      by typecheckIface, and at that point it has no idea what the ModBreaks
      should be, so typecheckIface made it empty.  The right place for the
      ModBreaks to go is with the Linkable, which is retained when
      compilation is avoided.  So now I've placed the ModBreaks in with the
      CompiledByteCode, which also makes it clear that only byte-code
      modules have breakpoints.
      
      This fixes break022/break023
      e2782137
  12. 04 Sep, 2007 1 commit
  13. 03 Sep, 2007 1 commit
  14. 01 Sep, 2007 1 commit
  15. 03 Aug, 2007 2 commits
  16. 01 Aug, 2007 1 commit
    • simonpj@microsoft.com's avatar
      Fix a knot-tying bug with ghc --make · e5896a10
      simonpj@microsoft.com authored
      This bug showed up when I touched Data.Generics.Schemes, and then said
      	make build.library.base
      This compiles the base library with --make, and I got an assertion failure
      in TcIface.  The explanation is in Note [Tying the knot] in TcIface.
      
      As well as fixing the bug, I also impoved the assertion message.
      
      This might fix or improve other knot-tying problems with --make
      e5896a10
  17. 16 Jul, 2007 1 commit
  18. 11 Jul, 2007 1 commit
  19. 06 Jun, 2007 1 commit
    • simonpj@microsoft.com's avatar
      Remove unnecessary free-variables from renamer · 3c4a732b
      simonpj@microsoft.com authored
      The renamer used to be responsible for making sure that all interfaces
      with instance decls (other than orphans) were loaded.  But TH makes that
      impossible, so the typechecker does it, via checkWiredInTyCon.
      
      This patch simply removes redundant additions to the free-variable set
      in the renamer, which were there, I believe, solely to ensure that the 
      instances came in.  Removing them should change nothing, but it's a 
      useful clean up.
      3c4a732b
  20. 22 May, 2007 1 commit
  21. 15 May, 2007 1 commit
  22. 11 May, 2007 2 commits
  23. 08 May, 2007 1 commit
    • chak@cse.unsw.edu.au.'s avatar
      Improved VectInfo · 098f818b
      chak@cse.unsw.edu.au. authored
      - We need to keep pairs of (f, f_CC) in VectInfo as it is difficult
        to obtain Names from OccNames (of imported modules) in Core passes.
      - There is a choice of keeping Names or Vars in VectInfo.  We go with Vars
        for now; mainly to avoid converting between Names and Vars repeatedly for
        the same VectInfo in other than one-shot mode.
      
        Again goes to the HEAD straight away to avoid conflicts down the road.
      098f818b
  24. 07 May, 2007 1 commit
    • chak@cse.unsw.edu.au.'s avatar
      Add VectInfo to HPT · e5f78a4a
      chak@cse.unsw.edu.au. authored
        I am putting this patch (as the previous VectInfo patch) straight away
        into the head to avoid the kind of merging disaster we had with the FC
        branch.  The patch does not interfere with any other functionality and
        hence should cause no harm in the head.
      e5f78a4a
  25. 25 Apr, 2007 2 commits
    • chak@cse.unsw.edu.au.'s avatar
      Generating synonym instance representation tycons · 13cd965d
      chak@cse.unsw.edu.au. authored
      - Type synonym instances are turned into representation synonym tycons
      - They are entered into the pool of family instances (FamInst environments)
        in the same way as data/newtype instances
      - Still missing is writing the parent tycon information into ifaces and 
        various well-formedness checks.
      13cd965d
    • simonpj@microsoft.com's avatar
      Retain inline-pragma information on unfoldings in interface files · d33c0b24
      simonpj@microsoft.com authored
      	WARNING: this patch changes interface-file formats slightly
      	 	 you will need to recompile your libraries
      
      Duncan Coutts wanted to export a function that has a NOINLNE pragma
      in a local let-defintion.  This works fine within a module, but was 
      not surviving across the interface-file serialisation.
      
      http://www.haskell.org/pipermail/glasgow-haskell-users/2007-March/012171.html
      
      Regardless of whether or not he's doing something sensible, it seems
      reasonable to try to retain local-binder IdInfo across interface files.
      This initial patch just retains inline-pragma info, on the grounds that
      other IdInfo can be re-inferred at the inline site.
      
      Interface files get a tiny bit bigger, but it seesm slight.
      
      d33c0b24
  26. 17 Apr, 2007 1 commit
    • Simon Marlow's avatar
      Re-working of the breakpoint support · cdce6477
      Simon Marlow authored
      This is the result of Bernie Pope's internship work at MSR Cambridge,
      with some subsequent improvements by me.  The main plan was to
      
       (a) Reduce the overhead for breakpoints, so we could enable 
           the feature by default without incurrent a significant penalty
       (b) Scatter more breakpoint sites throughout the code
      
      Currently we can set a breakpoint on almost any subexpression, and the
      overhead is around 1.5x slower than normal GHCi.  I hope to be able to
      get this down further and/or allow breakpoints to be turned off.
      
      This patch also fixes up :print following the recent changes to
      constructor info tables.  (most of the :print tests now pass)
      
      We now support single-stepping, which just enables all breakpoints.
      
        :step <expr>     executes <expr> with single-stepping turned on
        :step            single-steps from the current breakpoint
      
      The mechanism is quite different to the previous implementation.  We
      share code with the HPC (haskell program coverage) implementation now.
      The coverage pass annotates source code with "tick" locations which
      are tracked by the coverage tool.  In GHCi, each "tick" becomes a
      potential breakpoint location.
      
      Previously breakpoints were compiled into code that magically invoked
      a nested instance of GHCi.  Now, a breakpoint causes the current
      thread to block and control is returned to GHCi.
      
      See the wiki page for more details and the current ToDo list:
      
        http://hackage.haskell.org/trac/ghc/wiki/NewGhciDebugger
      cdce6477
  27. 30 Mar, 2007 1 commit
    • simonpj@microsoft.com's avatar
      The ru_local field of a CoreRule is False for implicit Ids · ec81fdde
      simonpj@microsoft.com authored
      	MERGE to 6.6.1
      
      For class-ops, record selectors, data constructors, we want the ru_local
      field of the Rule to be False.  We do not attach the rule to the binding
      for the Id, because there simply isn't a binding until the code gen stage.
      
      (NB: the ru_local field is different to the orphan-hood of the rule.)
      
      This fixes a bug that meant that RULES on class ops were never exported.
      ec81fdde
  28. 16 Mar, 2007 1 commit
    • simonpj@microsoft.com's avatar
      Refactor TcRnDriver, and check exports on hi-boot files · ec0b8599
      simonpj@microsoft.com authored
      This patch refactors TcRnDriver to make the top-level structure
      easier to understand.  
      
      The change was driven by Trac #924, and this patch fixes that bug.
      When comparing a module against its hs-boot file, we must ensure that
      the module exports everything that the hs-boot file exports.
      ec0b8599
  29. 23 Feb, 2007 1 commit
  30. 21 Feb, 2007 1 commit
    • simonpj@microsoft.com's avatar
      Deal more correctly with orphan instances · eb2bf7ad
      simonpj@microsoft.com authored
      Conal Eliott (Trac #1145) exposed a nasty flaw in the way in which
      orphan instances are computed, when there are functional dependencies
      in the class.  It took me some time to figure out what was going on,
      and led to more refactoring.
      
      Briefly:
      
      * Elaborate comments about orphan-hood and versioning added to IfaceSyn
      * The is_orph field vanishes from InstEnv.Instance
      * Similarly ru_orph vanishes from CoreSyn.CoreRule
      * Orphan-hood is computed in MkIface.instanceToIfaceInst, and
      	MkIface.coreRuleToIfaceRule
      
      Elsewhere just tidying up.
      eb2bf7ad
  31. 11 Jan, 2007 1 commit
  32. 10 Dec, 2006 1 commit
    • mnislaih's avatar
      Breakpoint code instrumentation · 37610105
      mnislaih authored
      Instrumentation gets activated by the '-fdebugging' dynflag.
      
      All the instrumentation occurrs in the desugarer; it consists of inserting 'breakpoint' combinators at a number of places in the AST, namely: 
       - Binding sites
       - Do-notation statements 
      These 'breakpoint' combinators will later be further desugared (at DsExpr) into ___Jump functions.
      For more info about this and all the ghci.debugger see the page at the GHC wiki:
      
      http://hackage.haskell.org/trac/ghc/wiki/GhciDebugger
      37610105
  33. 29 Nov, 2006 1 commit
    • andy@galois.com's avatar
      TickBox representation change · 8100cd43
      andy@galois.com authored
      This changes the internal representation of TickBoxes,
      from
              Note (TickBox "module" n)  <expr>
      into
      
              case tick<module,n> of
                _ -> <expr>
      
      tick has type :: #State #World, when the module and tick numbe
      are stored inside IdInfo.
      
      Binary tick boxes change from
      
               Note (BinaryTickBox "module" t f) <expr>
      
      into
      
                btick<module,t,f> <expr>
      
      btick has type :: Bool -> Bool, with the module and tick number
      stored inside IdInfo.
      8100cd43
  34. 24 Oct, 2006 1 commit
    • andy@galois.com's avatar
      Haskell Program Coverage · d5934bbb
      andy@galois.com authored
      This large checkin is the new ghc version of Haskell
      Program Coverage, an expression-level coverage tool for Haskell.
      
      Parts:
      
       - Hpc.[ch] - small runtime support for Hpc; reading/writing *.tix files.
       - Coverage.lhs - Annotates the HsSyn with coverage tickboxes.
        - New Note's in Core,
            - TickBox      -- ticked on entry to sub-expression
            - BinaryTickBox  -- ticked on exit to sub-expression, depending
      	       	     -- on the boolean result.
      
        - New Stg level TickBox (no BinaryTickBoxes, though) 
      
      You can run the coverage tool with -fhpc at compile time. 
      Main must be compiled with -fhpc. 
      				      
      d5934bbb