1. 30 Oct, 2012 1 commit
  2. 21 Aug, 2012 1 commit
  3. 16 Jul, 2012 1 commit
  4. 04 Nov, 2011 1 commit
  5. 25 Aug, 2011 1 commit
  6. 16 Jul, 2011 1 commit
  7. 15 Jul, 2011 1 commit
  8. 05 Jul, 2011 1 commit
    • batterseapower's avatar
      Refactoring: use a structured CmmStatics type rather than [CmmStatic] · 54843b5b
      batterseapower authored
      I observed that the [CmmStatics] within CmmData uses the list in a very stylised way.
      The first item in the list is almost invariably a CmmDataLabel. Many parts of the
      compiler pattern match on this list and fail if this is not true.
      
      This patch makes the invariant explicit by introducing a structured type CmmStatics
      that holds the label and the list of remaining [CmmStatic].
      
      There is one wrinkle: the x86 backend sometimes wants to output an alignment directive just
      before the label. However, this can be easily fixed up by parameterising the native codegen
      over the type of CmmStatics (though the GenCmmTop parameterisation) and using a pair
      (Alignment, CmmStatics) there instead.
      
      As a result, I think we will be able to remove CmmAlign and CmmDataLabel from the CmmStatic
      data type, thus nuking a lot of code and failing pattern matches. This change will come as part
      of my next patch.
      54843b5b
  9. 24 Jan, 2011 1 commit
    • Simon Marlow's avatar
      Merge in new code generator branch. · 889c084e
      Simon Marlow authored
      This changes the new code generator to make use of the Hoopl package
      for dataflow analysis.  Hoopl is a new boot package, and is maintained
      in a separate upstream git repository (as usual, GHC has its own
      lagging darcs mirror in http://darcs.haskell.org/packages/hoopl).
      
      During this merge I squashed recent history into one patch.  I tried
      to rebase, but the history had some internal conflicts of its own
      which made rebase extremely confusing, so I gave up. The history I
      squashed was:
      
        - Update new codegen to work with latest Hoopl
        - Add some notes on new code gen to cmm-notes
        - Enable Hoopl lag package.
        - Add SPJ note to cmm-notes
        - Improve GC calls on new code generator.
      
      Work in this branch was done by:
         - Milan Straka <fox@ucw.cz>
         - John Dias <dias@cs.tufts.edu>
         - David Terei <davidterei@gmail.com>
      
      Edward Z. Yang <ezyang@mit.edu> merged in further changes from GHC HEAD
      and fixed a few bugs.
      889c084e
  10. 13 Oct, 2010 2 commits
  11. 17 Sep, 2009 1 commit
    • Ben.Lippmeier@anu.edu.au's avatar
      NCG: Refactor representation of code with liveness info · e17cf7ff
      Ben.Lippmeier@anu.edu.au authored
       * I've pushed the SPILL and RELOAD instrs down into the
         LiveInstr type to make them easier to work with. 
      
       * When the graph allocator does a spill cycle it now just
         re-annotates the LiveCmmTops instead of converting them 
         to NatCmmTops and back. 
      
       * This saves working out the SCCS again, and avoids rewriting
         the SPILL and RELOAD meta instructions into real machine
         instructions.
      e17cf7ff
  12. 15 Oct, 2009 1 commit
    • simonpj@microsoft.com's avatar
      Fix Trac #959: a long-standing bug in instantiating otherwise-unbound type variables · 388e3356
      simonpj@microsoft.com authored
          
         DO NOT MERGE TO GHC 6.12 branch
         (Reason: interface file format change.)
      
      The typechecker needs to instantiate otherwise-unconstraint type variables to
      an appropriately-kinded constant type, but we didn't have a supply of 
      arbitrarily-kinded tycons for this purpose.  Now we do.
      
      The details are described in Note [Any types] in TysPrim.  The
      fundamental change is that there is a new sort of TyCon, namely
      AnyTyCon, defined in TyCon.
      
      Ter's a small change to interface-file binary format, because the new
      AnyTyCons have to be serialised.
      
      I tided up the handling of uniques a bit too, so that mkUnique is not
      exported, so that we can see all the different name spaces in one module.
      388e3356
  13. 07 Jul, 2009 1 commit
  14. 18 May, 2009 1 commit
    • Ben.Lippmeier@anu.edu.au's avatar
      Split Reg into vreg/hreg and add register pairs · f9288086
      Ben.Lippmeier@anu.edu.au authored
       * The old Reg type is now split into VirtualReg and RealReg.
       * For the graph coloring allocator, the type of the register graph
         is now (Graph VirtualReg RegClass RealReg), which shows that it colors
         in nodes representing virtual regs with colors representing real regs.
         (as was intended)  
       * RealReg contains two contructors, RealRegSingle and RealRegPair,
         where RealRegPair is used to represent a SPARC double reg 
         constructed from two single precision FP regs. 
       * On SPARC we can now allocate double regs into an arbitrary register
         pair, instead of reserving some reg ranges to only hold float/double values. 
      f9288086
  15. 15 Feb, 2009 1 commit
    • Ben.Lippmeier@anu.edu.au's avatar
      NCG: Split up the native code generator into arch specific modules · b04a210e
      Ben.Lippmeier@anu.edu.au authored
        - nativeGen/Instruction defines a type class for a generic
          instruction set. Each of the instruction sets we have, 
          X86, PPC and SPARC are instances of it.
        
        - The register alloctors use this type class when they need
          info about a certain register or instruction, such as
          regUsage, mkSpillInstr, mkJumpInstr, patchRegs..
        
        - nativeGen/Platform defines some data types enumerating
          the architectures and operating systems supported by the 
          native code generator.
        
        - DynFlags now keeps track of the current build platform, and 
          the PositionIndependentCode module uses this to decide what
          to do instead of relying of #ifdefs.
        
        - It's not totally retargetable yet. Some info info about the
          build target is still hardwired, but I've tried to contain
          most of it to a single module, TargetRegs.
        
        - Moved the SPILL and RELOAD instructions into LiveInstr.
        
        - Reg and RegClass now have their own modules, and are shared
          across all architectures.
      b04a210e
  16. 04 Feb, 2009 2 commits
  17. 03 Feb, 2009 1 commit
  18. 21 Jul, 2008 1 commit
  19. 29 May, 2008 1 commit
    • dias@eecs.harvard.edu's avatar
      Replacing copyins and copyouts with data-movement instructions · 0d80489c
      dias@eecs.harvard.edu authored
      o Moved BlockId stuff to a new file to avoid module recursion
      o Defined stack areas for parameter-passing locations and spill slots
      o Part way through replacing copy in and copy out nodes
        - added movement instructions for stack pointer
        - added movement instructions for call and return parameters
          (but not with the proper calling conventions)
      o Inserting spills and reloads for proc points is now procpoint-aware
        (it was relying on the presence of a CopyIn node as a proxy for
         procpoint knowledge)
      o Changed ZipDataflow to expect AGraphs (instead of being polymorphic in
         the type of graph)
      0d80489c
  20. 21 Sep, 2007 1 commit
  21. 14 Sep, 2007 2 commits
  22. 12 Sep, 2007 2 commits
  23. 11 Sep, 2007 2 commits
  24. 05 Sep, 2007 1 commit
  25. 04 Sep, 2007 1 commit
  26. 03 Sep, 2007 1 commit
  27. 01 Sep, 2007 1 commit
  28. 28 Aug, 2007 1 commit
  29. 24 Aug, 2007 1 commit