.\" .de Id .. .de Sp .if n .sp .if t .sp 0.4 .. .TH dis_time 4rheolef "rheolef-6.7" "rheolef-6.7" "rheolef-6.7" .\" label: /*D:dis_time .SH NAME \fBdis_time\fP, \fBseq_time\fP -- Time in seconds since an arbitrary time in the past. .SH SYNOPSIS .\" begin_example .Sp .nf double dis_time(); double seq_time(); .Sp .fi .\" end_example .PP .SH EXAMPLE .\" begin_example .Sp .nf double t_start = dis_time(); //.... stuff to be timed ... double t_end = dis_time(); derr << "That took " << t_end - t_start << " seconds" << endl .Sp .fi .\" end_example .PP .SH DESCRIPTION \fBdis_time\fP returns a floating-point number of seconds, representing elapsed wall-clock time since some time in the past. The \fItime in the past\fP is guaranteed not to change during the life of the process. The user is responsible for converting large numbers of seconds to other units if they are preferred. This function is portable (it returns seconds, not \fIticks\fP), it allows high resolution, and carries no unnecessary baggage. In a distributed environment, \fBdis_time\fP clocks are synchronized: different nodes return the same time value at the same instant. .PP \fBseq_time\fP is similar but the time returned is local to the node that called them and clocks are not synchronized: in a distributed environment, different nodes can return diferent local times, at different instant when the call to \fBseq_time\fP is reached. .\" skip start:AUTHOR: .\" skip start:DATE: .\" skip start:METHODS: .\" END