From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: XeCycle Newsgroups: gmane.emacs.help Subject: Re: Performance problems (CPU 100%) with NULs in files Date: Thu, 22 Sep 2011 14:09:46 +0800 Message-ID: <87k491kt05.fsf@gmail.com> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: dough.gmane.org 1316671816 20022 80.91.229.12 (22 Sep 2011 06:10:16 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 22 Sep 2011 06:10:16 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Sep 22 08:10:13 2011 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1R6cU9-0001eu-0u for geh-help-gnu-emacs@m.gmane.org; Thu, 22 Sep 2011 08:10:13 +0200 Original-Received: from localhost ([::1]:57478 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6cU8-0006Kn-Dw for geh-help-gnu-emacs@m.gmane.org; Thu, 22 Sep 2011 02:10:12 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:45299) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6cU3-0006Im-Lg for help-gnu-emacs@gnu.org; Thu, 22 Sep 2011 02:10:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R6cU2-0003sf-Br for help-gnu-emacs@gnu.org; Thu, 22 Sep 2011 02:10:07 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:55322) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6cU1-0003rH-WA for help-gnu-emacs@gnu.org; Thu, 22 Sep 2011 02:10:06 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1R6cU0-0001bz-7d for help-gnu-emacs@gnu.org; Thu, 22 Sep 2011 08:10:04 +0200 Original-Received: from 211.80.81.186 ([211.80.81.186]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 22 Sep 2011 08:10:04 +0200 Original-Received: from xecycle by 211.80.81.186 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 22 Sep 2011 08:10:04 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 58 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 211.80.81.186 User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) Cancel-Lock: sha1:LeBLuWUgY/GEV99Q15kZaJAY5QM= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 80.91.229.12 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:82287 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable "Ludwig, Mark" writes: > I frequently encounter data files that are supposed to be 100% > ASCII but contain long sequences of NUL characters (ASCII zero). > (The reasons are out of my control.) > > When I first started using EMACS [sic] in 1980, I was delighted > to find it served as a very fine binary file editor.=C2=A0 It seems > that modern Emacs no longer is a fine binary file =E2=80=93 at least not > by default. > > What happens is that as I scroll through the file, when the NULs > are visible, Emacs gets into some intensive processing for a long > time (minutes, sometimes!).=C2=A0 It eventually unwinds and repaints > the display, but any movement of point sends it into this loop > again.=C2=A0 I have found that M-< or M-> will quickly reposition away > from the problem (assuming the beginning and/or end of the file > do not contain NULs).=C2=A0 Most other movement operations send it > into the loop. > > I understand about encodings, and have messed around with forcing > it into us-ascii, but it appears not to be related to this CPU > consumption problem.=C2=A0 Does anyone know how to solve this?=C2=A0 I=E2= =80=99ll > file a bug report if this is a legitimate bug.=C2=A0 I=E2=80=99m just > concerned that it=E2=80=99s a =E2=80=9Cfeature=E2=80=9D of some sort, tho= ugh I hope not. > > Thanks! > Mark What about trying `hexl-mode'? =2D-=20 Carl Lei (XeCycle) Department of Physics, Shanghai Jiao Tong University OpenPGP public key: 7795E591 Fingerprint: 1FB6 7F1F D45D F681 C845 27F7 8D71 8EC4 7795 E591 --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iQEcBAEBAgAGBQJOetEqAAoJEI1xjsR3leWRmJ8H/0p1gCIyXn4aeC/+SOLjUaJo GNb/hAsUBh5c+pnH54gNTYYiYydOD4pgvkuTERwfgPLZu6GYVw5mGcYBoSlkFD5R cIkD3+3IPqTmAHz85E0FqZbuDRCzqzJSee+xUdAnnTMCA5mRR6q2uidWNLKiMKWU OEExiWwaEkqecP6vzAdly5QGXt7iEvnYKBCBJwmPFvou88dszC4aXWX/DfOJD05M 0kuOpICjZ+XJZNNUAcBqts9fQQpi0Qj1MFdczWSl6dnyekxYKwLz6fzek3Hgxn8e n2jZjxEV9mPRHqkI189VyrYKQiDTSiLU33o18Q0sUr26g9IgB8kAVdVgXacb7aw= =ceIc -----END PGP SIGNATURE----- --=-=-=--