82c02b6c87e6b40859ee351eaab7f9957c4aafc9
12 virtual ~memtracer_t() {}
14 virtual bool interested_in_range(uint64_t begin
, uint64_t end
, bool store
, bool fetch
) = 0;
15 virtual void trace(uint64_t addr
, size_t bytes
, bool store
, bool fetch
) = 0;
18 class memtracer_list_t
: public memtracer_t
21 bool interested_in_range(uint64_t begin
, uint64_t end
, bool store
, bool fetch
)
23 for (std::vector
<memtracer_t
*>::iterator it
= list
.begin(); it
!= list
.end(); ++it
)
24 if ((*it
)->interested_in_range(begin
, end
, store
, fetch
))
28 void trace(uint64_t addr
, size_t bytes
, bool store
, bool fetch
)
30 for (std::vector
<memtracer_t
*>::iterator it
= list
.begin(); it
!= list
.end(); ++it
)
31 (*it
)->trace(addr
, bytes
, store
, fetch
);
33 void hook(memtracer_t
* h
)
38 std::vector
<memtracer_t
*> list
;