From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id 6bCWOaCLnWroazEAWB0awg (envelope-from ) for ; Sun, 06 Sep 2026 11:49:52 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=Nt+Kyank; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=YapVChgz; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=H8/ur+sc; dkim=neutral header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=pEytpfYk; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id DB8151E033; Sun, 06 Sep 2026 11:49:52 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [38.145.34.32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id CB88A1E033 for ; Sun, 06 Sep 2026 11:49:51 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 68BE24BB3B93 for ; Sun, 6 Sep 2026 15:49:51 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 68BE24BB3B93 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=Nt+Kyank; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=YapVChgz; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=H8/ur+sc; dkim=neutral header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=pEytpfYk Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2a07:de40:b251:101:10:150:64:2]) by sourceware.org (Postfix) with ESMTPS id 425814BB3B93 for ; Sun, 6 Sep 2026 15:48:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 425814BB3B93 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 425814BB3B93 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=2a07:de40:b251:101:10:150:64:2 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788709729; cv=none; b=aOjch4/MGxUoUnbVv+DvMqrGVQpVCphMa/vhW0jbh4hBGy2VkkOApyr+lnFqwQv84iLKIVFq4lsyx8mk8KrIjyoQtXXZtvW2XXHEjP3RISxv7uQ8/pGFq6cpeJ12JarF26tKawqkMsQDpET8SiIYDUkrxk/2U6kqfw7RM9/u/+0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788709729; c=relaxed/simple; bh=u2Au5AaHhpWjZD+JjGBUiQRuK3geOdrRLc7jSSrK1GM=; h=DKIM-Signature:DKIM-Signature:DKIM-Signature:DKIM-Signature:From: To:Subject:Date:Message-ID:MIME-Version; b=J2cD0unP1lLMVdQobAtSxD7Zukq8GE1/dK4CVQdmB51e1mnZJQt/5cXjPOn//rC25fbOxSBMc7PSi1JH9AVPRNEwcx6tw3MxWD3EjUofU38NErVQm02FzxsEXfCnvIEJRVZIddPP7BM3n2mvxCxKLbBhq/PpG5wfJ2o4O0TK2U4= ARC-Authentication-Results: i=1; sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=Nt+Kyank; dkim=pass header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=YapVChgz; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.a=rsa-sha256 header.s=susede2_rsa header.b=H8/ur+sc; dkim=neutral header.d=suse.de header.i=@suse.de header.a=ed25519-sha256 header.s=susede2_ed25519 header.b=pEytpfYk DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 425814BB3B93 Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 9831D1F394 for ; Sun, 6 Sep 2026 15:48:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1788709723; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=Mbp9oS2WavuT7QOId+e1HrKqko7T7hVMft4NMunyWtM=; b=Nt+KyankkkDZbLJVg8i1DKM5EvWtSxT1Q1rGmf8kRYPthwgf6Y2TYDPIYuW4iseg5cvj82 dOg1kljXjMTAX7kWAaS5t79sJFh3vd6L1IOaki06aZmNhbK3iPhdfbeTdqIANRCAXuAH8e j8FZzp90vERSbQvgUnoSjUTUBdMLVj4= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1788709723; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=Mbp9oS2WavuT7QOId+e1HrKqko7T7hVMft4NMunyWtM=; b=YapVChgznBGn6EcKUw7/IGJfF3cSTI8Nro5/XgD9oGQkgQHkMl0V1AdpTeoHRFIiBwI7dE jud4a0CH4O+IPYBQ== Authentication-Results: smtp-out2.suse.de; dkim=pass header.d=suse.de header.s=susede2_rsa header.b="H8/ur+sc"; dkim=pass header.d=suse.de header.s=susede2_ed25519 header.b=pEytpfYk DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1788709719; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=Mbp9oS2WavuT7QOId+e1HrKqko7T7hVMft4NMunyWtM=; b=H8/ur+schi1v7HzZx/OmVMvcbLN7XJFQiPq7Yvj8j2uaV5hCA1G4820ExZoRtszQ/3j/IO vfmiqQSQERkFHsApdoT5KZAGAcX6r9WO6AUuRit/VtOBldNvZ3/zQwzW9vL86kHH42xITo meOKj36SSzv3fcxyx4RZx9/T16uqpBg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1788709719; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=Mbp9oS2WavuT7QOId+e1HrKqko7T7hVMft4NMunyWtM=; b=pEytpfYk6jGBWVQfBEAgxQ7cvKuPnAUEK7zV9/r5TktCqKwCE5YPXvV6vIYavzxCFjnnfm gfuSpf424Kz0lCAA== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 6D182133CF for ; Sun, 6 Sep 2026 15:48:39 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id 5J03GVeLnWqvNAAAD6G6ig (envelope-from ) for ; Sun, 06 Sep 2026 15:48:39 +0000 From: Tom de Vries To: gdb-patches@sourceware.org Subject: [PATCH 1/2] [gdb/testsuite] Fix timeout in do_self_tests Date: Sun, 6 Sep 2026 17:48:37 +0200 Message-ID: <20260906154838.139837-1-tdevries@suse.de> X-Mailer: git-send-email 2.51.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 9831D1F394 X-Rspamd-Server: rspamd1.dmz-prg2.suse.org X-Rspamd-Action: no action X-Spamd-Result: default: False [-3.01 / 50.00]; BAYES_HAM(-3.00)[100.00%]; MID_CONTAINS_FROM(1.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; R_MISSING_CHARSET(0.50)[]; R_DKIM_ALLOW(-0.20)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; NEURAL_HAM_SHORT(-0.20)[-0.999]; MIME_GOOD(-0.10)[text/plain]; MX_GOOD(-0.01)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; ARC_NA(0.00)[]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:97:from]; MIME_TRACE(0.00)[0:+]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.de:dkim,suse.de:mid,imap1.dmz-prg2.suse.org:helo,imap1.dmz-prg2.suse.org:rdns,sourceware.org:url]; DNSWL_BLOCKED(0.00)[2a07:de40:b281:106:10:150:64:167:received]; PREVIOUSLY_DELIVERED(0.00)[gdb-patches@sourceware.org]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; RCVD_TLS_ALL(0.00)[]; TO_DN_NONE(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DKIM_TRACE(0.00)[suse.de:+] X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org I noticed a patch reporting a timeout in the selftests on slow systems [1]. I tried to see if I could trigger some timeouts. With the following setup: - gdb build with -O0 - running gdb.gdb/*.exp - aarch64-linux platform - all cpu threads set to the lowest value: 600 Mhz - taskset -c 0 I managed to trigger timeouts in the form of warnings: ... (gdb) set height 0 WARNING: Couldn't set the height to 0 set width 0 WARNING: Couldn't set the width to 0. break main (gdb) set width 0 (gdb) break main Breakpoint 1 at 0x41767c: file gdb.c, line 30. (gdb) ... in both gdb.gdb/selftest.exp and gdb.gdb/python-helper.exp. Note that this is extra slow because the default worker-threads is set using std::thread::hardware_concurrency, which is 8 even though we use taskset -c 0: ... $ taskset -c 0 gdb -q -batch -ex "maint show worker-thread" The number of worker threads GDB can use is the default (currently 8). ... making 8 worker threads compete for 1 cpu thread. The timeouts are triggered in do_self_tests by gdb loading the symbols in the background, making the effort to do so overlap with subsequent commands. Fix this using "maintenance set dwarf synchronous on". [1] https://sourceware.org/pipermail/gdb-patches/2026-September/230133.html --- gdb/testsuite/lib/selftest-support.exp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/gdb/testsuite/lib/selftest-support.exp b/gdb/testsuite/lib/selftest-support.exp index bcfa99e8f34..cc9ad0b4127 100644 --- a/gdb/testsuite/lib/selftest-support.exp +++ b/gdb/testsuite/lib/selftest-support.exp @@ -246,7 +246,18 @@ proc do_self_tests {body} { set ::GDB "libtool --mode=execute $::GDB" } - set ::GDBFLAGS "$::GDBFLAGS $file" + # By default, dwarf synchronous is off, so the effort to load $file + # may be spread over subsequent commands and cause timeouts on slow + # systems. Use "maintenance set dwarf synchronous on", to make sure + # $file is completely loaded during gdb_start. + # Proc gdb_start has a timeout of 600 for spawning gdb, which seems + # sufficient to handle both spawning gdb and loading $file. + # Using gdb_load would permit a timeout of 120s just for loading + # $file, but we're not using that because we want libtool to + # update $file. + append ::GDBFLAGS \ + " " -iex " " {"maintenance set dwarf synchronous on"} \ + " " $file gdb_start } base-commit: 668300e5c9e1e8baa55d9402cdd4dff5e81601d2 -- 2.51.0