From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: npostavs@users.sourceforge.net Newsgroups: gmane.emacs.bugs Subject: bug#25122: 24.5; function describe-variable hangs on large variables Date: Sun, 12 Mar 2017 10:15:21 -0400 Message-ID: <87wpbu7f9i.fsf@users.sourceforge.net> References: <20161206022112.GF25778@E15-2016.optimum.net> <87twahk19y.fsf@gmail.com> <87d1h4fld5.fsf@users.sourceforge.net> <871sxkyv2m.fsf@gmail.com> <87mvcs8j7w.fsf@users.sourceforge.net> <87lgsbtxwe.fsf@gmail.com> <871su38ogm.fsf@users.sourceforge.net> <87d1dnrq96.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1489328117 13373 195.159.176.226 (12 Mar 2017 14:15:17 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 12 Mar 2017 14:15:17 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) Cc: 25122@debbugs.gnu.org, Stefan Monnier , Boruch Baum To: Thierry Volpiatto Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Mar 12 15:15:13 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cn4H6-0002CI-QX for geb-bug-gnu-emacs@m.gmane.org; Sun, 12 Mar 2017 15:15:09 +0100 Original-Received: from localhost ([::1]:47193 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cn4H9-0008F8-O6 for geb-bug-gnu-emacs@m.gmane.org; Sun, 12 Mar 2017 10:15:11 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40420) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cn4H3-0008Dm-W9 for bug-gnu-emacs@gnu.org; Sun, 12 Mar 2017 10:15:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cn4H0-0007Ky-R2 for bug-gnu-emacs@gnu.org; Sun, 12 Mar 2017 10:15:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:54538) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cn4H0-0007Ks-Mb for bug-gnu-emacs@gnu.org; Sun, 12 Mar 2017 10:15:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cn4H0-0004T7-DS for bug-gnu-emacs@gnu.org; Sun, 12 Mar 2017 10:15:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: npostavs@users.sourceforge.net Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 12 Mar 2017 14:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25122 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 25122-submit@debbugs.gnu.org id=B25122.148932805117108 (code B ref 25122); Sun, 12 Mar 2017 14:15:02 +0000 Original-Received: (at 25122) by debbugs.gnu.org; 12 Mar 2017 14:14:11 +0000 Original-Received: from localhost ([127.0.0.1]:52737 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cn4GB-0004Rs-Il for submit@debbugs.gnu.org; Sun, 12 Mar 2017 10:14:11 -0400 Original-Received: from mail-it0-f65.google.com ([209.85.214.65]:34260) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cn4G9-0004Re-HX for 25122@debbugs.gnu.org; Sun, 12 Mar 2017 10:14:09 -0400 Original-Received: by mail-it0-f65.google.com with SMTP id r141so3726640ita.1 for <25122@debbugs.gnu.org>; Sun, 12 Mar 2017 07:14:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=xgoXNydUtUDM2TayMQIfCGeVsCvc/CU9OpEMFeNKjos=; b=NgT5LgjQ1l6k1qCnZfxFZPRMZNjFZmQc4Nn5jJDMfKGIuPLcRQUzZoaTVGc+YIenS2 deJBoQT0cqUZ7MoN9AFo1tWkv3J2+38EY5RZ1QCur1vPQgguP0Hti5JkHp9C+ahm529/ Ug/92Znq4yWRerMHgMe3pW+URaaOjhvaS3QqOzFgMkt/oPxrN6nkhMicsKTdm063xAVy 4/lbj2SwIOKZ6++3i4lZKJdPYEgfMlZa3jHostxopfi8Jq59IumY1ntckYxMxxSQNC+k ADwReiZ7KW+m7WPBWLlIdUCebKyHauvoCsp8I3iUMyLxpkiLQ5IHepdHNj7DMe6ne2pD kn4Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:references:date :in-reply-to:message-id:user-agent:mime-version; bh=xgoXNydUtUDM2TayMQIfCGeVsCvc/CU9OpEMFeNKjos=; b=Jm0DpIC1x+YxbYkppUpC1fzDVYaHy3gOqSCT9FnJMHnPP7/T6KG9vP1BjHq30TzF9a Ph9+qTSIuklL1GM3piMfI3hKNi9oqpazSVBfXN0DDyzh+rS2q+tAu6OkLGZT50fIGQqs Oi2OK4ZyvuC8jPQhdmDWyN5BQnI2Vb5KiPOlvstEKeuOOahEab4S1gA+GaxEGOyejskO g6JpU4B1S6eFfREeofDWK7yZVV7A4VNMZfQRKvLbdd/a0GOCk5E678InGjbCWmSqStC3 4uHJZs4zlpGoX/YDcPs/mQ91fZDhlt6HsjM5zngbSRlB3PublquvVFYen0QDYd4OTjnP IZVg== X-Gm-Message-State: AFeK/H0ELY0mCJKGgGgdDbr1hx6S2WV1SK9G6jYcXe8kxNphI03DYYKfRsdT67Re+ZE5uQ== X-Received: by 10.36.54.149 with SMTP id l143mr6563665itl.38.1489328044067; Sun, 12 Mar 2017 07:14:04 -0700 (PDT) Original-Received: from zony ([45.2.7.65]) by smtp.googlemail.com with ESMTPSA id v197sm2747541ita.2.2017.03.12.07.14.03 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 12 Mar 2017 07:14:03 -0700 (PDT) In-Reply-To: <87d1dnrq96.fsf@gmail.com> (Thierry Volpiatto's message of "Sun, 12 Mar 2017 06:57:41 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:130515 Archived-At: Thierry Volpiatto writes: > npostavs@users.sourceforge.net writes: > >> and suspend it after printing X lines. > > Instead just print something like "Computing foo value ..." and let finish > the thread, letting user reading and moving cursor in docstring while it > finishes, once done save-excursion and send message "Computing foo value > done". Threads aren't truly parallel. The user can't do anything while the thread is running. > >> Then hitting RET on "..." would just print another X lines. > > I think like Drew that this would be annoying. I wonder if we could just hook this into scrolling somehow? So the lines would only be printed when you scroll to look at them. > > That said, what's the reason of choosing the slower approach to compute > value (in a thread or not) instead of using the approach described in > the advice I sent here which takes 1s to compute load-history instead of > 3mn ? (I use this advice since one year now without any problems). As mentioned in https://debbugs.gnu.org/cgi/bugreport.cgi?bug=21717#8, it breaks circularity. Try describing this variable: (defvar circular-list (let ((l (number-sequence 1 100))) (setcdr (last l) l) l) "A circular list that has problems with (mapc 'pp val).") We could probably achieve something similar without breaking circular printing by not calling indent-sexp on the full list, but 1s is longer than "instant" anyway (which is about 50ms or less) which is why I'm exploring other options.