Skip to content

Commit

Permalink
pt/addrtrace: Add type & vec for imgobj & funcobj
Browse files Browse the repository at this point in the history
  • Loading branch information
aewag committed Mar 3, 2023
1 parent 23d8afc commit 786340e
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions pintool/addrtrace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,29 @@ std::vector<entry_t> trace; /* Contains all traced instructions */
ofstream imgfile; /* Holds memory layout with function symbols */
ofstream vdsofile; /* Holds vdso shared library */

/***********************************************************************/
/* Image tracking*/
typedef struct {
string name;
uint64_t baseaddr;
uint64_t endaddr;
string hash;
} imgobj_t;

typedef std::vector<imgobj_t> IMGVEC;
IMGVEC imgvec;

/* Image to function mapping*/
typedef struct {
string name;
uint64_t baseaddr;
uint64_t endaddr;
string funcname;
} funcobj_t;

typedef std::vector<funcobj_t> FUNCVEC;
FUNCVEC funcvec;

/***********************************************************************/
/* Heap tracking */

Expand Down

0 comments on commit 786340e

Please sign in to comment.