comparison lisp/emacs-lisp/profile.el @ 18423:3934c0e29d14

(profile-million): Variable moved.
author Richard M. Stallman <rms@gnu.org>
date Mon, 23 Jun 1997 19:12:42 +0000
parents 11218164bc54
children db005054f15d
comparison
equal deleted inserted replaced
18422:96deedadd2f0 18423:3934c0e29d14
90 (defvar profile-max-fun-name 0 "Max length of name of any function profiled.") 90 (defvar profile-max-fun-name 0 "Max length of name of any function profiled.")
91 (defvar profile-temp-result- nil "Should NOT be used anywhere else.") 91 (defvar profile-temp-result- nil "Should NOT be used anywhere else.")
92 (defvar profile-time (cons 0 0) "Used to return result from a filter.") 92 (defvar profile-time (cons 0 0) "Used to return result from a filter.")
93 (defvar profile-buffer "*profile*" "Name of profile buffer.") 93 (defvar profile-buffer "*profile*" "Name of profile buffer.")
94 94
95 (defconst profile-million 1000000)
96
95 ;;; 97 ;;;
96 ;;; F U N C T I O N S 98 ;;; F U N C T I O N S
97 ;;; 99 ;;;
98 100
99 (defun profile-functions (&optional flist) 101 (defun profile-functions (&optional flist)
186 (setcar init-time 1) ; mark first entry 188 (setcar init-time 1) ; mark first entry
187 (setq init-time (cdr init-time)) 189 (setq init-time (cdr init-time))
188 (setcar init-time (car profile-time)) 190 (setcar init-time (car profile-time))
189 (setcdr init-time (cdr profile-time))) 191 (setcdr init-time (cdr profile-time)))
190 )) 192 ))
191
192 (defconst profile-million 1000000)
193 193
194 (defun profile-update-function (fun) 194 (defun profile-update-function (fun)
195 "When the call to the function FUN is finished, add its run time." 195 "When the call to the function FUN is finished, add its run time."
196 ;; assumes that profile-time contains the current time 196 ;; assumes that profile-time contains the current time
197 (let ((init-time (profile-find-function fun profile-init-list)) 197 (let ((init-time (profile-find-function fun profile-init-list))