IDA SDK

- Main Page
- Header Files
- Classes
- Modules

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Attributes | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
callregs_t Class Reference

## Detailed Description

Register allocation calling convention.

(allocation policy, arrays of GP and FP registers)

## Public Attributes
argreg_policy_t | policy
| argument policy
int | nregs
| max number of registers that can be used in a call
intvec_t | gpregs
| array of gp registers
intvec_t | fpregs
| array of fp registers

## Public Member Functions
| callregs_t ()
| Constructor.
| callregs_t (int request)
| Constructor - initialize with the given request (see init_regs())
void | init_regs (int request)
| Init policy & registers using given request. More...
void | set (argreg_policy_t _policy, const int *gprs, const int *fprs)
| Init policy & registers (arrays are -1-terminated)
void | reset ()
| Set policy and registers to invalid values.
bool | reginds (int *gp_ind, int *fp_ind, int r)
| Get register indexes within GP/FP arrays. More...

## Static Public Member Functions
static int | regcount (int request)
| Get max number of registers may be used in a function call. More...
static int | findreg (const intvec_t &regs, int r)

## Protected Member Functions
bool | findregs (int *gp_ind, int *fp_ind, int r, const intvec_t &gprs, const intvec_t &fprs)
| Search for register r in gprs and fprs. More...

## Member Function Documentation

void callregs_t::init_regs | ( | int | request | ) |
| inline

Init policy & registers using given request.

request should be one of:

- ph.get_fastcall_regs3
- ph.get_varcall_regs3
- ph.get_thiscall_regs3

static int callregs_t::regcount | ( | int | request | ) |
| inline static

Get max number of registers may be used in a function call.

request should be one of:

- ph.get_fastcall_regs3
- ph.get_varcall_regs3
- ph.get_thiscall_regs3

bool callregs_t::reginds | ( | int * | gp_ind,
|  | int * | fp_ind,
|  | int | r
| ) |  |
| inline

Get register indexes within GP/FP arrays.

(-1 -> is not present in the corresponding array)

bool callregs_t::findregs | ( | int * | gp_ind,
|  | int * | fp_ind,
|  | int | r,
|  | const intvec_t & | gprs,
|  | const intvec_t & | fprs
| ) |  |
| inline protected

Search for register r in gprs and fprs.

If found, fill gp_ind and fp_ind based on policy

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

- typeinf.hpp