Debian Bug report logs - #389476
xterm: ansi color slows scrolling down

version graph

Package: xterm; Maintainer for xterm is Debian X Strike Force <debian-x@lists.debian.org>; Source for xterm is src:xterm.

Reported by: friedel@nomaden.org

Date: Mon, 25 Sep 2006 22:48:38 UTC

Severity: minor

Found in version xterm/210-3

Reply or subscribe to this bug.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Debian X Strike Force <debian-x@lists.debian.org>:
Bug#389476; Package xterm. Full text and rfc822 format available.

Acknowledgement sent to friedel@nomaden.org:
New Bug report received and forwarded. Copy sent to Debian X Strike Force <debian-x@lists.debian.org>. Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Friedrich Delgado Friedrichs <friedel@nomaden.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: xterm: ansi color slows scrolling down
Date: Tue, 26 Sep 2006 00:22:45 +0200
Package: xterm
Version: 210-3
Severity: minor


I've noticed that there is a considerable slowdown in scrolling speed
when lines contain ansi-color codes that change the background (!)
colour.

This slowdown is hardly noticeable on a reasonably fast machine, but
on my trusty old toshiba libretto (only 266 Mhz, but I'll never part
with it) listing a directory with 200 files with ls --color=yes is
unbearably slow.

This must have crept in a few updates ago, I can't remember scrolling
being that slow on the laptop before. It's not fixed in 210-3.1
(tested on the laptop, uses same distribution and software, but
neomagic display hardware) and not in upstream (220) either.

The following loop in a bash tests that behaviour:

bogomips=`grep bogomips /proc/cpuinfo|tail -1|cut -f2 -d:|cut -f1 -d.`; wallclock=`date +%s`;i=0; while [ $i -lt $bogomips ]; do echo -e "\033[47m$i\033[00m"; i=$(($i + 1)); done; echo $((`date +%s` - $wallclock)) seconds

Outputs numbers up to $bogomips with white background. Will take about
10 seconds on my athlon 550 at home and the machines at work (intel
2800 mhz), and about 55 seconds on my laptop. I assume something
causes additional sluggishness on the laptop (maybe the display
driver? There's an old bug at
https://bugs.freedesktop.org/show_bug.cgi?id=1877 which might be
related).

The slowdown only happens when the background colour is changed, so if
you change the first escape sequence in the echo string to e.g.
"\033[31m" (red foreground) the whole loop takes about 1 second.

Also there is no slowdown in rxvt, on any machine.

I think this should probably be forwarded to upstream but I'd like it
to be in the debian BTS nonetheless.

Finally I manage to hit a bug that is actually reproducible! :)

Kind regards
     Friedel
-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (990, 'unstable'), (500, 'testing'), (500, 'stable'), (1, 'experimental')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.17-2-k7
Locale: LANG=de_DE.utf8, LC_CTYPE=de_DE.utf8 (charmap=UTF-8) (ignored: LC_ALL set to de_DE.utf8)

Versions of packages xterm depends on:
ii  libc6                        2.3.6.ds1-4 GNU C Library: Shared libraries
ii  libfontconfig1               2.3.2-7     generic font configuration library
ii  libice6                      1:1.0.0-3   X11 Inter-Client Exchange library
ii  libncurses5                  5.5-2       Shared libraries for terminal hand
ii  libsm6                       1:1.0.0-4   X11 Session Management library
ii  libx11-6                     2:1.0.0-8   X11 client-side library
ii  libxaw7                      1:1.0.2-4   X11 Athena Widget library
ii  libxext6                     1:1.0.1-2   X11 miscellaneous extension librar
ii  libxft2                      2.1.8.2-8   FreeType-based font drawing librar
ii  libxmu6                      1:1.0.1-3   X11 miscellaneous utility library
ii  libxt6                       1:1.0.0-5   X11 toolkit intrinsics library
ii  xbitmaps                     1.0.1-2     Base X bitmaps

Versions of packages xterm recommends:
ii  xutils                        1:7.1.ds-1 X Window System utility programs

-- no debconf information



Information forwarded to debian-bugs-dist@lists.debian.org, Debian X Strike Force <debian-x@lists.debian.org>:
Bug#389476; Package xterm. Full text and rfc822 format available.

Acknowledgement sent to dickey@his.com:
Extra info received and forwarded to list. Copy sent to Debian X Strike Force <debian-x@lists.debian.org>. Full text and rfc822 format available.

Message #10 received at 389476@bugs.debian.org (full text, mbox):

From: Thomas Dickey <dickey@his.com>
To: 389476@bugs.debian.org
Subject: re: #389476 xterm: ansi color slows scrolling down
Date: Thu, 30 Nov 2006 20:36:21 -0500
[Message part 1 (text/plain, inline)]
I think this is due to the way xterm is managing graphic contexts,
and have in mind a way to improve that (perhaps in xterm #224).

-- 
Thomas E. Dickey <dickey@invisible-island.net>
http://invisible-island.net
ftp://invisible-island.net
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian X Strike Force <debian-x@lists.debian.org>:
Bug#389476; Package xterm. (Sun, 09 Aug 2009 22:06:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to dickey@his.com:
Extra info received and forwarded to list. Copy sent to Debian X Strike Force <debian-x@lists.debian.org>. (Sun, 09 Aug 2009 22:06:02 GMT) Full text and rfc822 format available.

Message #15 received at 389476@bugs.debian.org (full text, mbox):

From: Thomas Dickey <dickey@his.com>
To: 389476@bugs.debian.org
Subject: re: #389476 xterm: ansi color slows scrolling down
Date: Sun, 09 Aug 2009 18:03:44 -0400
[Message part 1 (text/plain, inline)]
I've made some improvements since #210 (about 30%, for the GC caching
which I referred to in the last item).  Any further improvements would
do what rxvt does - simply do not output changes to the screen (there are
pros/cons for that).

-- 
Thomas E. Dickey <dickey@invisible-island.net>
http://invisible-island.net
ftp://invisible-island.net
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian X Strike Force <debian-x@lists.debian.org>:
Bug#389476; Package xterm. (Tue, 22 Nov 2011 21:45:08 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jim Paris <jim@jtan.com>:
Extra info received and forwarded to list. Copy sent to Debian X Strike Force <debian-x@lists.debian.org>. (Tue, 22 Nov 2011 21:45:10 GMT) Full text and rfc822 format available.

Message #20 received at 389476@bugs.debian.org (full text, mbox):

From: Jim Paris <jim@jtan.com>
To: 389476@bugs.debian.org
Subject: Scrolling with background colors is still much slower
Date: Tue, 22 Nov 2011 16:37:30 -0500
Hi,

Xterm is still *really* slow for me when background colors are set;
it's if jump-scrolling is disabled.  For example:

$ time xterm -geometry 80x25 -e 'for i in `seq 1 10000`; do echo -e "This is line \e[40;31;01m$i\e[0m" ; done'

real    0m23.052s
user    0m1.396s
sys     0m1.148s

$ time xterm -geometry 80x25 -e 'for i in `seq 1 10000`; do echo -e "This is line \e[31;01m$i\e[0m" ; done'

real    0m0.781s
user    0m0.400s
sys     0m0.116s


-jim




Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Apr 16 04:32:18 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.