The arm_stop subroutine is used to mark the end of the execution of a transaction. Measurement of the transaction response time completes at the execution of this subroutine.
ARM Library (libarm.a).
#include arm.h
arm_ret_stat_t arm_stop( arm_start_handle_t arm_handle,
const arm_status_t comp_status,
arm_flag_t flags,
arm_data_t * data,
arm_data_sz_t data_size);
Each arm_stop subroutine call marks the end of an instance of a transaction within an application. Multiple instances (simultaneous executions of the transaction) may exist. Control information for the transaction instance is held from the execution of the arm_start (arm_start Subroutine) subroutine call and until the execution of a matching arm_stop subroutine call, at which time the elapsed time is calculated and used to update transaction measurement metrics for the transaction. Metrics are accumulated for each unique combination of the following three components:
This subroutine is part of the implementation of the ARM API in the Performance Toolbox for AIX® licensed product.
The identifier is returned by an earlier call to arm_start, arm_start Subroutine. The arm_handle argument is used to look for a slot structure created by the arm_start (arm_start Subroutine) call, which returned this arm_handle. If one is not found, no action is taken and the function returns -1. If one is found, a post structure is allocated and added to the linked list of post structures used to pass data to the SpmiArmd daemon. The post structure is updated with the start time from the slot structure, the path to the transaction context, and the stop time of the transaction instance.
In compliance with the ARM API specifications, if the start_handle passed is one returned from a previous arm_start subroutine call that failed, or from an arm_start subroutine operating as a no-operation function, the arm_stop subroutine call executes as a no-operation function. It will return a zero to indicate successful completion.
User supplied transaction completion code. The following codes are defined:
In the current API definition, the last three arguments are for future use and they are ignored in the implementation.
If successful, the subroutine returns zero. If the subroutine fails, a value less than zero is returned.
No error codes are defined by the PTX implementation of the ARM API.
Item | Description |
---|---|
/usr/include/arm.h | Declares the subroutines, data structures, handles, and macros that an application program can use to access the ARM library. |