NAG Library Routine Document
X05BAF
1 Purpose
X05BAF returns the amount of processor time used since an unspecified previous time, via the routine name.
2 Specification
REAL (KIND=nag_wp) X05BAF |
|
3 Description
X05BAF returns the number of seconds of processor time used since some previous time. The previous time is system dependent, but may be, for example, the time the current job or the current program started running.
If the system clock of the host machine is inaccessible for any reason, X05BAF returns the value zero.
4 References
None.
5 Parameters
None.
6 Error Indicators and Warnings
None.
7 Accuracy
The accuracy of the value returned depends on the accuracy of the system clock on the host machine.
Since the value returned by X05BAF is the amount of processor time since some unspecified earlier time, no significance should be placed on the value other than as a marker to be compared with some later figure returned by X05BAF. The amount of processor time that has elapsed between two calls of X05BAF can be simply calculated as the earlier value subtracted from the later value.
9 Example
This example makes a call to X05BAF, performs some computations, makes another call to X05BAF, and gives the time used by the computations as the difference between the two returned values.
9.1 Program Text
Program Text (x05bafe.f90)
9.2 Program Data
None.
9.3 Program Results
Program Results (x05bafe.r)