dr_api.h File Reference

Top-level include file for DynamoRIO API. More...

#include "dr_defines.h"
#include "dr_events.h"
#include "dr_app.h"
#include "dr_ir_opnd.h"
#include "dr_tools.h"
#include "dr_proc.h"
#include "dr_ir_utils.h"
#include "dr_ir_instrlist.h"
#include "dr_ir_instr.h"
#include "dr_ir_opcodes.h"
#include "dr_ir_macros.h"
#include "dr_annotation.h"


DR_EXPORT void dr_client_main (client_id_t id, int argc, const char *argv[])
DR_EXPORT void dr_init (client_id_t id)

Detailed Description

Top-level include file for DynamoRIO API.

Function Documentation

DR_EXPORT void dr_client_main ( client_id_t  id,
int  argc,
const char *  argv[] 

When registering a process, users must provide a list of paths to client libraries and their associated client-specific options. DR looks up "dr_client_main" in each client library and calls that function when the process starts. Clients can register to receive callbacks for the various events within dr_client_main(). Note that client paths and options cannot include semicolons.

client_id is the ID supplied at registration and is used to identify the client for dr_get_option_array(), dr_get_client_path(), and external nudges.

The arguments passed to the client are specified in argc and argv. To match standalone application conventions, argv[0] is set to the client library path, with the actual parameters starting at index 1.

DR_EXPORT void dr_init ( client_id_t  id)

Legacy, deprecated initialization routine.