1. 19 Apr, 2013 1 commit
  2. 30 Oct, 2012 1 commit
  3. 25 Oct, 2012 2 commits
  4. 23 Oct, 2012 1 commit
  5. 22 Oct, 2012 1 commit
    • Simon Marlow's avatar
      Foreign calls can clobber heap & stack memory too · 412af8c2
      Simon Marlow authored
      We were making an aggressive assumption that foreign calls cannot
      clobber heap or stack memory, which for the majority of foreign calls
      is true, but we violate the assumption in the implementation of
      primops in the RTS.  This was causing crashes in some STM tests.
      412af8c2
  6. 08 Oct, 2012 1 commit
    • Simon Marlow's avatar
      Produce new-style Cmm from the Cmm parser · a7c0387d
      Simon Marlow authored
      The main change here is that the Cmm parser now allows high-level cmm
      code with argument-passing and function calls.  For example:
      
      foo ( gcptr a, bits32 b )
      {
        if (b > 0) {
           // we can make tail calls passing arguments:
           jump stg_ap_0_fast(a);
        }
      
        return (x,y);
      }
      
      More details on the new cmm syntax are in Note [Syntax of .cmm files]
      in CmmParse.y.
      
      The old syntax is still more-or-less supported for those occasional
      code fragments that really need to explicitly manipulate the stack.
      However there are a couple of differences: it is now obligatory to
      give a list of live GlobalRegs on every jump, e.g.
      
        jump %ENTRY_CODE(Sp(0)) [R1];
      
      Again, more details in Note [Syntax of .cmm files].
      
      I have rewritten most of the .cmm files in the RTS into the new
      syntax, except for AutoApply.cmm which is generated by the genapply
      program: this file could be generated in the new syntax instead and
      would probably be better off for it, but I ran out of enthusiasm.
      
      Some other changes in this batch:
      
       - The PrimOp calling convention is gone, primops now use the ordinary
         NativeNodeCall convention.  This means that primops and "foreign
         import prim" code must be written in high-level cmm, but they can
         now take more than 10 arguments.
      
       - CmmSink now does constant-folding (should fix #7219)
      
       - .cmm files now go through the cmmPipeline, and as a result we
         generate better code in many cases.  All the object files generated
         for the RTS .cmm files are now smaller.  Performance should be
         better too, but I haven't measured it yet.
      
       - RET_DYN frames are removed from the RTS, lots of code goes away
      
       - we now have some more canned GC points to cover unboxed-tuples with
         2-4 pointers, which will reduce code size a little.
      a7c0387d
  7. 05 Oct, 2012 1 commit
  8. 24 Sep, 2012 2 commits
  9. 12 Sep, 2012 1 commit
    • ian@well-typed.com's avatar
      Pass DynFlags down to bWord · f611396a
      ian@well-typed.com authored
      I've switched to passing DynFlags rather than Platform, as (a) it's
      simpler to not have to extract targetPlatform in so many places, and
      (b) it may be useful to have DynFlags around in future.
      f611396a
  10. 07 Aug, 2012 1 commit
    • ian@well-typed.com's avatar
      Define callerSaves for all platforms · 46b5c197
      ian@well-typed.com authored
      This means that we now generate the same code whatever platform we are
      on, which should help avoid changes on one platform breaking the build
      on another.
      
      It's also another step towards full cross-compilation.
      46b5c197
  11. 06 Aug, 2012 3 commits
  12. 02 Aug, 2012 5 commits
  13. 30 Jul, 2012 4 commits
  14. 17 Jul, 2012 2 commits