ghc-7.10.3: The GHC API

Safe Haskell | None
Language | Haskell2010

NCGMonad

# Documentation

data NatM_State

Constructors

NatM_State |

Fields

natm_us :: UniqSupply
natm_delta :: Int
natm_imports :: [CLabel]
natm_pic :: Maybe Reg
natm_dflags :: DynFlags
natm_this_module :: Module
natm_modloc :: ModLocation
natm_fileid :: DwarfFiles
natm_debug_map :: LabelMap DebugBlock

mkNatM_State :: UniqSupply -> Int -> DynFlags -> Module -> ModLocation -> DwarfFiles -> LabelMap DebugBlock -> NatM_State

data NatM result

Instances

Monad NatM |
Functor NatM |
Applicative NatM |
HasDynFlags NatM |
CmmMakeDynamicReferenceM NatM |

initNat :: NatM_State -> NatM a -> (a, NatM_State)

addImportNat :: CLabel -> NatM ()

getUniqueNat :: NatM Unique

mapAccumLNat :: (acc -> x -> NatM (acc, y)) -> acc -> [x] -> NatM (acc, [y])

setDeltaNat :: Int -> NatM ()

getDeltaNat :: NatM Int

getThisModuleNat :: NatM Module

getBlockIdNat :: NatM BlockId

getNewLabelNat :: NatM CLabel

getNewRegNat :: Size -> NatM Reg

getNewRegPairNat :: Size -> NatM (Reg, Reg)

getPicBaseMaybeNat :: NatM (Maybe Reg)

getPicBaseNat :: Size -> NatM Reg

getDynFlags :: HasDynFlags m => m DynFlags

getModLoc :: NatM ModLocation

getFileId :: FastString -> NatM Int

getDebugBlock :: Label -> NatM (Maybe DebugBlock)

type DwarfFiles = UniqFM (FastString, Int)