ghc-lib-0.20210228: The GHC API, decoupled from GHC versions
Safe HaskellNone
LanguageHaskell2010

GHC.CmmToAsm.Monad

Synopsis

Documentation

data NcgImpl statics instr jumpDest Source #

Constructors

NcgImpl 

Fields

data NatM_State Source #

Constructors

NatM_State 

Fields

mkNatM_State :: UniqSupply -> Int -> NCGConfig -> ModLocation -> DwarfFiles -> LabelMap DebugBlock -> CFG -> NatM_State Source #

data NatM result Source #

Instances

Instances details
Monad NatM Source # 
Instance details

Defined in GHC.CmmToAsm.Monad

Methods

(>>=) :: NatM a -> (a -> NatM b) -> NatM b #

(>>) :: NatM a -> NatM b -> NatM b #

return :: a -> NatM a #

Functor NatM Source # 
Instance details

Defined in GHC.CmmToAsm.Monad

Methods

fmap :: (a -> b) -> NatM a -> NatM b #

(<$) :: a -> NatM b -> NatM a #

Applicative NatM Source # 
Instance details

Defined in GHC.CmmToAsm.Monad

Methods

pure :: a -> NatM a #

(<*>) :: NatM (a -> b) -> NatM a -> NatM b #

liftA2 :: (a -> b -> c) -> NatM a -> NatM b -> NatM c #

(*>) :: NatM a -> NatM b -> NatM b #

(<*) :: NatM a -> NatM b -> NatM a #

MonadUnique NatM Source # 
Instance details

Defined in GHC.CmmToAsm.Monad

HasModule NatM Source # 
Instance details

Defined in GHC.CmmToAsm.Monad

CmmMakeDynamicReferenceM NatM Source # 
Instance details

Defined in GHC.CmmToAsm.PIC

Methods

addImport :: CLabel -> NatM () Source #

addImportNat :: CLabel -> NatM () Source #

addNodeBetweenNat :: BlockId -> BlockId -> BlockId -> NatM () Source #

Record that we added a block between from and old.

addImmediateSuccessorNat :: BlockId -> BlockId -> NatM () Source #

Place succ after block and change any edges block -> X to succ -> X

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

getConfig :: NatM NCGConfig Source #

Get native code generator configuration

getPlatform :: NatM Platform Source #

Get target platform from native code generator configuration

getCfgWeights :: NatM Weights Source #

Get CFG edge weights

getFileId :: FastString -> NatM Int Source #

type DwarfFiles = UniqFM FastString (FastString, Int) Source #