From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#32452: 26.1; gnutls_try_handshake maxes out cpu retrying when server is a bit busy Date: Fri, 17 Aug 2018 07:55:44 -0400 Message-ID: <87o9e1w6kf.fsf@gmail.com> References: <87wosqwlu3.fsf@gmail.com> <83d0uiig3j.fsf@gnu.org> <83zhxmgqrh.fsf@gnu.org> <87r2ixx0t6.fsf@gmail.com> <83pnyhh6ta.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1534506852 25701 195.159.176.226 (17 Aug 2018 11:54:12 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 17 Aug 2018 11:54:12 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) Cc: 32452@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Aug 17 13:54:08 2018 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 1fqdKM-0006TT-Lu for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Aug 2018 13:54:02 +0200 Original-Received: from localhost ([::1]:33198 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fqdMT-0003LY-8k for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Aug 2018 07:56:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56934) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fqdMM-0003Kq-Db for bug-gnu-emacs@gnu.org; Fri, 17 Aug 2018 07:56:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fqdMI-0006Un-Fn for bug-gnu-emacs@gnu.org; Fri, 17 Aug 2018 07:56:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48279) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fqdMI-0006UW-Br for bug-gnu-emacs@gnu.org; Fri, 17 Aug 2018 07:56:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fqdMI-0006nz-8w for bug-gnu-emacs@gnu.org; Fri, 17 Aug 2018 07:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 17 Aug 2018 11:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32452 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 32452-submit@debbugs.gnu.org id=B32452.153450695326142 (code B ref 32452); Fri, 17 Aug 2018 11:56:02 +0000 Original-Received: (at 32452) by debbugs.gnu.org; 17 Aug 2018 11:55:53 +0000 Original-Received: from localhost ([127.0.0.1]:53297 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fqdM8-0006nZ-Kp for submit@debbugs.gnu.org; Fri, 17 Aug 2018 07:55:52 -0400 Original-Received: from mail-it0-f44.google.com ([209.85.214.44]:50448) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fqdM7-0006nO-Mr for 32452@debbugs.gnu.org; Fri, 17 Aug 2018 07:55:51 -0400 Original-Received: by mail-it0-f44.google.com with SMTP id j81-v6so10901640ite.0 for <32452@debbugs.gnu.org>; Fri, 17 Aug 2018 04:55:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=KrxWAnMjEDfcLP1V7Mk8J4VifeUkE86nt69vff3h6tw=; b=jJiYREgCzVPX/JlXo22D5bUQntkYFmbmBDo+T0ZDdzpO7MMcgDehOpEELcUePYZnvV tCwDfKw5v0xLCM18kCtE5OfLQe4nh3bP0ibL8xUKPMT0Oo95cX7NpXtbc7+gJVS4qPjJ rnKpbeVktxDae/Ig5v3tUQoREYi3RUYy3S1sTW1syAoWAPJrDEpcZI7/DoT3hg1axEP/ MmX6bKwyPfvGiDsVJK2b8N+IpXSWgREdSYnaysF8BvjUvThF3lx2kT5aclniuiBOjw9T DE1ZYv13E66Z7+7H1fHzbEBiltXoH5nfILmHPqcLACb0FCxRTrRp9lQ1lVF4V/2l68AX 8JjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=KrxWAnMjEDfcLP1V7Mk8J4VifeUkE86nt69vff3h6tw=; b=I5+jNTY42t/MyJydrZ+HoqXiTlD4/OIPiSCtesAhNcjzWbuV5Kq8XHfUXIdi2nPKhm dZ+2pq1Vfovrrmb58rJBcWcagpjUQKDze5x2SXLbo7ZzPPcDjK5ZeXOt5H+3U+7r+z7D RLIi8t8C5LoHzbRRYq4IfAJ4LdIjeJozM3bitpSHvXkbAoypj2L/AP2vTT3+PRVn5ug3 rdooVfBPEX7u7x+EWde6chflpR7Gj78ooTrtHpzSWiQ8yevSaMFUQgIqxTXR2iKiYOGT 4ao7gn48w/hIYiCYyiCYXQBNJYAfYAu9iwnD49zuzK+jnXwRA3d+K44xEOkAgVKUIyb+ 8Mew== X-Gm-Message-State: AOUpUlHcqJnYzKbE1Nl3VsgRejYs96qaBXH/sodxRcxzrxY5oXM1JGTX E9aZrna63aqTF0Zy4KBJFW0F0eAE X-Google-Smtp-Source: AA+uWPw4drku+Ah/5ZNywQEjMccYaRZD9GCJnQ6mOPjhvaPC8ztIeYf0Eh25noR3UYOViNNRrCGPBg== X-Received: by 2002:a02:9d50:: with SMTP id m16-v6mr29961191jal.119.1534506945859; Fri, 17 Aug 2018 04:55:45 -0700 (PDT) Original-Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id v26-v6sm835272ioh.53.2018.08.17.04.55.45 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 17 Aug 2018 04:55:45 -0700 (PDT) In-Reply-To: <83pnyhh6ta.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 17 Aug 2018 08:59:29 +0300") 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:149554 Archived-At: Eli Zaretskii writes: > OK, so do you understand the sequence of the events well enough to > describe what happens, and explain why we get so many EAGAIN errors? > I'm not yet sure this is bug, maybe it's just how things are in this > case (modulo exerting less CPU load, something that we certainly > should try). I haven't really traced things through properly, but my current understanding/guess is that we're using non-blocking sockets even though we actually want blocking behaviour. So to get the blocking behaviour we just spin in a loop. > Also, does this happen with every server, or just with some? debbugs.gnu.org seems to be the most extreme case (at the moment), with other servers I see only about a hundred "Resource temporarily unavailable" messages (I'm noticing this now because I switched on gnutls-log-level, but it's not enough to cause a noticable CPU spike).