Go to the documentation of this file.
35 #ifndef TTA_OPERAND_HH
36 #define TTA_OPERAND_HH
107 virtual int index()
const;
112 virtual const std::string&
typeString()
const;
120 virtual int width()
const;
125 virtual const std::set<int>&
swap()
const;
130 virtual bool isNull()
const {
return false; }
176 virtual int index()
const;
182 virtual const std::set<int>&
swap()
const;
183 virtual bool isNull()
const {
return true; }
int elementCount_
Number of total elements.
static const std::string OPRND_ELEM_COUNT
Object state name for element count.
static const std::string OPRND_MEM_DATA
Object state name for memory data.
virtual void setElementCount(int elementCount)
static const std::string SINT_WORD_STRING
virtual bool isOutput() const
static const std::string SLONG_WORD_STRING
static const std::string OPRND_MEM_ADDRESS
Object state name for memory address.
virtual bool isAddress() const
int addressUnits_
size of the data this operation addresses. 0 if unknown.
static const std::string OPRND_MEM_UNITS
Object state name for memory unit count.
virtual ObjectState * saveState() const
virtual int elementCount() const
int elementWidth_
Width of an element.
bool isAddress_
Flag indicating whether Operand is address or not.
virtual bool isMemoryData() const
virtual bool isInput() const
virtual int width() const
virtual void setType(OperandType type)
static const std::string OPRND_CAN_SWAP
Object state name for can swap.
virtual void setElementWidth(int elementWidth)
static NullOperand & instance()
virtual int elementWidth() const
static const std::string OPRND_OUT
Object state name for output operand.
virtual bool isOutput() const
virtual bool isNull() const
static const std::string RAW_DATA_STRING
static const std::string HALF_FLOAT_WORD_STRING
static const std::string FLOAT_WORD_STRING
virtual bool isVector() const
virtual bool canSwap(const Operand &op) const
static const std::string OPRND_ID
Object state name for operand id.
virtual bool canSwap(const Operand &op) const
virtual bool isNull() const
bool isInput_
Direction of operand.
static const std::string DOUBLE_WORD_STRING
virtual const std::string & typeString() const
virtual const std::set< int > & swap() const
static const std::string UINT_WORD_STRING
virtual int index() const
std::set< int > swap_
Indexes of Operands which can be swapped with this Operand.
static const std::string OPRND_IN
Object state name for input operand.
Operand & operator=(const Operand &)
Assignment not allowed.
static const std::string UNKNOWN_TYPE_STRING
static const std::string OPRND_TYPE
Object state name for operand type.
static const std::string OPRND_ELEM_WIDTH
Object state name for element width.
static NullOperand * instance_
Unique instance.
NullOperand & operator=(const NullOperand &)
Assignment not allowed.
virtual OperandType type() const
virtual TCEString CTypeString() const
virtual bool isMemoryData() const
OperandType type_
Type of the Operand.
virtual int memoryUnits() const
static const std::string BOOL_STRING
virtual int index() const
virtual bool isAddress() const
bool isMemoryData_
Flag indicating whether Operand is memory data or not.
virtual bool isInput() const
std::set< int > swap_
Needed for one method, always empty.
static const std::string ULONG_WORD_STRING
static int defaultElementWidth(OperandType type)
int index_
Index of the Operand.
virtual void loadState(const ObjectState *state)
virtual const std::set< int > & swap() const