processmemory-0.1.0.0: C bindings for the gnu-extension functions process_vm_readv and process_vm_writev

Safe HaskellSafe
LanguageHaskell2010

Data.Memory.Debug

Contents

Synopsis

Documentation

data IOVec Source #

Constructors

IOVec 

Fields

Instances
Show IOVec Source # 
Instance details

Defined in Data.Memory.Debug.IOVec

Methods

showsPrec :: Int -> IOVec -> ShowS #

show :: IOVec -> String #

showList :: [IOVec] -> ShowS #

Storable IOVec Source # 
Instance details

Defined in Data.Memory.Debug.IOVec

Methods

sizeOf :: IOVec -> Int #

alignment :: IOVec -> Int #

peekElemOff :: Ptr IOVec -> Int -> IO IOVec #

pokeElemOff :: Ptr IOVec -> Int -> IOVec -> IO () #

peekByteOff :: Ptr b -> Int -> IO IOVec #

pokeByteOff :: Ptr b -> Int -> IOVec -> IO () #

peek :: Ptr IOVec -> IO IOVec #

poke :: Ptr IOVec -> IOVec -> IO () #

Reading and writing

processVMReadV :: CPid -> Ptr Word8 -> Int -> IO [Word8] Source #

Wrapper function for process_vm_readv. No flags, only single io vectors are read

processVMWriteV :: CPid -> Ptr Word8 -> Int -> [Word8] -> IO () Source #

Wrapper function for process_vm_writev. No flags, only single io vectors are written

encode :: Binary a => a -> [Word8] Source #

Wrapper function for Data.Binary.encode. Our package works with lists of Word8 so this is a convenient helper function that does the conversion for you.

It is not efficient, but this module is not designed for large amounts of memory transfers anyway.

decode :: Binary a => [Word8] -> a Source #

module Foreign