Service to monitor access to memory pages.
More...
#include <PageAccessControlSvc.h>
Service to monitor access to memory pages.
- Author
- Paolo Calafiura
This service uses
Definition at line 51 of file PageAccessControlSvc.h.
◆ PageAccessControlSvc()
PageAccessControlSvc::PageAccessControlSvc |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
Standard GAUDI constructor.
Definition at line 8 of file PageAccessControlSvc.cxx.
16 "start monitoring on initialize, stop on finalize");
◆ ~PageAccessControlSvc()
virtual PageAccessControlSvc::~PageAccessControlSvc |
( |
| ) |
|
|
inlinevirtual |
◆ accessed()
bool PageAccessControlSvc::accessed |
( |
const void * |
address | ) |
const |
|
virtual |
◆ controlPage()
virtual bool PageAccessControlSvc::controlPage |
( |
const void * |
address | ) |
|
|
inlinevirtual |
◆ finalize()
StatusCode PageAccessControlSvc::finalize |
( |
| ) |
|
|
virtual |
◆ initialize()
StatusCode PageAccessControlSvc::initialize |
( |
| ) |
|
|
virtual |
◆ interfaceID()
const InterfaceID & IPageAccessControlSvc::interfaceID |
( |
| ) |
|
|
inlinestaticinherited |
Retrieve interface ID.
Definition at line 56 of file IPageAccessControlSvc.h.
58 static const InterfaceID IID_IPageAccessControlSvc(
"IPageAccessControlSvc", 1, 0);
59 return IID_IPageAccessControlSvc;
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ queryInterface()
StatusCode PageAccessControlSvc::queryInterface |
( |
const InterfaceID & |
riid, |
|
|
void ** |
ppvInterface |
|
) |
| |
|
virtual |
Definition at line 61 of file PageAccessControlSvc.cxx.
68 return Service::queryInterface(riid, ppvInterface);
71 return StatusCode::SUCCESS;
◆ report()
void PageAccessControlSvc::report |
( |
| ) |
const |
|
virtual |
◆ startMonitoring()
bool PageAccessControlSvc::startMonitoring |
( |
| ) |
|
|
virtual |
In baseline implementation, protect pages and install a SEGV handler that counts the number of accesses to a protected address.
Implements IPageAccessControlSvc.
Definition at line 19 of file PageAccessControlSvc.cxx.
23 sa.sa_sigaction= cPtrAccessSEGVHandler;
24 sa.sa_flags=SA_SIGINFO;
26 rc=sigaction(SIGSEGV,&sa,
nullptr);
◆ stopMonitoring()
bool PageAccessControlSvc::stopMonitoring |
( |
| ) |
|
|
virtual |
◆ m_accessControl
◆ m_autoMonitor
BooleanProperty PageAccessControlSvc::m_autoMonitor |
|
private |
◆ m_saveSEGVaction
struct sigaction PageAccessControlSvc::m_saveSEGVaction |
|
private |
◆ m_SEGVHandler
The documentation for this class was generated from the following files:
static const InterfaceID & interfaceID()
Retrieve interface ID.
PageAccessControl m_accessControl
protected_t::const_iterator const_iterator
struct sigaction m_saveSEGVaction
the default action for SIGSEGV
Interface to a service that monitors memory page accesses.
virtual bool stopMonitoring()
virtual void report() const
In baseline implementation, controlled via PageAccessControlSvc.OutputLevel
BooleanProperty m_autoMonitor
start on init, stop on finalize
PtrAccessSEGVHandler m_SEGVHandler