We present a new approach to static program analysis that permits each expression in a program to be assigned an execution time estimate. Our approach uses a time system in conjunction with a conventional type system to compute both the type and the time of an expression. The time of an expression is either an integer upper bound on the number of ticks the expression will execute, or the distinguished element long that indicates that the expression contains a loop and thus may run for an arbitrary length of time. Every Financially supported in Ecole des Mines de Paris by Bull under a CIFRE contract. ySupported by DARPA ONR Grant No. N00014-89-J-1988 1
Vincent Dornic, Pierre Jouvelot, David K. Gifford