From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jim Porter Newsgroups: gmane.emacs.bugs Subject: bug#71355: 30.0.50; [PATCH] Improve performance of buffered output in Eshell Date: Thu, 6 Jun 2024 11:02:59 -0700 Message-ID: <066f89aa-4026-b5fd-e529-12e70360bed6@gmail.com> References: <22b0dc8f-11dc-5fd2-c75d-88c17580d28d@gmail.com> <848772e9-5ef0-8a8a-decd-c0b79366ec27@gmail.com> <86ikynk30i.fsf@gnu.org> <037ebce9-93af-f1ad-67d9-550fd1074294@gmail.com> <8634prjpt0.fsf@gnu.org> <9da5a395-48e8-fb20-145b-1d2581315fcf@gmail.com> <86y17ji860.fsf@gnu.org> <86v82ni5dd.fsf@gnu.org> <7f6b9173-e16f-c65d-8758-8ca7098876b7@gmail.com> <86r0daistt.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21308"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71355@debbugs.gnu.org, stefankangas@gmail.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jun 06 20:05:16 2024 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 1sFHUC-0005OL-8t for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 06 Jun 2024 20:05:16 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sFHTm-00006x-90; Thu, 06 Jun 2024 14:04:50 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sFHTk-00006f-On for bug-gnu-emacs@gnu.org; Thu, 06 Jun 2024 14:04:48 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sFHTj-0008Cc-RD for bug-gnu-emacs@gnu.org; Thu, 06 Jun 2024 14:04:48 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sFHTy-0007uz-Fv for bug-gnu-emacs@gnu.org; Thu, 06 Jun 2024 14:05:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 06 Jun 2024 18:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71355 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 71355-submit@debbugs.gnu.org id=B71355.171769706530334 (code B ref 71355); Thu, 06 Jun 2024 18:05:02 +0000 Original-Received: (at 71355) by debbugs.gnu.org; 6 Jun 2024 18:04:25 +0000 Original-Received: from localhost ([127.0.0.1]:59758 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sFHTM-0007t6-61 for submit@debbugs.gnu.org; Thu, 06 Jun 2024 14:04:25 -0400 Original-Received: from mail-pl1-f177.google.com ([209.85.214.177]:42230) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sFHTK-0007sj-It for 71355@debbugs.gnu.org; Thu, 06 Jun 2024 14:04:22 -0400 Original-Received: by mail-pl1-f177.google.com with SMTP id d9443c01a7336-1f612d7b0f5so8496385ad.0 for <71355@debbugs.gnu.org>; Thu, 06 Jun 2024 11:04:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1717696982; x=1718301782; darn=debbugs.gnu.org; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=EH0HDZHZQbl+hIJaAFKRZ+QyZjXhi0EjMcxo0flyfLw=; b=ipHvXveRUZTOmwWerrQHjJI6cfXCciYNTZ8wMYAkztcajgjnCnboaXpZe5Kv1yFJjd ktbYUtyveXrcjTuueytQHYBdUV8is2SXSgWqk4dIgjk3/+0CMX1fo98ehWtHbhwK1Rx3 aJtPh0BWYWU712uGzg6Wl+ggIoRf4W9I0UZ5Puz0eDOCOljO242fJb81DA+2YGa+UALH RW09WWXCf/Fdq6YJY39EOMJqq1/9ilaejrcz07WTUysY7u8MM+q1svrEXnLwnLf5FZYM OEy2zHFIUUtGScfGGqELj/r1SlKx2K5J7dvbkSohCDi8PcOZIQLVW3iOnqCWq1K3ks37 2q7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717696982; x=1718301782; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=EH0HDZHZQbl+hIJaAFKRZ+QyZjXhi0EjMcxo0flyfLw=; b=XQVXG13/uOqmDsNk9WDqANvTG0KMkLHD59os7ayF20zajmivzob4fkrOVI3uNehMif 14OafbScxZPmO442nxoVtlCjb7kxX36qQDW7GokPbSVtgDtEgub22TCJBwDfMz4h2y0V 1AeGRPyTmNkSRiSybBbzkY0aymaK/BozAj4nGqXeWZxt+IcUHMUw0Ebnf6hRCB+0eT9M emcNDqxP1z2IyXMxuqsYT8uQ+nrw0OBghPxQypa9Rr6gwBgEwaToI/7N2Z7g7f+urxc6 NdHv8bZdtB6sQGw5I9IxmY8k99R6b7DRnrCQRxLCIY+Sd7QXdPOCKX6WZpeDa6Iqdi8N b+4g== X-Gm-Message-State: AOJu0Yz17Gtn5fVwwYGPr1G239pksD4BKxHY+Y2tu6Fvwvqk6Mcm8uXT q9k9eRB2nuPmAIOuqg4lz1ss0nwBA85V2KWQrF6eG/jqewScOhD1 X-Google-Smtp-Source: AGHT+IE563AnUG4BMsH62N9xPFW6TtO88DHqkpM+h7Cjb33cJ20/Cp2az4zDXJCSuw1IQ+fmZqywKg== X-Received: by 2002:a17:902:a386:b0:1f3:81c:c17 with SMTP id d9443c01a7336-1f6d019f382mr4470625ad.23.1717696981826; Thu, 06 Jun 2024 11:03:01 -0700 (PDT) Original-Received: from [192.168.1.2] (syn-023-240-098-037.res.spectrum.com. [23.240.98.37]) by smtp.googlemail.com with ESMTPSA id d9443c01a7336-1f6bd7cd029sm18150805ad.137.2024.06.06.11.03.00 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 06 Jun 2024 11:03:01 -0700 (PDT) Content-Language: en-US In-Reply-To: <86r0daistt.fsf@gnu.org> 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:286715 Archived-At: On 6/5/2024 9:43 PM, Eli Zaretskii wrote: > My main point is that 'cat' is used to show the contents of a file to > the user, so the assumption is that the user _wants_ to see that > stuff. So having the stuff flash before user's eyes in an instant is > not necessarily the best idea, even though it is faster, and thus > performance-wise we win. For "cat" specifically, I think what we want is just to finish as fast as we can so that Eshell hands control back to the Emacs command loop, and then the user can start examining the output. (For example, by pressing C-c C-r to go to the beginning of the output, or using the "Smart" module[1].) > If the above is agreed, and you still think 2K characters is the best > default value, I'm fine with that. Agreed. I'd definitely like to improve the usability for dealing with long-running commands or ones that output a lot of text in Eshell. I think that's a separate task though. (For example, the text flashing before the user's eyes also happens when running the external /usr/bin/cat, and I haven't touched that code path here. A fix for that behavior would go elsewhere so that both the internal and external cats could benefit.) [1] I don't use the Smart module so I don't know a ton about it, but it avoids scrolling the output as it comes in and stays at the beginning.