diff --git a/core/autoload/debug.el b/core/autoload/debug.el index 6d260a271..99262a8e3 100644 --- a/core/autoload/debug.el +++ b/core/autoload/debug.el @@ -79,3 +79,13 @@ selection of all minor-modes, active or not." (warn "Something went wrong.\n\n%s" (pp-to-string status)) (message "Your trust roots are set up properly.\n\n%s" (pp-to-string status)) t))))) + +(defvar doom--profiler nil) +;;;###autoload +(defun doom/toggle-profiler () + (interactive) + (if (not doom--profiler) + (profiler-start 'cpu+mem) + (profiler-report) + (profiler-stop)) + (setq doom--profiler (not doom--profiler)))