From patchwork Thu Oct 17 22:50:22 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pedro Alves X-Patchwork-Id: 35124 Received: (qmail 17838 invoked by alias); 17 Oct 2019 22:59:24 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 17828 invoked by uid 89); 17 Oct 2019 22:59:24 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS autolearn=ham version=3.3.1 spammy= X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 17 Oct 2019 22:59:23 +0000 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id DD27D89B009 for ; Thu, 17 Oct 2019 22:50:45 +0000 (UTC) Received: from localhost.localdomain (ovpn04.gateway.prod.ext.ams2.redhat.com [10.39.146.4]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7A61D10027C5 for ; Thu, 17 Oct 2019 22:50:45 +0000 (UTC) From: Pedro Alves To: gdb-patches@sourceware.org Subject: [PATCH v2 20/24] gdbarch-selftests.c: No longer error out if debugging something Date: Thu, 17 Oct 2019 23:50:22 +0100 Message-Id: <20191017225026.30496-21-palves@redhat.com> In-Reply-To: <20191017225026.30496-1-palves@redhat.com> References: <20191017225026.30496-1-palves@redhat.com> Since each inferior has its own target stack, the stratum condition for the "error out if debugging something" check is always false. gdb/ChangeLog: yyyy-mm-dd Pedro Alves * gdbarch-selftests.c (register_to_value_test): Remove "target already pushed" check. --- gdb/gdbarch-selftests.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/gdb/gdbarch-selftests.c b/gdb/gdbarch-selftests.c index 0942050479..7fd56b0343 100644 --- a/gdb/gdbarch-selftests.c +++ b/gdb/gdbarch-selftests.c @@ -71,11 +71,6 @@ register_to_value_test (struct gdbarch *gdbarch) builtin->builtin_char32, }; - /* Error out if debugging something, because we're going to push the - test target, which would pop any existing target. */ - if (current_top_target ()->stratum () >= process_stratum) - error (_("target already pushed")); - /* Create a mock environment. An inferior with a thread, with a process_stratum target pushed. */