Latest available version: IDA and decompilers v8.4.240320sp1 see all releases
Hex-Rays logo State-of-the-art binary code analysis tools
email icon

Structure to hold a register value. More...

#include <idd.hpp>

Public Member Functions

 regval_t (const regval_t &r)
 
regval_toperator= (const regval_t &r)
 Assign this regval to the given value.
 
void clear (void)
 Clear register value.
 
bool operator== (const regval_t &r) const
 Compare two regvals with '=='.
 
bool operator!= (const regval_t &r) const
 Compare two regvals with '!='.
 
void swap (regval_t &r)
 Set this = r and r = this.
 
void _set_int (uint64 x)
 Use set_int()
 
void _set_float (const fpvalue_t &x)
 Use set_float()
 
void _set_bytes (const uchar *data, size_t size)
 Use set_bytes(const uchar *, size_t)
 
void _set_bytes (const bytevec_t &v)
 Use set_bytes(const bytevec_t &)
 
bytevec_t_set_bytes (void)
 Use set_bytes(void)
 
void _set_unavailable (void)
 Use set_unavailable(void)
 
Setters

These functions ensure that the previous value is cleared

Set int value (ival)

void set_int (uint64 x)
 
void set_float (const fpvalue_t &x)
 Set float value (fval)
 
void set_bytes (const uchar *data, size_t size)
 Set custom regval with raw data.
 
void set_bytes (const bytevec_t &v)
 Set custom value with existing bytevec.
 
bytevec_tset_bytes (void)
 Initialize this regval to an empty custom value.
 
void set_unavailable (void)
 Mark as unavailable.
 
Getters

Get custom value

bytevec_tbytes (void)
 
const bytevec_tbytes (void) const
 Get const custom value.
 
void * get_data (void)
 Get pointer to value.
 
const void * get_data (void) const
 Get const pointer to value.
 
size_t get_data_size (void) const
 Get size of value.
 

Public Attributes

int32 rvtype = RVT_INT
 one of Register value types
 
union {
   uint64   ival
 8: integer value
 
   fpvalue_t   fval
 12: floating point value in the internal representation (see ieee.h)
 
   uchar   reserve [sizeof(bytevec_t)]
 bytevec_t: custom data type (use bytes() to access it)
 
}; 
 

Detailed Description

Structure to hold a register value.

Small values (up to 64-bit integers and floating point values) use RVT_INT and RVT_FLOAT types. For bigger values the bytes() vector is used.


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