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.133.124]) by sourceware.org (Postfix) with ESMTPS id 81655385703F for ; Tue, 31 Jan 2023 15:15:09 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 81655385703F Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1675178109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=U7Stg1ogds0SPISwb99m8TOc18AijBEovJzvdYyGRKM=; b=XWbVBGHhXxUmlD8YZ1L71vi/T45r4lnUaIxTlXf3PLgUStRLx9mX1kcP+KGGnNNyNVSkRH XtcsXEU5QCsK0QdvSZbS9508m1VlbzhlhPXYwdWK8JoUfhLzB7SxeUiLrtM2Fs2arRQVXg kH27rD6sJl/K+jZVZkzGwtk321+IxPY= Received: from mail-pf1-f199.google.com (mail-pf1-f199.google.com [209.85.210.199]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-76-Bugr-wxJPPa7egvxBEaWHw-1; Tue, 31 Jan 2023 10:15:06 -0500 X-MC-Unique: Bugr-wxJPPa7egvxBEaWHw-1 Received: by mail-pf1-f199.google.com with SMTP id j14-20020aa7928e000000b00593bca77b0dso3300888pfa.9 for ; Tue, 31 Jan 2023 07:15:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=U7Stg1ogds0SPISwb99m8TOc18AijBEovJzvdYyGRKM=; b=qy4Djcd1vUJS6m6Kk4zzCBEA8FEsKVR8C1BUG9EQkP07FpsQ+i3ozaH/6Nu70ma1og XYAdD6DWxQRACopv9qJTUeFUDhCZMiDX5MGaUjf0HVheZjEOSgDD7QH5yqxfeBwNzt04 L1H5JJ/3w9+zdc11Iv2l/qTSH/52y9RFeKsas5Q+YX9J4HufbuBfbtLdWZFzMU4xBCY/ UkKGS7A4J+CwKl5DeHoSN1uENETWm9ItAMIXV0dFQOZfgUy1nFmuSxVLmkayFUPs+FAP n8YFnkPbCak+Kx0bb93owkylUb5x0ub4v1auvxD4p5OXuNyYE5mNztSYFxwykUN3E6BP lIXw== X-Gm-Message-State: AO0yUKWOyNjj9LIk4w8P5oFIIV3rz4QdDtYhPGw72kRsFQJ6eLi0mgIk LRysjeYx7HW5dPKzoEcSEftdxxWpTsjCQdmqz+TjmvsKSepF4R0Il0IxU9krJDHvmoYC8knPRct EvKL3LQXaAi19P0BgiCAxym65TfRgrd51Z4pADg== X-Received: by 2002:a05:6a00:4487:b0:593:e0ce:f9bf with SMTP id cu7-20020a056a00448700b00593e0cef9bfmr991460pfb.14.1675178105600; Tue, 31 Jan 2023 07:15:05 -0800 (PST) X-Google-Smtp-Source: AK7set+AVzSkko2XnN3Tyr0JK+02fld12RwhuhQ+OmT+uYjlnlJmvRDRjSO3AJjUyydBfR+ZCfEqjew0EmTp58zOcMU= X-Received: by 2002:a05:6a00:4487:b0:593:e0ce:f9bf with SMTP id cu7-20020a056a00448700b00593e0cef9bfmr991451pfb.14.1675178105230; Tue, 31 Jan 2023 07:15:05 -0800 (PST) MIME-Version: 1.0 References: <20230129162105.526266-1-tom@tromey.com> <20230129162105.526266-2-tom@tromey.com> In-Reply-To: <20230129162105.526266-2-tom@tromey.com> From: Alexandra Petlanova Hajkova Date: Tue, 31 Jan 2023 16:14:54 +0100 Message-ID: Subject: Re: [PATCH 1/5] Save breakpoints so they are automatically pending To: Tom Tromey Cc: gdb-patches@sourceware.org X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: multipart/alternative; boundary="000000000000e5f00705f390cbcd" X-Spam-Status: No, score=-3.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP 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: --000000000000e5f00705f390cbcd Content-Type: text/plain; charset="UTF-8" On Sun, Jan 29, 2023 at 5:21 PM Tom Tromey wrote: > PR breakpoints/18183 points out that breakpoints saved with the "save > breakpoints" command can be slightly inconvenient, depending on "set > breakpoint pending". > > This patch makes use of the new "with" command to save breakpoints > such that they will automatically be made pending, if necessary, when > being restored. > > Unfortunately, reloading a breakpoint saved this way will also print: > > No symbol table is loaded. Use the "file" command. > > This seems strange to me, and also a bit useless, but changing > create_breakpoint not to call exception_print in the AUTO_BOOLEAN_TRUE > case caused other regressions, so I've left it as-is for the time > being. > > Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=18183 > > I've tried this out and I think it's very convenient and makes gdb more user friendly. Before this patch: gdb]$ ./gdb -ex 'b write' /bin/ls save breakpoints tbb The pending breakpoint was not reloaded: gdb]$ ./gdb /bin/ls (gdb) source tbb Function "write" not defined. Make breakpoint pending on future shared library load? (y or [n]) [answered N; input not from terminal] (gdb) and after applying the patch pending breakpoint is there: (gdb) source tbb Function "write" not defined. Breakpoint 1 (write) pending. --000000000000e5f00705f390cbcd--