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 600EA3858C78 for ; Mon, 27 May 2024 21:40:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 600EA3858C78 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 600EA3858C78 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=1716846058; cv=none; b=bS/ojN8rMFNO30oifFrK5G0gRzJ7PpU0BtgbXBrVvMWG4SUO8Qf610JKOq2alCkpS0Mu+WRzkhceksKcwMCwjKRzEux7lCy20JgJeH1gKevEwfeszMSjTE2iS8211XOEbZ0TkJ4tYXz6PBWmndZoSlG7CmYVrvwCimDDYOoqL+0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1716846058; c=relaxed/simple; bh=FR4h80fsLywgeJNP/ChXSxuMPPXmc2kFe548mi1gKxs=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=MfCs3CwiYNcQmAvyFH5xFjsy+jdI39qtAEsKDBcEEOjMjI/aKTBhDY7Sx4wUXOuYcb+Gg71ouOEuqeJCxMzMN/byy+9cN8WMz42qvKwOz4RzEQCR97JGKvXT0LAmJaQYUDHg/Aw+a6EUyBcRc68ww4h/3n1JV7bnQ6uUk6wTEpE= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1716846055; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=AO4aa57jW/h7USSNyVgieZ2tL+Fd268hLUIMEHq/qMw=; b=D/O3lZcmfiAJKZK7H3JiMtiFWXM9eV6tLOaQ9/9KNASaZc9Sn2wm0KaSQbULzW/P2+AAKc QDDBUm6l7HJKDDi9fIiZmntm3mW7FaqJU7C1vUzKvY4Qak8u2pQxpSSE6ZpQjXFzsqZR6D yaZXP5Jyah/R1CyrFFbJ2qMKwjSoXh0= Received: from mail-wr1-f71.google.com (mail-wr1-f71.google.com [209.85.221.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-639-eSP_VyukP8OoyzEsD5d7iw-1; Mon, 27 May 2024 17:40:54 -0400 X-MC-Unique: eSP_VyukP8OoyzEsD5d7iw-1 Received: by mail-wr1-f71.google.com with SMTP id ffacd0b85a97d-3580f213373so86499f8f.3 for ; Mon, 27 May 2024 14:40:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716846053; x=1717450853; h=mime-version:message-id:date:references:in-reply-to:subject:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=AO4aa57jW/h7USSNyVgieZ2tL+Fd268hLUIMEHq/qMw=; b=t6mjE3Geyb5r5WRx90mrugXE5QfGICj/ZKQxwshc+aOcGVvWwTAePzoMNPapXvgIgR JdS3XLyRHbAejlU4ysJlFsccmSXfxYG1wjzmNGflAjZt4n1ssz9fPKug4qLNX8uNwtmf LwU02kTRI4ArRkkj55uXSnuiFP860Tt7T2CwU1ohPUK3F/SQwvI0EIGXTYtZorTJ6fZE hiZ6YoV8ILXlQ+FyhCpEDeXTV5K2Z1andjT29KHUMYqhq/SYXLnoHskO8ucOj6B9cX4+ EtOzI3I6USvXslo6B0Alg4wUJQElSD1YYaPUGYZZeBi9cmog7hf30p5yO84zyYMuCFrH VFmA== X-Forwarded-Encrypted: i=1; AJvYcCW7edgkGf3hrMiq1c4PewGmwbdXZ0tLKEpRe/3LsTSjv+oqRI9LFTYM5tiFDmFfw2eons35XSuw5zRq0XAqdQzYAINQ02SmUDhE6g== X-Gm-Message-State: AOJu0YytXgD4NF8FDLFgaRS/qZGv+0/gCC3H6+/9SYcSbcPfBOpAuuaQ oio+xiSlwS7xdmOv/5Vz8uFLzva/8PUY5/hgZm8Cmt4qFLRof5kxEktmjNMZBnsENsoPvI0ubFB RO2yaGbA8A3h/dmtIB4bjEa2/x+axF/xqy4N4YHXRFq9P4yVqNB+bkw3yiutXDnAM9is= X-Received: by 2002:a5d:4942:0:b0:354:faf2:417 with SMTP id ffacd0b85a97d-35526c69728mr5844719f8f.27.1716846053254; Mon, 27 May 2024 14:40:53 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEsbiL6xMGnOsd+fbOZ1/NLHaQ6LKeSxqA8GyRY9SZ3K5DoltWdp8AE8JKGQ+jmunwj6yBulQ== X-Received: by 2002:a5d:4942:0:b0:354:faf2:417 with SMTP id ffacd0b85a97d-35526c69728mr5844714f8f.27.1716846052699; Mon, 27 May 2024 14:40:52 -0700 (PDT) Received: from localhost (host86-153-169-45.range86-153.btcentralplus.com. [86.153.169.45]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3557dcf06c4sm9925444f8f.104.2024.05.27.14.40.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 May 2024 14:40:52 -0700 (PDT) From: Andrew Burgess To: Tom de Vries , gdb-patches@sourceware.org Subject: Re: [PATCH 1/3] [gdb/testsuite] Mention DEBUGINFOD_VERBOSE in gdb.debuginfod test-cases In-Reply-To: <20240527141808.31563-1-tdevries@suse.de> References: <20240527141808.31563-1-tdevries@suse.de> Date: Mon, 27 May 2024 22:40:51 +0100 Message-ID: <87o78r9bmk.fsf@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-9.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,KAM_BADIPHTTP,KAM_SHORT,NUMERIC_HTTP_ADDR,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE,WEIRD_PORT 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: Tom de Vries writes: > In proc start_debuginfod we start debuginfod with a fair amount of verbosity: > ... > spawn debuginfod -vvvv -d $db -p $port -F $debugdir > ... > which gives a lot of information on startup, but none or not much after that. > > There's another way to increase verbosity of debuginfod: through the > environment variable DEBUGINFOD_VERBOSE, which gives us the following > additional information (edited for readability): > ... > (gdb) file fetch_src_and_symbols^M > Reading symbols from fetch_src_and_symbols...^M > +debuginfod_find_debuginfo $hex^M > +server urls "http://127.0.0.1:8000"^M > +checking build-id^M > +checking cache dir $client_cache^M > +using timeout 10^M > +init server 0 http://127.0.0.1:8000^M > +url 0 http://127.0.0.1:8000/buildid/$hex/debuginfo^M > +query 1 urls in parallel^M > Downloading separate debug info for $fetch_src_and_symbols...^M > +server response No error^M > +got file from server^M > +found $client_cache/$hex/debuginfo (fd=18)^M > Reading symbols from $client_cache/$hex/debuginfo...^M > (gdb) > ... > > IMO this is too verbose to enable by default, but it's good to at least > mention the option explicitly in the test-cases. > > Tested by enabling it in the 3 gdb.debuginfod test-cases. This generates 2 > FAILs, but I don't think it's worthwhile to address these. > > Tested on x86_64-linux. > --- > gdb/testsuite/gdb.debuginfod/build-id-no-debug-warning.exp | 3 +++ > gdb/testsuite/gdb.debuginfod/crc_mismatch.exp | 3 +++ > gdb/testsuite/gdb.debuginfod/fetch_src_and_symbols.exp | 3 +++ > 3 files changed, 9 insertions(+) > > diff --git a/gdb/testsuite/gdb.debuginfod/build-id-no-debug-warning.exp b/gdb/testsuite/gdb.debuginfod/build-id-no-debug-warning.exp > index b86622543ef..25d800a378b 100644 > --- a/gdb/testsuite/gdb.debuginfod/build-id-no-debug-warning.exp > +++ b/gdb/testsuite/gdb.debuginfod/build-id-no-debug-warning.exp > @@ -127,6 +127,9 @@ prepare_for_debuginfod cache db > proc_with_prefix local_debuginfod { } { > global db debuginfod_debugdir cache build_id_debug_file > > + # Uncomment to increase verbosity of debuginfod when handling query. > + #setenv DEBUGINFOD_VERBOSE 1 > + I'm not a huge fan of leaving comment out code like this. I have some patches pending that add more debuginfod tests. Am I expected to add this same commented out code before every call to start_debuginfod? Some alternative suggestions: - Add this comment to start_debuginfod's comment, as in: "If additional debugging is required try 'setenv DEBUGINFOD_VERBOSE 1'." - We could document this in testsuite/README as a hint for debugging debuginfod tests. - We could add an 'args' list argument to start_debuginfod, and accept a 'verbose=1' argument within args. Hopefully you might find one of these an acceptable alternative... thanks, Andrew > set url [start_debuginfod $db $debuginfod_debugdir] > if {$url eq ""} { > unresolved "failed to start debuginfod server" > diff --git a/gdb/testsuite/gdb.debuginfod/crc_mismatch.exp b/gdb/testsuite/gdb.debuginfod/crc_mismatch.exp > index 017ef132573..27069b580dc 100644 > --- a/gdb/testsuite/gdb.debuginfod/crc_mismatch.exp > +++ b/gdb/testsuite/gdb.debuginfod/crc_mismatch.exp > @@ -99,6 +99,9 @@ proc_with_prefix local_debuginfod { } { > global binfile db debugdir cache > set escapedobjdirsubdir [string_to_regexp [standard_output_file {}]] > > + # Uncomment to increase verbosity of debuginfod when handling query. > + #setenv DEBUGINFOD_VERBOSE 1 > + > set url [start_debuginfod $db $debugdir] > if {$url eq ""} { > unresolved "failed to start debuginfod server" > diff --git a/gdb/testsuite/gdb.debuginfod/fetch_src_and_symbols.exp b/gdb/testsuite/gdb.debuginfod/fetch_src_and_symbols.exp > index 401af0df0d2..0fb752ff6bd 100644 > --- a/gdb/testsuite/gdb.debuginfod/fetch_src_and_symbols.exp > +++ b/gdb/testsuite/gdb.debuginfod/fetch_src_and_symbols.exp > @@ -209,6 +209,9 @@ proc disable_delete_breakpoints {} { > proc_with_prefix local_url { } { > global binfile outputdir debugdir db > > + # Uncomment to increase verbosity of debuginfod when handling query. > + #setenv DEBUGINFOD_VERBOSE 1 > + > set url [start_debuginfod $db $debugdir] > if { $url == "" } { > unresolved "failed to start debuginfod server" > > base-commit: 4250085217f2011335257fd3291cb50c939e9746 > -- > 2.35.3