From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Kangas Newsgroups: gmane.emacs.bugs Subject: bug#57367: [PATCH] Speed up em-smart Date: Wed, 6 Sep 2023 15:46:28 -0700 Message-ID: References: <87r10q6byc.fsf@gnus.org> <9257e0e5-232e-7e20-f4d1-385066c4337e@gmail.com> <87bkrtxzfj.fsf@gnus.org> <87ilm0x1ol.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22485"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Morgan Smith , Lars Ingebrigtsen , 57367@debbugs.gnu.org To: Jim Porter Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Sep 07 00:47:13 2023 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 1qe1In-0005fc-0T for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 07 Sep 2023 00:47:13 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qe1Ic-0002Bi-Ol; Wed, 06 Sep 2023 18:47:02 -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 1qe1Ia-0002BH-Pm for bug-gnu-emacs@gnu.org; Wed, 06 Sep 2023 18:47:00 -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 1qe1Ia-0003b6-HD for bug-gnu-emacs@gnu.org; Wed, 06 Sep 2023 18:47:00 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qe1Ib-0001j3-QA for bug-gnu-emacs@gnu.org; Wed, 06 Sep 2023 18:47:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 06 Sep 2023 22:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57367 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo patch Original-Received: via spool by 57367-submit@debbugs.gnu.org id=B57367.16940403986601 (code B ref 57367); Wed, 06 Sep 2023 22:47:01 +0000 Original-Received: (at 57367) by debbugs.gnu.org; 6 Sep 2023 22:46:38 +0000 Original-Received: from localhost ([127.0.0.1]:38087 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qe1IE-0001iN-0u for submit@debbugs.gnu.org; Wed, 06 Sep 2023 18:46:38 -0400 Original-Received: from mail-lf1-x12f.google.com ([2a00:1450:4864:20::12f]:45448) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qe1IC-0001iA-9x for 57367@debbugs.gnu.org; Wed, 06 Sep 2023 18:46:36 -0400 Original-Received: by mail-lf1-x12f.google.com with SMTP id 2adb3069b0e04-501eec0a373so454518e87.3 for <57367@debbugs.gnu.org>; Wed, 06 Sep 2023 15:46:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1694040389; x=1694645189; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=kZZFM+6NAS4kgZGz7WwJYLwGFyzEq94XfIdnSZ+bt3I=; b=MurjP+BatKPhBLuj89p1R/+xSOIb8WO2dkEt0H747YeEDWa2hvrguTbHQa9jdTOgtL Qpe/YQYNeZkkkY5IEzJHwI+AmFFZTy4vWNLIRyMsMkkqAK6D2snDgjaAihcH8adt1BKI 04UOxRl4eNqpoYcawJyRdb5zh3jFF58FaIvXK9riNUDZ+cBGWMxWfyAGtKgyGtaTeCU1 vvH1ZNSNZt/apof4KHIoXuXitJk2eFI0GwIQsHjl3dcGUSe85crt8LYBDjHF2Rck7EyQ 8uJCqug5T+SGTa53hdZlGw2SwtT/ixrGBcos5+v0/SA9dlOnzZERi7NaK08FvxRhxT9X e8Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1694040389; x=1694645189; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=kZZFM+6NAS4kgZGz7WwJYLwGFyzEq94XfIdnSZ+bt3I=; b=XVlNSGajdSwBcKlNQAhh8CFpvjs4Ue2tEYUk/GMlfR+mE7oDLFdb3ZLP31xA8wS0TI 6THLobO+7J58xDb8O0w4GgGKEN0KK1znCMqUttfDpfiBuwn0icr/1hCGFa8ZI0vJXU9H KpkMHr7CR7Bp1eHQaXJZhR7JiGxTDMvRMH3QYUD8CZz7fYVOKLJP9ge0Q1wN3fhXyofP 9s17LYn0iBtfGciZPBLvUiYBcImFX3w2c7qKjj4Uf6egdZZ9IFDwAnsLB96f/BQfnW95 YNDsdW7DDCDA1Krx1/NVWZ8CDUQjtuOGMmqFTFhp5XMIu0xlr1B1vIDZSEDuhz96kQ5N 4uzw== X-Gm-Message-State: AOJu0YzduA1MhYY7E1kD6i3+7IR4LPtAdqz5tnEn7PMN6lYlZFYlnckG 24GltssxSZu7gmSBH9i0PVgFPUFEweAfNis+7Ls= X-Google-Smtp-Source: AGHT+IEoHNNiJ7EVWKNF7fHlUH9+ZG1Vrhob+lFWn5Sn+c3958DcQfm/9cXhqYW7MumanKNON6A7HeuiDfpCrVrgeJI= X-Received: by 2002:ac2:4d0b:0:b0:500:bb99:69a6 with SMTP id r11-20020ac24d0b000000b00500bb9969a6mr3808768lfi.39.1694040388879; Wed, 06 Sep 2023 15:46:28 -0700 (PDT) Original-Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Wed, 6 Sep 2023 15:46:28 -0700 In-Reply-To: (Jim Porter's message of "Thu, 8 Sep 2022 21:36:17 -0700") 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:269593 Archived-At: Jim Porter writes: > On 9/6/2022 6:30 PM, Morgan Smith wrote: >> I've attached my patch V2. >> This restores some more of the original logic that I have now realized >> was indeed necessary. Again, this patch should not actually change >> anything with respect to program logic, flow, or user experience. In my >> limited testing, it seems to act just as it did before (but >> significantly more performant). > > Thanks, this does indeed seem a lot faster. I do notice one small change in > behavior though: after starting Eshell with the em-smart module loaded, run > "echo hi" and then split the window vertically with 'C-x 2'. Before the patch, > the window doesn't scroll. After the patch, the window is scrolled so that the > "echo hi" block is at the top (i.e. the "Welcome to the Emacs shell" banner is > hidden). > > The same sort of thing happens if you run a command with a lot of output first > and then run "echo hi". Before splitting, the "echo hi" block is at the > bottom. Without this patch, 'C-x 2' maintains that position (i.e. it scrolls the > minimum amount of the previous command out of view so that you can see the > most-recent command). With the patch, 'C-x 2' scrolls *all* of the previous > command out of view, so the "echo hi" block is at the top. > > I think the pre-patch behavior is the most-usable: if you can fit all of the > last command in the window, it should be at the bottom so that you can see (some > of) the previous command. > > (I also saw some strange issue with resizing the windows via the mouse, but I > can't reproduce it anymore. If I can figure out how trigger this reliably, I'll > send an update. Sorry that's not very helpful at present...) That was one year ago. Morgan, did you get a chance to look into the issues Jim pointed out above?