Changes between Version 17 and Version 18 of Commentary/Compiler/CmmType


Ignore:
Timestamp:
Oct 20, 2009 10:40:54 PM (6 years ago)
Author:
dmp
Comment:

fix broken link

Legend:

Unmodified
Added
Removed
Modified
  • Commentary/Compiler/CmmType

    v17 v18  
    322322`GlobalRegs` are a very special case in Cmm, partly because they must conform to the STG register convention and the target C calling convention.  That the Cmm parser recognises `R1` and `F3` as `GlobalRegs` is only the first step.  The main files to look at for more information on this delicate topic are:
    323323 * [[GhcFile(compiler/codeGen/CgCallConv.hs)]] (the section on "Register assignment")
    324  * [[GhcFile(includes/Regs.h)]] (defining STG registers)
    325  * [[GhcFile(includes/MachRegs.h)]] (target-specific mapping of machine registers for ''registerised'' builds of GHC)
     324 * [[GhcFile(includes/stg/Regs.h)]] (defining STG registers)
     325 * [[GhcFile(includes/stg/MachRegs.h)]] (target-specific mapping of machine registers for ''registerised'' builds of GHC)
    326326 * [[GhcFile(rts/PrimOps.cmm)]] (examples of `GlobalReg` register usage for out-of-line primops)
    327327All arguments to out-of-line !PrimOps in [[GhcFile(rts/PrimOps.cmm)]] are STG registers.
     
    626626This is essentially a custom-coded version of the GNU Assembler (`as`) `.machine` directive, which is essentially the same as passing the `-arch [cpu_type]` option to `as`.
    627627
    628 Cmm does not support the `target` directive.  This is partly due GHC generally lacking cross-compiler capabilities.  Should GHC move toward adding cross-compilation capabilities, the `target` might not be a bad thing to add.  Target architecture parameters are currently handled through the [wiki:Building/BuildSystem Build System], which partly sets such architectural parameters through [[GhcFile(includes/mkDerivedConstants.c)]] and [[GhcFile(includes/ghcconfig.h)]].
     628Cmm does not support the `target` directive.  This is partly due GHC generally lacking cross-compiler capabilities.  Should GHC move toward adding cross-compilation capabilities, the `target` might not be a bad thing to add.  Target architecture parameters are currently handled through the [wiki:Attic/Building/BuildSystem Build System], which partly sets such architectural parameters through [[GhcFile(includes/mkDerivedConstants.c)]] and [[GhcFile(includes/ghcconfig.h)]].
    629629
    630630=== Expressions ===