From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andrew Beekhof Newsgroups: gmane.emacs.bugs Subject: bug#16995: 24.3; CPU usage spikes to 100% for minutes at a time Date: Mon, 17 Mar 2014 16:12:33 +1100 Message-ID: <4408122E-520A-4CE2-928E-B7AA5194F8CC@beekhof.net> References: <4744FEC4-6132-4CEE-9CE0-47A0BCBC36D7@beekhof.net> <83d2hro0hr.fsf@gnu.org> <37089DA4-7533-4566-814E-6AC8857123CB@beekhof.net> <8361nioj0l.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 7.2 \(1874\)) Content-Type: multipart/signed; boundary="Apple-Mail=_A289E2C4-4BD2-4681-9ABA-0FB1EA3E425A"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Trace: ger.gmane.org 1395033191 32005 80.91.229.3 (17 Mar 2014 05:13:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 17 Mar 2014 05:13:11 +0000 (UTC) Cc: 16995@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Mar 17 06:13:19 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WPPrP-0008LR-Qy for geb-bug-gnu-emacs@m.gmane.org; Mon, 17 Mar 2014 06:13:16 +0100 Original-Received: from localhost ([::1]:55608 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPPrP-0005R0-Bj for geb-bug-gnu-emacs@m.gmane.org; Mon, 17 Mar 2014 01:13:15 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33467) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPPrI-0005QC-O4 for bug-gnu-emacs@gnu.org; Mon, 17 Mar 2014 01:13:13 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WPPrD-0001xQ-UH for bug-gnu-emacs@gnu.org; Mon, 17 Mar 2014 01:13:08 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:37349) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPPrD-0001xI-Ps for bug-gnu-emacs@gnu.org; Mon, 17 Mar 2014 01:13:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1WPPrD-0000fx-BN for bug-gnu-emacs@gnu.org; Mon, 17 Mar 2014 01:13:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Andrew Beekhof Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 17 Mar 2014 05:13:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 16995 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 16995-submit@debbugs.gnu.org id=B16995.13950331642543 (code B ref 16995); Mon, 17 Mar 2014 05:13:03 +0000 Original-Received: (at 16995) by debbugs.gnu.org; 17 Mar 2014 05:12:44 +0000 Original-Received: from localhost ([127.0.0.1]:38519 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WPPqt-0000eu-3J for submit@debbugs.gnu.org; Mon, 17 Mar 2014 01:12:43 -0400 Original-Received: from out1-smtp.messagingengine.com ([66.111.4.25]:44921) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WPPqo-0000ee-LA for 16995@debbugs.gnu.org; Mon, 17 Mar 2014 01:12:40 -0400 Original-Received: from compute4.internal (compute4.nyi.mail.srv.osa [10.202.2.44]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 42EAC208DF; Mon, 17 Mar 2014 01:12:38 -0400 (EDT) Original-Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Mon, 17 Mar 2014 01:12:38 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=beekhof.net; h= content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; s=mesmtp; bh=YI+sjfNb5kqrIp1jFo3PQVG7 7IA=; b=JaiKHFwKk8sD/G8rXJvBWetHy/gLY5O60M/FuY8GS5SQ7JmfRgCl6udD HSB6rnDWy7G+IsYhc8JBOPEn8Jtm+JrkpHl4t7Tz6ySdHlitNKsajIjIthNGcc8a c/BzTYW9rXh2nWd/FisPpOrTlDyX6zZ+zBFrLL5JO6sH+xlgcG0= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-type:mime-version:subject:from :in-reply-to:date:cc:message-id:references:to; s=smtpout; bh=YI+ sjfNb5kqrIp1jFo3PQVG77IA=; b=g596nmZI7dCxatdYkeinn/pYxd711kQHM4W kw98CTma/L4qfrznsHz7I7WzRPARzGzN4IrT2VihmT3wIzGr7Z28L42S+T6uuRwt UPQw8HF9o8NYqxLLb51ywBWqoBGhPpt7p5Ftpj+H9wIY1MKUY3xpPAGfrPH2Z8mo 3zs5j50g= X-Sasl-enc: lae3qW+bBZmTZnDO0rMO4ytuCW6rLxwr+wa3hI9NNVI3 1395033157 Original-Received: from [172.16.1.5] (unknown [120.147.36.73]) by mail.messagingengine.com (Postfix) with ESMTPA id C19BA6800C5; Mon, 17 Mar 2014 01:12:35 -0400 (EDT) In-Reply-To: X-Mao-Original-Outgoing-Id: 416725953.811497-1e4bf3865601f12a308f74c112548ef6 X-Mailer: Apple Mail (2.1874) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:86900 Archived-At: --Apple-Mail=_A289E2C4-4BD2-4681-9ABA-0FB1EA3E425A Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii On 14 Mar 2014, at 12:40 am, Stefan Monnier = wrote: >> So I guess the question now becomes why does Python mode conses so >> many Lisp objects that it triggers GC so frequently. >=20 > M-x profiler-start RET mem RET > ...reproduce the heavy allocation problem... > M-x profiler-report RET >=20 > might be a good start. bwahahaha. I can go one better and give you a reproducer. Time wasn't a factor, it was switching to a particular file that = triggered the (worst of the) problem. http://paste.fedoraproject.org/85549/13948345/ I had a bug in the file that was causing issues for soemthing: @@ -90,7 +92,7 @@ class CTSTest: self.logger.log(args) =20 def debug(self, args): - self.logger.debug(args + self.logger.debug(args) Clearly user error, but ideally emacs wouldn't grind to a halt as a = result. Here's the profiler report. + timer-event-handler 278,246,734 = 42% + which-func-update 163,238,117 = 24% + redisplay_internal (C function) 87,767,721 = 13% + which-func-update-1 48,416,290 = 7% + call-interactively 35,478,972 = 5% + apply 18,737,232 = 2% + byte-code 5,265,147 = 0% + which-function 4,192,656 = 0% + jit-lock-function 2,876,348 = 0% + redisplay 2,237,092 = 0% + sit-for 1,867,352 = 0% + read-from-minibuffer 1,418,935 = 0% + find-file 1,333,035 = 0% + xselect-convert-to-string 810,557 = 0% + vc-state-refresh 698,757 = 0% + isearch-lazy-highlight-new-loop 649,320 = 0% + isearch-update 589,542 = 0% + minibuffer-message 208,140 = 0% + completion--message 168,120 = 0% + isearch-process-search-string 153,114 = 0% + isearch-search-and-update 145,286 = 0% + jit-lock-fontify-now 136,240 = 0% + x-set-selection 82,873 = 0% + minibuffer-complete 46,642 = 0% + completion--do-completion 38,266 = 0% + deactivate-mark 36,976 = 0% + run-hook-with-args-until-success 24,764 = 0% + run-hooks 22,286 = 0% + run-hook-with-args 17,952 = 0% + xselect-convert-to-targets 17,443 = 0% + find-file-noselect 12,432 = 0% + self-insert-command 8,188 = 0% + c-mode 8,188 = 0% + find-tag 7,000 = 0% + mouse-fixup-help-message 6,144 = 0% + find-file-read-args 5,120 = 0% + funcall 4,096 = 0% + vc-find-file-hook 3,720 = 0% + vc-registered 2,487 = 0% + find-file-noselect-1 2,026 = 0% + file-truename 1,260 = 0% --Apple-Mail=_A289E2C4-4BD2-4681-9ABA-0FB1EA3E425A Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - http://gpgtools.org iQIcBAEBCgAGBQJTJoRCAAoJEBTzwpg4iwmNoNsP/Rw6Ej02gYd7yQm7eeH3PwEF 9282MSc1RWxDy87s90prHw1ZXxnyra52ZQoYDeMzhA+uhfdkTNtwhyz1aL3gyfRW vevLNapE/VavAB7rrcEWqGVCw7Z0rCWHeChMHwiv9EATiydcDNw2k4BmWSd1m+d/ 4vVrCHQv1lBEicYeMgS9zXGLVGMel7pIBs22vV0k19xPNLu0cK4vIvqXTxQlrqx5 w92Q93/Bchdl20VoiZzZoDOHaEAaWGPAg35drzSuGZ5nBvTsMjzZmdmJdKRdhfrd rgzPZU3mffzEI78Rj0H+z+kLC9cZ85U3iQVoSOlALTtzSxEwYgZWjSNxpe3SWVZV GAM2UlUlsYIVXVo0L+EGwfvJa+OiCn2tTYWxNwbf07VxR8hmwJqvISLJ4QILL6Sx sAXgRSeqHexGdDK832hSXLy5nCocBMtC5SgaS3BE/n6WZnvdaFWVL87ViSTx5pC5 f5pY6x4DjuFGi2nRC6FyXy0+23+yk5kBr3MuxusPpzXPxcjbP/TmGXvxu/2s9oB5 tsyJS4nXsp8ambA5UwCBcRKPlzRDDjUGLqA9WplyOCMDR6oCl4cfph7tiICcCrjx uJhPPQWp5J42nFp1PebKmOkVGunaYiQkVjAYIhMn70YroCR60bZaGqhHOXBvhpMT ck3jWdCTjTDQ0ln0Qj+K =uRMT -----END PGP SIGNATURE----- --Apple-Mail=_A289E2C4-4BD2-4681-9ABA-0FB1EA3E425A--