- -- pprTrace "live_ptrs for" (ppr bid <+> ppr youngByte <+> ppr liveSlots) $
- reverse $ slotsToList youngByte liveSlots []
- where slotsToList n [] results | n == oldByte = results -- at old end of stack frame
+ -- pprTrace "live_ptrs for" (ppr bid <+> text (show oldByte ++ "-" ++ show youngByte) <+>
+ -- ppr liveSlots) $
+ -- pprTrace ("stack layout for " ++ show bid ++ ": ") (ppr res) $ res
+ res
+ where res = reverse $ slotsToList youngByte liveSlots []
+
+ slotsToList :: Int -> [RegSlotInfo] -> [Maybe LocalReg] -> [Maybe LocalReg]
+ -- n starts at youngByte and is decremented down to oldByte
+ -- Returns a list, one element per word, with
+ -- (Just r) meaning 'pointer register r is saved here',
+ -- Nothing meaning 'non-pointer or empty'
+
+ slotsToList n [] results | n == oldByte = results -- at old end of stack frame
+