IDA SDK
Public Attributes | Public Member Functions | List of all members
switch_info_t Struct Reference

Detailed Description

Information about a switch statement.

Public Attributes

uint32 flags
 Switch info flags
 
ushort ncases
 number of cases (excluding default)
 
ea_t jumps
 jump table start address
 
union {
   ea_t   values
 values table address (if SWI_SPARSE is set)
 
   uval_t   lowcase
 the lowest value in cases
 
}; 
 
ea_t defjump
 default jump address (BADADDR if not used)
 
ea_t startea
 start of the switch idiom
 
int jcases
 number of entries in the jump table (SWI_INDIRECT)
 
sval_t ind_lowcase
 
ea_t elbase
 element base
 
int regnum
 the switch expression as a register number of the instruction at 'startea'. More...
 
op_dtype_t regdtype
 size of the switch expression register as dtype
 
uval_t custom
 information for custom tables (filled and used by modules)
 

Public Member Functions

int get_shift (void) const
 See SWI_SHIFT_MASK. More...
 
void set_shift (int shift)
 See SWI_SHIFT_MASK.
 
int get_jtable_element_size (void) const
 
void set_jtable_element_size (int size)
 
int get_vtable_element_size (void) const
 
void set_vtable_element_size (int size)
 
bool is_sparse (void) const
 
bool is_custom (void) const
 
bool is_indirect (void) const
 
bool is_subtract (void) const
 
bool is_nolowcase (void) const
 
bool use_std_table (void) const
 
sval_t get_lowcase (void) const
 
int get_jtable_size (void) const
 
void set_jtable_size (int size)
 
void set_expr (int r, op_dtype_t dt)
 
bool get_jrange_vrange (range_t *jrange=NULL, range_t *vrange=NULL) const
 get separate parts of the switch
 
void clear (void)
 

Member Function Documentation

int switch_info_t::get_shift ( void  ) const
inline

See SWI_SHIFT_MASK.

possible answers: 0..3.

Member Data Documentation

int switch_info_t::regnum

the switch expression as a register number of the instruction at 'startea'.

-1 means 'unknown'


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