From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 76AE13858D33 for ; Sun, 21 Jan 2024 03:56:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 76AE13858D33 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 76AE13858D33 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705809413; cv=none; b=bjba+SC6RNxYS9igY+mGdKA41ho40KyrRkFjI8q81vfIs07G9VQcFKeO1T8ZxdtjrqxYhW7CItgLnqCYd+Z1FyUk7QeS7L6jPDxhIbcUW4RPzryUi021cgMSQUWkjQjXmMThfpqvbRn1MTBj6lqOvbZRnYgnyH8Kn/5q622MhRY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705809413; c=relaxed/simple; bh=ZN6PAodhDFnbcCr0thSPQNg8yJ7O+rBf8BpCoqGmZUg=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=Sq88RXTxCfzl/mCxhN1Z0b5qEsNMV9Zpj6VbiyWWcBTDyLYOh4JvpXEJsAz/fLsXG//vpZ1eDK3rbAe8uBSKS0VPHeCXXqYM1zwxoYZrRc3/Ocs1XQ28k2qF26q0WsEDAQDy95Ehesze64hgnrlaeJPiyG+17J3roR6OtvGtmo8= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1705809411; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QKqoC7xNpnzfE5nmwNp5lPxPXPEJI8jQ/SgaWmzVOLU=; b=WtP0khhbOsMqLiZJmYx49lXKMrFOtX49Z/duwl/TlgzAx1I4y+R6GQBN8FXdJBAPK+ok8B 5qDbBhMeaXiXWap3BjXiWOQl79jHP169UJY2MKxNrQo3+9foFTD/SKNO3/NKghW2X48AAU DdjiLXbW2qqf9VfEZIqRQBx4gieW3lc= Received: from mail-oo1-f72.google.com (mail-oo1-f72.google.com [209.85.161.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-607-M4Vrqce2OuGTzrUjhuO3xg-1; Sat, 20 Jan 2024 22:56:49 -0500 X-MC-Unique: M4Vrqce2OuGTzrUjhuO3xg-1 Received: by mail-oo1-f72.google.com with SMTP id 006d021491bc7-5953e534a96so2500011eaf.0 for ; Sat, 20 Jan 2024 19:56:49 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705809409; x=1706414209; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=QKqoC7xNpnzfE5nmwNp5lPxPXPEJI8jQ/SgaWmzVOLU=; b=c9xrQJ+HktnPz8oIEl/+qg2Y5tpBLvQNrS4IABeI3iHbMVy3gMpxiRmXSUJEdjaA2h Du4CV4b3iA7xDe37zWxf+9NUXpZzTBIlbWJqfbG7kkKlzchyZjuQ4o0qu9Vq05I174i9 sbNG6W2Ah4+jiXtzJE910IrfZO4Hn0PxNdR2nwf3mxgBPwJl7pIbK5aKh5Jjtxc9UnGv mLWvLFpbiADT2AJdHkgaC/aukkeUsQ8X+0uMO37GUxeE1wDoM+40jzrOY9n4/GK1ZBZt j5pTUce1Cy4IWHwtkvV6Cw/7GYer9SrbL7qKniskot4oGoYKTfOLYetKGEy0ju7Il6yL yDMQ== X-Gm-Message-State: AOJu0YwqzEv5tJgxpLrYv341oOGfbj5Os9LABVgCBjDXDllHiptxFbAL HZXwTiAa8YMLYijDcn1AaF6xhizGBSjhL67cAYaIQu29czpxUfTzFtLVK726L6qf6Ic80UqCkFY cpJ9PO8JkmXaDKiqeIdHLCr0jDqoikMr0EXV/3ChF+OOo+v3CNTQaKbswvno= X-Received: by 2002:a05:6358:6f0e:b0:175:4f0f:bbab with SMTP id r14-20020a0563586f0e00b001754f0fbbabmr1443688rwn.22.1705809408814; Sat, 20 Jan 2024 19:56:48 -0800 (PST) X-Google-Smtp-Source: AGHT+IHxcrHBtaNFDF5btlNwel0AliP5jGlCOkG2Zak8sqCUSSxSN2b/svPdS7NTHLLozs4zY7O8XQ== X-Received: by 2002:a05:6358:6f0e:b0:175:4f0f:bbab with SMTP id r14-20020a0563586f0e00b001754f0fbbabmr1443686rwn.22.1705809408495; Sat, 20 Jan 2024 19:56:48 -0800 (PST) Received: from [150.1.200.12] (174-21-92-140.tukw.qwest.net. [174.21.92.140]) by smtp.gmail.com with ESMTPSA id db11-20020a17090ad64b00b002900eeada1asm6834134pjb.43.2024.01.20.19.56.47 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 20 Jan 2024 19:56:48 -0800 (PST) Message-ID: <3ec290a1-a9c7-4de0-8f7c-cb08f3d1a0e1@redhat.com> Date: Sat, 20 Jan 2024 19:56:47 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 00/16] Inferior argument (inc for remote targets) changes To: Andrew Burgess , gdb-patches@sourceware.org References: From: Keith Seitz In-Reply-To: X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,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 List-Id: On 1/9/24 06:26, Andrew Burgess wrote: > This series relates to bug PR gdb/28392. For background, check out > this series: > > https://inbox.sourceware.org/gdb-patches/20211022071933.3478427-1-m.weghorn@posteo.de Having run through this code in years gone by, this series is long overdue, so thank you for that. > Still, there's plenty here to comment on, and I figure between now and > April I can address any feedback that's given. Re: libiberty, I am sure you'll make something work. :-) FWIW, I've regression tested the series on our internal testing harness and found no regressions on Fedora 39 (x86_64, aarch64, ppc64le, s390x). I only have comments for a handful of the patches, and most of those comments are pretty trivial. Feel free to add my Reviewed-by. Keith > Andrew Burgess (14): > libiberty/buildargv: POSIX behaviour for backslash handling > gdb/testsuite: add some xfail in gdb.base/startup-with-shell.exp > gdb: remove the !startup_with_shell path from > construct_inferior_arguments > gdbserver: convert program_args to a single string > gdbsupport: have construct_inferior_arguments take an escape function > gdbsupport: split escape_shell_characters in two > gdb: move remote arg splitting and joining into gdbsupport/ > gdb/python: change escaping rules when setting arguments > gdb: add remote argument passing self tests > gdb/gdbserver: pass inferior arguments as a single string > gdb: allow 'set args' and run commands to contain newlines > gdb/gdbserver: remove some uses of free_vector_argv > gdb: new maintenance command to help debug remote argument issues > gdb/gdbserver: rework argument splitting and joining > > Michael Weghorn (2): > gdb: Support some escaping of args with startup-with-shell being off > gdb/gdbserver: add a '--no-escape-args' command line option > > gdb/Makefile.in | 1 + > gdb/NEWS | 41 +++ > gdb/doc/gdb.texinfo | 191 ++++++++++++- > gdb/doc/python.texi | 7 +- > gdb/infcmd.c | 128 ++++++++- > gdb/inferior.c | 8 - > gdb/inferior.h | 7 +- > gdb/main.c | 30 +- > gdb/nat/fork-inferior.c | 84 ++---- > gdb/python/py-inferior.c | 7 +- > gdb/remote.c | 94 ++++++- > gdb/testsuite/gdb.base/args.exp | 137 ++++++--- > gdb/testsuite/gdb.base/inferior-args.exp | 215 +++++++++++++-- > .../gdb.base/maint-test-remote-args.exp | 40 +++ > gdb/testsuite/gdb.base/startup-with-shell.exp | 143 ++++++++-- > gdb/testsuite/gdb.python/py-inferior.exp | 36 ++- > gdb/testsuite/gdb.server/inferior-args.c | 27 ++ > gdb/testsuite/gdb.server/inferior-args.exp | 157 +++++++++++ > gdb/unittests/remote-arg-selftests.c | 172 ++++++++++++ > gdbserver/linux-low.cc | 5 +- > gdbserver/linux-low.h | 2 +- > gdbserver/netbsd-low.cc | 6 +- > gdbserver/netbsd-low.h | 2 +- > gdbserver/server.cc | 74 +++-- > gdbserver/server.h | 5 + > gdbserver/target.h | 6 +- > gdbserver/win32-low.cc | 7 +- > gdbserver/win32-low.h | 2 +- > gdbsupport/Makefile.am | 1 + > gdbsupport/Makefile.in | 13 +- > gdbsupport/common-inferior.cc | 207 +++++++++----- > gdbsupport/common-inferior.h | 29 +- > gdbsupport/remote-args.cc | 260 ++++++++++++++++++ > gdbsupport/remote-args.h | 44 +++ > libiberty/argv.c | 8 +- > libiberty/testsuite/test-expandargv.c | 34 +++ > 36 files changed, 1927 insertions(+), 303 deletions(-) > create mode 100644 gdb/testsuite/gdb.base/maint-test-remote-args.exp > create mode 100644 gdb/testsuite/gdb.server/inferior-args.c > create mode 100644 gdb/testsuite/gdb.server/inferior-args.exp > create mode 100644 gdb/unittests/remote-arg-selftests.c > create mode 100644 gdbsupport/remote-args.cc > create mode 100644 gdbsupport/remote-args.h > > > base-commit: b7a5722ebdd24a0d15d56e96d30a649ea1d7b0ee