From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 83753 invoked by alias); 2 Jun 2016 09:31:17 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 83601 invoked by uid 89); 2 Jun 2016 09:31:16 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=2016-06-02, claim X-HELO: mail-pf0-f194.google.com Received: from mail-pf0-f194.google.com (HELO mail-pf0-f194.google.com) (209.85.192.194) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Thu, 02 Jun 2016 09:31:11 +0000 Received: by mail-pf0-f194.google.com with SMTP id c84so7368523pfc.1 for ; Thu, 02 Jun 2016 02:31:11 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=u9/ko6UWO38YvVjv8HWhe1276RDy/ZdgdCZn22jg+ds=; b=FjKBBseEP274j8BtHnglrm1OQSxgF6XHSDHmdOWTYEARFVfaM51YZ+a6UG6GdGz5+l oeM1zDzfHfNuUlqEv+T8h7+LeH0fAta0GXZFK9iqocKeVOVCTRWD6gjTYIW9B1IqJX9r qFbkIR/ue10+1ORxEeYAXzDGGwLZfen+elc5NgP77w+ISCqhQebT4h3jiafHA1ujcoRr cWSzCnCskY5as2g5gNUlCSmKH5gW1LiUi0cLKA0EXrYtTNmicUaXxnhOI97ZrpxL6Csj 9mxrDlKhQazqVuKcBR17y1RJyrFqZYXkHt6IO4BBCvY8NaGb9yJ/ML7QxqjJJdylTbts N3bA== X-Gm-Message-State: ALyK8tJCqaWmcZVn9aintb6YOSs01CO8Cfg8uwLcA878w7l88VGg2N3GisS+/mnlQA+pTA== X-Received: by 10.98.91.196 with SMTP id p187mr2725954pfb.58.1464859869475; Thu, 02 Jun 2016 02:31:09 -0700 (PDT) Received: from E107787-LIN.cambridge.arm.com (gcc113.osuosl.org. [140.211.9.71]) by smtp.gmail.com with ESMTPSA id hw10sm68656218pac.15.2016.06.02.02.31.08 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 02 Jun 2016 02:31:08 -0700 (PDT) From: Yao Qi X-Google-Original-From: Yao Qi To: gdb-patches@sourceware.org Subject: [PATCH 12/12] Support vCont s and S actions with software single step Date: Thu, 02 Jun 2016 09:31:00 -0000 Message-Id: <1464859846-15619-13-git-send-email-yao.qi@linaro.org> In-Reply-To: <1464859846-15619-1-git-send-email-yao.qi@linaro.org> References: <1464859846-15619-1-git-send-email-yao.qi@linaro.org> X-IsSubscribed: yes X-SW-Source: 2016-06/txt/msg00036.txt.bz2 GDBserver with software single step should be able to claim supporting vCont s and S actions, so that GDB knows the remote target can do single step. It doesn't matter to GDB that the single step in the remote target is done via hardware or software. gdb/gdbserver: 2016-06-02 Yao Qi * server.c (handle_v_requests): Support s and S actions if target_supports_software_single_step return true. --- gdb/gdbserver/server.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/gdb/gdbserver/server.c b/gdb/gdbserver/server.c index 18517bc..6d6cb09 100644 --- a/gdb/gdbserver/server.c +++ b/gdb/gdbserver/server.c @@ -2958,12 +2958,15 @@ handle_v_requests (char *own_buf, int packet_len, int *new_packet_len) { strcpy (own_buf, "vCont;c;C;t"); - if (target_supports_hardware_single_step () || !vCont_supported) + if (target_supports_hardware_single_step () + || target_supports_software_single_step () + || !vCont_supported) { - /* If target supports hardware single step, add actions s - and S to the list of supported actions. On the other - hand, if GDB doesn't request the supported vCont actions - in qSupported packet, add s and S to the list too. */ + /* If target supports single step either by hardware or by + software, add actions s and S to the list of supported + actions. On the other hand, if GDB doesn't request the + supported vCont actions in qSupported packet, add s and + S to the list too. */ own_buf = own_buf + strlen (own_buf); strcpy (own_buf, ";s;S"); } -- 1.9.1