foxdec-0.1.0.0: Formally Verified x86-64 Decompilation
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.X86.Instruction

Synopsis

Documentation

data Instruction Source #

Instances

Instances details
Generic Instruction Source # 
Instance details

Defined in Data.X86.Instruction

Associated Types

type Rep Instruction :: Type -> Type #

Show Instruction Source # 
Instance details

Defined in Data.X86.Instruction

Serialize Instruction Source # 
Instance details

Defined in Data.X86.Instruction

NFData Instruction Source # 
Instance details

Defined in Data.X86.Instruction

Methods

rnf :: Instruction -> () #

Eq Instruction Source # 
Instance details

Defined in Data.X86.Instruction

Ord Instruction Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Instruction Source # 
Instance details

Defined in Data.X86.Instruction

data Prefix Source #

Instances

Instances details
Generic Prefix Source # 
Instance details

Defined in Data.X86.Instruction

Associated Types

type Rep Prefix :: Type -> Type #

Methods

from :: Prefix -> Rep Prefix x #

to :: Rep Prefix x -> Prefix #

Show Prefix Source # 
Instance details

Defined in Data.X86.Instruction

Serialize Prefix Source # 
Instance details

Defined in Data.X86.Instruction

NFData Prefix Source # 
Instance details

Defined in Data.X86.Instruction

Methods

rnf :: Prefix -> () #

Eq Prefix Source # 
Instance details

Defined in Data.X86.Instruction

Methods

(==) :: Prefix -> Prefix -> Bool #

(/=) :: Prefix -> Prefix -> Bool #

Ord Prefix Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Prefix Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Prefix = D1 ('MetaData "Prefix" "Data.X86.Instruction" "foxdec-0.1.0.0-DGuc5MMkhbvOBLAebyTd5" 'False) ((C1 ('MetaCons "PrefixO16" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "PrefixA32" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "PrefixRepNE" 'PrefixI 'False) (U1 :: Type -> Type))) :+: ((C1 ('MetaCons "PrefixRep" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "PrefixLock" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "PrefixSeg" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 SReg)) :+: C1 ('MetaCons "PrefixRex" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Word8)))))

data Operand Source #

Instances

Instances details
Generic Operand Source # 
Instance details

Defined in Data.X86.Instruction

Associated Types

type Rep Operand :: Type -> Type #

Methods

from :: Operand -> Rep Operand x #

to :: Rep Operand x -> Operand #

Show Operand Source # 
Instance details

Defined in Data.X86.Instruction

Serialize Operand Source # 
Instance details

Defined in Data.X86.Instruction

NFData Operand Source # 
Instance details

Defined in Data.X86.Instruction

Methods

rnf :: Operand -> () #

Eq Operand Source # 
Instance details

Defined in Data.X86.Instruction

Methods

(==) :: Operand -> Operand -> Bool #

(/=) :: Operand -> Operand -> Bool #

Ord Operand Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Operand Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Operand = D1 ('MetaData "Operand" "Data.X86.Instruction" "foxdec-0.1.0.0-DGuc5MMkhbvOBLAebyTd5" 'False) ((C1 ('MetaCons "Op_Mem" 'PrefixI 'True) ((S1 ('MetaSel ('Just "mSize") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 BitSize) :*: (S1 ('MetaSel ('Just "mASize") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 BitSize) :*: S1 ('MetaSel ('Just "mReg") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Register))) :*: ((S1 ('MetaSel ('Just "mIdx") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Register) :*: S1 ('MetaSel ('Just "mScale") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Word8)) :*: (S1 ('MetaSel ('Just "mDisp") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int) :*: S1 ('MetaSel ('Just "mSeg") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe SReg))))) :+: (C1 ('MetaCons "Op_Reg" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Register)) :+: C1 ('MetaCons "Op_Imm" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Immediate)))) :+: ((C1 ('MetaCons "Op_Jmp" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Immediate)) :+: C1 ('MetaCons "Op_Const" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int))) :+: (C1 ('MetaCons "Op_Near" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Operand)) :+: C1 ('MetaCons "Op_Far" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Operand)))))

data Immediate Source #

Constructors

Immediate 

Fields

Instances

Instances details
Generic Immediate Source # 
Instance details

Defined in Data.X86.Instruction

Associated Types

type Rep Immediate :: Type -> Type #

Show Immediate Source # 
Instance details

Defined in Data.X86.Instruction

Serialize Immediate Source # 
Instance details

Defined in Data.X86.Instruction

NFData Immediate Source # 
Instance details

Defined in Data.X86.Instruction

Methods

rnf :: Immediate -> () #

Eq Immediate Source # 
Instance details

Defined in Data.X86.Instruction

Ord Immediate Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Immediate Source # 
Instance details

Defined in Data.X86.Instruction

type Rep Immediate = D1 ('MetaData "Immediate" "Data.X86.Instruction" "foxdec-0.1.0.0-DGuc5MMkhbvOBLAebyTd5" 'False) (C1 ('MetaCons "Immediate" 'PrefixI 'True) (S1 ('MetaSel ('Just "iSize") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 BitSize) :*: S1 ('MetaSel ('Just "iValue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Word64)))

canonicalize :: Instruction -> [Instruction] Source #

Canonicalizes an instruction by making sure there is at most one output and inputs/outputs are syntactically clear. | For example, the IMUL instruction comes in different flavors that hide the actual inputs and outputs to multiple registers