From patchwork Tue Jul 25 13:49:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 55944 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 49EF73858D3C for ; Tue, 25 Jul 2023 13:50:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 49EF73858D3C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1690293007; bh=1lqR1SzaJhcb3U5ZEe0lBlR9d0NM3X1xbCKhV2wz8Vo=; h=Subject:Date:To:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=de1U8BlAHPzDHZMq+kPRykOnKe4cxicsn6ZwC0NcPj4x4jQ9EGa+e5iC0rAS6O6wz RsIQfNF/ea485VJCBH+6QD8UCwCZLBrT6/cX9gPNvVAQc9jVZCdR0UkjJV7eBi/gMl rgVUHHWGF+1rQZ6r68wCUDlPpnjaiTLEcGK6idj0= X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-io1-xd32.google.com (mail-io1-xd32.google.com [IPv6:2607:f8b0:4864:20::d32]) by sourceware.org (Postfix) with ESMTPS id 8A0203857803 for ; Tue, 25 Jul 2023 13:49:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8A0203857803 Received: by mail-io1-xd32.google.com with SMTP id ca18e2360f4ac-7835c92c373so146772139f.0 for ; Tue, 25 Jul 2023 06:49:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690292979; x=1690897779; h=to:content-transfer-encoding:mime-version:message-id:date:subject :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=1lqR1SzaJhcb3U5ZEe0lBlR9d0NM3X1xbCKhV2wz8Vo=; b=QWn+dilOiS9M28WHWi/jsOmFT92utpkQtPE8/UvofYuD3xn8oDqyk0Aeu3j8rsfQkY luNf/KCMPsk4smTRlmSZJOGrEoIwWU1fJ55LvCfnMUmB3REGCbHYIrAPgKMrSwNfgbem 67lXI/3ZDKIJ8dU2AUap+t89byF2MEheSp7E8lXx2AqJq8LYZ7flWLlu/5r6z+1jAZgR N+WxU963DSOhzJH1oZ9wwQbEQn+NvDhdWxihvQMkPss7cipcIxoh8afc4xiLcA292Uns bXei8F/6HNu+ZbkQDX991XxRSCG4VvXrTevQDQhYh8o3Nx+45HzPG+xWSgMYyHKpaD3y Jx4Q== X-Gm-Message-State: ABy/qLbZlwND/yods47jNyVMNxYtDq1q/F3AkUUAKnryULtA8w9phXhE c1uiBTCHlJZMxcnmaIy1uZRtPm33jpoayK47dVUP1Q== X-Google-Smtp-Source: APBJJlHTCiIvQYwkWN9TCrS7JH93f5mz6F2xtWVWmfLOtXUnfYm2P9GMjHgIqSXai7LLY6fpZAjAyQ== X-Received: by 2002:a05:6e02:12e4:b0:346:4f37:8a3 with SMTP id l4-20020a056e0212e400b003464f3708a3mr1665013iln.5.1690292979762; Tue, 25 Jul 2023 06:49:39 -0700 (PDT) Received: from localhost.localdomain (75-166-135-140.hlrn.qwest.net. [75.166.135.140]) by smtp.gmail.com with ESMTPSA id c3-20020a02a403000000b00418a5e0e93esm3595018jal.162.2023.07.25.06.49.39 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 25 Jul 2023 06:49:39 -0700 (PDT) Subject: [PATCH 0/6] Several DAP fixes for VSCode Date: Tue, 25 Jul 2023 07:49:37 -0600 Message-Id: <20230725-dap-bt-path-v1-0-bb015b0d8e54@adacore.com> MIME-Version: 1.0 X-B4-Tracking: v=1; b=H4sIAPHSv2QC/x3MQQrCMBBG4auUWTuQJqjoVcTFpP01szCGSShC6 d1Nu/wW761UYYpK92Elw6JVv7ljPA00JclvsM7d5J0P7urPPEvh2LhISxw8bqOTAIQL9aIYXvo 7bo9nd5QKjiZ5SvvjI7XBaNv+2pSVKHYAAAA= To: gdb-patches@sourceware.org X-Mailer: b4 0.12.3 X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) 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-Patchwork-Original-From: Tom Tromey via Gdb-patches From: Tom Tromey Reply-To: Tom Tromey Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" Vladimir Makaev tried the gdb DAP implementation with VSCode and found a few bugs. This series fixes these. It also adds a new DAP launch parameter -- I thought I was going to need this, and while I didn't, it still seemed like a good idea to add. I'm not completely happy with this series. See the "full paths" patch for some discussion. Essentially I think the FrameDecorator API is not very well thought out, and once again this is an area where it would be very nice if we could add new methods to the spec. I wonder whether we should. One difference between pretty-printers and frame decorators is that my sense is that there are many more of the former, so the smaller for the latter. Another idea I had for that patch is to just change the base behavior of FrameDecorator, based on a global flag -- that would only be set by DAP. --- Tom Tromey (6): Rename private member of FrameDecorator Refactor dap_launch Add "cwd" parameter to DAP launch request Full paths in DAP stackTrace responses Move DAP breakpoint event code to breakpoint.py Do not send "new breakpoint" event when breakpoint is set gdb/doc/gdb.texinfo | 8 +++ gdb/python/lib/gdb/FrameDecorator.py | 119 ++++++++++++++++++++------------- gdb/python/lib/gdb/dap/breakpoint.py | 64 +++++++++++++++++- gdb/python/lib/gdb/dap/events.py | 37 ---------- gdb/python/lib/gdb/dap/launch.py | 34 +++++----- gdb/python/lib/gdb/frames.py | 14 +++- gdb/testsuite/gdb.dap/args-env.exp | 2 +- gdb/testsuite/gdb.dap/basic-dap.exp | 11 +-- gdb/testsuite/gdb.dap/cwd.exp | 40 +++++++++++ gdb/testsuite/gdb.dap/stop-at-main.exp | 2 +- gdb/testsuite/lib/dap-support.exp | 72 +++++++++++++------- 11 files changed, 262 insertions(+), 141 deletions(-) --- base-commit: 695776dc2f43c56dd2ae2f7036fb7cf74e19b46b change-id: 20230725-dap-bt-path-32e910a3ee36 Best regards,