From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-f67.google.com (mail-wm1-f67.google.com [209.85.128.67]) by sourceware.org (Postfix) with ESMTPS id 502323858D37 for ; Mon, 6 Jul 2020 19:02:55 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 502323858D37 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=palves.net Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=alves.ped@gmail.com Received: by mail-wm1-f67.google.com with SMTP id o2so43191259wmh.2 for ; Mon, 06 Jul 2020 12:02:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=FZNnC39ibjgxFAxM8hLbgn++DHCIkJGLjTFlkfZImFM=; b=KfAP3TrM92ugM3JIyukhvULj/aD55v3cLSrUD+UIrl0H+ABkUCy+QAT5LsOaSLH5Zq fKTsthKqo6mYRrp1rX02EGnuGRd89nh2HyHFXL4k+qwbNAIEhj5UsGeWUgAb2OyMg2Rd ryM+Zp3lCMQe5cphvWbseX0Xoux21216Und1+5XO3VItqOjRKqoBmPbJ6PY44RXMYAOx 97dqBKqRveKquG+/4s/HqlOEIU9Ctd3G4JWzTu9vnp5aU/RhRsmvpkp/AMLiXDE1zzgI 0yK8+F/GvpPVTnr1B0Q/Hfd2GF/RH4iZpWdDmcuv1HgP+vBeLy/8fMp0p/eOWRbn2kAG l+vQ== X-Gm-Message-State: AOAM531NmDdAZJ1kyw4f/9qNqNxIphQJa6POQ8NiLhbajnlf1n2fPGcw JCl+ow0crystmLyE1MSk7Jpm3K5CZAwvRw== X-Google-Smtp-Source: ABdhPJy9K7z1sgzFdCBPoqF6qbBO2GmxeGbUDPj2gL33jSSSu2Kic4rEycwSdIgTSUV9lCyo/9wOWw== X-Received: by 2002:a05:600c:4109:: with SMTP id j9mr564643wmi.157.1594062174187; Mon, 06 Jul 2020 12:02:54 -0700 (PDT) Received: from localhost ([2001:8a0:f91a:c400:8728:8fef:5b85:5934]) by smtp.gmail.com with ESMTPSA id t141sm451383wmt.26.2020.07.06.12.02.52 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 06 Jul 2020 12:02:53 -0700 (PDT) From: Pedro Alves To: gdb-patches@sourceware.org Subject: [PATCH 0/7] GDB busy loop when interrupting non-stop program (PR 26199) Date: Mon, 6 Jul 2020 20:02:45 +0100 Message-Id: <20200706190252.22552-1-pedro@palves.net> X-Mailer: git-send-email 2.14.5 X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Jul 2020 19:02:56 -0000 This patch series fixes PR 26199, a GDB 10 blocker. I discussed how to fix this with Simon, and we came to the conclusion that we can fix it by removing code. Easy. :-) That's the last patch in the series. Well, not so easy, actually... :-/ Doing that alone caused gdb.multi/multi-target.exp to regress. And the reason was that the fix for PR 261299 made that testcase trip on a few latent bugs... One of those bugs also caused a similar 100% cpu busy loop. And then, while fixing those, I added a new test scenario to gdb.multi/multi-target.exp to exercise the TARGET_WAITKIND_NO_RESUMED handling fixes in this series. That new test requires sending Ctrl-C to GDB after the test is done with, in order to cleanly kill gdbserver via "monitor exit". But, that Ctrl-C didn't work, due to an issue with GDB's terminal handling, GDB would just hang... That's all fixed by this series. Pedro Alves (6): Fix spurious unhandled remote %Stop notifications Fix latent bug in target_pass_ctrlc Avoid constant stream of TARGET_WAITKIND_NO_RESUMED Fix handle_no_resumed w/ multiple targets Make handle_no_resumed transfer terminal Testcase for previous handle_no_resumed fixes Simon Marchi (1): Fix GDB busy loop when interrupting non-stop program (PR 26199) gdb/infrun.c | 116 +++++++++++++++++++++---------- gdb/remote.c | 15 +++- gdb/target.c | 2 +- gdb/testsuite/gdb.multi/multi-target.c | 4 +- gdb/testsuite/gdb.multi/multi-target.exp | 76 ++++++++++++++++++++ 5 files changed, 173 insertions(+), 40 deletions(-) base-commit: ad8464f799a4c96c7ab8bdfec3f95846cf54f9b0 -- 2.14.5