diff options
| author | Stefan Monnier | 2012-09-24 17:15:53 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2012-09-24 17:15:53 -0400 |
| commit | ad942b63d7a9b984752f46bc2049fe10e488230d (patch) | |
| tree | 71e47ecb9d1e00b996a7e291fef9d4dda1f82386 /lisp | |
| parent | 3d80c99f3817bf5eccd6acc6a79498a4fde979a4 (diff) | |
| download | emacs-ad942b63d7a9b984752f46bc2049fe10e488230d.tar.gz emacs-ad942b63d7a9b984752f46bc2049fe10e488230d.zip | |
Try to let it compile on other platforms
* src/profiler.c (evict_lower_half): Fix typo.
(PROFILER_CPU_SUPPORT): Check and define if cpu-profiler is supported.
Don't compile the cpu-profiler code, if not supported.
(malloc_probe): Presume memory_log is non-nil.
(syms_of_profiler): Don't defsubr functions when they aren't defined.
* src/lisp.h (sample_profiler_running, gc_probe): Don't declare.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/profiler.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/profiler.el b/lisp/profiler.el index 00ee99a6132..90740a2e286 100644 --- a/lisp/profiler.el +++ b/lisp/profiler.el | |||
| @@ -20,7 +20,7 @@ | |||
| 20 | 20 | ||
| 21 | ;;; Commentary: | 21 | ;;; Commentary: |
| 22 | 22 | ||
| 23 | ;; | 23 | ;; |
| 24 | 24 | ||
| 25 | ;;; Code: | 25 | ;;; Code: |
| 26 | 26 | ||
| @@ -237,6 +237,7 @@ be same type." | |||
| 237 | 237 | ||
| 238 | (defun profiler-calltree-compute-percentages (tree) | 238 | (defun profiler-calltree-compute-percentages (tree) |
| 239 | (let ((total-count 0)) | 239 | (let ((total-count 0)) |
| 240 | ;; FIXME: the memory profiler's total wraps around all too easily! | ||
| 240 | (dolist (child (profiler-calltree-children tree)) | 241 | (dolist (child (profiler-calltree-children tree)) |
| 241 | (cl-incf total-count (profiler-calltree-count child))) | 242 | (cl-incf total-count (profiler-calltree-count child))) |
| 242 | (unless (zerop total-count) | 243 | (unless (zerop total-count) |