Class Etime

  extended by org.netlib.util.Etime

public class Etime
extends java.lang.Object

Implementation of Fortran ETIME intrinsic.

This file is part of the Fortran-to-Java (f2j) system, developed at the University of Tennessee.

This class implements the Fortran 77 ETIME intrinsic. ETIME is supposed to provide the CPU time for the process since the start of execution. Currently, Java doesn't have a similar method, so we use this cheesy simulation:

Essentially, this version of etime returns the wall-clock time elapsed since the beginning of execution.

Keith Seymour (

Constructor Summary
Method Summary
static void etime()
          Initializes the timer.
static float etime(float[] t, int t_offset)
          Get the elapsed time.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public Etime()
Method Detail


public static void etime()
Initializes the timer.


public static float etime(float[] t,
                          int t_offset)
Get the elapsed time. Sets the first element of the array 't' to the elapsed time. This is also the return value.

t - Two-element array of times. The first element should be user time. The second element should be system time. Currently these are set the same, though.
t_offset - Offset from t. Normally zero.
first element of t.