From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#46350: 28.0.50; touchpad-scrolling-eats-lots-of-cpu-samples Date: Sun, 07 Feb 2021 20:44:57 +0200 Message-ID: <83czxbn2dy.fsf@gnu.org> References: <83a6shnklg.fsf@gnu.org> <838s81nhoz.fsf@gnu.org> <8335y9neut.fsf@gnu.org> <83h7mnn4y6.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7588"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 46350@debbugs.gnu.org To: Andrey Orst Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Feb 07 19:47:55 2021 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 1l8p6B-0001s3-Ni for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 07 Feb 2021 19:47:55 +0100 Original-Received: from localhost ([::1]:52998 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l8p6A-00071C-PE for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 07 Feb 2021 13:47:54 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58842) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l8p3O-0004m9-Ep for bug-gnu-emacs@gnu.org; Sun, 07 Feb 2021 13:45:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:37235) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1l8p3N-0005BX-Lk for bug-gnu-emacs@gnu.org; Sun, 07 Feb 2021 13:45:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1l8p3N-0004Kh-JL for bug-gnu-emacs@gnu.org; Sun, 07 Feb 2021 13:45:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 07 Feb 2021 18:45:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46350 X-GNU-PR-Package: emacs Original-Received: via spool by 46350-submit@debbugs.gnu.org id=B46350.161272349716632 (code B ref 46350); Sun, 07 Feb 2021 18:45:01 +0000 Original-Received: (at 46350) by debbugs.gnu.org; 7 Feb 2021 18:44:57 +0000 Original-Received: from localhost ([127.0.0.1]:48781 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1l8p3I-0004KC-Pq for submit@debbugs.gnu.org; Sun, 07 Feb 2021 13:44:57 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:40910) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1l8p3F-0004Jz-UN for 46350@debbugs.gnu.org; Sun, 07 Feb 2021 13:44:55 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:34909) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l8p3A-00056U-Ma; Sun, 07 Feb 2021 13:44:48 -0500 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4922 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1l8p39-0000xJ-QB; Sun, 07 Feb 2021 13:44:48 -0500 In-Reply-To: (message from Andrey Orst on Sun, 7 Feb 2021 21:33:25 +0300) 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" Xref: news.gmane.io gmane.emacs.bugs:199539 Archived-At: > From: Andrey Orst > Date: Sun, 7 Feb 2021 21:33:25 +0300 > Cc: 46350@debbugs.gnu.org > > On Sun, Feb 7, 2021 at 8:49 PM Eli Zaretskii wrote: > > 1350 calls during what time, approximately? less than a second? > > If you've watched the video I've linked I cannot watch that video, sorry. But I don't think it matters, see below. > you can get a sense of what > time it takes -- about 15 seconds. Or more if I continue swyping > rapidly, since Emacs just sits at the bottom eating all input until I > stop. I didn't ask how much time it takes Emacs to process the inputs. I asked how much time did it take you to generate them by moving your finger on the touchpad. I very much doubt the answer to that is 15 sec. > Touchpad generates about 20-30 inputs per swipe, so I think ~90 inputs > is maximum human can produce in 1 second ~100 1-line scrolls per second is also a lot, for what Emacs must do to scroll. > Can Emacs poll mouse events less frequently? Emacs doesn't poll the mouse. The mouse events are received from the X event queue, together with all the other events: keyboard input, expose events, etc. We read the events from X and then process them one by one. > > So, once we've established that the touchpad injects 1-line scroll > > requests at such a high rate, what else needs to be investigated here? > > There I was talking about progressive speed turned on, as it builds up > almost instantly with my touchpad producing 30 inputs per swipe. Sorry, I don't understand: what builds up?