ROSE 0.11.145.147
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators Class Reference

Description

Semantic operators.

Most operations are delegated to the symbolic state. The return value from the symbolic state is replaced with an unknown if the expression grows beyond a certain complexity.

Definition at line 213 of file Semantics.h.

#include <Rose/BinaryAnalysis/Partitioner2/Semantics.h>

Inheritance diagram for Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators:
Inheritance graph
[legend]
Collaboration diagram for Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators:
Collaboration graph
[legend]

Public Types

using Super = InstructionSemantics::SymbolicSemantics::RiscOperators
 
using Ptr = RiscOperatorsPtr
 
- Public Types inherited from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators
using Super = BaseSemantics::RiscOperators
 Base type.
 
using Ptr = RiscOperatorsPtr
 Shared-ownership pointer.
 
- Public Types inherited from Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators
enum class  IteStatus {
  NEITHER ,
  A ,
  B ,
  BOTH
}
 Status for iteWithStatus operation. More...
 
using Ptr = RiscOperatorsPtr
 Shared-ownership pointer.
 

Public Member Functions

virtual InstructionSemantics::BaseSemantics::RiscOperatorsPtr create (const InstructionSemantics::BaseSemantics::SValuePtr &protoval, const SmtSolverPtr &solver=SmtSolverPtr()) const override
 Virtual allocating constructor.
 
virtual InstructionSemantics::BaseSemantics::RiscOperatorsPtr create (const InstructionSemantics::BaseSemantics::StatePtr &state, const SmtSolverPtr &solver=SmtSolverPtr()) const override
 Virtual allocating constructor.
 
virtual void startInstruction (SgAsmInstruction *) override
 Called at the beginning of every instruction.
 
- Public Member Functions inherited from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators
virtual BaseSemantics::SValuePtr boolean_ (bool b) override
 Returns a Boolean value.
 
virtual BaseSemantics::SValuePtr number_ (size_t nbits, uint64_t value) override
 Returns a number of the specified bit width.
 
SValuePtr svalueExpr (const ExprPtr &expr, const InsnSet &defs=InsnSet())
 
bool getset_omit_cur_insn (bool b)
 
virtual void substitute (const SValuePtr &from, const SValuePtr &to)
 Substitute all occurrences of from with to in the current state.
 
virtual BaseSemantics::SValuePtr filterResult (const BaseSemantics::SValuePtr &)
 Filters results from RISC operators.
 
virtual SymbolicExpression::Type sgTypeToSymbolicType (SgAsmType *)
 Convert a SgAsmType to a symbolic type.
 
virtual void interrupt (int majr, int minr) override
 Unconditionally raise an interrupt.
 
virtual BaseSemantics::SValuePtr and_ (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Computes bit-wise AND of two values.
 
virtual BaseSemantics::SValuePtr or_ (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Computes bit-wise OR of two values.
 
virtual BaseSemantics::SValuePtr xor_ (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Computes bit-wise XOR of two values.
 
virtual BaseSemantics::SValuePtr invert (const BaseSemantics::SValuePtr &a_) override
 One's complement.
 
virtual BaseSemantics::SValuePtr extract (const BaseSemantics::SValuePtr &a_, size_t begin_bit, size_t end_bit) override
 Extracts bits from a value.
 
virtual BaseSemantics::SValuePtr concat (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Concatenates the bits of two values.
 
virtual BaseSemantics::SValuePtr leastSignificantSetBit (const BaseSemantics::SValuePtr &a_) override
 Returns position of least significant set bit; zero when no bits are set.
 
virtual BaseSemantics::SValuePtr mostSignificantSetBit (const BaseSemantics::SValuePtr &a_) override
 Returns position of most significant set bit; zero when no bits are set.
 
virtual BaseSemantics::SValuePtr rotateLeft (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &sa_) override
 Rotate bits to the left.
 
virtual BaseSemantics::SValuePtr rotateRight (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &sa_) override
 Rotate bits to the right.
 
virtual BaseSemantics::SValuePtr shiftLeft (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &sa_) override
 Returns arg shifted left.
 
virtual BaseSemantics::SValuePtr shiftRight (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &sa_) override
 Returns arg shifted right logically (no sign bit).
 
virtual BaseSemantics::SValuePtr shiftRightArithmetic (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &sa_) override
 Returns arg shifted right arithmetically (with sign bit).
 
virtual BaseSemantics::SValuePtr equalToZero (const BaseSemantics::SValuePtr &a_) override
 Determines whether a value is equal to zero.
 
virtual BaseSemantics::SValuePtr iteWithStatus (const BaseSemantics::SValuePtr &sel_, const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_, IteStatus &) override
 If-then-else with status.
 
virtual BaseSemantics::SValuePtr unsignedExtend (const BaseSemantics::SValuePtr &a_, size_t new_width) override
 Extend (or shrink) operand a so it is nbits wide by adding or removing high-order bits.
 
virtual BaseSemantics::SValuePtr signExtend (const BaseSemantics::SValuePtr &a_, size_t new_width) override
 Sign extends a value.
 
virtual BaseSemantics::SValuePtr add (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Adds two integers of equal size.
 
virtual BaseSemantics::SValuePtr addWithCarries (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_, const BaseSemantics::SValuePtr &c_, BaseSemantics::SValuePtr &carry_out) override
 Add two values of equal size and a carry bit.
 
virtual BaseSemantics::SValuePtr negate (const BaseSemantics::SValuePtr &a_) override
 Two's complement.
 
virtual BaseSemantics::SValuePtr signedDivide (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Divides two signed values.
 
virtual BaseSemantics::SValuePtr signedModulo (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Calculates modulo with signed values.
 
virtual BaseSemantics::SValuePtr signedMultiply (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Multiplies two signed values.
 
virtual BaseSemantics::SValuePtr unsignedDivide (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Divides two unsigned values.
 
virtual BaseSemantics::SValuePtr unsignedModulo (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Calculates modulo with unsigned values.
 
virtual BaseSemantics::SValuePtr unsignedMultiply (const BaseSemantics::SValuePtr &a_, const BaseSemantics::SValuePtr &b_) override
 Multiply two unsigned values.
 
virtual BaseSemantics::SValuePtr fpConvert (const BaseSemantics::SValuePtr &a, SgAsmFloatType *aType, SgAsmFloatType *retType) override
 Convert from one floating-point type to another.
 
virtual BaseSemantics::SValuePtr reinterpret (const BaseSemantics::SValuePtr &, SgAsmType *) override
 Reinterpret an expression as a different type.
 
virtual BaseSemantics::SValuePtr readRegister (RegisterDescriptor reg, const BaseSemantics::SValuePtr &dflt) override
 Reads a value from a register.
 
virtual BaseSemantics::SValuePtr peekRegister (RegisterDescriptor reg, const BaseSemantics::SValuePtr &dflt) override
 Obtain a register value without side effects.
 
virtual void writeRegister (RegisterDescriptor reg, const BaseSemantics::SValuePtr &a_) override
 Writes a value to a register.
 
virtual BaseSemantics::SValuePtr readMemory (RegisterDescriptor segreg, const BaseSemantics::SValuePtr &addr, const BaseSemantics::SValuePtr &dflt, const BaseSemantics::SValuePtr &cond) override
 Reads a value from memory.
 
virtual BaseSemantics::SValuePtr peekMemory (RegisterDescriptor segreg, const BaseSemantics::SValuePtr &addr, const BaseSemantics::SValuePtr &dflt) override
 Read memory without side effects.
 
virtual void writeMemory (RegisterDescriptor segreg, const BaseSemantics::SValuePtr &addr, const BaseSemantics::SValuePtr &data, const BaseSemantics::SValuePtr &cond) override
 Writes a value to memory.
 
BaseSemantics::SValuePtr readOrPeekMemory (RegisterDescriptor segreg, const BaseSemantics::SValuePtr &addr, const BaseSemantics::SValuePtr &dflt, AllowSideEffects::Flag)
 
void computingDefiners (DefinersMode m)
 Property: Track which instructions define a semantic value.
 
DefinersMode computingDefiners () const
 Property: Track which instructions define a semantic value.
 
void computingMemoryWriters (WritersMode m)
 Property: Track which instructions write to each memory location.
 
WritersMode computingMemoryWriters () const
 Property: Track which instructions write to each memory location.
 
void computingRegisterWriters (WritersMode m)
 Property: Track latest writer to each register.
 
WritersMode computingRegisterWriters () const
 Property: Track latest writer to each register.
 
void trimThreshold (uint64_t n)
 Property: Maximum size of expressions.
 
uint64_t trimThreshold () const
 Property: Maximum size of expressions.
 
size_t nTrimmed () const
 Property: Number of symbolic expressions trimmed.
 
void nTrimmed (size_t n)
 Property: Number of symbolic expressions trimmed.
 
bool reinterpretMemoryReads () const
 Property: Reinterpret data as unsigned integers when reading from memory or registers.
 
void reinterpretMemoryReads (bool b)
 Property: Reinterpret data as unsigned integers when reading from memory or registers.
 
bool reinterpretRegisterReads () const
 Property: Reinterpret data as unsigned integers when reading from memory or registers.
 
void reinterpretRegisterReads (bool b)
 Property: Reinterpret data as unsigned integers when reading from memory or registers.
 
- Public Member Functions inherited from Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators
virtual SValuePtr protoval () const
 Property: Prototypical semantic value.
 
virtual void hash (Combinatorics::Hasher &)
 Compute hash of current state.
 
virtual void finishInstruction (SgAsmInstruction *insn)
 Called at the end of every instruction.
 
virtual void comment (const std::string &)
 Inject a line comment into debugging streams.
 
virtual SValuePtr bottom_ (size_t nbits)
 Returns a data-flow bottom value.
 
virtual SValuePtr filterCallTarget (const SValuePtr &a)
 Invoked to filter call targets.
 
virtual SValuePtr filterReturnTarget (const SValuePtr &a)
 Invoked to filter return targets.
 
virtual SValuePtr filterIndirectJumpTarget (const SValuePtr &a)
 Invoked to filter indirect jumps.
 
virtual void hlt ()
 Invoked for the x86 HLT instruction.
 
virtual void cpuid ()
 Invoked for the x86 CPUID instruction.
 
virtual SValuePtr rdtsc ()
 Invoked for the x86 RDTSC instruction.
 
virtual std::pair< SValuePtr, SValuePtrsplit (const SValuePtr &a, size_t splitPoint)
 Split a value into two narrower values.
 
virtual SValuePtr countLeadingZeros (const SValuePtr &a)
 Count leading zero bits.
 
virtual SValuePtr countLeadingOnes (const SValuePtr &a)
 Count leading one bits.
 
virtual SValuePtr reverseElmts (const SValuePtr &a, size_t elmtNBits)
 Reverse parts of a value.
 
virtual SValuePtr ite (const SValuePtr &cond, const SValuePtr &a, const SValuePtr &b) final
 If-then-else.
 
virtual SValuePtr addCarry (const SValuePtr &a, const SValuePtr &b, SValuePtr &carryOut, SValuePtr &overflowed)
 Adds two integers of equal size and carry.
 
virtual SValuePtr subtract (const SValuePtr &minuend, const SValuePtr &subtrahend)
 Subtract one value from another.
 
virtual SValuePtr subtractCarry (const SValuePtr &minuend, const SValuePtr &subtrahend, SValuePtr &carryOut, SValuePtr &overflowed)
 Subtract one value from another and carry.
 
virtual void interrupt (const SValuePtr &majr, const SValuePtr &minr, const SValuePtr &raise)
 Invoked for instructions that cause an interrupt.
 
virtual void raiseInterrupt (unsigned majorNumber, unsigned minorNumber, const SValuePtr &raise)
 Conditionally raise an interrupt.
 
virtual SValuePtr fpFromInteger (const SValuePtr &intValue, SgAsmFloatType *fpType)
 Construct a floating-point value from an integer value.
 
virtual SValuePtr fpToInteger (const SValuePtr &fpValue, SgAsmFloatType *fpType, const SValuePtr &dflt)
 Construct an integer value from a floating-point value.
 
virtual SValuePtr fpIsNan (const SValuePtr &fpValue, SgAsmFloatType *fpType)
 Whether a floating-point value is a special not-a-number bit pattern.
 
virtual SValuePtr fpIsDenormalized (const SValuePtr &fpValue, SgAsmFloatType *fpType)
 Whether a floating-point value is denormalized.
 
virtual SValuePtr fpIsZero (const SValuePtr &fpValue, SgAsmFloatType *fpType)
 Whether a floating-point value is equal to zero.
 
virtual SValuePtr fpIsInfinity (const SValuePtr &fpValue, SgAsmFloatType *fpType)
 Whether a floating-point value is infinity.
 
virtual SValuePtr fpSign (const SValuePtr &fpValue, SgAsmFloatType *fpType)
 Sign of floating-point value.
 
virtual SValuePtr fpEffectiveExponent (const SValuePtr &fpValue, SgAsmFloatType *fpType)
 Exponent of floating-point value.
 
virtual SValuePtr fpAdd (const SValuePtr &a, const SValuePtr &b, SgAsmFloatType *fpType)
 Add two floating-point values.
 
virtual SValuePtr fpSubtract (const SValuePtr &a, const SValuePtr &b, SgAsmFloatType *fpType)
 Subtract one floating-point value from another.
 
virtual SValuePtr fpMultiply (const SValuePtr &a, const SValuePtr &b, SgAsmFloatType *fpType)
 Multiply two floating-point values.
 
virtual SValuePtr fpDivide (const SValuePtr &a, const SValuePtr &b, SgAsmFloatType *fpType)
 Divide one floating-point value by another.
 
virtual SValuePtr fpSquareRoot (const SValuePtr &a, SgAsmFloatType *fpType)
 Square root.
 
virtual SValuePtr fpRoundTowardZero (const SValuePtr &a, SgAsmFloatType *fpType)
 Round toward zero.
 
virtual SValuePtr convert (const SValuePtr &a, SgAsmType *srcType, SgAsmType *dstType)
 Convert value from one type to another.
 
virtual SmtSolverPtr solver () const
 Property: Satisfiability module theory (SMT) solver.
 
virtual void solver (const SmtSolverPtr &s)
 Property: Satisfiability module theory (SMT) solver.
 
const HotPatchhotPatch () const
 Property: Post-instruction hot patches.
 
HotPatchhotPatch ()
 Property: Post-instruction hot patches.
 
void hotPatch (const HotPatch &hp)
 Property: Post-instruction hot patches.
 
virtual StatePtr currentState () const
 Property: Current semantic state.
 
virtual void currentState (const StatePtr &s)
 Property: Current semantic state.
 
virtual StatePtr initialState () const
 Property: Optional lazily updated initial state.
 
virtual void initialState (const StatePtr &s)
 Property: Optional lazily updated initial state.
 
virtual const std::string & name () const
 Property: Name used for debugging.
 
virtual void name (const std::string &s)
 Property: Name used for debugging.
 
void print (std::ostream &stream, const std::string prefix="") const
 Print multi-line output for this object.
 
virtual void print (std::ostream &stream, Formatter &fmt) const
 Print multi-line output for this object.
 
WithFormatter with_format (Formatter &fmt)
 Used for printing RISC operators with formatting.
 
WithFormatter operator+ (Formatter &fmt)
 Used for printing RISC operators with formatting.
 
WithFormatter operator+ (const std::string &linePrefix)
 Used for printing RISC operators with formatting.
 
virtual size_t nInsns () const
 Property: Number of instructions processed.
 
virtual void nInsns (size_t n)
 Property: Number of instructions processed.
 
virtual SgAsmInstructioncurrentInstruction () const
 Property: Current instruction.
 
virtual void currentInstruction (SgAsmInstruction *insn)
 Property: Current instruction.
 
virtual bool isNoopRead () const
 Property: No-op read.
 
virtual void isNoopRead (bool b)
 Property: No-op read.
 
virtual SValuePtr undefined_ (size_t nbits)
 Returns a new undefined value.
 
virtual SValuePtr unspecified_ (size_t nbits)
 Returns a new undefined value.
 
virtual SValuePtr concatLoHi (const SValuePtr &lowBits, const SValuePtr &highBits)
 Aliases for concatenation.
 
virtual SValuePtr concatHiLo (const SValuePtr &highBits, const SValuePtr &lowBits)
 Aliases for concatenation.
 
virtual SValuePtr isEqual (const SValuePtr &a, const SValuePtr &b)
 Equality comparison.
 
virtual SValuePtr isNotEqual (const SValuePtr &a, const SValuePtr &b)
 Equality comparison.
 
virtual SValuePtr isUnsignedLessThan (const SValuePtr &a, const SValuePtr &b)
 Comparison for unsigned values.
 
virtual SValuePtr isUnsignedLessThanOrEqual (const SValuePtr &a, const SValuePtr &b)
 Comparison for unsigned values.
 
virtual SValuePtr isUnsignedGreaterThan (const SValuePtr &a, const SValuePtr &b)
 Comparison for unsigned values.
 
virtual SValuePtr isUnsignedGreaterThanOrEqual (const SValuePtr &a, const SValuePtr &b)
 Comparison for unsigned values.
 
virtual SValuePtr isSignedLessThan (const SValuePtr &a, const SValuePtr &b)
 Comparison for signed values.
 
virtual SValuePtr isSignedLessThanOrEqual (const SValuePtr &a, const SValuePtr &b)
 Comparison for signed values.
 
virtual SValuePtr isSignedGreaterThan (const SValuePtr &a, const SValuePtr &b)
 Comparison for signed values.
 
virtual SValuePtr isSignedGreaterThanOrEqual (const SValuePtr &a, const SValuePtr &b)
 Comparison for signed values.
 
virtual SValuePtr readRegister (RegisterDescriptor reg)
 Reads a value from a register.
 
SValuePtr peekRegister (RegisterDescriptor reg)
 Obtain a register value without side effects.
 

Static Public Member Functions

static RiscOperatorsPtr promote (const InstructionSemantics::BaseSemantics::RiscOperatorsPtr &)
 Run-time promotion of a base RiscOperators pointer to our operators.
 
static RiscOperatorsPtr instance (const RegisterDictionaryPtr &)
 Instantiate a new RiscOperators object and configure it using default values.
 
static RiscOperatorsPtr instance (const RegisterDictionaryPtr &, const SmtSolverPtr &, SemanticMemoryParadigm memoryParadigm=LIST_BASED_MEMORY)
 Instantiate a new RiscOperators object and configure it using default values.
 
static RiscOperatorsPtr instance (const InstructionSemantics::BaseSemantics::SValuePtr &protoval)
 Instantiate a new RiscOperators object with specified prototypical values.
 
static RiscOperatorsPtr instance (const InstructionSemantics::BaseSemantics::SValuePtr &protoval, const SmtSolverPtr &)
 Instantiate a new RiscOperators object with specified prototypical values.
 
static RiscOperatorsPtr instance (const InstructionSemantics::BaseSemantics::StatePtr &)
 Instantiate a new RiscOperators with specified state.
 
static RiscOperatorsPtr instance (const InstructionSemantics::BaseSemantics::StatePtr &, const SmtSolverPtr &)
 Instantiate a new RiscOperators with specified state.
 
- Static Public Member Functions inherited from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators
static RiscOperatorsPtr instanceFromRegisters (const RegisterDictionaryPtr &, const SmtSolverPtr &solver=SmtSolverPtr())
 Instantiates a new RiscOperators object and configures it to use semantic values and states that are defaults for SymbolicSemantics.
 
static RiscOperatorsPtr instanceFromProtoval (const BaseSemantics::SValuePtr &protoval, const SmtSolverPtr &solver=SmtSolverPtr())
 Instantiates a new RiscOperators object with specified prototypical values.
 
static RiscOperatorsPtr instanceFromState (const BaseSemantics::StatePtr &, const SmtSolverPtr &solver=SmtSolverPtr())
 Instantiates a new RiscOperators object with specified state.
 
static RiscOperatorsPtr promote (const BaseSemantics::RiscOperatorsPtr &)
 Run-time promotion of a base RiscOperators pointer to symbolic operators.
 
static SgAsmFloatTypesgIsIeee754 (SgAsmType *)
 Tests whether a SgAsmType is an IEEE-754 floating-point type.
 
- Static Public Member Functions inherited from Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators
static RiscOperatorsPtr promote (const RiscOperatorsPtr &x)
 

Protected Member Functions

 RiscOperators (const InstructionSemantics::BaseSemantics::SValuePtr &protoval, const SmtSolverPtr &solver)
 
 RiscOperators (const InstructionSemantics::BaseSemantics::StatePtr &state, const SmtSolverPtr &solver)
 
- Protected Member Functions inherited from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators
 RiscOperators (const BaseSemantics::SValuePtr &protoval, const SmtSolverPtr &solver)
 
 RiscOperators (const BaseSemantics::StatePtr &state, const SmtSolverPtr &solver)
 
SValuePtr svalueUndefined (size_t nbits)
 
SValuePtr svalueBottom (size_t nbits)
 
SValuePtr svalueUnspecified (size_t nbits)
 
SValuePtr svalueNumber (size_t nbits, uint64_t value)
 
SValuePtr svalueBoolean (bool b)
 
- Protected Member Functions inherited from Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators
 RiscOperators (const SValuePtr &protoval, const SmtSolverPtr &solver=SmtSolverPtr())
 
 RiscOperators (const StatePtr &state, const SmtSolverPtr &solver=SmtSolverPtr())
 

Additional Inherited Members

- Protected Attributes inherited from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators
bool omit_cur_insn
 
DefinersMode computingDefiners_
 
WritersMode computingMemoryWriters_
 
WritersMode computingRegisterWriters_
 
uint64_t trimThreshold_
 
bool reinterpretMemoryReads_
 
bool reinterpretRegisterReads_
 
size_t nTrimmed_ = 0
 

Member Typedef Documentation

◆ Super

Definition at line 215 of file Semantics.h.

◆ Ptr

using Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators::Ptr = RiscOperatorsPtr

Definition at line 216 of file Semantics.h.

Constructor & Destructor Documentation

◆ ~RiscOperators()

Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators::~RiscOperators ( )
virtual

Member Function Documentation

◆ create() [1/2]

virtual InstructionSemantics::BaseSemantics::RiscOperatorsPtr Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators::create ( const InstructionSemantics::BaseSemantics::SValuePtr protoval,
const SmtSolverPtr solver = SmtSolverPtr() 
) const
inlineoverridevirtual

Virtual allocating constructor.

The protoval is a prototypical semantic value that is used as a factory to create additional values as necessary via its virtual constructors. The state upon which the RISC operations operate must be set by modifying the currentState property. An optional SMT solver may be specified (see solver).

Reimplemented from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators.

Definition at line 270 of file Semantics.h.

References instance(), Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators::protoval(), and Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators::solver().

◆ create() [2/2]

virtual InstructionSemantics::BaseSemantics::RiscOperatorsPtr Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators::create ( const InstructionSemantics::BaseSemantics::StatePtr state,
const SmtSolverPtr solver = SmtSolverPtr() 
) const
inlineoverridevirtual

Virtual allocating constructor.

The supplied state is that upon which the RISC operations operate and is also used to define the prototypical semantic value. Other states can be supplied by setting currentState. The prototypical semantic value is used as a factory to create additional values as necessary via its virtual constructors. An optional SMT solver may be specified (see solver).

Reimplemented from Rose::BinaryAnalysis::InstructionSemantics::SymbolicSemantics::RiscOperators.

Definition at line 276 of file Semantics.h.

References instance(), and Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators::solver().

◆ promote()

static RiscOperatorsPtr Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators::promote ( const InstructionSemantics::BaseSemantics::RiscOperatorsPtr )
static

Run-time promotion of a base RiscOperators pointer to our operators.

This is a checked conversion–it will fail if x does not point to our object.

◆ startInstruction()

virtual void Rose::BinaryAnalysis::Partitioner2::Semantics::RiscOperators::startInstruction ( SgAsmInstruction insn)
overridevirtual

Called at the beginning of every instruction.

This method is invoked every time the translation object begins processing an instruction. Some policies use this to update a pointer to the current instruction.

Reimplemented from Rose::BinaryAnalysis::InstructionSemantics::BaseSemantics::RiscOperators.


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