-{-# OPTIONS -w #-}
--- The above warning supression flag is a temporary kludge.
--- While working on this module you are encouraged to remove it and fix
--- any warnings in the module. See
--- http://hackage.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#Warnings
--- for details
-
module CmmInfo (
emptyContInfoTable,
cmmToRawCmm,
import ZipCfgCmmRep
import Constants
-import Outputable
+import Panic
import StaticFlags
import Unique
import UniqSupply
-import Panic
import Data.Bits
-- <normal forward rest of StgInfoTable>
-- <forward variable part>
--
--- See includes/InfoTables.h
+-- See includes/rts/storage/InfoTables.h
--
-- For return-points these are as follows
--
-- * The SRT slot is only there if there is SRT info to record
mkInfoTable :: Unique -> CmmTop -> [RawCmmTop]
-mkInfoTable uniq (CmmData sec dat) = [CmmData sec dat]
+mkInfoTable _ (CmmData sec dat) = [CmmData sec dat]
mkInfoTable uniq (CmmProc (CmmInfo _ _ info) entry_label arguments blocks) =
case info of
-- Code without an info table. Easy.
layout = packHalfWordsCLit ptrs nptrs
-- A selector thunk.
- ThunkSelectorInfo offset srt ->
+ ThunkSelectorInfo offset _srt ->
mkInfoTableAndCode info_label std_info [{- no SRT -}] entry_label
arguments blocks
where
-> C_SRT
-> ([CmmLit], -- srt_label
StgHalfWord) -- srt_bitmap
-mkSRTLit info_label NoC_SRT = ([], 0)
+mkSRTLit _ NoC_SRT = ([], 0)
mkSRTLit info_label (C_SRT lbl off bitmap) =
([makeRelativeRefTo info_label (cmmLabelOffW lbl off)], bitmap)
small_bitmap = case bitmap of
[] -> 0
- [b] -> fromIntegral b
+ [b] -> b
_ -> panic "mkLiveness"
small_liveness =
fromIntegral (length bits) .|. (small_bitmap `shiftL` bITMAP_BITS_SHIFT)