From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#21077: 24.5; Slow printing in inferior python buffer with python-shell-enable-font-lock Date: Mon, 03 Aug 2015 17:41:24 -0400 Message-ID: References: <83615k6jf7.fsf@gnu.org> <834ml37v7a.fsf@gnu.org> <83380n6zrn.fsf@gnu.org> <85oair5gex.fsf@iznogoud.viz> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1438638148 7084 80.91.229.3 (3 Aug 2015 21:42:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 3 Aug 2015 21:42:28 +0000 (UTC) Cc: 21077@debbugs.gnu.org, Ista Zahn To: Wolfgang Jenkner Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Aug 03 23:42:12 2015 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 1ZMNUo-0001Ds-Kg for geb-bug-gnu-emacs@m.gmane.org; Mon, 03 Aug 2015 23:42:10 +0200 Original-Received: from localhost ([::1]:60589 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMNUo-0000vj-65 for geb-bug-gnu-emacs@m.gmane.org; Mon, 03 Aug 2015 17:42:10 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58747) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMNUj-0000qL-Gy for bug-gnu-emacs@gnu.org; Mon, 03 Aug 2015 17:42:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZMNUg-0005Mp-Qy for bug-gnu-emacs@gnu.org; Mon, 03 Aug 2015 17:42:05 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:37239) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMNUg-0005Mj-Nr for bug-gnu-emacs@gnu.org; Mon, 03 Aug 2015 17:42:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1ZMNUg-0006Ve-CT for bug-gnu-emacs@gnu.org; Mon, 03 Aug 2015 17:42:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 03 Aug 2015 21:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21077 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 21077-submit@debbugs.gnu.org id=B21077.143863809024985 (code B ref 21077); Mon, 03 Aug 2015 21:42:02 +0000 Original-Received: (at 21077) by debbugs.gnu.org; 3 Aug 2015 21:41:30 +0000 Original-Received: from localhost ([127.0.0.1]:38685 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZMNUA-0006Uv-1a for submit@debbugs.gnu.org; Mon, 03 Aug 2015 17:41:30 -0400 Original-Received: from smtp-as-01.vtxnet.net ([194.38.175.130]:60351) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZMNU8-0006Un-Gj for 21077@debbugs.gnu.org; Mon, 03 Aug 2015 17:41:29 -0400 Original-Received: from smtp-as-01.vtxnet.net (localhost [127.0.0.1]) by smtp-as-01.vtxnet.net (Postfix) with ESMTP id 4F43D5DFAD; Mon, 3 Aug 2015 23:41:27 +0200 (CEST) Original-Received: from smtp-pri-03.vtxnet.net (smtp-pri-03-1.vtxnet.net [212.147.62.147]) by smtp-as-01.vtxnet.net (Postfix) with ESMTP id 6F7295DFAC; Mon, 3 Aug 2015 23:41:25 +0200 (CEST) Original-Received: from localhost (unknown [127.0.0.1]) by smtp-pri-03.vtxnet.net (VTX Services SA) with ESMTP id 6D00768B82C; Mon, 3 Aug 2015 21:41:25 +0000 (UTC) Original-Received: from smtp-pri-03.vtxnet.net ([212.147.62.147]) by localhost (smtp-pri-03.vtxnet.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CPc3SXuMzJA6; Mon, 3 Aug 2015 23:41:24 +0200 (CEST) Original-Received: from fmsmemgm.homelinux.net (dyn.83-228-180-068.dsl.vtx.ch [83.228.180.68]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp-pri-03.vtxnet.net (VTX Services SA) with ESMTP id 88A9068B7E8; Mon, 3 Aug 2015 23:41:24 +0200 (CEST) Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id 1FB4CAE148; Mon, 3 Aug 2015 17:41:24 -0400 (EDT) In-Reply-To: <85oair5gex.fsf@iznogoud.viz> (Wolfgang Jenkner's message of "Sat, 01 Aug 2015 14:42:14 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) 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:105293 Archived-At: >> In the case of comint modes, rather than disable font-lock we should >> refrain from font-locking the text after the last \n (since that's the >> line that keeps getting expanded, so we end up re-font-locking it O(N) >> times for a line of length N, for a total amount of work of O(N^2)). >> IIRC I have a similar hack in grep.el or compile.el. > But comint-output-filter does > (font-lock-prepend-text-property prompt-start (point) > 'font-lock-face > 'comint-highlight-prompt) > So keyword fontification seems to be inhibited anyway. Is this done in > a particularly inefficient way? That doesn't inhibit keyword fontification per se. It just makes most keyword rules ineffective, but the test is done after the hard work anyway, so in a way yes, it's done in an inefficient way (tho skipping some keywords by checking font-lock-face would in general be even more inefficient). Stefan