From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrea Corallo via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#45751: [feature/native-comp] emacs keeps running 100% of CPU Date: Mon, 11 Jan 2021 10:17:09 +0000 Message-ID: References: <87k0slu13n.fsf@gmail.com> <87im84jsu0.fsf@gmail.com> <87h7nojsll.fsf@gmail.com> Reply-To: Andrea Corallo Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6364"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 45751@debbugs.gnu.org To: =?UTF-8?Q?=C3=89douard?= Debry Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jan 11 11:18:20 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kyuHD-0001av-OI for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 11 Jan 2021 11:18:19 +0100 Original-Received: from localhost ([::1]:48056 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kyuHC-0002Fe-Jp for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 11 Jan 2021 05:18:18 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58790) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kyuGw-0002FJ-3E for bug-gnu-emacs@gnu.org; Mon, 11 Jan 2021 05:18:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:44178) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kyuGv-00067z-RF for bug-gnu-emacs@gnu.org; Mon, 11 Jan 2021 05:18:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kyuGv-0006dE-N9 for bug-gnu-emacs@gnu.org; Mon, 11 Jan 2021 05:18:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Andrea Corallo Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 11 Jan 2021 10:18:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 45751 X-GNU-PR-Package: emacs Original-Received: via spool by 45751-submit@debbugs.gnu.org id=B45751.161036023225426 (code B ref 45751); Mon, 11 Jan 2021 10:18:01 +0000 Original-Received: (at 45751) by debbugs.gnu.org; 11 Jan 2021 10:17:12 +0000 Original-Received: from localhost ([127.0.0.1]:55722 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kyuG7-0006c2-Lm for submit@debbugs.gnu.org; Mon, 11 Jan 2021 05:17:11 -0500 Original-Received: from mx.sdf.org ([205.166.94.24]:64924) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kyuG6-0006bu-6U for 45751@debbugs.gnu.org; Mon, 11 Jan 2021 05:17:10 -0500 Original-Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTP id 10BAH98C024215; Mon, 11 Jan 2021 10:17:09 GMT In-Reply-To: <87h7nojsll.fsf@gmail.com> ("=?UTF-8?Q?=C3=89douard?= Debry"'s message of "Mon, 11 Jan 2021 00:10:46 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:197679 Archived-At: =C3=89douard Debry writes: > On lun., janv. 11 2021, =C3=89douard Debry wrote: >> On dim., janv. 10 2021, Andrea Corallo wrote: >>> =C3=89douard Debry writes: >>> >>>> I noticed that when launching emacs on linux (debian buster), >>>> it keeps on running 100% of the CPU and seems to gradually eat all >>>> memory, approximately 1-2% every minute. >>>> >>>> It seems related to native compiling. In the >>>> *Async-native-compile-log* I read : >>>> >>>> <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D> >>>> Compiling >>>> /home/edouard/.emacs.d/elpa/color-theme-sanityinc-solarized-20200805.6= 03/color-theme-sanityinc-solarized.el... >>> >>> I see a similar issue with sanityinc-tomorrow.el, the compilation >>> is way >>> slower than any other one but it completes eventually. I guess is >>> the >>> same issue you see and with sufficient RAM also sanityinc-solarized >>> should complete. >>> >>> In case of of sanityinc-tomorrow I think is because of >>> `color-theme-sanityinc-tomorrow'. This is a single function that >>> after >>> macro expansion becomes enormous. >>> >>> We need to make the compiler robust against these corner cases, >>> I'll >>> have a look this week into adding some logic for that. >>> >>> Thanks >>> >>> Andrea >> >> I have waited for approximately one hour and until linux became >> totally unresponsive, I >> had to reboot. >> >> I am not 100% sure it is because of emacs compiling the color theme >> package and eating >> all memory, >> but I never had such a crash on linux since I own this laptop and I >> had exactly the same >> crash on >> windows 10 with emacs native-comp eating all memory. >> >> So most probably, my previous bug is related to that. I could try >> another theme and see >> if this still happens. >> >> Regards > > Also, is there a way to prevent emacs native-comp to compile some > packages, some kind > of blacklist. I would prefer at the moment because I am used to this > color theme. Yes, `comp-deferred-compilation-deny-list'. > Do you think there may be a noticeable difference on emacs's > performance between a > color theme natively compiled (*eln) or just byte compiled (*elc) I don't think so. Andrea