pm_clear_ebb_handler Subroutine
Purpose
Clears the Event-Based Branching (EBB) facility configured for the calling thread.
Library
Performance Monitor APIs Library (libpmapi.a)
Syntax
#include <pmapi.h>
int pm_clear_ebb_handler (void ** old_handler, void ** old_data_area)
Description
The pm_clear_ebb_handler subroutine clears the EBB facility that is previously configured for the calling thread, through the pm_set_ebb_handler subroutine.
Note: The pm_clear_ebb_handler subroutine
can only be called when the thread mode is 1:1 and when counting for
the thread is not started.
Parameters
Item | Description |
---|---|
old_handler | The old EBB handler configured for the thread. The value can be set to NULL if it is not required. |
old_data_area | The old EBB data area. The value can be set to NULL if it is not required. |
Return Values
If unsuccessful, a value other than zero is returned and a positive error code is set. If successful, a value of zero is returned.
Error Codes
The subroutine is unsuccessful if one of the following error codes are returned:
Item | Description |
---|---|
Pmapi_NoInit | The pm_initialize subroutine is not called. |
Pmapi_Unsupported_EBBThreadMode | The thread is not running in the 1:1 mode. |
Pmapi_NoSetProg | The pm_set_program subroutine is not called. |
Pmapi_Invalid_EBB_Config | The PTHREAD_EBB_PMU_TYPE flag is not passed to the pthread subroutine. |
Pmapi_EBB_NotSet | The EBB handler is not set by the caller. |
Non-zero error codes | Returned by the pthread call or the pmsvcs call. |
Files
The pmapi.h file defines standard macros, data types, and subroutines.