CPU Performance Counters Library Functions cpceventdiff(3CPC)
NAME
cpceventdiff, cpceventaccum - simple difference and
accumulate operations
SYNOPSIS
cc [ flag... ] file... -lcpc [ library... ]
#include
void cpceventaccum(cpceventt *accum, cpceventt *event);
void cpceventdiff(cpceventt *diff, cpceventt *after,
cpceventt *before);
DESCRIPTION
The cpceventaccum() and cpceventdiff() functions per-
form common accumulate and difference operations on
cpcevent(3CPC) data structures. Use of these functions
increases program portability, since structure members are
not referenced directly .
cpceventaccum()
The cpceventaccum() function adds the cepic fields of
event into the corresponding fields of accum. The cehrt
field of accum is set to the later of the times in event and
accum.
SPARC:
The function adds the contents of the cetick field of event
into the corresponding field of accum.
x86:
The function adds the contents of the cetsc field of event
into the corresponding field of accum.
cpceventdiff()
The cpceventdiff() function places the difference between
the cepic fields of after and before and places them in the
corresponding field of diff. The cehrt field of diff is set
to the cehrt field of after.
SPARC:
Additionally, the function computes the difference between
the cetick fields of after and before, and places it in the
corresponding field of diff.
x86:
Additionally, the function computes the difference between
the cetsc fields of after and before, and places it in the
corresponding field of diff.
SunOS 5.11 Last change: 28 Mar 2005 1
CPU Performance Counters Library Functions cpceventdiff(3CPC)
ATRIBUTES
See attributes(5) for descriptions of the following attri-
butes:
ATRIBUTE TYPE ATRIBUTE VALUE
Interface Stability Obsolete
MT-Level MT-Safe
SEE ALSO
cpc(3CPC), cpcbufadd(3CPC), cpcbufsub(3CPC),
cpcevent(3CPC), libcpc(3LIB), attributes(5)
NOTES
The cpceventaccum() and cpceventdiff() functions exist
for binary compatibility only. Source containing these func-
tions will not compile. These functions are obsolete and
might be removed in a future release. Applications should
use cpcbufadd(3CPC) and cpcbufsub(3CPC) instead.
SunOS 5.11 Last change: 28 Mar 2005 2
|