libTriton  version 0.6 build 1382
Public Member Functions | Protected Attributes | List of all members
triton::arch::MemoryAccess Class Reference

This class is used to represent a memory access. More...

#include <memoryAccess.hpp>

Inheritance diagram for triton::arch::MemoryAccess:

Public Member Functions

TRITON_EXPORT MemoryAccess ()
 Constructor.
 
TRITON_EXPORT MemoryAccess (triton::uint64 address, triton::uint32 size)
 Constructor.
 
TRITON_EXPORT MemoryAccess (const MemoryAccess &other)
 Constructor by copy.
 
TRITON_EXPORT triton::ast::SharedAbstractNode getLeaAst (void) const
 Returns the AST of the memory access (LEA).
 
TRITON_EXPORT triton::uint64 getAddress (void) const
 Returns the address of the memory.
 
TRITON_EXPORT triton::uint32 getAbstractHigh (void) const
 Returns the highest bit of the memory vector. More...
 
TRITON_EXPORT triton::uint32 getAbstractLow (void) const
 Returns the lower bit of the memory vector. More...
 
TRITON_EXPORT triton::uint32 getBitSize (void) const
 Returns the size (in bits) of the memory vector.
 
TRITON_EXPORT triton::uint64 getPcRelative (void) const
 LEA - Gets pc relative.
 
TRITON_EXPORT triton::uint32 getSize (void) const
 Returns the size (in bytes) of the memory vector.
 
TRITON_EXPORT triton::uint32 getType (void) const
 Returns the type of the operand (triton::arch::OP_MEM).
 
TRITON_EXPORT triton::arch::RegistergetSegmentRegister (void)
 LEA - Returns the segment register operand.
 
TRITON_EXPORT triton::arch::RegistergetBaseRegister (void)
 LEA - Returns the base register operand.
 
TRITON_EXPORT triton::arch::RegistergetIndexRegister (void)
 LEA - Returns the index register operand.
 
TRITON_EXPORT triton::arch::ImmediategetDisplacement (void)
 LEA - Returns the displacement operand.
 
TRITON_EXPORT triton::arch::ImmediategetScale (void)
 LEA - Returns the scale operand.
 
TRITON_EXPORT const triton::arch::RegistergetConstSegmentRegister (void) const
 LEA - Returns the segment register operand.
 
TRITON_EXPORT const triton::arch::RegistergetConstBaseRegister (void) const
 LEA - Returns the base register operand.
 
TRITON_EXPORT const triton::arch::RegistergetConstIndexRegister (void) const
 LEA - Returns the index register operand.
 
TRITON_EXPORT const triton::arch::ImmediategetConstDisplacement (void) const
 LEA - Returns the displacement operand.
 
TRITON_EXPORT const triton::arch::ImmediategetConstScale (void) const
 LEA - Returns the scale operand.
 
TRITON_EXPORT bool isOverlapWith (const MemoryAccess &other) const
 Returns true if other and self overlap.
 
TRITON_EXPORT void setAddress (triton::uint64 addr)
 Sets the address of the memory access.
 
TRITON_EXPORT void setPcRelative (triton::uint64 addr)
 LEA - Sets pc relative.
 
TRITON_EXPORT void setSegmentRegister (const triton::arch::Register &segment)
 LEA - Sets the segment register operand.
 
TRITON_EXPORT void setBaseRegister (const triton::arch::Register &base)
 LEA - Sets the base register operand.
 
TRITON_EXPORT void setIndexRegister (const triton::arch::Register &index)
 LEA - Sets the index register operand.
 
TRITON_EXPORT void setDisplacement (const triton::arch::Immediate &displacement)
 LEA - Sets the displacement operand.
 
TRITON_EXPORT void setScale (const triton::arch::Immediate &scale)
 LEA - Sets the scale operand.
 
TRITON_EXPORT void setLeaAst (const triton::ast::SharedAbstractNode &ast)
 Sets the AST of the memory access (LEA).
 
TRITON_EXPORT MemoryAccessoperator= (const MemoryAccess &other)
 Copies a MemoryAccess.
 
- Public Member Functions inherited from triton::arch::BitsVector
TRITON_EXPORT BitsVector ()
 Constructor.
 
TRITON_EXPORT BitsVector (triton::uint32 high, triton::uint32 low)
 Constructor.
 
TRITON_EXPORT BitsVector (const triton::arch::BitsVector &other)
 Constructor by copy.
 
TRITON_EXPORT triton::uint32 getHigh (void) const
 Returns the highest bit.
 
TRITON_EXPORT triton::uint32 getLow (void) const
 Returns the lower bit.
 
TRITON_EXPORT triton::uint32 getVectorSize (void) const
 Returns the size of the vector.
 
TRITON_EXPORT triton::uint512 getMaxValue (void) const
 Returns the max possible value of the bitvector.
 
TRITON_EXPORT BitsVectoroperator= (const BitsVector &other)
 Copy a BitsVector.
 
TRITON_EXPORT void setHigh (triton::uint32 v)
 Sets the highest bit position.
 
TRITON_EXPORT void setLow (triton::uint32 v)
 Sets the lower bit position.
 
TRITON_EXPORT void setPair (std::pair< triton::uint32, triton::uint32 > p)
 Sets the pair<high, low> position.
 
- Public Member Functions inherited from triton::arch::OperandInterface
virtual TRITON_EXPORT ~OperandInterface ()
 Destructor.
 

Protected Attributes

triton::uint64 address
 The memory' address.
 
triton::uint64 pcRelative
 Contains the pc relative if it exists.
 
triton::arch::Register segmentReg
 LEA - If the operand has a segment register, this attribute is filled.
 
triton::arch::Register baseReg
 LEA - If the operand has a base register, this attribute is filled.
 
triton::arch::Register indexReg
 LEA - If the operand has an index register, this attribute is filled.
 
triton::arch::Immediate displacement
 LEA - If the operand has a displacement, this attribute is filled.
 
triton::arch::Immediate scale
 LEA - If the operand has a scale, this attribute is filled.
 
triton::ast::SharedAbstractNode leaAst
 The AST of the memory access (LEA).
 
- Protected Attributes inherited from triton::arch::BitsVector
triton::uint32 high
 The highest bit of the bitvector.
 
triton::uint32 low
 The lower bit of the bitvector.
 

Detailed Description

This class is used to represent a memory access.

Definition at line 40 of file memoryAccess.hpp.

Member Function Documentation

◆ getAbstractHigh()

triton::uint32 triton::arch::MemoryAccess::getAbstractHigh ( void  ) const
virtual

Returns the highest bit of the memory vector.

See also
BitsVector::getHigh()

Implements triton::arch::OperandInterface.

Definition at line 54 of file memoryAccess.cpp.

◆ getAbstractLow()

triton::uint32 triton::arch::MemoryAccess::getAbstractLow ( void  ) const
virtual

Returns the lower bit of the memory vector.

See also
BitsVector::getLow()

Implements triton::arch::OperandInterface.

Definition at line 49 of file memoryAccess.cpp.


The documentation for this class was generated from the following files: