From patchwork Wed Apr 29 23:03:52 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134194 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id B4C784358A67 for ; Wed, 29 Apr 2026 23:05:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B4C784358A67 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=CTF6ptZT X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2e.google.com (mail-vk1-xa2e.google.com [IPv6:2607:f8b0:4864:20::a2e]) by sourceware.org (Postfix) with ESMTPS id 05EDC4BB3BD2 for ; Wed, 29 Apr 2026 23:04:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 05EDC4BB3BD2 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 05EDC4BB3BD2 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2e ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503880; cv=none; b=aYus78s7HumHzFAjWN/Sd/ATzDSgcl/f7bCmutauc6fQSYXAD09DpI02ZlXnfnmYZjsyrmJq9yhXKN9j8QporjCbeyBJjmVC+uEUH8KwF7/Gy4w3gsk2+eUx2Ts0nNCwqbJjSUSC9fnASVG0UJSt68/FoYMu/guLhTzrrAKOfu0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503880; c=relaxed/simple; bh=SDcoNcf5BWp5vQpMdf05ZN6y+Ht6IFWvXF/25IKz+Vc=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=hewwg8wHVkUmB0XwlSYrSFfGPk/pLkLiPjxmt8NBcBIMXAttwt21kEd1gohK6cLxcIoPI22+S2AJIOEJ8nKmeaSiWmL+yJd9/XNEt2nUAHs/WIJJZAcvo6TQ0kpuvHq3VjTt77hjic4jUW2r/v2FZ9i+HbK17m65JW+x313Wj9E= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 05EDC4BB3BD2 Received: by mail-vk1-xa2e.google.com with SMTP id 71dfb90a1353d-56f3e6bbecdso114972e0c.2 for ; Wed, 29 Apr 2026 16:04:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503879; x=1778108679; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Fq6+Ur2Y2aVaNmD0c9fO364hZzroM9ZUTkx1sI6pIBA=; b=CTF6ptZTXhv5CKbzsFQN2yroLWIiQzsmzJ95pnD+YqJpqX+KNbmfXDj48vVv2aLrCQ YXSyQJtuxTpHDp4rU7ligFvFhLmlIVSjuKCiHgKtQWA3+aNAFRfqQCyN8g5T/w6n6ueV r9un3FHkH3C7IB5pnIvZ63wRurLrxlQm5797wAXOTAvIPv5gG75UsbvACthrnPMmpDPg 181rmeWeM8f/PaQtvoBQnZwjs6z8srb38qtDKRGTzt8UD7qhDybCGv9AoYsJk69+GtOh NO30SBicNP8Er6xxTarOrOiNWh8UzghZ0esAxYfw2XM+xoJF8yfGXRCaiERShG2Pe7bF K6YQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503879; x=1778108679; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=Fq6+Ur2Y2aVaNmD0c9fO364hZzroM9ZUTkx1sI6pIBA=; b=DeYGz3xGvDmCxohtM6Lb1pLLqSdGE7Ypx9CEyFgUmfUlte5RXpcfSXjv9/LGy9kHFR ZDqI4vt8sPg+hx7M+SSUenU0tC3KTsOsKyDpAX5OZMI84pUyz5vY1Dl98c53JhR2zUSt WrKwnCSOhKhwgq6lZYir75xSvikL9jRMICRP471n4Qby2nOkrUfDDyefSJaEAVsIGe8B SlCX61I+uVMuts/MUXA9b117XTizA+sWH3Oalw8cix8oQ7duKZBh/oNp5vjHO5i0kq3o 6M3B18HE/dxPeJLQTwGT3enXmFYJFieeMAnpojs4PVPW+NN0PZYlubi3U8SEiei5X9Dy 3hYg== X-Gm-Message-State: AOJu0Yx6s/I689FFCnuLpA+DCeK5exei8aUDrVlUs96L5qgifOpRlA8B YI4GjcGTrlmYk6OH0fUMiNYqg3YYHefWCuxR0NZmox6VGu4QayO51kETmt1/U0bFgVRrc3YL+06 vyZZ6 X-Gm-Gg: AeBDievFjIyzJh4nNYoDidGnHjnVwXt6+199yfMittzNB+8UfAk2DprkrJ8TeFNOOle XD1dzIlSnpo0ib1RJvlsuIvc9dXms1gYy8jMXmCkKJEJ/+SLMx2R5MPbTQ9b0xO4XDBRgnlB4Qf 3JRLuZnUiWm3PBNBNP9h2VyOAksxWdpnRmD+eUy5I778D3m22JRoTFMeagaENxtYzPDfY9eNtkU FBgySDQbbJCns5Idm22ADc9FvWwlFPrx67Waq20YMUJQ6xf3E+W/Fmc/dFhvYeczVMq8hm6Zx7g 043lpMpquHLEVUIqSyL2pJ1mK+9KdxIFRCxAhw6CBshElI5noBB9svfenC6dbKLLkhJFhEl1TJW oz1VGaRRfp8o4Faid4JAUKyBd45xW2LM82EoOu8rrXEDI6G/0feYqq4LR5tcH+ABtsgi2zWp7iW jdqIYwKRT3+putprEsdeApmKp+qLAuHxyZOCEefxGNE3IR X-Received: by 2002:a05:6122:e266:b0:56b:5e7e:d3fa with SMTP id 71dfb90a1353d-573c9607b49mr89326e0c.7.1777503879061; Wed, 29 Apr 2026 16:04:39 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6ddbac7sm2046567e0c.13.2026.04.29.16.04.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:38 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 01/37] GDB: testsuite: aarch64, arm: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:03:52 -0300 Message-ID: <20260429230432.60487-2-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' \ aarch64-*.exp* arm-*.exp* thumb*.exp* iwmmxt-regs.exp pr25124.exp and $ sed -i 's/^ return 0/ return/' \ aarch64-*.exp* arm-*.exp* thumb*.exp* iwmmxt-regs.exp pr25124.exp inside gdb/testsuite/gdb.arch. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.arch/aarch64-atomic-inst.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-brk-patterns.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-fp.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-fpmr-core.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-fpmr-sighandler.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-fpmr.exp | 4 ++-- .../gdb.arch/aarch64-frameptr-vecreg-unwind.exp | 2 +- gdb/testsuite/gdb.arch/aarch64-mops-single-step.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-mops-watchpoint.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-mte.exp | 12 ++++++------ gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-pauth.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-prologue.exp | 2 +- gdb/testsuite/gdb.arch/aarch64-pseudo-unwind.exp | 2 +- gdb/testsuite/gdb.arch/aarch64-sighandler-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-sme-sanity.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-tagged-pointer.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-unwind-pc.exp | 4 ++-- gdb/testsuite/gdb.arch/aarch64-w-registers.exp | 4 ++-- gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp | 4 ++-- gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp | 2 +- gdb/testsuite/gdb.arch/arm-disp-step.exp | 4 ++-- gdb/testsuite/gdb.arch/arm-neon.exp | 4 ++-- gdb/testsuite/gdb.arch/arm-pseudo-unwind-legacy.exp | 2 +- gdb/testsuite/gdb.arch/arm-pseudo-unwind.exp | 2 +- .../gdb.arch/arm-single-step-kernel-helper.exp | 6 +++--- gdb/testsuite/gdb.arch/iwmmxt-regs.exp | 2 +- gdb/testsuite/gdb.arch/pr25124.exp | 2 +- gdb/testsuite/gdb.arch/thumb-bx-pc.exp | 4 ++-- gdb/testsuite/gdb.arch/thumb-prologue.exp | 4 ++-- gdb/testsuite/gdb.arch/thumb-singlestep.exp | 4 ++-- gdb/testsuite/gdb.arch/thumb2-it.exp | 4 ++-- 32 files changed, 61 insertions(+), 61 deletions(-) diff --git a/gdb/testsuite/gdb.arch/aarch64-atomic-inst.exp b/gdb/testsuite/gdb.arch/aarch64-atomic-inst.exp index 269e32cecc74..38c83d67dc44 100644 --- a/gdb/testsuite/gdb.arch/aarch64-atomic-inst.exp +++ b/gdb/testsuite/gdb.arch/aarch64-atomic-inst.exp @@ -20,15 +20,15 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "[gdb_get_line_number "ldxr"]" \ "Breakpoint $decimal at $hex" \ "Set the breakpoint at the start of the sequence" diff --git a/gdb/testsuite/gdb.arch/aarch64-brk-patterns.exp b/gdb/testsuite/gdb.arch/aarch64-brk-patterns.exp index f3abd842d0ea..b23d36b8e2bb 100644 --- a/gdb/testsuite/gdb.arch/aarch64-brk-patterns.exp +++ b/gdb/testsuite/gdb.arch/aarch64-brk-patterns.exp @@ -20,15 +20,15 @@ require is_aarch64_target standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Number of expected SIGTRAP's to get. This needs to be kept in sync # with the source file. set expected_traps 3 diff --git a/gdb/testsuite/gdb.arch/aarch64-fp.exp b/gdb/testsuite/gdb.arch/aarch64-fp.exp index e2e3777a7289..7d8c323ba2a4 100644 --- a/gdb/testsuite/gdb.arch/aarch64-fp.exp +++ b/gdb/testsuite/gdb.arch/aarch64-fp.exp @@ -20,15 +20,15 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set endianness [get_endianness] gdb_test "break ${srcfile}:[gdb_get_line_number "return"]" \ diff --git a/gdb/testsuite/gdb.arch/aarch64-fpmr-core.exp b/gdb/testsuite/gdb.arch/aarch64-fpmr-core.exp index dea9f82bd4a1..81ebd4892aa9 100644 --- a/gdb/testsuite/gdb.arch/aarch64-fpmr-core.exp +++ b/gdb/testsuite/gdb.arch/aarch64-fpmr-core.exp @@ -40,17 +40,17 @@ proc check_fpmr_core_file {core_filename} { require is_aarch64_target require allow_aarch64_fpmr_tests standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } set binfile [standard_output_file ${testfile}] if {![runto_main]} { - return -1 + return } set crash_breakpoint "crash point" gdb_breakpoint [gdb_get_line_number $crash_breakpoint] gdb_continue_to_breakpoint $crash_breakpoint diff --git a/gdb/testsuite/gdb.arch/aarch64-fpmr-sighandler.exp b/gdb/testsuite/gdb.arch/aarch64-fpmr-sighandler.exp index d0c23ca2861a..19c28c70c50d 100644 --- a/gdb/testsuite/gdb.arch/aarch64-fpmr-sighandler.exp +++ b/gdb/testsuite/gdb.arch/aarch64-fpmr-sighandler.exp @@ -20,15 +20,15 @@ require is_aarch64_target require allow_aarch64_fpmr_tests standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } set reg_main_value "0x3fff7fc049" set reg_handler_value "0xff008041" diff --git a/gdb/testsuite/gdb.arch/aarch64-fpmr.exp b/gdb/testsuite/gdb.arch/aarch64-fpmr.exp index bbaf2bf3eed9..72fd977fc673 100644 --- a/gdb/testsuite/gdb.arch/aarch64-fpmr.exp +++ b/gdb/testsuite/gdb.arch/aarch64-fpmr.exp @@ -18,15 +18,15 @@ require is_aarch64_target require allow_aarch64_fpmr_tests standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_multiple "info register \$fpmr" "Test FPMR SRC1 E5M2" { -re ".*\r\n.*\[ \ F8S1=E5M2 \ diff --git a/gdb/testsuite/gdb.arch/aarch64-frameptr-vecreg-unwind.exp b/gdb/testsuite/gdb.arch/aarch64-frameptr-vecreg-unwind.exp index 784868651b8d..29c44a657adb 100644 --- a/gdb/testsuite/gdb.arch/aarch64-frameptr-vecreg-unwind.exp +++ b/gdb/testsuite/gdb.arch/aarch64-frameptr-vecreg-unwind.exp @@ -17,11 +17,11 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} \ "${srcfile}" {debug}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.arch/aarch64-mops-single-step.exp b/gdb/testsuite/gdb.arch/aarch64-mops-single-step.exp index 3671d3fdaa35..b489723b9869 100644 --- a/gdb/testsuite/gdb.arch/aarch64-mops-single-step.exp +++ b/gdb/testsuite/gdb.arch/aarch64-mops-single-step.exp @@ -20,11 +20,11 @@ require allow_aarch64_mops_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug additional_flags=-march=armv9.3-a]] } { - return -1 + return } # If the inferior is rescheduled to another CPU while a main or epilogue # instruction is executed, the OS resets the inferior back to the prologue # instruction, so we need to allow for that possibility. @@ -70,11 +70,11 @@ proc step_through_sequence { prefix } { fail "step through $prefix sequence" return 0 } if {![runto_main]} { - return -1 + return } gdb_breakpoint ${srcfile}:[gdb_get_line_number "Break memset"] gdb_breakpoint ${srcfile}:[gdb_get_line_number "Break memcpy"] gdb_breakpoint ${srcfile}:[gdb_get_line_number "Break memmove"] diff --git a/gdb/testsuite/gdb.arch/aarch64-mops-watchpoint.exp b/gdb/testsuite/gdb.arch/aarch64-mops-watchpoint.exp index da80fa2fe8ed..35d15d2588a0 100644 --- a/gdb/testsuite/gdb.arch/aarch64-mops-watchpoint.exp +++ b/gdb/testsuite/gdb.arch/aarch64-mops-watchpoint.exp @@ -22,16 +22,16 @@ require allow_hw_watchpoint_tests allow_aarch64_mops_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug additional_flags=-march=armv9.3-a]] } { - return -1 + return } set linespec ${srcfile}:[gdb_get_line_number "Break here"] if {![runto ${linespec}]} { - return -1 + return } gdb_test "watch -location a\[28\]" \ "(Hardware w|W)atchpoint ${decimal}: -location a\\\[28\\\]" \ "set watch on a" diff --git a/gdb/testsuite/gdb.arch/aarch64-mte.exp b/gdb/testsuite/gdb.arch/aarch64-mte.exp index 4da381095739..4826041e330a 100644 --- a/gdb/testsuite/gdb.arch/aarch64-mte.exp +++ b/gdb/testsuite/gdb.arch/aarch64-mte.exp @@ -45,46 +45,46 @@ proc get_ltag_from_ptr { ptr } { require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Targets that don't support memory tagging should not execute the # runtime memory tagging tests. if {![supports_memtag]} { unsupported "memory tagging unsupported" - return -1 + return } gdb_breakpoint "access_memory" if {[gdb_continue "access_memory"]} { - return -1 + return } # Fetch a known pointer to an area mapped with PROT_MTE. set tagged_ptr_symbol "tagged_ptr" set tagged_ptr_addr [get_hexadecimal_valueof $tagged_ptr_symbol -1] if {$tagged_ptr_addr == -1} { unresolved "unexpected pointer or tag value" - return -1 + return } # Fetch a known pointer to an area not mapped with PROT_MTE. set untagged_ptr_symbol "untagged_ptr" set untagged_ptr_addr [get_hexadecimal_valueof $untagged_ptr_symbol -1] if {$untagged_ptr_addr == -1} { unresolved "unexpected pointer or tag value" - return -1 + return } with_test_prefix "literals" { # Test inspecting an allocation tag from a pointer to a memory area that # is not mapped with PROT_MTE. diff --git a/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp b/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp index 2f90b518fcb6..8066b2035e1b 100644 --- a/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp +++ b/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp @@ -21,15 +21,15 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # We need to iterate over two distinct ranges, separated by a single bit. # This bit is 55 (VA_RANGE_SELECT) which tells us if we have a kernel-space # address or a user-space address. diff --git a/gdb/testsuite/gdb.arch/aarch64-pauth.exp b/gdb/testsuite/gdb.arch/aarch64-pauth.exp index e89ec701342a..6f363097f030 100644 --- a/gdb/testsuite/gdb.arch/aarch64-pauth.exp +++ b/gdb/testsuite/gdb.arch/aarch64-pauth.exp @@ -40,15 +40,15 @@ foreach pauth_flag "-mbranch-protection=pac-ret+leaf -msign-return-address=all" } } # If we couldn't compile, just bail out. if {!$compilation_ok} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [ gdb_get_line_number "break here" ] gdb_continue_to_breakpoint "break here" ".*break here.*" diff --git a/gdb/testsuite/gdb.arch/aarch64-prologue.exp b/gdb/testsuite/gdb.arch/aarch64-prologue.exp index 98583e84aa9f..c6fe2e262a5e 100644 --- a/gdb/testsuite/gdb.arch/aarch64-prologue.exp +++ b/gdb/testsuite/gdb.arch/aarch64-prologue.exp @@ -17,11 +17,11 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}]} { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.arch/aarch64-pseudo-unwind.exp b/gdb/testsuite/gdb.arch/aarch64-pseudo-unwind.exp index f2bf2236a9b1..d43ab468cabe 100644 --- a/gdb/testsuite/gdb.arch/aarch64-pseudo-unwind.exp +++ b/gdb/testsuite/gdb.arch/aarch64-pseudo-unwind.exp @@ -24,11 +24,11 @@ if { ![istarget aarch64-*-* ] } { standard_testfile aarch64-pseudo-unwind.c aarch64-pseudo-unwind-asm.S if { [prepare_for_testing "failed to prepare" ${testfile} \ "${srcfile} ${srcfile2}" {debug}] } { - return -1 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.arch/aarch64-sighandler-regs.exp b/gdb/testsuite/gdb.arch/aarch64-sighandler-regs.exp index aff80020cd33..740b807e7078 100644 --- a/gdb/testsuite/gdb.arch/aarch64-sighandler-regs.exp +++ b/gdb/testsuite/gdb.arch/aarch64-sighandler-regs.exp @@ -27,15 +27,15 @@ if { ![allow_aarch64_sve_tests] } { lappend compile_flags "additional_flags=-DSVE" } standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} ${compile_flags}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set endianness [get_endianness] if {$endianness == "little"} { diff --git a/gdb/testsuite/gdb.arch/aarch64-sme-sanity.exp b/gdb/testsuite/gdb.arch/aarch64-sme-sanity.exp index f3ded57969d2..c0c4af53a4f9 100644 --- a/gdb/testsuite/gdb.arch/aarch64-sme-sanity.exp +++ b/gdb/testsuite/gdb.arch/aarch64-sme-sanity.exp @@ -45,15 +45,15 @@ require allow_aarch64_sme_tests require !gdb_protocol_is_remote set compile_flags {"debug" "macros" "additional_flags=-march=armv8.5-a+sve"} standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} ${compile_flags}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Adjust the repeat count for the test. gdb_test_no_output "set print repeats 1" "adjust repeat count" diff --git a/gdb/testsuite/gdb.arch/aarch64-tagged-pointer.exp b/gdb/testsuite/gdb.arch/aarch64-tagged-pointer.exp index 21242a698cc1..12cede6e2eb2 100644 --- a/gdb/testsuite/gdb.arch/aarch64-tagged-pointer.exp +++ b/gdb/testsuite/gdb.arch/aarch64-tagged-pointer.exp @@ -17,15 +17,15 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "breakpoint here"] gdb_continue_to_breakpoint "breakpoint here" diff --git a/gdb/testsuite/gdb.arch/aarch64-unwind-pc.exp b/gdb/testsuite/gdb.arch/aarch64-unwind-pc.exp index 7ee2eec43b81..e08b4d1f90ee 100644 --- a/gdb/testsuite/gdb.arch/aarch64-unwind-pc.exp +++ b/gdb/testsuite/gdb.arch/aarch64-unwind-pc.exp @@ -20,15 +20,15 @@ require is_aarch64_target standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } proc test_reg_vals {} { gdb_test "p \$pc - &main" "= 8" "p \$pc" gdb_test "p/x \$x30" "= 0x1234" "p \$x30" diff --git a/gdb/testsuite/gdb.arch/aarch64-w-registers.exp b/gdb/testsuite/gdb.arch/aarch64-w-registers.exp index 31de299c7f16..c2685b302012 100644 --- a/gdb/testsuite/gdb.arch/aarch64-w-registers.exp +++ b/gdb/testsuite/gdb.arch/aarch64-w-registers.exp @@ -18,16 +18,16 @@ require is_aarch64_target standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}]} { - return -1 + return } if {![runto_main]} { untested "could not run to main" - return -1 + return } array set w_values { 0 0x0 1 0x10 diff --git a/gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp b/gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp index c0516313ee30..703d5d66f4e1 100644 --- a/gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp +++ b/gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp @@ -22,13 +22,13 @@ standard_testfile # on ARM, causing the PC to acquire a wrong value. That's why we use # the "-Wl,-Ttext-segment" option compile the binary. if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug text_segment=0xb0000000]] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_test "next" "${::decimal}\\s+return 0;" diff --git a/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp b/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp index cb6d9e60b0bf..c2ecaffd1d2c 100644 --- a/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp +++ b/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp @@ -17,11 +17,11 @@ require {istarget "arm*-*-*"} standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile ]} { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.arch/arm-disp-step.exp b/gdb/testsuite/gdb.arch/arm-disp-step.exp index 8bf9da42a59d..d68c7c85e279 100644 --- a/gdb/testsuite/gdb.arch/arm-disp-step.exp +++ b/gdb/testsuite/gdb.arch/arm-disp-step.exp @@ -20,11 +20,11 @@ require is_aarch32_target standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } ######################################### # Test ldm/stm related to PC. @@ -405,11 +405,11 @@ proc test_add_rn_pc {} { # is on, and we type 'run', GDB will first try to single step on _dl_debug_state, # which is in library might be compiled in Thumb. gdb_test_no_output "set displaced-stepping off" if {![runto_main]} { - return 0 + return } gdb_test_no_output "set displaced-stepping on" gdb_test "show displaced-stepping" ".* displaced stepping .* is on.*" diff --git a/gdb/testsuite/gdb.arch/arm-neon.exp b/gdb/testsuite/gdb.arch/arm-neon.exp index e15c04420c72..3ef346150d65 100644 --- a/gdb/testsuite/gdb.arch/arm-neon.exp +++ b/gdb/testsuite/gdb.arch/arm-neon.exp @@ -20,15 +20,15 @@ require {is_any_target "aarch64*-*-*" "arm*-*-*"} require allow_float_test standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug quiet}] } { unsupported "ARM NEON is not supported" - return -1 + return } if {![runto_main]} { - return -1 + return } # Test passing vectors in function argument in the inferior call. for {set i 1} {$i <= 18} {incr i} { diff --git a/gdb/testsuite/gdb.arch/arm-pseudo-unwind-legacy.exp b/gdb/testsuite/gdb.arch/arm-pseudo-unwind-legacy.exp index bdfe665ee70b..06a9ba3a74ed 100644 --- a/gdb/testsuite/gdb.arch/arm-pseudo-unwind-legacy.exp +++ b/gdb/testsuite/gdb.arch/arm-pseudo-unwind-legacy.exp @@ -29,11 +29,11 @@ if { ![istarget arm*-*-* ] } { standard_testfile arm-pseudo-unwind-legacy.c arm-pseudo-unwind-legacy-asm.S if { [prepare_for_testing "failed to prepare" ${testfile} \ "${srcfile} ${srcfile2}" {debug additional_flags=-marm}] } { - return -1 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.arch/arm-pseudo-unwind.exp b/gdb/testsuite/gdb.arch/arm-pseudo-unwind.exp index af637d639757..d2d65f792d59 100644 --- a/gdb/testsuite/gdb.arch/arm-pseudo-unwind.exp +++ b/gdb/testsuite/gdb.arch/arm-pseudo-unwind.exp @@ -24,11 +24,11 @@ if { ![istarget arm*-*-* ] } { standard_testfile arm-pseudo-unwind.c arm-pseudo-unwind-asm.S if { [prepare_for_testing "failed to prepare" ${testfile} \ "${srcfile} ${srcfile2}" {debug additional_flags=-marm}] } { - return -1 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.arch/arm-single-step-kernel-helper.exp b/gdb/testsuite/gdb.arch/arm-single-step-kernel-helper.exp index 78d7c2fbb3af..be1e123d265e 100644 --- a/gdb/testsuite/gdb.arch/arm-single-step-kernel-helper.exp +++ b/gdb/testsuite/gdb.arch/arm-single-step-kernel-helper.exp @@ -17,15 +17,15 @@ require is_aarch32_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug]] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # Initialize kernel_user_helper_version. gdb_test "next" "for .*" @@ -41,11 +41,11 @@ gdb_test_multiple "p kernel_user_helper_version" \ } } if { !$kernel_helper_supported } { unsupported "kernel doesn't have helpers" - return 0 + return } # Get the instruction branching to kernel helper, they can be # blx rN or bx rN. set branch_to_kernel_helper 0 diff --git a/gdb/testsuite/gdb.arch/iwmmxt-regs.exp b/gdb/testsuite/gdb.arch/iwmmxt-regs.exp index 6c1848593b21..5317c9bfae35 100644 --- a/gdb/testsuite/gdb.arch/iwmmxt-regs.exp +++ b/gdb/testsuite/gdb.arch/iwmmxt-regs.exp @@ -36,11 +36,11 @@ gdb_load ${binfile} # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # Set all the registers to arbitrary values. for {set i 0} {$i < 16} {incr i 1} { gdb_test "set \$wR$i.u64 = ((${i}LL << 32) | ${i})" "" "set reg wR$i" diff --git a/gdb/testsuite/gdb.arch/pr25124.exp b/gdb/testsuite/gdb.arch/pr25124.exp index 6086790bc568..b543812a50a4 100644 --- a/gdb/testsuite/gdb.arch/pr25124.exp +++ b/gdb/testsuite/gdb.arch/pr25124.exp @@ -20,11 +20,11 @@ require is_aarch32_target standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile # Check if the disassemble ouput is correct. diff --git a/gdb/testsuite/gdb.arch/thumb-bx-pc.exp b/gdb/testsuite/gdb.arch/thumb-bx-pc.exp index 3a86ea2e2922..29dbfb348931 100644 --- a/gdb/testsuite/gdb.arch/thumb-bx-pc.exp +++ b/gdb/testsuite/gdb.arch/thumb-bx-pc.exp @@ -20,15 +20,15 @@ require is_aarch32_target set testfile "thumb-bx-pc" set srcfile ${testfile}.S set opts {} if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "stepi" "$hex in main \\(\\)" "stepi for bx pc" gdb_test "x /i \$pc" \ diff --git a/gdb/testsuite/gdb.arch/thumb-prologue.exp b/gdb/testsuite/gdb.arch/thumb-prologue.exp index ccf7a235cd73..d0eb17927746 100644 --- a/gdb/testsuite/gdb.arch/thumb-prologue.exp +++ b/gdb/testsuite/gdb.arch/thumb-prologue.exp @@ -21,22 +21,22 @@ standard_testfile # Don't use "debug", so that we don't have line information for the assembly # fragments. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {"additional_flags=-mthumb"}] != "" } { untested "ARM prologue tests" - return -1 + return } clean_restart $testfile # # Run to `main' where we begin our tests. # if {![runto_main]} { - return -1 + return } # Testcase for TPCS prologue. gdb_breakpoint "* *(int *)tpcs_offset + (int) &tpcs_frame_1" diff --git a/gdb/testsuite/gdb.arch/thumb-singlestep.exp b/gdb/testsuite/gdb.arch/thumb-singlestep.exp index 53fce5770a94..cb9f77f4ee76 100644 --- a/gdb/testsuite/gdb.arch/thumb-singlestep.exp +++ b/gdb/testsuite/gdb.arch/thumb-singlestep.exp @@ -20,15 +20,15 @@ require is_aarch32_target set testfile "thumb-singlestep" set srcfile ${testfile}.S set additional_flags "additional_flags=-mthumb" if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} [list debug $additional_flags]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # GDB doesn't skip prologue for asm files, so do one single step to # pass instruction "push". gdb_test "si" "blx foo.*" "single step" diff --git a/gdb/testsuite/gdb.arch/thumb2-it.exp b/gdb/testsuite/gdb.arch/thumb2-it.exp index d100a34acc1c..0c9246b2131e 100644 --- a/gdb/testsuite/gdb.arch/thumb2-it.exp +++ b/gdb/testsuite/gdb.arch/thumb2-it.exp @@ -19,17 +19,17 @@ require {istarget arm*-*eabi*} standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile if {![runto_main]} { - return -1 + return } # Make sure that the compiler options allow Thumb-2. gdb_test_multiple "list" "list main" { -re ".*@ No Thumb-2.*$gdb_prompt $" { From patchwork Wed Apr 29 23:03:53 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134195 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 822234358A5A for ; Wed, 29 Apr 2026 23:05:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 822234358A5A Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=Urtjr0he X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa29.google.com (mail-vk1-xa29.google.com [IPv6:2607:f8b0:4864:20::a29]) by sourceware.org (Postfix) with ESMTPS id 6FE7A4BB3BE4 for ; Wed, 29 Apr 2026 23:04:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6FE7A4BB3BE4 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 6FE7A4BB3BE4 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a29 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503883; cv=none; b=Yc40Ab4uIXBUrf9iVYdZ50OTnf9b5mdOYsVC58zF2A1tudjnAiVfTQWX0snuZfJ5EmRUClt5of7ttjiHR4rzHFkL/oHc4IbjrbO/qLQuEuNUYht3DvGwKzb5cbxmLhzQaBeYO76Omiuyb0kJsEicdILMH3fjSUHrRLVL2lSiG3U= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503883; c=relaxed/simple; bh=4lRkJSCsBE2yJ7Tn+3xoWebL6Hh+GOW1jYSejhPLcoU=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=vKMRTmkyxkt4W6KWFeOTERP+ZFNSDCfjWaP+8YotjFWR542CDB/sm7sbxW3QVKpDvc0fUM+njAqkUd9cdj993e0VvCv4/gmS1hz0E2ezYVrGWete7Wh6Wi1jmjDhSTR2PBcmVaIpWn8BEKuDLqYVIoDNcKXVVuXanxpRb3GowTE= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6FE7A4BB3BE4 Received: by mail-vk1-xa29.google.com with SMTP id 71dfb90a1353d-5675d609621so262508e0c.2 for ; Wed, 29 Apr 2026 16:04:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503883; x=1778108683; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=lQ3Nh6ui+GH3cdPPCj7h7F9rr4qRwqsmIanpmgX7uG0=; b=Urtjr0he7cbK5MWmhMu0+NpKSXZIdzGSwAlpmlKx2vkgxNv/aM7Q0rezspltNdGCbb RArpKuGMkjo/dOikHdKnMhAhsGZMG7HMVvqBuJoL3ETMQyn7EeM7BJ32Qp/MdbN8chy0 nWFr6Mgb8X2PwvxOVRgdWek1XQIsVyp90UI3AqRhBba4kXuks8Xt6xWTcF18fcaxDNV6 LYgxbXyUerJrSyBzFQEJnWmp6NyL9esSfPPw67/wOHKeT42712f/iI+LuFg6XiXWf48x iTOvIGsD1mDF5EkL4Sim1MMaD99LjpL16kRwpstZGd+O1wWCXvF7DuVPmh8GTkoAm35N af7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503883; x=1778108683; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=lQ3Nh6ui+GH3cdPPCj7h7F9rr4qRwqsmIanpmgX7uG0=; b=HhuEEa/HHRMPL5I85SmiNf05hpupkre+wADaX+ZX780K8GgqcNIck07uFXbuF6nCBU CIn+dpJ4S+O846lgjqnpzYs3YbME8erQ9E4RAGGd60l3aV08wkZxeIGU+SZuPxm946qf AHu/wblJ8j9gAPJN0WdpoV03KTwB+NeI4CYRoMdTdCNYKudF/JopVdl0Mu5zXDCXrmmJ hM4oHM6zmlYugpmUzaasHnZfrnT7nus3Io71Nii5NNIMn1LtcN8xjpQ8fSZQ4mRvhVuS M54ccG4fRMYtlsX4KlSd62GaZMI7Ap0W0pPu9CatnA5TA0jVP36JCXc+tCqwHUOnDm7H Ketg== X-Gm-Message-State: AOJu0YyTAm9mIisTKARWHh+Dy/Y9ErO5j4jLOHVKP3prkfb+X1c1IwZc uyqFJAEryF8SCDj33kWYAbDZb5xlPhekb8Y0zlVZla/+6FFsQ8WTozQm2O26spFK+2F7j+YCHWV 8dyMG X-Gm-Gg: AeBDiesyZdThOPAEg+yZzGL6oP7PMTY1vnSn/UxkK9VbzH48bnckTv9MylnVqqam7nY UyejRSJWHHNcTLtx2GqsOXcEK5ifxAC8Whaq9b0jl/DjiE5/t5YZIVn8G+3tehRM+1MvomQQSoD detT7KYLKLUuzVfqSNYvjM03vqH3xgQXs5A5RqKDyAPdfoYNsZi4ebaMQqEwSuRNuqZLd6mJSoD ZA7w4KZuq7k6WBtQ1zk6UaitsPpf8qqxfNZjVjp3QioFikxugK4OiF6pGIl5zVlK+9QloJSf0KX 1iGyW09iMv3k/6jQwBORJmKFwByPW4s4Z+2VYgGy7b6GpyLEYFrGAspjXE4jtSu2L4Lns2u6cNX egpLYP2bBcEkI8uzFMcxdblYUXHeLivlHcZGDGSbzGte2XIhA77r5RWH7Gh4+dMRggj1IQHSINT rPx4BjGsAwNoYbOBWgO8WXlC6iKv66f0fclL0UBU3Wl8pE X-Received: by 2002:a05:6122:c82:b0:56c:ca03:b668 with SMTP id 71dfb90a1353d-573c9577ef4mr96286e0c.3.1777503882710; Wed, 29 Apr 2026 16:04:42 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6b7d1f5sm2047650e0c.3.2026.04.29.16.04.41 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:41 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 02/37] GDB: testsuite: aarch64, arm: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:03:53 -0300 Message-ID: <20260429230432.60487-3-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes the "return -1" statements that weren't caught by the sed command. In aarch64-prologue.exp and arm-cmse-sgstubs.exp, this was caused by a misaligned line, which is now fixed. In aarch64-mte.exp, aarch64-non-address-bits.exp, arm-pthread_cond_timedwait-bt.exp and thumb2-it.exp this is because the return statements have extra indentation due to being inside with_test_prefix, save_vars or gdb_test_multiple blocks. --- gdb/testsuite/gdb.arch/aarch64-mte.exp | 6 +++--- gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp | 2 +- gdb/testsuite/gdb.arch/aarch64-prologue.exp | 2 +- gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp | 2 +- gdb/testsuite/gdb.arch/arm-pthread_cond_timedwait-bt.exp | 2 +- gdb/testsuite/gdb.arch/thumb2-it.exp | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/gdb/testsuite/gdb.arch/aarch64-mte.exp b/gdb/testsuite/gdb.arch/aarch64-mte.exp index 4826041e330a..72d4bba72531 100644 --- a/gdb/testsuite/gdb.arch/aarch64-mte.exp +++ b/gdb/testsuite/gdb.arch/aarch64-mte.exp @@ -276,11 +276,11 @@ with_test_prefix "print command" { set ltag [get_ltag_from_ptr ${tagged_ptr_addr}] } if {$ltag == -1} { unresolved "unexpected tag value" - return -1 + return } set atag [expr {($ltag + 1) % 16}] set atag_hexnn [get_tag_nn $atag] @@ -333,18 +333,18 @@ gdb_test "continue" \ "display tag violation information" # Restart to execute the async tag fault test. with_test_prefix "async" { if {![runto_main]} { - return -1 + return } gdb_breakpoint "access_memory" if {[gdb_continue "access_memory"]} { fail "could not run to tagged memory test function" - return -1 + return } # Force a tag fault. gdb_test "memory-tag set-allocation-tag tagged_ptr 1 05" \ $atag_msg \ diff --git a/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp b/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp index 8066b2035e1b..595dcb4f2ce1 100644 --- a/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp +++ b/gdb/testsuite/gdb.arch/aarch64-non-address-bits.exp @@ -54,11 +54,11 @@ gdb_test_multiple "ptype \$pauth_cmask" "fetch PAC cmask" { } -re -wrap "type = void" { } -re ".*$gdb_prompt $" { fail $gdb_test_name - return 1 + return } } # Value of the cmask register. set cmask 0 diff --git a/gdb/testsuite/gdb.arch/aarch64-prologue.exp b/gdb/testsuite/gdb.arch/aarch64-prologue.exp index c6fe2e262a5e..509fd31e8b4f 100644 --- a/gdb/testsuite/gdb.arch/aarch64-prologue.exp +++ b/gdb/testsuite/gdb.arch/aarch64-prologue.exp @@ -21,11 +21,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}]} { return } if {![runto_main]} { - return -1 + return } # Ensure gdb can break at excessiveprologue then continue. gdb_breakpoint "excessiveprologue" gdb_continue_to_breakpoint "excessiveprologue" diff --git a/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp b/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp index c2ecaffd1d2c..188ee1a913c4 100644 --- a/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp +++ b/gdb/testsuite/gdb.arch/arm-cmse-sgstubs.exp @@ -21,11 +21,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile ]} { return } if {![runto_main]} { - return -1 + return } gdb_test "si" "0x.*" "branch to func from main" gdb_test "ni" "0x.*" "next instruction in func" diff --git a/gdb/testsuite/gdb.arch/arm-pthread_cond_timedwait-bt.exp b/gdb/testsuite/gdb.arch/arm-pthread_cond_timedwait-bt.exp index 85ca6e78210f..02ae70095170 100644 --- a/gdb/testsuite/gdb.arch/arm-pthread_cond_timedwait-bt.exp +++ b/gdb/testsuite/gdb.arch/arm-pthread_cond_timedwait-bt.exp @@ -32,11 +32,11 @@ if { [build_executable "failed to prepare" ${testfile} ${srcfile} \ } save_vars { GDBFLAGS } { append GDBFLAGS " --readnever" if { [clean_restart $testfile] == -1 } { - return -1 + return } } if { ![runto_main] } { return diff --git a/gdb/testsuite/gdb.arch/thumb2-it.exp b/gdb/testsuite/gdb.arch/thumb2-it.exp index 0c9246b2131e..9ffcc6e1e3b9 100644 --- a/gdb/testsuite/gdb.arch/thumb2-it.exp +++ b/gdb/testsuite/gdb.arch/thumb2-it.exp @@ -33,11 +33,11 @@ if {![runto_main]} { # Make sure that the compiler options allow Thumb-2. gdb_test_multiple "list" "list main" { -re ".*@ No Thumb-2.*$gdb_prompt $" { pass "list main" untested "skipping tests due to lack of Thumb-2" - return -1 + return } -re ".*@ Thumb-2 OK.*$gdb_prompt $" { pass "list main" } } From patchwork Wed Apr 29 23:03:54 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134198 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id A15B44358A49 for ; Wed, 29 Apr 2026 23:06:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A15B44358A49 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=z2AmvZ7E X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x930.google.com (mail-ua1-x930.google.com [IPv6:2607:f8b0:4864:20::930]) by sourceware.org (Postfix) with ESMTPS id 4764C4320FDA for ; Wed, 29 Apr 2026 23:04:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4764C4320FDA Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4764C4320FDA Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::930 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503887; cv=none; b=DeXvsBu+pM5agPf+TtuL2Uo9r40TRH+Pks3WbmoLVSV9X/JFssh5LKioAy63usxi+vC8Q6nfIJ7f0tecYre4s2BwWUDJwkWOdnlpA06LUYilZzMaB1SPs3pUp/Zje7i/SyWEdTejqS/lEDFxXOVdMwqlXQTvguuhsaKZ+JEcHt8= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503887; c=relaxed/simple; bh=Yz7qQ56vMsW6s4qWitKTTtRV5F91VFD41LW2QmcJjeg=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=TMzoYQs0227KjjOS1JedbtQ7cnCSGBEK1DQt5gvN4V3yR+Qt8cWljHzxS72Y0+9gjam02bZp1qwHwmnUTx566DTR4b4kGL+0f2z5NCIvUJ1VUEWEry8eH4lnLVSZ1cGTkIcZ+Pxw8nT9oE0o6ggrTrdXOJ7MlVGq0FK7zMXF0nY= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4764C4320FDA Received: by mail-ua1-x930.google.com with SMTP id a1e0cc1a2514c-94aaa5d3bfcso179924241.3 for ; Wed, 29 Apr 2026 16:04:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503887; x=1778108687; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=6jCj+HQ7fbd64xWKQhTIyE2i3CaQ8q05NXfAuXNOlFQ=; b=z2AmvZ7EtU+xB7KBLTWTPTgHrgy/8SOegUfZCLlLzahkAXhZIIwXGCGvEt20TYOIy5 FqPwod1juqR766t3q+QkAXOewRRuEdwBtxJeafSbLGNwdAiizp+UkH35gS+wS/0Q4mjC 0Vz3AGLpHwxpzmkBI9r3xvKVMBysqFPb9zF2xMhCT6IQWfbNW5u1oToOrIuVtDgOWczc 8OKEa1uBxpw7/SncvYsASAiWjAmUpLOXUYdLdYTfbIIOqhDnAPrVkNhqbA7myKimEYmP pO3s9Q1kOKhvg00lxwyRbloIwEzyBBYjxLFANNtVXuZTmTttGDoxh1qBo3iO5+ChlVcX hwlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503887; x=1778108687; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=6jCj+HQ7fbd64xWKQhTIyE2i3CaQ8q05NXfAuXNOlFQ=; b=NewqHMfi4hpwVh+Lgjk9IUPl4jQ+MMt3WsJwwedQZZ7OgAtx4LBZvXYoLk0CIdfU3R ffhQH74r1lIg4lWbjxJm1a0+BFgjHUS3XoHDuaN41ubD0rpocdhhRfAWc0E4f8TdDFch WfdKtYr0pSWF4oIASlivxtUeBL8MklWIsStGbxsJoq5tdnA9QJsZAaQE/D3VKJX7Jjeo +0lNX11y1KDkeY4qtuqVOSi0OBT/r6+mAI5IpWHS+VsZDcuT8TfCdT6TquvcyfCMdpCn aJAz9hLZ461/grohqPNsfcrJjSs6IOwvkorY65IRLTBloD386mnLruyjp2XkSjpVHiN/ n2lw== X-Gm-Message-State: AOJu0YwW/iycTN76yr/sObkt942ifE4l38EH19MkCNsyF7hDIpA3cLZz OBEBxXnsbBJyWK4YVXw+VOPXOympdTFXD5YzKD+KxKcMP6E94oZEU6ZVEg0hZqcbiftCFKhvSZ1 1KrT4 X-Gm-Gg: AeBDievMX3KWgV1yx7I6IIYfuC01FHXzZKfe95PeJ35Q16iKvNFDUDXSd3ZX/t909qc W2jzDGM2H81Dt/OKpQpCOnq5sub3gt7yfvaO9BfF+fV8KIg7XOQAI+8R3FgJfcbgK5DKByAebch HVqioHwErXky6AFZQte1eTGefGD+lN5r//hJBtnGokylWy3uQcYLn9B0y6qSBhBUKeIcX7x816R APYgbVhorKTjYgrZF+Ol78DAEyI/JFpUs9woziPnMRPLmTK70Jeii/zsW+LloyPHcqgWO4Kjlxh cOIGgqVKzGZOwh8LmjbNbPMvWnX4Wt+OACrFAToS7GrGZxG7PqL2vBYEAjeeSzp9zg3/d1XAS/T FftcnFmfg2FLysBM/V5cG76uzBm+0C8BT8ecw8NwV4OvJZx8puBMXuUXtBr3snJRgRLTd69M1i6 cgAYkS/T3Hyl2WDi7tlic2S6/28ekqZ1vohr/bOF/PbkW3 X-Received: by 2002:a05:6102:5cc2:b0:611:82b:a599 with SMTP id ada2fe7eead31-62ad4b81c17mr305871137.21.1777503886082; Wed, 29 Apr 2026 16:04:46 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-62982135e26sm1997328137.3.2026.04.29.16.04.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:45 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 03/37] GDB: testsuite: x86, amd64, i386, ia64: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:03:54 -0300 Message-ID: <20260429230432.60487-4-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' \ amd64-*.exp* i386-*.exp* x86*.exp* ia64*.exp* core-file-pid0.exp and $ sed -i 's/^ return 0/ return/' \ amd64-*.exp* i386-*.exp* x86*.exp* ia64*.exp* core-file-pid0.exp inside gdb/testsuite/gdb.arch. --- gdb/testsuite/gdb.arch/amd64-break-on-asm-line.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-byte.exp | 2 +- gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-disp-step-self-call.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-disp-step.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-dword.exp | 2 +- gdb/testsuite/gdb.arch/amd64-entry-value-inline.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-entry-value-param-dwarf5.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-entry-value-param.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-entry-value-paramref.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-entry-value.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-eval.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-frameptr-vecreg-unwind.exp | 2 +- gdb/testsuite/gdb.arch/amd64-gs_base.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-i386-address.exp | 2 +- gdb/testsuite/gdb.arch/amd64-init-x87-values.exp | 2 +- gdb/testsuite/gdb.arch/amd64-invalid-stack-middle.exp | 8 ++++---- gdb/testsuite/gdb.arch/amd64-invalid-stack-top.exp | 8 ++++---- gdb/testsuite/gdb.arch/amd64-lam.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-optimout-repeat.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-prologue-xmm.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-pseudo-unwind.exp | 2 +- gdb/testsuite/gdb.arch/amd64-stap-expressions.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-stap-optional-prefix.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-stap-special-operands.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-stap-wrong-subexp.exp | 2 +- gdb/testsuite/gdb.arch/amd64-tailcall-cxx.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-tailcall-noret.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-tailcall-ret.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-tailcall-self.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-watchpoint-downgrade.exp | 4 ++-- gdb/testsuite/gdb.arch/amd64-word.exp | 2 +- gdb/testsuite/gdb.arch/core-file-pid0.exp | 6 +++--- gdb/testsuite/gdb.arch/i386-attach-see-vdso.exp | 2 +- gdb/testsuite/gdb.arch/i386-avx.exp | 2 +- gdb/testsuite/gdb.arch/i386-avx512.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-biarch-core.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-bp_permanent.exp | 2 +- gdb/testsuite/gdb.arch/i386-byte.exp | 2 +- gdb/testsuite/gdb.arch/i386-cfi-notcurrent.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-disp-step-self-call.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-disp-step.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-dr3-watch.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-float.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-gnu-cfi.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-permbkpt.exp | 2 +- gdb/testsuite/gdb.arch/i386-pkru.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-prologue.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-signal.exp | 2 +- gdb/testsuite/gdb.arch/i386-size-overlap.exp | 2 +- gdb/testsuite/gdb.arch/i386-size.exp | 2 +- gdb/testsuite/gdb.arch/i386-sse-stack-align.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-sse.exp | 2 +- gdb/testsuite/gdb.arch/i386-stap-eval-lang-ada.exp | 4 ++-- gdb/testsuite/gdb.arch/i386-unwind.exp | 2 +- gdb/testsuite/gdb.arch/i386-word.exp | 2 +- gdb/testsuite/gdb.arch/ia64-breakpoint-shadow.exp | 6 +++--- gdb/testsuite/gdb.arch/x86-avx512bf16.exp | 4 ++-- gdb/testsuite/gdb.arch/x86-avx512fp16-abi.exp | 4 ++-- gdb/testsuite/gdb.arch/x86-avx512fp16.exp | 4 ++-- 60 files changed, 107 insertions(+), 107 deletions(-) diff --git a/gdb/testsuite/gdb.arch/amd64-break-on-asm-line.exp b/gdb/testsuite/gdb.arch/amd64-break-on-asm-line.exp index 93e1ed36652b..bd05a4d4ae3a 100644 --- a/gdb/testsuite/gdb.arch/amd64-break-on-asm-line.exp +++ b/gdb/testsuite/gdb.arch/amd64-break-on-asm-line.exp @@ -18,15 +18,15 @@ require is_x86_64_m64_target standard_testfile .S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ { debug }] } { untested "could not compile" - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break on specified line" \ ".*/\\* Break here\\. \\*/.*" diff --git a/gdb/testsuite/gdb.arch/amd64-byte.exp b/gdb/testsuite/gdb.arch/amd64-byte.exp index 90668056a13e..0c908d2d8663 100644 --- a/gdb/testsuite/gdb.arch/amd64-byte.exp +++ b/gdb/testsuite/gdb.arch/amd64-byte.exp @@ -28,11 +28,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } set byte_regs(1) al set byte_regs(2) bl set byte_regs(3) cl diff --git a/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp b/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp index 3a16bfb3824f..f2c3fb1845c2 100644 --- a/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp +++ b/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp @@ -23,20 +23,20 @@ require support_displaced_stepping standard_testfile .S set options [list debug nopie] if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $options] } { - return -1 + return } # Get things started. gdb_test "set displaced-stepping on" "" gdb_test "show displaced-stepping" ".* displaced stepping .* is on.*" if {![runto_main]} { - return 0 + return } # GDB picks a spare register from this list to hold the RIP-relative # address. set rip_regs { "rax" "rbx" "rcx" "rdx" "rbp" "rsi" "rdi" } diff --git a/gdb/testsuite/gdb.arch/amd64-disp-step-self-call.exp b/gdb/testsuite/gdb.arch/amd64-disp-step-self-call.exp index ce0283d462e7..603077adcd46 100644 --- a/gdb/testsuite/gdb.arch/amd64-disp-step-self-call.exp +++ b/gdb/testsuite/gdb.arch/amd64-disp-step-self-call.exp @@ -23,18 +23,18 @@ set newline "\[\r\n\]*" set opts {debug nopie} standard_testfile .S -alarm.c if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" $opts] } { - return -1 + return } gdb_test "set displaced-stepping on" "" gdb_test "show displaced-stepping" ".* displaced stepping .* is on.*" if {![runto_main]} { - return 0 + return } # Proceed to the test function. gdb_breakpoint "test_call" gdb_continue_to_breakpoint "test_call" diff --git a/gdb/testsuite/gdb.arch/amd64-disp-step.exp b/gdb/testsuite/gdb.arch/amd64-disp-step.exp index d05b6760e585..9b33c77c9a8a 100644 --- a/gdb/testsuite/gdb.arch/amd64-disp-step.exp +++ b/gdb/testsuite/gdb.arch/amd64-disp-step.exp @@ -23,18 +23,18 @@ set newline "\[\r\n\]*" set opts {debug nopie} standard_testfile .S -signal.c if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" $opts] } { - return -1 + return } gdb_test "set displaced-stepping on" "" gdb_test "show displaced-stepping" ".* displaced stepping .* is on.*" if {![runto_main]} { - return 0 + return } ########################################## # Test call/ret. diff --git a/gdb/testsuite/gdb.arch/amd64-dword.exp b/gdb/testsuite/gdb.arch/amd64-dword.exp index d7305f140011..01fb47786765 100644 --- a/gdb/testsuite/gdb.arch/amd64-dword.exp +++ b/gdb/testsuite/gdb.arch/amd64-dword.exp @@ -28,11 +28,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } set nr_regs 14 set dword_regs(1) eax set dword_regs(2) ebx diff --git a/gdb/testsuite/gdb.arch/amd64-entry-value-inline.exp b/gdb/testsuite/gdb.arch/amd64-entry-value-inline.exp index 257a7c8cf604..b67f676b7163 100644 --- a/gdb/testsuite/gdb.arch/amd64-entry-value-inline.exp +++ b/gdb/testsuite/gdb.arch/amd64-entry-value-inline.exp @@ -28,15 +28,15 @@ if {[info exists COMPILE]} { if {[is_remote host]} { gdb_remote_download host $srcdir/$subdir/$srcfile2 } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here" $srcfile2] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.arch/amd64-entry-value-param-dwarf5.exp b/gdb/testsuite/gdb.arch/amd64-entry-value-param-dwarf5.exp index e5697c9c9ab5..8043235eec8e 100644 --- a/gdb/testsuite/gdb.arch/amd64-entry-value-param-dwarf5.exp +++ b/gdb/testsuite/gdb.arch/amd64-entry-value-param-dwarf5.exp @@ -28,15 +28,15 @@ if {[info exists COMPILE]} { if {[is_remote host]} { gdb_remote_download host $srcdir/$subdir/$srcfile2 } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here" $srcfile2] with_test_prefix "call 1" { diff --git a/gdb/testsuite/gdb.arch/amd64-entry-value-param.exp b/gdb/testsuite/gdb.arch/amd64-entry-value-param.exp index 5b2b65e86365..4c1d63ab5a3c 100644 --- a/gdb/testsuite/gdb.arch/amd64-entry-value-param.exp +++ b/gdb/testsuite/gdb.arch/amd64-entry-value-param.exp @@ -28,15 +28,15 @@ if {[info exists COMPILE]} { if {[is_remote host]} { remote_download host $srcdir/$subdir/$srcfile2 } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here" $srcfile2] with_test_prefix "call 1" { diff --git a/gdb/testsuite/gdb.arch/amd64-entry-value-paramref.exp b/gdb/testsuite/gdb.arch/amd64-entry-value-paramref.exp index 146d92eb2670..cb789b541bc2 100644 --- a/gdb/testsuite/gdb.arch/amd64-entry-value-paramref.exp +++ b/gdb/testsuite/gdb.arch/amd64-entry-value-paramref.exp @@ -22,15 +22,15 @@ if {[is_remote host]} { gdb_remote_download host $srcdir/$subdir/$srcfile2 } if { [prepare_for_testing_full "failed to prepare" \ [list $testfile "c++" $srcfile {}]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here" $srcfile2] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.arch/amd64-entry-value.exp b/gdb/testsuite/gdb.arch/amd64-entry-value.exp index 65c4ab142c3e..997312ee4375 100644 --- a/gdb/testsuite/gdb.arch/amd64-entry-value.exp +++ b/gdb/testsuite/gdb.arch/amd64-entry-value.exp @@ -25,15 +25,15 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "breakhere" gdb_breakpoint "breakhere_locexpr" gdb_breakpoint "stacktest" diff --git a/gdb/testsuite/gdb.arch/amd64-eval.exp b/gdb/testsuite/gdb.arch/amd64-eval.exp index 34fb21e0678f..2b145375595b 100644 --- a/gdb/testsuite/gdb.arch/amd64-eval.exp +++ b/gdb/testsuite/gdb.arch/amd64-eval.exp @@ -21,15 +21,15 @@ require is_x86_64_m64_target standard_testfile .cc if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ { debug c++ additional_flags=-std=c++11 }] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" diff --git a/gdb/testsuite/gdb.arch/amd64-frameptr-vecreg-unwind.exp b/gdb/testsuite/gdb.arch/amd64-frameptr-vecreg-unwind.exp index e1ca703881dd..9e358c016427 100644 --- a/gdb/testsuite/gdb.arch/amd64-frameptr-vecreg-unwind.exp +++ b/gdb/testsuite/gdb.arch/amd64-frameptr-vecreg-unwind.exp @@ -24,11 +24,11 @@ require is_x86_64_m64_target standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} \ "${srcfile}" {debug}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.arch/amd64-gs_base.exp b/gdb/testsuite/gdb.arch/amd64-gs_base.exp index db64c52d89fd..c879cd9d2bf6 100644 --- a/gdb/testsuite/gdb.arch/amd64-gs_base.exp +++ b/gdb/testsuite/gdb.arch/amd64-gs_base.exp @@ -17,15 +17,15 @@ standard_testfile require is_amd64_regs_target if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug nowarnings]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print /x \$fs_base" "= $hex" "print fs_base" gdb_test "print /x \$gs_base" "= $hex" "print gs_base" diff --git a/gdb/testsuite/gdb.arch/amd64-i386-address.exp b/gdb/testsuite/gdb.arch/amd64-i386-address.exp index 710e9c0cdb46..c9e759272355 100644 --- a/gdb/testsuite/gdb.arch/amd64-i386-address.exp +++ b/gdb/testsuite/gdb.arch/amd64-i386-address.exp @@ -20,11 +20,11 @@ require {is_any_target "x86_64-*-*" "i?86-*-*"} is_lp64_target require {!istarget "*-*-openbsd*"} if {[prepare_for_testing "failed to prepare" amd64-i386-address amd64-i386-address.S [list debug "additional_flags=-m32 -nostdlib"]]} { - return -1 + return } gdb_run_cmd set test "trap stop" diff --git a/gdb/testsuite/gdb.arch/amd64-init-x87-values.exp b/gdb/testsuite/gdb.arch/amd64-init-x87-values.exp index 91c198e43a31..4c7664676d63 100644 --- a/gdb/testsuite/gdb.arch/amd64-init-x87-values.exp +++ b/gdb/testsuite/gdb.arch/amd64-init-x87-values.exp @@ -24,11 +24,11 @@ standard_testfile .S set options [list debug \ additional_flags=-static \ ldflags=-nostartfiles] if { [build_executable "failed to prepare" ${testfile} ${srcfile} $options] } { - return -1 + return } # Start the test file, and check the x87 control registers (and # mxcsr), we expect the default values in all registers. # diff --git a/gdb/testsuite/gdb.arch/amd64-invalid-stack-middle.exp b/gdb/testsuite/gdb.arch/amd64-invalid-stack-middle.exp index 713bef8ba473..a48896d60a6c 100644 --- a/gdb/testsuite/gdb.arch/amd64-invalid-stack-middle.exp +++ b/gdb/testsuite/gdb.arch/amd64-invalid-stack-middle.exp @@ -30,15 +30,15 @@ standard_testfile .S require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {nopie}] } { - return -1 + return } if {![runto breakpt]} { - return -1 + return } gdb_test "bt" "^#0 +breakpt *\\(\\) \[^\r\n\]*\r\n#1 +${::hex} in func5\[^\r\n\]*\r\n#2 +${::hex} in func4\[^\r\n\]*\r\n#3 +${::hex} in func3\[^\r\n\]*\r\nBacktrace stopped: Cannot access memory at address ${::hex}" \ "first backtrace, with error message" @@ -46,11 +46,11 @@ gdb_test "bt" "^#0 +breakpt *\\(\\) \[^\r\n\]*\r\n#1 +${::hex} in func5\[^\r\n\] "second backtrace, with error message" clean_restart ${::testfile} if {![runto breakpt]} { - return -1 + return } gdb_test "interpreter-exec mi \"-stack-info-depth\"" \ "\\^done,depth=\"4\"" \ "check mi -stack-info-depth command, first time" @@ -60,11 +60,11 @@ gdb_test "interpreter-exec mi \"-stack-info-depth\"" \ "check mi -stack-info-depth command, second time" clean_restart ${::testfile} if {![runto breakpt]} { - return -1 + return } gdb_test "interpreter-exec mi \"-stack-list-frames\"" \ "\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"breakpt\",file=\"\[^\"\]+\",fullname=\"\[^\"\]+\",line=\"${decimal}\"(,arch=\"\[^\"\]+\")?\},frame=\{level=\"1\",addr=\"$hex\",func=\"func5\",file=\"\[^\"\]+\",fullname=\"\[^\"\]+\",line=\"${decimal}\"(,arch=\"\[^\"\]+\")?\},frame=\{level=\"2\",addr=\"$hex\",func=\"func4\",file=\"\[^\"\]+\",fullname=\"\[^\"\]+\",line=\"${decimal}\"(,arch=\"\[^\"\]+\")?\},frame=\{level=\"3\",addr=\"$hex\",func=\"func3\",file=\"\[^\"\]+\",fullname=\"\[^\"\]+\",line=\"${decimal}\"(,arch=\"\[^\"\]+\")?\}\\\]" \ "check mi -stack-list-frames command, first time" diff --git a/gdb/testsuite/gdb.arch/amd64-invalid-stack-top.exp b/gdb/testsuite/gdb.arch/amd64-invalid-stack-top.exp index 9a4f2e2663e2..d3ad91ed64fd 100644 --- a/gdb/testsuite/gdb.arch/amd64-invalid-stack-top.exp +++ b/gdb/testsuite/gdb.arch/amd64-invalid-stack-top.exp @@ -31,15 +31,15 @@ set opts {} standard_testfile .c require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto breakpt]} { - return -1 + return } # Use 'bt no-filters' here as the python filters will raise their own # error during initialisation, the no-filters case is simpler. @@ -50,11 +50,11 @@ gdb_test "bt no-filters" "^#0 +$hex in func2 \\(\\)\r\nBacktrace stopped: Cannot "second backtrace, with error message" clean_restart ${::testfile} if {![runto breakpt]} { - return -1 + return } gdb_test "interpreter-exec mi \"-stack-info-depth\"" \ "\\^done,depth=\"1\"" \ "check mi -stack-info-depth command, first time" @@ -64,11 +64,11 @@ gdb_test "interpreter-exec mi \"-stack-info-depth\"" \ "check mi -stack-info-depth command, second time" clean_restart ${::testfile} if {![runto breakpt]} { - return -1 + return } gdb_test "interpreter-exec mi \"-stack-list-frames\"" \ "\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"func2\"(,arch=\"\[^\"\]+\")?\}\\\]" \ "check mi -stack-list-frames command, first time" diff --git a/gdb/testsuite/gdb.arch/amd64-lam.exp b/gdb/testsuite/gdb.arch/amd64-lam.exp index 746ab313871b..3abdb3116d88 100644 --- a/gdb/testsuite/gdb.arch/amd64-lam.exp +++ b/gdb/testsuite/gdb.arch/amd64-lam.exp @@ -19,15 +19,15 @@ require allow_lam_tests standard_testfile amd64-lam.c # Test LAM 57. if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Breakpoint here"] gdb_continue_to_breakpoint "Breakpoint here" diff --git a/gdb/testsuite/gdb.arch/amd64-optimout-repeat.exp b/gdb/testsuite/gdb.arch/amd64-optimout-repeat.exp index 209aa240e623..a2651898b0c6 100644 --- a/gdb/testsuite/gdb.arch/amd64-optimout-repeat.exp +++ b/gdb/testsuite/gdb.arch/amd64-optimout-repeat.exp @@ -23,13 +23,13 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print v" { = {i = 0, xxx = { }}} diff --git a/gdb/testsuite/gdb.arch/amd64-prologue-xmm.exp b/gdb/testsuite/gdb.arch/amd64-prologue-xmm.exp index bae24da9cf76..f402350acdee 100644 --- a/gdb/testsuite/gdb.arch/amd64-prologue-xmm.exp +++ b/gdb/testsuite/gdb.arch/amd64-prologue-xmm.exp @@ -27,15 +27,15 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if {[prepare_for_testing "failed to prepare" ${testfile} $srcfile $opts]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "func" gdb_breakpoint "marker" diff --git a/gdb/testsuite/gdb.arch/amd64-pseudo-unwind.exp b/gdb/testsuite/gdb.arch/amd64-pseudo-unwind.exp index a50978d439eb..44ef137d8758 100644 --- a/gdb/testsuite/gdb.arch/amd64-pseudo-unwind.exp +++ b/gdb/testsuite/gdb.arch/amd64-pseudo-unwind.exp @@ -27,11 +27,11 @@ if { ![istarget x86_64-*-* ] || ![is_lp64_target] } { standard_testfile amd64-pseudo-unwind.c amd64-pseudo-unwind-asm.S if { [prepare_for_testing "failed to prepare" ${testfile} \ "${srcfile} ${srcfile2}" {debug}] } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.arch/amd64-stap-expressions.exp b/gdb/testsuite/gdb.arch/amd64-stap-expressions.exp index 4f2c6c26dab4..1d6d0cf786c5 100644 --- a/gdb/testsuite/gdb.arch/amd64-stap-expressions.exp +++ b/gdb/testsuite/gdb.arch/amd64-stap-expressions.exp @@ -16,11 +16,11 @@ standard_testfile ".S" require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Helper procedure to go to probe NAME proc goto_probe { name } { @@ -36,11 +36,11 @@ proc test_probe_value { value } { gdb_test "print \$_probe_argc" "= 1" gdb_test "print \$_probe_arg0" "= $value" } if { ![runto_main] } { - return -1 + return } # Name and expected value for each probe. set probe_names_and_values { { "log_neg" "0" } diff --git a/gdb/testsuite/gdb.arch/amd64-stap-optional-prefix.exp b/gdb/testsuite/gdb.arch/amd64-stap-optional-prefix.exp index 4b4d0543f64d..9cd7dec166c1 100644 --- a/gdb/testsuite/gdb.arch/amd64-stap-optional-prefix.exp +++ b/gdb/testsuite/gdb.arch/amd64-stap-optional-prefix.exp @@ -18,11 +18,11 @@ standard_testfile ".S" require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Helper procedure to go to probe NAME proc goto_probe { name } { @@ -44,11 +44,11 @@ proc test_probe_value_without_reg { value } { gdb_test "print \$_probe_argc" "= 1" gdb_test "print \$_probe_arg0" "= $value" } if { ![runto_main] } { - return -1 + return } foreach probe_name [list "foo" "bar" "foo_prefix" "bar_prefix"] \ probe_val [list "42" "42" "42" "42"] \ probe_reg_val [list "\$rsp" "\$rbp - 8" "\$rsp" "\$rbp - 8"] { diff --git a/gdb/testsuite/gdb.arch/amd64-stap-special-operands.exp b/gdb/testsuite/gdb.arch/amd64-stap-special-operands.exp index 9c819e490acd..3fbdae9197de 100644 --- a/gdb/testsuite/gdb.arch/amd64-stap-special-operands.exp +++ b/gdb/testsuite/gdb.arch/amd64-stap-special-operands.exp @@ -27,18 +27,18 @@ proc test_probe { probe_name } { } standard_testfile amd64-stap-triplet.S if { [prepare_for_testing "failed to prepare" $testfile-triplet $srcfile] } { - return -1 + return } test_probe "triplet" standard_testfile amd64-stap-three-arg-disp.S if { [prepare_for_testing "failed to prepare" $testfile-three-arg-displ \ $srcfile] } { - return -1 + return } test_probe "three_arg" diff --git a/gdb/testsuite/gdb.arch/amd64-stap-wrong-subexp.exp b/gdb/testsuite/gdb.arch/amd64-stap-wrong-subexp.exp index 2f55fbdf82c8..e7089c20f489 100644 --- a/gdb/testsuite/gdb.arch/amd64-stap-wrong-subexp.exp +++ b/gdb/testsuite/gdb.arch/amd64-stap-wrong-subexp.exp @@ -16,11 +16,11 @@ require is_x86_64_m64_target standard_testfile amd64-stap-wrong-subexp.S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } proc goto_probe { probe_name } { if { ![runto "-pstap $probe_name"] } { return diff --git a/gdb/testsuite/gdb.arch/amd64-tailcall-cxx.exp b/gdb/testsuite/gdb.arch/amd64-tailcall-cxx.exp index 5d6ae1776c66..c2cffe0793b2 100644 --- a/gdb/testsuite/gdb.arch/amd64-tailcall-cxx.exp +++ b/gdb/testsuite/gdb.arch/amd64-tailcall-cxx.exp @@ -25,13 +25,13 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if { [prepare_for_testing "failed to prepare" ${testfile} "${srcfile} ${srcfile2}" $opts] } { - return -1 + return } if {![runto g]} { - return -1 + return } gdb_test "bt" "\r\n#0 +g \\(x=x@entry=2\\) at \[^\r\n\]*\r\n#1 +${::hex} in f \\(x=x@entry=1\\) at \[^\r\n\]*\r\n#2 +${::hex} in main .*" diff --git a/gdb/testsuite/gdb.arch/amd64-tailcall-noret.exp b/gdb/testsuite/gdb.arch/amd64-tailcall-noret.exp index 8a58dda00b1d..767602805b97 100644 --- a/gdb/testsuite/gdb.arch/amd64-tailcall-noret.exp +++ b/gdb/testsuite/gdb.arch/amd64-tailcall-noret.exp @@ -25,13 +25,13 @@ if {[info exists COMPILE]} { } lappend opts nopie if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto noret]} { - return -1 + return } gdb_test "bt" "#0 +noret \\(x=1\\) at \[^\r\n\]*\r\n#1 +${::hex} in mayret \\(x=x@entry=1\\) at \[^\r\n\]*\r\n#2 +${::hex} in tailcall \\(x=x@entry=1\\) at \[^\r\n\]*\r\n#3 +${::hex} in main \\(\\) at .*" diff --git a/gdb/testsuite/gdb.arch/amd64-tailcall-ret.exp b/gdb/testsuite/gdb.arch/amd64-tailcall-ret.exp index 00ed2323a620..7ae151c690f3 100644 --- a/gdb/testsuite/gdb.arch/amd64-tailcall-ret.exp +++ b/gdb/testsuite/gdb.arch/amd64-tailcall-ret.exp @@ -28,15 +28,15 @@ if {[info exists COMPILE]} { if {[is_remote host]} { gdb_remote_download host $srcdir/$subdir/$srcfile2 } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "g" gdb_continue_to_breakpoint "first time in g" ".* v = 2;" diff --git a/gdb/testsuite/gdb.arch/amd64-tailcall-self.exp b/gdb/testsuite/gdb.arch/amd64-tailcall-self.exp index 63a3e00411a9..f1c6396d5108 100644 --- a/gdb/testsuite/gdb.arch/amd64-tailcall-self.exp +++ b/gdb/testsuite/gdb.arch/amd64-tailcall-self.exp @@ -16,13 +16,13 @@ standard_testfile .S require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {}] } { - return -1 + return } if {![runto b]} { - return -1 + return } gdb_test "bt" "#0 +b \\(\\) at \[^\r\n\]*\r\n#1 +${::hex} in a \\(q=\\) at \[^\r\n\]*\r\n#2 +${::hex} in main \\(\[^\r\n\]*\\) at .*" diff --git a/gdb/testsuite/gdb.arch/amd64-watchpoint-downgrade.exp b/gdb/testsuite/gdb.arch/amd64-watchpoint-downgrade.exp index e26d6efb201c..459330563f87 100644 --- a/gdb/testsuite/gdb.arch/amd64-watchpoint-downgrade.exp +++ b/gdb/testsuite/gdb.arch/amd64-watchpoint-downgrade.exp @@ -29,18 +29,18 @@ require target_can_use_run_cmd is_x86_64_m64_target # control the use of s/w vs h/w watchpoints, this test isn't about # those, so skip the test in these cases. if {[target_info gdb_protocol] == "remote" || [target_info gdb_protocol] == "extended-remote"} { unsupported "using [target_info gdb_protocol] protocol" - return -1 + return } standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ { debug }] } { - return -1 + return } # Insert the watchpoint, it should default to a h/w watchpoint. gdb_test "watch global_var" \ "Hardware watchpoint $decimal: global_var" diff --git a/gdb/testsuite/gdb.arch/amd64-word.exp b/gdb/testsuite/gdb.arch/amd64-word.exp index 8b06288f1a58..616f52cfdbb8 100644 --- a/gdb/testsuite/gdb.arch/amd64-word.exp +++ b/gdb/testsuite/gdb.arch/amd64-word.exp @@ -28,11 +28,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } set nr_regs 14 set word_regs(1) ax set word_regs(2) bx diff --git a/gdb/testsuite/gdb.arch/core-file-pid0.exp b/gdb/testsuite/gdb.arch/core-file-pid0.exp index 8f4f88bcdb6a..3f389a705480 100644 --- a/gdb/testsuite/gdb.arch/core-file-pid0.exp +++ b/gdb/testsuite/gdb.arch/core-file-pid0.exp @@ -26,26 +26,26 @@ standard_testfile if {[istarget "x86_64-*-linux*"]} { set cf_name ${testfile}.x86-64.core.bz2 set cf_size 8757248 } else { unsupported "no pre-generated core file for this target" - return -1 + return } # Decompress the core file. set corebz2file ${srcdir}/${subdir}/${cf_name} set corefile [decompress_bz2 $corebz2file] if { $corefile eq "" } { untested "failed to bunzip2 the core file" - return -1 + return } # Check the size of the decompressed core file. Just for sanity. file stat ${corefile} corestat if { $corestat(size) != ${cf_size} } { untested "uncompressed core file is the wrong size" - return -1 + return } # Copy over the corefile if we are remote testing. set corefile [gdb_remote_download host $corefile] diff --git a/gdb/testsuite/gdb.arch/i386-attach-see-vdso.exp b/gdb/testsuite/gdb.arch/i386-attach-see-vdso.exp index 46f81f28c2d4..a53e14bf33d0 100644 --- a/gdb/testsuite/gdb.arch/i386-attach-see-vdso.exp +++ b/gdb/testsuite/gdb.arch/i386-attach-see-vdso.exp @@ -26,11 +26,11 @@ if {![istarget "i386-*-*"]} { lappend options "additional_flags=-m32" } # The kernel VDSO is used for the syscalls returns only on i386 (not x86_64). if { [build_executable "failed to prepare" $testfile $srcfile $options] } { - return -1 + return } # Don't tell GDB which executable we're debugging. clean_restart diff --git a/gdb/testsuite/gdb.arch/i386-avx.exp b/gdb/testsuite/gdb.arch/i386-avx.exp index 9d65bfcc3294..1a786ee8a514 100644 --- a/gdb/testsuite/gdb.arch/i386-avx.exp +++ b/gdb/testsuite/gdb.arch/i386-avx.exp @@ -43,11 +43,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } gdb_test "break [gdb_get_line_number "first breakpoint here"]" \ "Breakpoint .* at .*i386-avx.c.*" \ "set first breakpoint in main" diff --git a/gdb/testsuite/gdb.arch/i386-avx512.exp b/gdb/testsuite/gdb.arch/i386-avx512.exp index f1a0d59ccd89..c79563366dc8 100644 --- a/gdb/testsuite/gdb.arch/i386-avx512.exp +++ b/gdb/testsuite/gdb.arch/i386-avx512.exp @@ -26,15 +26,15 @@ standard_testfile set comp_flags "-mavx512f -I${srcdir}/../nat" if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug nowarnings additional_flags=${comp_flags}]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set supports_avx512 0 set test "probe AVX512 support" diff --git a/gdb/testsuite/gdb.arch/i386-biarch-core.exp b/gdb/testsuite/gdb.arch/i386-biarch-core.exp index 95b1a3e29cb0..a9102559e5b5 100644 --- a/gdb/testsuite/gdb.arch/i386-biarch-core.exp +++ b/gdb/testsuite/gdb.arch/i386-biarch-core.exp @@ -38,17 +38,17 @@ set corebz2file ${srcdir}/${subdir}/${testfile}.core.bz2 set address 0x400078 set corefile [decompress_bz2 $corebz2file] if { $corefile == "" } { untested "failed bzip2" - return -1 + return } file stat ${corefile} corestat if {$corestat(size) != 102400} { untested "bzip2 produces invalid result" - return -1 + return } set corefile [gdb_remote_download host $corefile] # First check if this particular GDB supports i386, otherwise we should not diff --git a/gdb/testsuite/gdb.arch/i386-bp_permanent.exp b/gdb/testsuite/gdb.arch/i386-bp_permanent.exp index d2fcf0a311f9..ef4d0370de89 100644 --- a/gdb/testsuite/gdb.arch/i386-bp_permanent.exp +++ b/gdb/testsuite/gdb.arch/i386-bp_permanent.exp @@ -27,11 +27,11 @@ set additional_flags [gdb_target_symbol_prefix_flags] # Don't use "debug", so that we don't have line information for the assembly # fragments. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list $additional_flags]] != "" } { untested "failed to compile" - return -1 + return } clean_restart $::testfile diff --git a/gdb/testsuite/gdb.arch/i386-byte.exp b/gdb/testsuite/gdb.arch/i386-byte.exp index 9082638dcaa6..9a4e28585ef5 100644 --- a/gdb/testsuite/gdb.arch/i386-byte.exp +++ b/gdb/testsuite/gdb.arch/i386-byte.exp @@ -29,11 +29,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } set byte_regs(1) al set byte_regs(2) bl set byte_regs(3) cl diff --git a/gdb/testsuite/gdb.arch/i386-cfi-notcurrent.exp b/gdb/testsuite/gdb.arch/i386-cfi-notcurrent.exp index 11a9f0331928..a340182c1d88 100644 --- a/gdb/testsuite/gdb.arch/i386-cfi-notcurrent.exp +++ b/gdb/testsuite/gdb.arch/i386-cfi-notcurrent.exp @@ -20,13 +20,13 @@ require is_x86_like_target set testfile "i386-cfi-notcurrent" set srcfile ${testfile}.S if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {nodebug}]} { - return -1 + return } if {![runto f]} { - return -1 + return } gdb_test "backtrace" "#0 \[^\r\n\]* f \[^\r\n\]*\r\n#1 \[^\r\n\]* g \[^\r\n\]*\r\n#2 \[^\r\n\]* main \[^\r\n\]*" diff --git a/gdb/testsuite/gdb.arch/i386-disp-step-self-call.exp b/gdb/testsuite/gdb.arch/i386-disp-step-self-call.exp index 8c7061ecd78e..6a9290fe609a 100644 --- a/gdb/testsuite/gdb.arch/i386-disp-step-self-call.exp +++ b/gdb/testsuite/gdb.arch/i386-disp-step-self-call.exp @@ -23,18 +23,18 @@ set newline "\[\r\n\]*" set opts {debug nopie} standard_testfile .S -alarm.c if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" $opts] } { - return -1 + return } gdb_test "set displaced-stepping on" "" gdb_test "show displaced-stepping" ".* displaced stepping .* is on.*" if {![runto_main]} { - return 0 + return } # Proceed to the test function. gdb_breakpoint "test_call" gdb_continue_to_breakpoint "test_call" diff --git a/gdb/testsuite/gdb.arch/i386-disp-step.exp b/gdb/testsuite/gdb.arch/i386-disp-step.exp index b593651ad45c..f265d3fe3d03 100644 --- a/gdb/testsuite/gdb.arch/i386-disp-step.exp +++ b/gdb/testsuite/gdb.arch/i386-disp-step.exp @@ -25,18 +25,18 @@ standard_testfile .S set opts {} lappend opts debug lappend opts nopie if { [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] } { - return -1 + return } gdb_test "set displaced-stepping on" "" gdb_test "show displaced-stepping" ".* displaced stepping .* is on.*" if {![runto_main]} { - return 0 + return } ########################################## # Test call/ret. diff --git a/gdb/testsuite/gdb.arch/i386-dr3-watch.exp b/gdb/testsuite/gdb.arch/i386-dr3-watch.exp index 058eefdb0051..d0c9209f62c3 100644 --- a/gdb/testsuite/gdb.arch/i386-dr3-watch.exp +++ b/gdb/testsuite/gdb.arch/i386-dr3-watch.exp @@ -22,15 +22,15 @@ require {is_any_target "i?86-*-*" "x86_64-*-*"} standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug $additional_flags}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set breakpoint always-inserted on" # Test that we handle watchpoints in all of DR0-DR3. diff --git a/gdb/testsuite/gdb.arch/i386-float.exp b/gdb/testsuite/gdb.arch/i386-float.exp index 23db5f843c2c..a121093728a1 100644 --- a/gdb/testsuite/gdb.arch/i386-float.exp +++ b/gdb/testsuite/gdb.arch/i386-float.exp @@ -24,15 +24,15 @@ standard_testfile .S # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags_asm] if { [prepare_for_testing "failed to prepare" $testfile $srcfile [list debug nopie $additional_flags]] } { - return -1 + return } if {![runto_main]} { - return 0 + return } with_test_prefix "zero" { gdb_test "stepi" ".*fldt.*" gdb_test "info float" "R7: Empty 0x00000000000000000000\r\n.*" diff --git a/gdb/testsuite/gdb.arch/i386-gnu-cfi.exp b/gdb/testsuite/gdb.arch/i386-gnu-cfi.exp index c7e019829e75..458a902fb974 100644 --- a/gdb/testsuite/gdb.arch/i386-gnu-cfi.exp +++ b/gdb/testsuite/gdb.arch/i386-gnu-cfi.exp @@ -33,11 +33,11 @@ set binfile [standard_output_file ${testfile}] # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if { [gdb_compile "${srcdir}/${subdir}/${srcfilec} ${srcdir}/${subdir}/${srcfileasm}" "${binfile}" executable [list debug $additional_flags]] != "" } { untested "failed to compile" - return -1 + return } # Get things started. clean_restart $::testfile @@ -65,11 +65,11 @@ gdb_test_multiple "backtrace" "" { set gate_n $expect_out(1,string) pass $gdb_test_name } } if { $gate_n == "" } { - return -1 + return } # Check we see the inserted `DW_CFA_GNU_negative_offset_extended' CFI. # We see there the original CFI-stored filename `gate.c'. diff --git a/gdb/testsuite/gdb.arch/i386-permbkpt.exp b/gdb/testsuite/gdb.arch/i386-permbkpt.exp index f365597e052e..58ab263688a1 100644 --- a/gdb/testsuite/gdb.arch/i386-permbkpt.exp +++ b/gdb/testsuite/gdb.arch/i386-permbkpt.exp @@ -25,11 +25,11 @@ standard_testfile .S # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags_asm] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug $additional_flags]] != "" } { untested "failed to compile" - return -1 + return } clean_restart ${::testfile} gdb_test "break -q main" "" "first permanent break" diff --git a/gdb/testsuite/gdb.arch/i386-pkru.exp b/gdb/testsuite/gdb.arch/i386-pkru.exp index 94cf2101e18b..b9b0b99b0de3 100644 --- a/gdb/testsuite/gdb.arch/i386-pkru.exp +++ b/gdb/testsuite/gdb.arch/i386-pkru.exp @@ -29,15 +29,15 @@ if { [istarget *-*-linux*] } { set comp_flags "-I${srcdir}/../nat/" if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug additional_flags=${comp_flags}]] } { untested "failed to compile x86 PKEYS test." - return -1 + return } if {![runto_main]} { - return -1 + return } set supports_pkru 0 set test "probe PKRU support" gdb_test_multiple "print have_pkru()" $test { diff --git a/gdb/testsuite/gdb.arch/i386-prologue.exp b/gdb/testsuite/gdb.arch/i386-prologue.exp index 03a32ba9c3f9..bb2cbdbcc6d1 100644 --- a/gdb/testsuite/gdb.arch/i386-prologue.exp +++ b/gdb/testsuite/gdb.arch/i386-prologue.exp @@ -32,11 +32,11 @@ set additional_flags [gdb_target_symbol_prefix_flags] # Don't use "debug", so that we don't have line information for the assembly # fragments. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list $additional_flags]] != "" } { untested "failed to compile" - return -1 + return } # The code used by the tests here encodes some breakpoints by using # inline assembler. This will generate a SIGTRAP which will be caught @@ -58,11 +58,11 @@ clean_restart $::testfile # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # Testcase for standard prologue. gdb_test "continue" "Program received signal SIGTRAP.*" "continue to standard" diff --git a/gdb/testsuite/gdb.arch/i386-signal.exp b/gdb/testsuite/gdb.arch/i386-signal.exp index 9e7976b5a275..35096076d6f4 100644 --- a/gdb/testsuite/gdb.arch/i386-signal.exp +++ b/gdb/testsuite/gdb.arch/i386-signal.exp @@ -25,11 +25,11 @@ lappend opts nopie lappend opts additional_flags=-DIS_AMD64_REGS_TARGET=[is_amd64_regs_target] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable $opts] != "" } { untested "failed to compile" - return -1 + return } clean_restart $::testfile runto func diff --git a/gdb/testsuite/gdb.arch/i386-size-overlap.exp b/gdb/testsuite/gdb.arch/i386-size-overlap.exp index ccc1d56e6dbc..7991dc9cfc8a 100644 --- a/gdb/testsuite/gdb.arch/i386-size-overlap.exp +++ b/gdb/testsuite/gdb.arch/i386-size-overlap.exp @@ -25,11 +25,11 @@ standard_testfile set additional_flags [gdb_target_symbol_prefix_flags] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable [list debug $additional_flags]] != "" } { untested "failed to compile" - return -1 + return } clean_restart $::testfile # We use gdb_run_cmd so this stands a chance to work for remote diff --git a/gdb/testsuite/gdb.arch/i386-size.exp b/gdb/testsuite/gdb.arch/i386-size.exp index 0b2b2a3c3bda..723a96a3673f 100644 --- a/gdb/testsuite/gdb.arch/i386-size.exp +++ b/gdb/testsuite/gdb.arch/i386-size.exp @@ -30,11 +30,11 @@ set binfile [standard_output_file ${testfile}] set additional_flags [gdb_target_symbol_prefix_flags] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable [list debug $additional_flags]] != "" } { untested "i386-size" - return -1 + return } clean_restart $::testfile # We use gdb_run_cmd so this stands a chance to work for remote diff --git a/gdb/testsuite/gdb.arch/i386-sse-stack-align.exp b/gdb/testsuite/gdb.arch/i386-sse-stack-align.exp index 60b83b525fd5..8732279fc28a 100644 --- a/gdb/testsuite/gdb.arch/i386-sse-stack-align.exp +++ b/gdb/testsuite/gdb.arch/i386-sse-stack-align.exp @@ -27,17 +27,17 @@ if {[info exists COMPILE]} { lappend opts debug optimize=-O2 additional_flags=-msse } if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $opts] != "" } { unsupported "failed to compile" - return -1 + return } clean_restart $executable if {![runto_main]} { - return -1 + return } set args "" foreach i {0 1 2 3 4} { set test "print (int) test_g$i ($args)" diff --git a/gdb/testsuite/gdb.arch/i386-sse.exp b/gdb/testsuite/gdb.arch/i386-sse.exp index 8722a059ef17..54a66880a9f8 100644 --- a/gdb/testsuite/gdb.arch/i386-sse.exp +++ b/gdb/testsuite/gdb.arch/i386-sse.exp @@ -41,11 +41,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } send_gdb "print have_sse ()\r" gdb_expect { -re ".. = 1\r\n$gdb_prompt " { diff --git a/gdb/testsuite/gdb.arch/i386-stap-eval-lang-ada.exp b/gdb/testsuite/gdb.arch/i386-stap-eval-lang-ada.exp index 21beeb400054..63b3ef17adb2 100644 --- a/gdb/testsuite/gdb.arch/i386-stap-eval-lang-ada.exp +++ b/gdb/testsuite/gdb.arch/i386-stap-eval-lang-ada.exp @@ -17,16 +17,16 @@ standard_testfile ".S" # We can only test this if the target is i686 or x86_64 with -m32 require is_x86_like_target if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } gdb_test_no_output "set language ada" if { ![runto "-pstap bar"] } { - return -1 + return } gdb_test "print \$_probe_arg0" " = 40" \ "printing \$_probe_arg0" diff --git a/gdb/testsuite/gdb.arch/i386-unwind.exp b/gdb/testsuite/gdb.arch/i386-unwind.exp index 8f522308fe46..7d816aa2ec5c 100644 --- a/gdb/testsuite/gdb.arch/i386-unwind.exp +++ b/gdb/testsuite/gdb.arch/i386-unwind.exp @@ -28,11 +28,11 @@ standard_testfile # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug $additional_flags]] != "" } { untested "failed to compile" - return -1 + return } clean_restart $::testfile # Testcase for backtrace/1435. diff --git a/gdb/testsuite/gdb.arch/i386-word.exp b/gdb/testsuite/gdb.arch/i386-word.exp index 312daf81aed0..21e601223b0b 100644 --- a/gdb/testsuite/gdb.arch/i386-word.exp +++ b/gdb/testsuite/gdb.arch/i386-word.exp @@ -29,11 +29,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } set word_regs(1) ax set word_regs(2) bx set word_regs(3) cx diff --git a/gdb/testsuite/gdb.arch/ia64-breakpoint-shadow.exp b/gdb/testsuite/gdb.arch/ia64-breakpoint-shadow.exp index e206c07cefef..7c746c12e294 100644 --- a/gdb/testsuite/gdb.arch/ia64-breakpoint-shadow.exp +++ b/gdb/testsuite/gdb.arch/ia64-breakpoint-shadow.exp @@ -18,19 +18,19 @@ require {istarget "ia64-*-*"} set testfile ia64-breakpoint-shadow set srcfile ${testfile}.S set binfile ${objdir}/${subdir}/${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart gdb_load $binfile # We need to start the inferior to place the breakpoints in the memory at all. if {![runto_main]} { - return -1 + return } # The default "auto" mode removes all the breakpoints when we stop (and not # running the nonstop mode). We would not be able to test the shadow. gdb_test "set breakpoint always-inserted on" @@ -53,11 +53,11 @@ gdb_test_multiple "b bundle" $test { set bpt2address $expect_out(1,string) } } if {![info exists bpt2address]} { - return -1 + return } gdb_test "b *($bpt2address + 1)" "Breakpoint \[0-9\] at .*" "slot 1 breakpoint placed" gdb_test "b *($bpt2address + 2)" "Can't insert breakpoint for non-existing slot X" "slot 2 (slot X) breakpoint refusal" diff --git a/gdb/testsuite/gdb.arch/x86-avx512bf16.exp b/gdb/testsuite/gdb.arch/x86-avx512bf16.exp index cebea7c3b620..08d4849bae20 100644 --- a/gdb/testsuite/gdb.arch/x86-avx512bf16.exp +++ b/gdb/testsuite/gdb.arch/x86-avx512bf16.exp @@ -21,15 +21,15 @@ require allow_avx512bf16_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # Test xmm set line1 [gdb_get_line_number "first breakpoint here"] gdb_breakpoint $line1 diff --git a/gdb/testsuite/gdb.arch/x86-avx512fp16-abi.exp b/gdb/testsuite/gdb.arch/x86-avx512fp16-abi.exp index 4b2e3e547e88..6adff2155313 100644 --- a/gdb/testsuite/gdb.arch/x86-avx512fp16-abi.exp +++ b/gdb/testsuite/gdb.arch/x86-avx512fp16-abi.exp @@ -19,15 +19,15 @@ require allow_avx512fp16_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug additional_flags="-mavx512fp16"}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_test "p square(2.2)" "= 4\\.8359" set line1 [gdb_get_line_number "BP1"] diff --git a/gdb/testsuite/gdb.arch/x86-avx512fp16.exp b/gdb/testsuite/gdb.arch/x86-avx512fp16.exp index 2d3ab6814c35..e99ec13f7d0e 100644 --- a/gdb/testsuite/gdb.arch/x86-avx512fp16.exp +++ b/gdb/testsuite/gdb.arch/x86-avx512fp16.exp @@ -18,15 +18,15 @@ require allow_avx512fp16_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # Test xmm. set line1 [gdb_get_line_number "first breakpoint here"] gdb_breakpoint $line1 From patchwork Wed Apr 29 23:03:55 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134196 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id C5DBA4BB3BE6 for ; Wed, 29 Apr 2026 23:05:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C5DBA4BB3BE6 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=JXk42/HB X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2c.google.com (mail-vk1-xa2c.google.com [IPv6:2607:f8b0:4864:20::a2c]) by sourceware.org (Postfix) with ESMTPS id A804C4358A69 for ; Wed, 29 Apr 2026 23:04:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A804C4358A69 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org A804C4358A69 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2c ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503890; cv=none; b=LkEbBo7yVJxJ/wpRB6hcttY1GcbJLtM7QJDHzysIEXp76C69nxsMUoc1sGT5Q1aPEAGKnI3OSqvzaPR3qOP8WdFGNycou/q5d9vA6zlwekHL+WuZQAM3CyMP1SHpUjgewjyX9QNF0Hb/oy1GhybnD/NarVH0QBs9zMXabSJxtCE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503890; c=relaxed/simple; bh=g1seObBqvc0NYaOeN0jhgPBcMgmtHUNQunC1N+6VmLY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=SX4kCIGbiilsNJKlTw1frc+FSIaIQ/GLTEZF6SeqKEjBd4qPlIQM9rtRXtKKLd+tqR2V4qx5+Azb9PliOlyeRGkcZdZ9/LQaBm7ZmFInSWZwkUnuo1CQJZNZAod7d1lnhk8y0uIQhBZTr0Rhi95LNLSpGa0UK3TcsErmTD7D/5E= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A804C4358A69 Received: by mail-vk1-xa2c.google.com with SMTP id 71dfb90a1353d-56db1b3626bso170921e0c.1 for ; Wed, 29 Apr 2026 16:04:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503890; x=1778108690; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=9aaF9Y+/WHb6VVQLcfAOn3TegGAc3hYFS0bSI0q4dto=; b=JXk42/HBdVopia9ndsSu4FKbr8K3g6ihF35PJCNcxjrdMjJ0NBEBKcJ8yhNVdrU3aq aHOLffcpVF7PP1idYb1MEBVJCcb7jN/S7NZmbXrXoSutKiOmm4kTA+DYe2hkBUF6o0XK WpRt6RkDMX3q7vO9Zf83ORBqK5TBUZP8nWh15bGicAR8Bj/hSI0HEyiYtUR2ZCdOp/dM xDU52hRawCBul1SmIS+JMTPKZSFg9Ja1+zCgY1oxT1WrjMPiJCzIXgr9tV/o8rY4Bjpc Lrphwbz0rCffcJKSzsYaoJTvGYy7LNtjXpgcHI/vS+wLA0EI2oDcnnl1DZ7LvGGZ7GPu isHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503890; x=1778108690; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=9aaF9Y+/WHb6VVQLcfAOn3TegGAc3hYFS0bSI0q4dto=; b=ERhJTOi3Uz9eCKQqJzFq8KwJej8b2zk5GWI0sJmT3U2R/WE+f+JpdLZeLxW+zm9L4f TmLZgoUtGPv/eTLLFRHCwol+idx0fyZMMAkk1MH4dM28Dbu+9U8HkR9WPgawbi1EU9nF Ium9DFHnnjkqaU1b5bgVRvGLM5MCTODGrW+ihhKPuWFABM4CilPzHncoxc56V9pYzCpJ 2ib6zU+XnLER5cPXddhpWeYq51p8xGFuyFfmPYrPtd6b90C6Bc7HJo2X/4coCY99Hubg gPcqAdk/Bzr8xsa1MftYrjDNIscE1ltLfVXDzJOyW6dTjozYrEvDfwRsdQ0ostzFkbFi lngw== X-Gm-Message-State: AOJu0Yy5BWHHulXwmmvVeTF8LbbFqO4siR2lOapvQQmXX8YLTrgNN6E9 oy7OfzZQoKIMfryKd36v2fUto+y4TAXlCTEPMXD/rBcwNlfNwUX+WauZumizDnyBFVJpw4vhfyM SwCEz X-Gm-Gg: AeBDieuTfJwVv5mfTW0qEI67xES5hdRdLMezVl1s0afYbDYcseBw2TSGKVfjQ1YYwiW Ujf9TueCwaruJ6DSW47ReKR6pVJS5VQKlwIc4quXOCv0L/ddhE7KOaDlBzJmEqDsqNKAbkyRhnM Q171t5GDhn6uhNja1wWP8lw/Y+EWzMkkn+3d1nyA4ZfRiA+DME3M6t8t0tz4RfYZtiYQCqP9yeD Wg023AqkjxdeawcXkM+5Q+D+KlhFJ9cCbGbf88LPkBiHOIdC8t7m2iUCK5nTOvfRrqnIkeF6y+S n+rAxijqfD8T7wqbTSuKZeXwv08z/Uwi0eivuTZxKzAEx4Ygwr7Zf/FVE/qbhfnCOKil1aDQiZp rozEUhkMiSDf8E8SgVje0GtY9xHK7FgEjWgkQysf4OS3wKueqvPrpwc4kZLZ2BgGs0Ioo0kp+zN VQxLn2Rxx4QSsAUCmz7czb8pgd7NEd/uYW/SN6jj/uD9MF X-Received: by 2002:a05:6122:4f9a:b0:56f:7c7e:f33a with SMTP id 71dfb90a1353d-573c90a960fmr134327e0c.0.1777503890011; Wed, 29 Apr 2026 16:04:50 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6e264aasm2022321e0c.17.2026.04.29.16.04.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:49 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 04/37] GDB: testsuite: x86, amd64, i386: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:03:55 -0300 Message-ID: <20260429230432.60487-5-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes the "return -1" statements that weren't caught by the sed command. In amd64-shadow-stack-cmds.exp the return statements have extra indentation due to being inside a save_vars block. In i386-bp_permanent.exp this was caused by misaligned lines, which are now fixed. --- gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp | 8 ++++---- gdb/testsuite/gdb.arch/i386-bp_permanent.exp | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp b/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp index e4daecb590dd..e67a0c2e4a1f 100644 --- a/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp +++ b/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp @@ -42,16 +42,16 @@ save_vars { ::env(GLIBC_TUNABLES) } { append_environment GLIBC_TUNABLES "glibc.cpu.hwcaps" "SHSTK" if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug additional_flags="-fcf-protection=return"}] } { - return -1 + return } clean_restart ${::testfile} if { ![runto_main] } { - return -1 + return } with_test_prefix "test inferior call and continue" { gdb_breakpoint [ gdb_get_line_number "break call1" ] gdb_continue_to_breakpoint "break call1" ".*break call1.*" @@ -83,11 +83,11 @@ save_vars { ::env(GLIBC_TUNABLES) } { gdb_continue_to_end } clean_restart ${::testfile} if { ![runto_main] } { - return -1 + return } set call1_line [ gdb_get_line_number "break call1" ] set call2_line [ gdb_get_line_number "break call2" ] @@ -120,11 +120,11 @@ save_vars { ::env(GLIBC_TUNABLES) } { gdb_continue_to_end } clean_restart ${::testfile} if { ![runto_main] } { - return -1 + return } with_test_prefix "test return from past frame" { gdb_breakpoint $call2_line gdb_continue_to_breakpoint "break call2" ".*break call2.*" diff --git a/gdb/testsuite/gdb.arch/i386-bp_permanent.exp b/gdb/testsuite/gdb.arch/i386-bp_permanent.exp index ef4d0370de89..9805f5626348 100644 --- a/gdb/testsuite/gdb.arch/i386-bp_permanent.exp +++ b/gdb/testsuite/gdb.arch/i386-bp_permanent.exp @@ -38,11 +38,11 @@ clean_restart $::testfile # # Run to `main' where we begin our tests. # if {![runto_main]} { - return -1 + return } set function "standard" set retcode [gdb_test_multiple "disassemble $function" "disassemble function '$function'" { @@ -51,12 +51,12 @@ set retcode [gdb_test_multiple "disassemble $function" "disassemble function '$f set address_after_bp $expect_out(3,string) } }] if {$retcode != 0} { - fail "disassemble failed, skipping entire test." - return -1 + fail "disassemble failed, skipping entire test." + return } gdb_breakpoint "*$address_bp" gdb_test "continue" "Breakpoint .*, $address_bp in $function.*" \ From patchwork Wed Apr 29 23:03:56 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134200 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 72B6B4358A49 for ; Wed, 29 Apr 2026 23:06:15 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 72B6B4358A49 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=auM2Bgn4 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x932.google.com (mail-ua1-x932.google.com [IPv6:2607:f8b0:4864:20::932]) by sourceware.org (Postfix) with ESMTPS id E56164358A5E for ; Wed, 29 Apr 2026 23:04:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E56164358A5E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org E56164358A5E Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::932 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503894; cv=none; b=Dyj4SW8AOlSSZ3uCVUmTVHuqJVfwp2R0K9mHyPeF4/NEpxqAAhX+ANWM8kIPqotOkohl1ScYWl6wnV+l+thH0/K6Ff6guYUvsSBKPw932CWw4oUuX85CVEQSIeze6jgUUJyFkR9syGTbDh1aNhWyJ0aNE5Shl8MLV2znRkp5pZw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503894; c=relaxed/simple; bh=ZgIRhckrQ63pGcpLwX/Hs+g8dWwxDcHUs68l6AXSplc=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=UBYLhDKXkhfo9+108GFCtclV9Sroent+SroI2csNxNHTXde5dxW9e72Or2leROCdvhV8tcjlT+L+8BIKTiZXE0dGXEZukVkc4SYmhPyEYNmiav9s0l8oibVBRzo6u0xqGKyPOcdJ26xFDKfb+JWqCgXkcCE5DYonH6lYlzkVrjA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E56164358A5E Received: by mail-ua1-x932.google.com with SMTP id a1e0cc1a2514c-94de664b541so117457241.1 for ; Wed, 29 Apr 2026 16:04:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503893; x=1778108693; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=lV2y4hIHEmbFh+J7Ho4vK/otaUPJDhnevSb2OgaBV8Y=; b=auM2Bgn4JLahuaGbobKaO9Zn2t5e6qUZC7O/qYrWlPmwbm2NjEhiC+GGjWrEgg9YUo mkrzek9G0HA0TxTyT5CJ/gAFpMcWHdjNaHP21JTCAZm12JbL6/rtv2yHUMdDMB0X+NB6 V3uBvjuoORzRLZLoZwg3ogKdzbnRhMsnevwsRAd8LlEz21Kqc71Fs26BZbuEfQmDEhfh DoDBhHw2cngQEih6vNVOsjo15P071n1gvf+38f3Tn/lp0qfkJm8VxLjQWRFQfEkiNt8g a/z94PJ4p1qM4hD0rU0LDHuGLdskLkZ+uFSk0qSuGJqmJj28nQrRLiK9CMw/QTqEoNQV o2hQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503893; x=1778108693; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=lV2y4hIHEmbFh+J7Ho4vK/otaUPJDhnevSb2OgaBV8Y=; b=UA541WI4mqvZ1YPRixBXJ8wnvTFISrXwmSfnYXcq+QV6rmTPZgdWEmhi1l2dFCtGDw 74rUZ7ibAPj+3vbHrt/x0HijfnFZRLOuaxQkvjc5ZxSPfovCeA/sFynXhDecIxhlfWZX KDtAvi4opeEbtDLX3QdEwNibFlE67IKbwXTms6xQmfoIi8UioGSqhQJgMoHrRKICZv0/ sfEptRC4+4/7aMn5btawsitS3mrv8rIgtR6uQUuzLGkZPj5j33BXyTk4ua2eCqENggTG vc4nlwdwOhw9jtxQiDGB/h9rZBbpvrV4a51+EfWqmoB+DESSX8r/NPU9GGEVKel6zNIK 8zaw== X-Gm-Message-State: AOJu0YzMOv/4ABt1DP8wXotL0yVXlwa1r1j9jOkSsHV/EGvwAkY6rj7z UFM1n5JKRJg+7kdYKAJ5J3EDl3TtOPcEdAgG22fZYniJ5Rz/2k4AErYggx4ZCadDGiSC4/LiIkS c/1B6 X-Gm-Gg: AeBDiesYKUDG+9Db4KhcrbktwCz+UE6SbxEM/0kv2vgT3y/1tcaK3dr21KJHOLYGWt5 47A8ayIqOeNXOz12FUKREpD0LAUMLdbWXo1fIQBH2iqu/YPnLvWcbRkr3huB2Ujbcfn3QiU+8jp keAEBfbluwHeOqc2ftQNngGf7QMGgq9ZVD8OlrfKHVe/pcSwWfHlk/rBf4lewvhpSaP+WyWGCZw 63iNmp7IcTTyEZL8v75CgP+ezzh9XgXfxg23p5ucAUlNMOrQkRQW2/2lIJYeSP9j3u55cA36sWO lA6f3un1xVW1G4mz1R7yI3K/EOyQ5FfrBIEL3yPd5MEijpgM9PRnqpCvVPkNFMeIN0GOtwhebFd 8cop/1AGCaKiMG7zsH5Ukcs5DtbWL7gWnOPwErOJMJe24qQU7KT39DozqjHF06gHB1T+SAI/moN UPIucZauWBube+UXLZKDSEZoFFJduIjEeHn3HOEdxvvooe X-Received: by 2002:a05:6102:424f:b0:608:8fb9:9104 with SMTP id ada2fe7eead31-62ad4b88388mr251668137.29.1777503893047; Wed, 29 Apr 2026 16:04:53 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb7830468sm1839567241.13.2026.04.29.16.04.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:52 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 05/37] GDB: testsuite: powerpc: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:03:56 -0300 Message-ID: <20260429230432.60487-6-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' \ aix*.exp* altivec*.exp* e500*.exp* powerpc*.exp* ppc*.exp* vsx*.exp* and $ sed -i 's/^ return 0/ return/' \ aix*.exp* altivec*.exp* e500*.exp* powerpc*.exp* ppc*.exp* vsx*.exp* inside gdb/testsuite/gdb.arch. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.arch/aix-sighandle.exp | 2 +- gdb/testsuite/gdb.arch/altivec-abi.exp | 2 +- gdb/testsuite/gdb.arch/altivec-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/e500-abi.exp | 2 +- gdb/testsuite/gdb.arch/e500-prologue.exp | 2 +- gdb/testsuite/gdb.arch/e500-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/powerpc-addpcis.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-aix-prologue.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-altivec.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-altivec2.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-altivec3.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-d128-regs.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-fpscr-gcore.exp | 10 +++++----- gdb/testsuite/gdb.arch/powerpc-lnia.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-power10.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-power7.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-power8.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-power9.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-prologue.exp | 4 ++-- gdb/testsuite/gdb.arch/powerpc-stackless.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-tar.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-trap.exp | 4 ++-- gdb/testsuite/gdb.arch/powerpc-vsx-gcore.exp | 10 +++++----- gdb/testsuite/gdb.arch/powerpc-vsx.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-vsx2.exp | 2 +- gdb/testsuite/gdb.arch/powerpc-vsx3.exp | 2 +- gdb/testsuite/gdb.arch/powerpc64-prologue.exp | 6 +++--- gdb/testsuite/gdb.arch/ppc-dfp.exp | 6 +++--- gdb/testsuite/gdb.arch/ppc-fp.exp | 4 ++-- gdb/testsuite/gdb.arch/ppc64-atomic-inst.exp | 2 +- gdb/testsuite/gdb.arch/ppc64-break-on-_exit.exp | 4 ++-- gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.exp | 2 +- gdb/testsuite/gdb.arch/ppc64-symtab-cordic.exp | 4 ++-- gdb/testsuite/gdb.arch/vsx-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/vsx-vsr-float28.exp | 4 ++-- 37 files changed, 58 insertions(+), 58 deletions(-) diff --git a/gdb/testsuite/gdb.arch/aix-sighandle.exp b/gdb/testsuite/gdb.arch/aix-sighandle.exp index df988b26a44d..4e5bb50c8560 100644 --- a/gdb/testsuite/gdb.arch/aix-sighandle.exp +++ b/gdb/testsuite/gdb.arch/aix-sighandle.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . require {istarget "powerpc*-*-aix*"} if { [prepare_for_testing "failed to prepare" aix-sighandle aix-sighandle.c] } { - return -1 + return } set srcfile aix-sighandle.c set binfile aix-sighandle diff --git a/gdb/testsuite/gdb.arch/altivec-abi.exp b/gdb/testsuite/gdb.arch/altivec-abi.exp index 40b1c3519e28..f7bea3de4ced 100644 --- a/gdb/testsuite/gdb.arch/altivec-abi.exp +++ b/gdb/testsuite/gdb.arch/altivec-abi.exp @@ -168,7 +168,7 @@ if {[test_compiler_info gcc*]} { } } elseif {[test_compiler_info xlc*]} { altivec_abi_tests "additional_flags=-qaltivec" "auto" } else { warning "unknown compiler" - return -1 + return } diff --git a/gdb/testsuite/gdb.arch/altivec-regs.exp b/gdb/testsuite/gdb.arch/altivec-regs.exp index 70a15a9190a8..4dd8610d8f15 100644 --- a/gdb/testsuite/gdb.arch/altivec-regs.exp +++ b/gdb/testsuite/gdb.arch/altivec-regs.exp @@ -30,11 +30,11 @@ if {[test_compiler_info gcc*]} { set compile_flags "$compile_flags additional_flags=-maltivec additional_flags=-mabi=altivec" } elseif {[test_compiler_info xlc*]} { set compile_flags "$compile_flags additional_flags=-qaltivec" } else { warning "unknown compiler" - return -1 + return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $compile_flags] != "" } { untested "failed to compile" return -1 @@ -47,11 +47,11 @@ gdb_load ${binfile} # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "start here"] gdb_continue_to_breakpoint "start here" diff --git a/gdb/testsuite/gdb.arch/e500-abi.exp b/gdb/testsuite/gdb.arch/e500-abi.exp index 1c074f10aa7e..6f549539e2c3 100644 --- a/gdb/testsuite/gdb.arch/e500-abi.exp +++ b/gdb/testsuite/gdb.arch/e500-abi.exp @@ -40,11 +40,11 @@ gdb_load ${binfile} # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } gdb_test "b marker" "Breakpoint 2 at.*file.*e500-abi.c, line ${::decimal}." "break marker" gdb_test "continue" "Breakpoint 2.*marker.*e500-abi.c.*" "continue to marker" gdb_test "finish" "Run till exit from .0.*marker.*at.*e500-abi.c.*main \\(\\) at.*e500-abi.c.*res_vec = vec_func \\(a_vec,.*goes in r3.*" "back to main (1)" diff --git a/gdb/testsuite/gdb.arch/e500-prologue.exp b/gdb/testsuite/gdb.arch/e500-prologue.exp index b3d0056fd97c..f6884285e3a3 100644 --- a/gdb/testsuite/gdb.arch/e500-prologue.exp +++ b/gdb/testsuite/gdb.arch/e500-prologue.exp @@ -22,11 +22,11 @@ require {istarget "powerpc-*"} set testfile "e500-prologue" set srcfile ${testfile}.c set binfile ${objdir}/${subdir}/${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {}] != "" } { unsupported "failed to compile" - return -1 + return } clean_restart gdb_load $binfile diff --git a/gdb/testsuite/gdb.arch/e500-regs.exp b/gdb/testsuite/gdb.arch/e500-regs.exp index 2dc1ade4b448..b9d172c058d7 100644 --- a/gdb/testsuite/gdb.arch/e500-regs.exp +++ b/gdb/testsuite/gdb.arch/e500-regs.exp @@ -39,11 +39,11 @@ gdb_load ${binfile} # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # set all the registers integer portions to 1 for {set i 0} {$i < 32} {incr i 1} { for {set j 0} {$j < 2} {incr j 1} { @@ -137,11 +137,11 @@ gdb_expect_list "info vector" ".*$gdb_prompt $" { # some unusual values. clean_restart gdb_load $binfile if {![runto_main]} { - return 0 + return } gdb_test "break vector_fun" \ "Breakpoint 2 at.*e500-regs.c, line ${::decimal}\\." \ "set breakpoint at vector_fun" diff --git a/gdb/testsuite/gdb.arch/powerpc-addpcis.exp b/gdb/testsuite/gdb.arch/powerpc-addpcis.exp index e699e730021c..a8895446cde3 100644 --- a/gdb/testsuite/gdb.arch/powerpc-addpcis.exp +++ b/gdb/testsuite/gdb.arch/powerpc-addpcis.exp @@ -30,11 +30,11 @@ set retval 0 standard_testfile .s if { [prepare_for_testing "failed to prepare" $testfile "$srcfile" \ {debug quiet}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.arch/powerpc-aix-prologue.exp b/gdb/testsuite/gdb.arch/powerpc-aix-prologue.exp index f465f36fe2da..0da2383b1082 100644 --- a/gdb/testsuite/gdb.arch/powerpc-aix-prologue.exp +++ b/gdb/testsuite/gdb.arch/powerpc-aix-prologue.exp @@ -23,11 +23,11 @@ require {istarget "powerpc-*-aix*"} set testfile "powerpc-aix-prologue" set srcfile ${testfile}.c set binfile ${objdir}/${subdir}/${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {}] != "" } { unsupported "failed to compile" - return -1 + return } clean_restart gdb_load $binfile diff --git a/gdb/testsuite/gdb.arch/powerpc-altivec.exp b/gdb/testsuite/gdb.arch/powerpc-altivec.exp index edbb822ff838..cb89ba7e518f 100644 --- a/gdb/testsuite/gdb.arch/powerpc-altivec.exp +++ b/gdb/testsuite/gdb.arch/powerpc-altivec.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-altivec2.exp b/gdb/testsuite/gdb.arch/powerpc-altivec2.exp index 1b34cb6a8a33..621f44dc4e42 100644 --- a/gdb/testsuite/gdb.arch/powerpc-altivec2.exp +++ b/gdb/testsuite/gdb.arch/powerpc-altivec2.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-altivec3.exp b/gdb/testsuite/gdb.arch/powerpc-altivec3.exp index 602e65217494..6607e24d7a8f 100644 --- a/gdb/testsuite/gdb.arch/powerpc-altivec3.exp +++ b/gdb/testsuite/gdb.arch/powerpc-altivec3.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp b/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp index 05ae31877e1b..10c77ef29489 100644 --- a/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp +++ b/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp @@ -34,11 +34,11 @@ clean_restart $::testfile if {![runto_main]} { return } if {[gdb_test "show arch" ".*powerpc:common.*" "checking for PPC arch"]} { - return -1 + return } gdb_test "next" "" for {set i 0} {$i < 16} {incr i 1} { diff --git a/gdb/testsuite/gdb.arch/powerpc-fpscr-gcore.exp b/gdb/testsuite/gdb.arch/powerpc-fpscr-gcore.exp index e0afcf419272..b2ead4cef5ee 100644 --- a/gdb/testsuite/gdb.arch/powerpc-fpscr-gcore.exp +++ b/gdb/testsuite/gdb.arch/powerpc-fpscr-gcore.exp @@ -29,17 +29,17 @@ gdb_produce_source $gen_src { return 0; } } if {[build_executable "compile" $binfile $gen_src] == -1} { - return -1 + return } clean_restart $testfile if {![runto_main]} { - return -1 + return } # Check if our target has FPSCR proc check_fpscr_access {} { global gdb_prompt @@ -57,28 +57,28 @@ proc check_fpscr_access {} { } return 0 } if { ![check_fpscr_access] } { - return -1 + return } set fpscr_size_process [get_integer_valueof "sizeof(\$fpscr)" -1 "process size"] set core_filename [standard_output_file "$testfile.core"] set core_generated [gdb_gcore_cmd "$core_filename" "generate core file"] if { !$core_generated } { - return -1 + return } clean_restart set core_loaded [gdb_core_cmd "$core_filename" "load core file"] if { $core_loaded != 1 } { - return -1 + return } set fpscr_size_corefile [get_integer_valueof "sizeof(\$fpscr)" -2 "corefile size" ] set test "fpscr size matches" diff --git a/gdb/testsuite/gdb.arch/powerpc-lnia.exp b/gdb/testsuite/gdb.arch/powerpc-lnia.exp index 799b6fc06b79..700ba0dea67d 100644 --- a/gdb/testsuite/gdb.arch/powerpc-lnia.exp +++ b/gdb/testsuite/gdb.arch/powerpc-lnia.exp @@ -29,11 +29,11 @@ set retval 0 standard_testfile .s if { [prepare_for_testing "failed to prepare" $testfile "$srcfile" \ {debug quiet}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp b/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp index 4f90080cf564..865ceb18ccd1 100644 --- a/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp +++ b/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp @@ -22,11 +22,11 @@ set retval 0 standard_testfile .s if { [prepare_for_testing "failed to prepare" $testfile "$srcfile" \ {debug quiet}] } { - return -1 + return } gdb_test "set radix 0b10000" gdb_test "set debug displaced" diff --git a/gdb/testsuite/gdb.arch/powerpc-power10.exp b/gdb/testsuite/gdb.arch/powerpc-power10.exp index 4fa55b01da1b..1389a5568e27 100644 --- a/gdb/testsuite/gdb.arch/powerpc-power10.exp +++ b/gdb/testsuite/gdb.arch/powerpc-power10.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-power7.exp b/gdb/testsuite/gdb.arch/powerpc-power7.exp index 17ef875f4aef..810f536f8b0f 100644 --- a/gdb/testsuite/gdb.arch/powerpc-power7.exp +++ b/gdb/testsuite/gdb.arch/powerpc-power7.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-power8.exp b/gdb/testsuite/gdb.arch/powerpc-power8.exp index baefb3cb6554..14a49b71f987 100644 --- a/gdb/testsuite/gdb.arch/powerpc-power8.exp +++ b/gdb/testsuite/gdb.arch/powerpc-power8.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-power9.exp b/gdb/testsuite/gdb.arch/powerpc-power9.exp index 7e446330e68a..2d4884ce815f 100644 --- a/gdb/testsuite/gdb.arch/powerpc-power9.exp +++ b/gdb/testsuite/gdb.arch/powerpc-power9.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp b/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp index 1a6c4ca367e3..1f41f3aaaa3f 100644 --- a/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp +++ b/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp @@ -20,11 +20,11 @@ set binfile [standard_output_file ${testfile}] if {[gdb_compile \ [list ${srcdir}/${subdir}/$srcfile ${srcdir}/${subdir}/$srcfile2] \ "${binfile}" executable {}] != ""} { untested "failed to build $binfile" - return -1 + return } clean_restart $testfile diff --git a/gdb/testsuite/gdb.arch/powerpc-prologue.exp b/gdb/testsuite/gdb.arch/powerpc-prologue.exp index c52507a716c9..7256f7514649 100644 --- a/gdb/testsuite/gdb.arch/powerpc-prologue.exp +++ b/gdb/testsuite/gdb.arch/powerpc-prologue.exp @@ -25,22 +25,22 @@ set binfile [standard_output_file ${testfile}] # Don't use "debug", so that we don't have line information for the assembly # fragments. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {}] != "" } { untested "PowerPC prologue tests" - return -1 + return } clean_restart $testfile # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # Testcase for PIC prologue. gdb_breakpoint "gdb2029_marker" diff --git a/gdb/testsuite/gdb.arch/powerpc-stackless.exp b/gdb/testsuite/gdb.arch/powerpc-stackless.exp index 78084682d51c..eff840886079 100644 --- a/gdb/testsuite/gdb.arch/powerpc-stackless.exp +++ b/gdb/testsuite/gdb.arch/powerpc-stackless.exp @@ -18,11 +18,11 @@ require {istarget "powerpc*-*-*"} standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Run until SIGSEGV. gdb_run_cmd diff --git a/gdb/testsuite/gdb.arch/powerpc-tar.exp b/gdb/testsuite/gdb.arch/powerpc-tar.exp index dadafdfcebc9..0bda11caf9ca 100644 --- a/gdb/testsuite/gdb.arch/powerpc-tar.exp +++ b/gdb/testsuite/gdb.arch/powerpc-tar.exp @@ -25,11 +25,11 @@ require {istarget "powerpc*-*-linux*"} standard_testfile .c if {[build_executable "compile" $binfile $srcfile {debug}] == -1} { - return -1 + return } proc check_register_access { regname } { global gdb_prompt diff --git a/gdb/testsuite/gdb.arch/powerpc-trap.exp b/gdb/testsuite/gdb.arch/powerpc-trap.exp index 5d94efa9db41..099ae8da0a9d 100644 --- a/gdb/testsuite/gdb.arch/powerpc-trap.exp +++ b/gdb/testsuite/gdb.arch/powerpc-trap.exp @@ -32,16 +32,16 @@ if { [istarget powerpc-*] } { unsupported "Skipping powerpc-specific tests" return } if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { untested "could not run to main" - return -1 + return } set keep_going 1 set count 0 diff --git a/gdb/testsuite/gdb.arch/powerpc-vsx-gcore.exp b/gdb/testsuite/gdb.arch/powerpc-vsx-gcore.exp index b0c197f6a95f..3f51b0f7fff5 100644 --- a/gdb/testsuite/gdb.arch/powerpc-vsx-gcore.exp +++ b/gdb/testsuite/gdb.arch/powerpc-vsx-gcore.exp @@ -29,17 +29,17 @@ gdb_produce_source $gen_src { return 0; } } if {[build_executable "compile" $binfile $gen_src] == -1} { - return -1 + return } clean_restart $testfile if {![runto_main]} { - return -1 + return } # Check if VSX register access through gdb is supported proc check_vsx_access {} { global gdb_prompt @@ -57,30 +57,30 @@ proc check_vsx_access {} { } return 0 } if { ![check_vsx_access] } { - return -1 + return } for {set i 0} {$i < 64} {incr i 1} { gdb_test_no_output "set \$vs$i.uint128 = $i" } set core_filename [standard_output_file "$testfile.core"] set core_generated [gdb_gcore_cmd "$core_filename" "generate core file"] if { !$core_generated } { - return -1 + return } clean_restart set core_loaded [gdb_core_cmd "$core_filename" "load core file"] if { $core_loaded != 1 } { - return -1 + return } for {set i 0} {$i < 64} {incr i 1} { gdb_test "print \$vs$i.uint128" ".* = $i" "print vs$i" } diff --git a/gdb/testsuite/gdb.arch/powerpc-vsx.exp b/gdb/testsuite/gdb.arch/powerpc-vsx.exp index aeefe3df0746..c53502ce332c 100644 --- a/gdb/testsuite/gdb.arch/powerpc-vsx.exp +++ b/gdb/testsuite/gdb.arch/powerpc-vsx.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-vsx2.exp b/gdb/testsuite/gdb.arch/powerpc-vsx2.exp index eb27085d7339..23ff53d855a3 100644 --- a/gdb/testsuite/gdb.arch/powerpc-vsx2.exp +++ b/gdb/testsuite/gdb.arch/powerpc-vsx2.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc-vsx3.exp b/gdb/testsuite/gdb.arch/powerpc-vsx3.exp index 9e9661b39df1..89e9775962bd 100644 --- a/gdb/testsuite/gdb.arch/powerpc-vsx3.exp +++ b/gdb/testsuite/gdb.arch/powerpc-vsx3.exp @@ -22,11 +22,11 @@ set objfile [standard_output_file ${testfile}.o] require {istarget "powerpc*-*-*"} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" } { untested "PowerPC instructions disassembly" - return -1 + return } clean_restart gdb_load $objfile diff --git a/gdb/testsuite/gdb.arch/powerpc64-prologue.exp b/gdb/testsuite/gdb.arch/powerpc64-prologue.exp index 1add4a4d2929..342d18ea4bd8 100644 --- a/gdb/testsuite/gdb.arch/powerpc64-prologue.exp +++ b/gdb/testsuite/gdb.arch/powerpc64-prologue.exp @@ -23,21 +23,21 @@ standard_testfile .c # Don't use "debug", so that we don't have line information for the assembly # fragments. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {}] != "" } { untested "PowerPC prologue tests" - return -1 + return } if { [prepare_for_testing "failed to prepare" $testfile "$srcfile" \ {}] } { - return -1 + return } # Run to `main' where we begin our tests. if {![runto_main]} { - return 0 + return } # Testcase for PIC prologue. gdb_breakpoint "gdb2029_marker" gdb_test "continue" "Breakpoint $decimal, $hex in gdb2029_marker \\(\\).*" \ diff --git a/gdb/testsuite/gdb.arch/ppc-dfp.exp b/gdb/testsuite/gdb.arch/ppc-dfp.exp index 08c732774df1..becfc8206ca9 100644 --- a/gdb/testsuite/gdb.arch/ppc-dfp.exp +++ b/gdb/testsuite/gdb.arch/ppc-dfp.exp @@ -21,16 +21,16 @@ require {istarget "powerpc*"} standard_testfile if {![test_compiler_info gcc*]} { # We use GCC's extended asm syntax warning "unknown compiler" - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {quiet debug}] != "" } { unsupported "this machine doesn't support Decimal Floating Point." - return -1 + return } clean_restart $::testfile gdb_breakpoint [gdb_get_line_number "Set DFP rounding mode."] @@ -40,11 +40,11 @@ gdb_run_cmd # When the prompt comes back we'll be at the Set DFP rounding mode breakpoint. # Unless the program bails out after checking AT_HWCAP. gdb_expect { -re "$inferior_exited_re with code 01.\[\r\n\]+$gdb_prompt $" { unsupported "this machine doesn't support Decimal Floating Point." - return -1 + return } -re ".*$gdb_prompt $" {} } diff --git a/gdb/testsuite/gdb.arch/ppc-fp.exp b/gdb/testsuite/gdb.arch/ppc-fp.exp index e935b5ab1882..f17e37102ad5 100644 --- a/gdb/testsuite/gdb.arch/ppc-fp.exp +++ b/gdb/testsuite/gdb.arch/ppc-fp.exp @@ -21,16 +21,16 @@ require {istarget "powerpc*"} standard_testfile if {![test_compiler_info gcc*]} { # We use GCC's extended asm syntax warning "unknown compiler" - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {quiet debug}] != "" } { verbose "Skipping FPSCR tests." - return -1 + return } clean_restart $::testfile gdb_breakpoint [gdb_get_line_number "Invalid operation."] diff --git a/gdb/testsuite/gdb.arch/ppc64-atomic-inst.exp b/gdb/testsuite/gdb.arch/ppc64-atomic-inst.exp index c020df807f44..56854c75394d 100644 --- a/gdb/testsuite/gdb.arch/ppc64-atomic-inst.exp +++ b/gdb/testsuite/gdb.arch/ppc64-atomic-inst.exp @@ -22,11 +22,11 @@ require {istarget "powerpc*"} is_lp64_target standard_testfile .S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug quiet}] } { - return -1 + return } # The test proper. DISPLACED is true if we should try with displaced # stepping. proc do_test { displaced } { diff --git a/gdb/testsuite/gdb.arch/ppc64-break-on-_exit.exp b/gdb/testsuite/gdb.arch/ppc64-break-on-_exit.exp index fd8eae300c34..684fa04213de 100644 --- a/gdb/testsuite/gdb.arch/ppc64-break-on-_exit.exp +++ b/gdb/testsuite/gdb.arch/ppc64-break-on-_exit.exp @@ -37,15 +37,15 @@ if {[info exists COMPILE]} { standard_testfile .s -main.c } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] $flags] } { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_breakpoint "_exit" # If the skip_prologue analysis of _exit is too eager, we may not hit the diff --git a/gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.exp b/gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.exp index 482dbb4d04fd..db8c7582d0c3 100644 --- a/gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.exp +++ b/gdb/testsuite/gdb.arch/ppc64-isa207-atomic-inst.exp @@ -25,11 +25,11 @@ require {istarget "powerpc*"} is_lp64_target standard_testfile .c .S if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" \ {debug quiet}] } { - return -1 + return } # The test proper. DISPLACED is true if we should try with displaced # stepping. diff --git a/gdb/testsuite/gdb.arch/ppc64-symtab-cordic.exp b/gdb/testsuite/gdb.arch/ppc64-symtab-cordic.exp index 9a804591514d..c418435921b6 100644 --- a/gdb/testsuite/gdb.arch/ppc64-symtab-cordic.exp +++ b/gdb/testsuite/gdb.arch/ppc64-symtab-cordic.exp @@ -27,17 +27,17 @@ set kobz2file ${srcdir}/${subdir}/cordic.ko.bz2 set kodebugbz2file ${srcdir}/${subdir}/cordic.ko.debug.bz2 set kofile [decompress_bz2 $kobz2file] if { $kofile == "" } { untested "failed bzip2 for [file tail $kobz2file]" - return -1 + return } set kodebugfile [decompress_bz2 $kodebugbz2file] if { $kodebugfile == "" } { untested "failed bzip2 for [file tail $kodebugbz2file]" - return -1 + return } # This test won't work properly if system debuginfo is installed. # Test message is suppressed by "" as otherwise we could print PASS+UNTESTED # result to gdb.sum making a false feeling the issue has been tested. diff --git a/gdb/testsuite/gdb.arch/vsx-regs.exp b/gdb/testsuite/gdb.arch/vsx-regs.exp index cac7be5ee09e..bb5675f17542 100644 --- a/gdb/testsuite/gdb.arch/vsx-regs.exp +++ b/gdb/testsuite/gdb.arch/vsx-regs.exp @@ -28,11 +28,11 @@ if {[test_compiler_info gcc*]} { set compile_flags "$compile_flags additional_flags=-maltivec additional_flags=-mabi=altivec" } elseif {[test_compiler_info xlc*]} { set compile_flags "$compile_flags additional_flags=-qaltivec" } else { warning "unknown compiler" - return -1 + return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $compile_flags] != "" } { untested "failed to compile" return -1 @@ -43,11 +43,11 @@ gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} # Run to `main' where we begin our tests. if {![runto_main]} { - return 0 + return } set endianness [get_endianness] # Data sets used throughout the test diff --git a/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp b/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp index 9c44cdd61637..217f240f437d 100644 --- a/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp +++ b/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp @@ -27,11 +27,11 @@ if {[test_compiler_info gcc*]} { set compile_flags "$compile_flags additional_flags=-maltivec additional_flags=-mabi=altivec" } elseif {[test_compiler_info xlc*]} { set compile_flags "$compile_flags additional_flags=-qaltivec" } else { warning "unknown compiler" - return -1 + return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $compile_flags] != "" } { untested "failed to compile" return -1 @@ -42,11 +42,11 @@ gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} # Run to `main' where we begin our tests. if {![runto_main]} { - return 0 + return } set endianness [get_endianness] # Data sets used throughout the test From patchwork Wed Apr 29 23:03:57 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134204 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 63FCE4BB58BE for ; Wed, 29 Apr 2026 23:07:02 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 63FCE4BB58BE Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=rAptnE0i X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2b.google.com (mail-vk1-xa2b.google.com [IPv6:2607:f8b0:4864:20::a2b]) by sourceware.org (Postfix) with ESMTPS id 1437C4358A6E for ; Wed, 29 Apr 2026 23:04:57 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1437C4358A6E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1437C4358A6E Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2b ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503897; cv=none; b=vWUKQM8oG40xp45wHw1NixTkfFWqm58eFHlHvzFUamT2C/yn3bDgyJ5iORiVQpC7ZErwGH0+JTyhOfTfMzDCTSKaCqI1Y/ORfMxsHHtU6aIq1IN6jxG7ahOdnY0KpR1own9Njtm8I+YkioydyojrVhLwoR5V4K5A/+MwKkVmRPc= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503897; c=relaxed/simple; bh=L7EQjV4LL7ZA9NQs3v49Fg7uGRF1ABt3nKLjOXIZZlE=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=u4NvSbdgFVy2TCv8jYOyzBKI3PaRWMmEPhTL2DpGUTlvy/HDVgqbMZzV4LziRxac3cLsoSg6LiGAYRO36V5kFcAP00uomHRLwsI16dChL1+R3+0MOeIHqMBCK7mDB3eLRND0ZJ935DG47spdEuIQyy3eGnGvdYGJtwj/TaRxhGo= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1437C4358A6E Received: by mail-vk1-xa2b.google.com with SMTP id 71dfb90a1353d-56efdc96b05so176798e0c.1 for ; Wed, 29 Apr 2026 16:04:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503896; x=1778108696; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=FTTWI1scC7j5LMRVC8FLw2DZIJzbb+IqFDGlNUjXLv8=; b=rAptnE0iaAzBDlN3TxWp4Dg9aiFro9GlLAz0gaolo+a+7qknrgVeF9E4x37jd3hEhG /d8VR+vdNxuYuMFVMsh/v+ByU4LDiCjboDbytgOOWARxx6K83Uc3zWUO7gnm7I6dGHOp mBtiVoL/c+sUckPSEeDBFIZ8cdfGp4OQ6maOJgs3C/Ckq+m78lpVU8jaU/YQXar6A5Yt mSkqVhpzRIYDi3UH6xlE/h/0pO2EQ6Ml7SMXzJU8ksSdDx3K0zuc8onPwmdlre9cxpCz yTipUPNJxkV4LShGkJMPYaC5czj+OuhqhDApFyVZVKR+Xf5gYImuJo5uw8G73VhZunNd bKxQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503896; x=1778108696; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=FTTWI1scC7j5LMRVC8FLw2DZIJzbb+IqFDGlNUjXLv8=; b=VfnsjK44oXh05ArqTwNgss+k90YGNDQ3lismArp5UkGBsTieE/kF6mm9sTXUYtHlOw Wn6kKwpNpSC1M56Xfu9aRZtZWbhj+o0QAryERIcJh76Cm+BypjYVpgcRQXB3LlSHQPl7 L76yaxHAbOSUAhzkHQrXvU2Vg5x3ARy/Cvd//rZDUJxOcmgQLw1l1ZXEH6FwyDMaG/ut y7m2EXUUrcvKW0XMPtdHFphDBlAfSPOaJ3qK/kYB3lkXh7SlWGCcujfmSo/Qa+Qg9PGO 8D7m/sGs/UTGXJixJVOWht5M6Da2ycyo8Z3Q+Q4gvFk7QQd3eSdfpoNHynwzePNDOjZD TF7w== X-Gm-Message-State: AOJu0YwElNGAx69VswMdo8l2fJc1t3tCesw83LKZKfiPMhMSx1vCdC2r e9nyT/Sa1CeYmJU8Xp4eYTR6ThPZe/EEDsx/TkOUK4ncvbjFGvR/8vminxLdm+n3Y0R8EUewy0a VXn/H X-Gm-Gg: AeBDievtz0KO3R1kqu2Sf0Fn1BgHo7p19HFrbM0huUgChvhH2HVHG9mtoFt8yDSUL0i +yIDccdhcORKGv9O4A1HPDqZX20zvVKqcJyOYVupS9D28iB0dSbbVPl/HCmIAs5l6qpI6jIjs7F 4UerIwIYZDEnzKoGoz04fv/nJq9ptOo/CpYoz1TQIMOCHrwXTTwWPdQjWUCgvF59NAMBLDd2xlD fkU2gldMRXAea52uXFgCVXvB0l5wxbsB4ndXfTcjs1l9ViyzrHTfJMCqwv/26O8LrNmYjwfFFY3 iybdnvSKODD+D1pG+RzAjv+W3ebKNxVsvHZOO22haLix/jiN+AUQqrf3Fr5ot1hKAxbaypzSSIO M4ycOVefmHytAtzG/QibfZIgWruPe5vGP39k9MqPAsNSFxAcE7CCan/dnK3tUveUOdXHBGeVdFe Dom2AoXHzHAWbUbzgJS4OSqSWODZdMvcSuOj1R+c/8ON8c X-Received: by 2002:a05:6122:6599:b0:567:4e8a:fb13 with SMTP id 71dfb90a1353d-573c962185bmr101041e0c.8.1777503896417; Wed, 29 Apr 2026 16:04:56 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573beef358asm1341660e0c.0.2026.04.29.16.04.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:55 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 06/37] GDB: testsuite: powerpc: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:03:57 -0300 Message-ID: <20260429230432.60487-7-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes the "return -1" statements that weren't caught by the sed command because they were in a misaligned line, which is then aligned by this patch. --- gdb/testsuite/gdb.arch/altivec-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/e500-abi.exp | 4 ++-- gdb/testsuite/gdb.arch/e500-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/powerpc-d128-regs.exp | 4 ++-- gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp | 4 ++-- gdb/testsuite/gdb.arch/vsx-regs.exp | 6 +++--- gdb/testsuite/gdb.arch/vsx-vsr-float28.exp | 4 ++-- 7 files changed, 15 insertions(+), 15 deletions(-) diff --git a/gdb/testsuite/gdb.arch/altivec-regs.exp b/gdb/testsuite/gdb.arch/altivec-regs.exp index 4dd8610d8f15..04dc342de6d4 100644 --- a/gdb/testsuite/gdb.arch/altivec-regs.exp +++ b/gdb/testsuite/gdb.arch/altivec-regs.exp @@ -34,12 +34,12 @@ if {[test_compiler_info gcc*]} { warning "unknown compiler" return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $compile_flags] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} diff --git a/gdb/testsuite/gdb.arch/e500-abi.exp b/gdb/testsuite/gdb.arch/e500-abi.exp index 6f549539e2c3..e0223fd67888 100644 --- a/gdb/testsuite/gdb.arch/e500-abi.exp +++ b/gdb/testsuite/gdb.arch/e500-abi.exp @@ -27,12 +27,12 @@ set testfile "e500-abi" set binfile ${objdir}/${subdir}/${testfile} set src1 ${srcdir}/${subdir}/${testfile}.c if { [gdb_compile ${src1} ${binfile} executable {debug nowarnings}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} diff --git a/gdb/testsuite/gdb.arch/e500-regs.exp b/gdb/testsuite/gdb.arch/e500-regs.exp index b9d172c058d7..03d6f42b5332 100644 --- a/gdb/testsuite/gdb.arch/e500-regs.exp +++ b/gdb/testsuite/gdb.arch/e500-regs.exp @@ -26,12 +26,12 @@ require {istarget "powerpc-*eabispe"} set testfile "e500-regs" set binfile ${objdir}/${subdir}/${testfile} set src1 ${srcdir}/${subdir}/${testfile}.c if { [gdb_compile ${src1} ${binfile} executable {debug nowarnings}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} diff --git a/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp b/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp index 10c77ef29489..7043fac5e568 100644 --- a/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp +++ b/gdb/testsuite/gdb.arch/powerpc-d128-regs.exp @@ -23,12 +23,12 @@ require {istarget "powerpc64*-*"} standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {quiet debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } clean_restart $::testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp b/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp index 1f41f3aaaa3f..3899121f9341 100644 --- a/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp +++ b/gdb/testsuite/gdb.arch/powerpc-prologue-frame.exp @@ -27,12 +27,12 @@ if {[gdb_compile \ clean_restart $testfile if {![runto bar]} { - untested "could not run to bar" - return -1 + untested "could not run to bar" + return } gdb_test "bt" \ "#0\[ \t\]*$hex in bar.*\r\n#1\[ \t\]*$hex in foo.*\r\n#2\[ \t\]*$hex in main.*" \ "Backtrace to the main frame" diff --git a/gdb/testsuite/gdb.arch/vsx-regs.exp b/gdb/testsuite/gdb.arch/vsx-regs.exp index bb5675f17542..87f749f93b12 100644 --- a/gdb/testsuite/gdb.arch/vsx-regs.exp +++ b/gdb/testsuite/gdb.arch/vsx-regs.exp @@ -32,12 +32,12 @@ if {[test_compiler_info gcc*]} { warning "unknown compiler" return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $compile_flags] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} @@ -179,11 +179,11 @@ for {set i 0} {$i < 32} {incr i 1} { } # Test reading the core file. if {!$core_supported} { - return -1 + return } clean_restart gdb_load $binfile diff --git a/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp b/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp index 217f240f437d..436076f10038 100644 --- a/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp +++ b/gdb/testsuite/gdb.arch/vsx-vsr-float28.exp @@ -31,12 +31,12 @@ if {[test_compiler_info gcc*]} { warning "unknown compiler" return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $compile_flags] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} From patchwork Wed Apr 29 23:03:58 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134201 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id A5A724BB3BEA for ; Wed, 29 Apr 2026 23:06:28 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A5A724BB3BEA Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=T8CvnfTC X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x933.google.com (mail-ua1-x933.google.com [IPv6:2607:f8b0:4864:20::933]) by sourceware.org (Postfix) with ESMTPS id 1030F4358A68 for ; Wed, 29 Apr 2026 23:05:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1030F4358A68 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1030F4358A68 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::933 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503900; cv=none; b=xYwebbx0mSr3p7qgyNfgUzwdHzqS9jQYAaeK1UaLG8eVMmQv+eeRxB78QwjPonUhFHYTLtzRmXakQXxFeGLx0d79yPsS1mXxhaK/8YXE6mLQhizcePdV3weIi6WiQCxQZDeCZIuT5SJEz0a7//KZMj3JJzDDM5k/eskaTqzyyyk= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503900; c=relaxed/simple; bh=dJsn5TiNU+oOWltZFJdD676JrJeLmml8G40mdOcTgxM=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=CbnSi3+hXfzAL8HS4M/EUVvVL8HWjVQgsWt5pbPcu9ai6aKiR8sRx9Sxprl7X4OiP4BmsPKTYCQCSqfdKBFOrhBFgi5S8Il7FQF20oGo1jD3SC1n+8EaXF5/JjNImUiwsnyrUMFb35I0g7ckDW4krgGvbKKVW7JtmmeEw1WGPxs= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1030F4358A68 Received: by mail-ua1-x933.google.com with SMTP id a1e0cc1a2514c-944168e8c5fso199797241.2 for ; Wed, 29 Apr 2026 16:05:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503899; x=1778108699; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=B8WzwU8gtg4koLKSDqZQrm0YKHPYUZ1X/pEG8ZwgLeg=; b=T8CvnfTCXEbAGMYtVFeIFtGRiMxD1GepU1ai3RdFMCdnH6ZfcvsbrOleNcEXA/bhnG ImwcAB+0JYP/rz02fXltBa54YRSZhyN2okS5uv8pOaMVB3OicaQgqqtgf29A785/+wRd NznDcfMZ/jdAZ0e6heezEa/zT3NwfXpiCbOSAKGTOMLpzYnZhvKUrQ08H1No8QvE9258 xOV0MpbXvi2fSVxzuNseHz94VMk/Lh/U8Lh00ChZCkuMihDJbOElQ2UKcJNbmesXnglY NFs4dbwPNjjymysD1akv1CgKYT7cbR9B6xqJ90nBGJVEaBauqNWzV7YV0C44P8p4XzL6 0rGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503899; x=1778108699; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=B8WzwU8gtg4koLKSDqZQrm0YKHPYUZ1X/pEG8ZwgLeg=; b=RCjN0c3tKRKASS6jt4c7Lb+Hc7cHMr1tUwc4yzkAfkjL6ZhhI+DSUXyyVwsujjkIip 9KpAl/Do5znuqAviGJriCOizOZphXcvZ7SK54rJIF/MVG0vIVFVuP5iEXHRHtZYua9ip zwOgC9U1XoS7zUB43SgioA0jDu8/jFGlsHLoAjW3/Ou+a+lgPLQ2n5iDg8bUbspW37jN sJ+V6BlDDK8r3BHnBK2pzjHT7YfVGal1Hz4wU/I2e/btolG7C2nmDSI1KWp+5qNnVLwr O2F+O10ap13Sjnu3Fypp5PfEt1Y2TcFGr+QbTeMN5L9zll5emk6xdRxKxlZgvWfJIAx2 +s9A== X-Gm-Message-State: AOJu0Yxm65PbZlYHXkuJfJIB33YlwshQoPbyYfSCLtEr9pyknuYmHn56 30Sw6zj7I/jWmxJw6omlSJnHL7wE4BSFnWT1/Ck5e4MOvLZcolP6gcRoIDVYgNqz+zcbKnYbfLN sUjHE X-Gm-Gg: AeBDies7sTjMmnX1ax7ciiJbaPDR9P4b914H9I0+Exhh+CdyMJPeXV4/tvMQlvbhHV9 qCgCHGkuW7ORGnGxXkBQkWo5/rg3PwBfHefAjwdJwRP+pxxQ58/Rf0viWR6DUXkTdNLm3Dou28/ i84ytC2+/EU1SZd66jt6azBy1QOEIzqh3jTtW0Rr0rQ6XxPpJ1gO24EWrwc0gvfuY+3TG2ZY5I+ kwlPI+1FkQk1/CyOz1qSxYlxAXdRjQEg3i3C7+a+wLHjnkux/BIzlV37qnmpGYw9NuwIAsu/m/P II4qeBpvSY0lXK39FJTm9E6oX3pDe61RThDwQko9a9rS8kzXs9SZ0/zTaEBeFMw9WG+PotSRzna EOyr8Mbqqb3XiDymyvLOInqWLEemyesygHYvQczooMLqmDluNRrzrfvgGvzp8PQbmhm5SeCGpLk riizIHPNC30SIMQFC2Ee6UhwzgxmHYy8MNTZlzr2CbWDLJDPblv7b7nuY= X-Received: by 2002:a05:6102:a4a:b0:60c:3f9d:6a0b with SMTP id ada2fe7eead31-62ad21380b4mr314169137.1.1777503899473; Wed, 29 Apr 2026 16:04:59 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb77bfca0sm1766523241.11.2026.04.29.16.04.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:04:59 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 07/37] GDB: testsuite: riscv: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:03:58 -0300 Message-ID: <20260429230432.60487-8-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' riscv*.exp* and $ sed -i 's/^ return 0/ return/' riscv*.exp* inside gdb/testsuite/gdb.arch. --- gdb/testsuite/gdb.arch/riscv-bp-infcall.exp | 2 +- gdb/testsuite/gdb.arch/riscv-info-fcsr.exp | 2 +- gdb/testsuite/gdb.arch/riscv-reg-aliases.exp | 2 +- gdb/testsuite/gdb.arch/riscv-tdesc-regs.exp | 8 ++++---- .../gdb.arch/riscv64-unwind-prologue-with-c_li.exp | 4 ++-- .../gdb.arch/riscv64-unwind-prologue-with-ld-lw.exp | 4 ++-- .../gdb.arch/riscv64-unwind-prologue-with-mv.exp | 4 ++-- 7 files changed, 13 insertions(+), 13 deletions(-) diff --git a/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp b/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp index adb937e9fea4..7d5e27debda6 100644 --- a/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp +++ b/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp @@ -19,11 +19,11 @@ require {istarget "riscv*-*-*"} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp b/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp index 5d252beca305..930f1b24c4e7 100644 --- a/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp +++ b/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp @@ -19,11 +19,11 @@ require {istarget "riscv*-*-*"} allow_float_test standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp b/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp index eb1caf879224..998f4f485d37 100644 --- a/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp +++ b/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp @@ -16,11 +16,11 @@ require {istarget "riscv*-*-*"} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.arch/riscv-tdesc-regs.exp b/gdb/testsuite/gdb.arch/riscv-tdesc-regs.exp index 707777cb0df1..10415fccd040 100644 --- a/gdb/testsuite/gdb.arch/riscv-tdesc-regs.exp +++ b/gdb/testsuite/gdb.arch/riscv-tdesc-regs.exp @@ -22,15 +22,15 @@ require {istarget "riscv*-*-*"} standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug quiet}] } { unsupported "failed to compile" - return -1 + return } if { ![runto_main] } { - return -1 + return } # First, figure out if we are 32-bit or 64-bit. set xlen [get_valueof "/d" "sizeof (\$a0)" 0] set flen [get_valueof "/d" "sizeof (\$fa0)" 0] @@ -38,20 +38,20 @@ set flen [get_valueof "/d" "sizeof (\$fa0)" 0] gdb_assert { $xlen != 0 && $flen != 0 } "read xlen and flen" # We only handle 32-bit or 64-bit x-registers. if { $xlen != 4 && $xlen != 8 } { unsupported "unknown x-register size" - return -1 + return } # If FLEN is 1 then the target doesn't have floating point support # (the register $fa0 was not recognised). Otherwise, we can only # proceed if FLEN equals XLEN, otherwise we'd need more test XML # files. if { $flen != 1 && $flen != $xlen } { unsupport "unknown xlen/flen combination" - return -1 + return } if { $xlen == 4 } { set xml_tdesc "riscv-tdesc-regs-32.xml" } else { diff --git a/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-c_li.exp b/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-c_li.exp index c175f0934b3c..495a720ba7c8 100644 --- a/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-c_li.exp +++ b/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-c_li.exp @@ -21,15 +21,15 @@ require {istarget "riscv64-*-*"} standard_testfile .c -foo.s if {[prepare_for_testing "failed to prepare" $testfile \ "$srcfile $srcfile2" nodebug]} { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_breakpoint "bar" gdb_continue_to_breakpoint "bar" gdb_test "bt" \ diff --git a/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-ld-lw.exp b/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-ld-lw.exp index dff317bd6155..b665dd4f4047 100644 --- a/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-ld-lw.exp +++ b/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-ld-lw.exp @@ -20,15 +20,15 @@ require {istarget "riscv64-*-*"} standard_testfile riscv64-unwind-prologue-with-ld-lw.c \ riscv64-unwind-prologue-with-ld-lw-foo.s if {[prepare_for_testing "failed to prepare" $testfile \ "$srcfile $srcfile2" nodebug]} { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_breakpoint "bar" gdb_continue_to_breakpoint "bar" gdb_test "bt" \ diff --git a/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-mv.exp b/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-mv.exp index 2afe1723a6e2..e0f66ac7f9e1 100644 --- a/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-mv.exp +++ b/gdb/testsuite/gdb.arch/riscv64-unwind-prologue-with-mv.exp @@ -19,16 +19,16 @@ require {istarget "riscv64-*-*"} standard_testfile .c .s if {[prepare_for_testing "failed to prepare" $testfile \ "$srcfile $srcfile2" nodebug]} { - return -1 + return } if {![runto_main]} { fail "can't run to main" - return 0 + return } gdb_breakpoint "bar" gdb_continue_to_breakpoint "bar" gdb_test "bt" \ From patchwork Wed Apr 29 23:03:59 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134209 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 4A2BE4358A40 for ; Wed, 29 Apr 2026 23:07:46 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4A2BE4358A40 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=g77V9xZP X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa35.google.com (mail-vk1-xa35.google.com [IPv6:2607:f8b0:4864:20::a35]) by sourceware.org (Postfix) with ESMTPS id 10A6A4358A4F for ; Wed, 29 Apr 2026 23:05:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 10A6A4358A4F Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 10A6A4358A4F Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a35 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503903; cv=none; b=yEemnAWUtifca74JZAFeo39pMsmZBrX8yy80coMzECt29kZSbNLgt0VKyqNavIarqZGJX+KFYpUj0PVSfoFYp5vPITNuk6IZ7U7OcTAaly5ecVgg0MXv/zq2Ip/k9/IcBl9eToxX7dXe4gs9pnzhWbaHmSbVDWDoCdgjPXWB+VM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503903; c=relaxed/simple; bh=JPkZZxQJtAFmxo1BKQHEyHgLG+OF4w7fIj5cVmxahEc=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=vWBEUAnVEhs6Z3O5ZDV8OPDjOYdLzQeWxdIgQSc+AGeSPhLJsT77xv7szt0EAwDTHDLaAyzEx9HkBcQkPn6jOrddrDTDuLTJSwh8Cs8lIw6AKg00/iZpWJTXgzZsZwrQRWiC/cUumwfe5pIlWnxObFQT59dXgvE2TLsw8m6vjAU= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 10A6A4358A4F Received: by mail-vk1-xa35.google.com with SMTP id 71dfb90a1353d-5637886c92aso155086e0c.0 for ; Wed, 29 Apr 2026 16:05:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503902; x=1778108702; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=LGhNrhgRvJkNkhEJA8oI5uxys7ccpjK/9JsNepdEaAo=; b=g77V9xZPYXNmlD4GD9yH9vAEWUFfzMHDVxvtqKJTmv2l9rx0m+I7xqu/Qk5bHG+06P sMW6F2mxgvO5lA+VqpkZUkdovmb9K6ogOv42aEDmD/TL22StOmyNBZGM/zswwlkSMBTS DqDBLhGJAEEUob/jLDlNNlgauo3glD+MTlfMvoRp4Chi4nePQ9462LfyQVmZ9A1cvsac aqGazCOEWXeEpNvgwAZB3RHOUgfY/lBTC4emGNi5e+YVFo84EKmspUv9OmP41qxUQc/s dDXFJTV3Wnpco+A5jvznzahL9+VLiDdtvlPnwDtGK+yUAAc1/DlIlxO5aUMmMcLpYWbR 5OVg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503902; x=1778108702; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=LGhNrhgRvJkNkhEJA8oI5uxys7ccpjK/9JsNepdEaAo=; b=V0IhwgYHH77S+1X1B9R3RlbOSlC9vNNN73/qYUNtdQRuap1f4tmuYrYpZO/APjTVje rSm+vNoNvRRoOThK9e6qCdf69PdHIp824vWutgohFQZvvLQPQ7l7vCzZUaPJzWASjqj6 NqKWjDDiDiidApHnAumpSBwVIyA1Rz4T/ZCZ8cVFU+KkT7LDxDkV/JAhey5enjad0vq9 +rK9xTsMXgbtNpjTgL0EuIC71zFxkIU7/VxVSs2i1rPZ7swIiMDkJ1p7Bg8J3hP8N+ii L5mGazhoyo1T4AlJ7IN2Ueqm20W1AzCdJUOinM3twbCdH6qVOwzSFggww4GraDCz+4WZ 5lUg== X-Gm-Message-State: AOJu0Yy4ZfElL8qkTDBeAP3wYgvfaUMPPZa7Drukoqq4wBC6g41PLpPc NNxmbQOe+14IU6fxWPUCKmzyXxhn6A4He6Vbs6TQ46fYMRXUwwKIuGJ63y4o7FKLdZd5TS5eD5N tMy0O X-Gm-Gg: AeBDievpnbMYUNLBah6zkSiVaTHZ/7skso7CtoKUmo5el6aWZdOTQL9UhAeGpzNx76O kv89V5hmAYDxzWEAYawmqX7pgcj7+CxmhMVkCaMWncblDSKcRiyzC+Qd67TBMWgbPmi8gwsavHW JqkoN2UMYnKDQcB5+VjvJvvNlAZeuPa/8/P7QUi+7yK9ci3qtHh7xccpoNhRKpIr1OQ0IPX0YMj gb1dk3eh+RyDWttdpyA4bP0CeCeDk6RMJtVb2k50gKB1chiWCqVvG7EKI+lTdSHSkKVM0SAVN4m 0LGIKyvKCZK+a0eARhzh177JZ58h4xgyGMyCuT7hD8U0XRYqOwhEnfh/ZPwy3y1qobDk2Y59FCS JPvzwa5pb6UhLiy3bxolPMZzyZnMIn+zba0WakOxcWFOv//td/hDRAKqaAeGjTKtmTYzCKnE4r1 aU6buK6vv07vrmUqfC09O/FZU9mnNGy466IxoRzW17rYZc X-Received: by 2002:a05:6102:3a06:b0:609:26c7:e4cc with SMTP id ada2fe7eead31-62ad2342254mr278801137.12.1777503902382; Wed, 29 Apr 2026 16:05:02 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb77bfca0sm1766593241.11.2026.04.29.16.05.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:02 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 08/37] GDB: testsuite: riscv: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:03:59 -0300 Message-ID: <20260429230432.60487-9-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes the "return -1" and "return 0" statements that weren't caught by the sed command. This happened only in one testcase due to the statements being inside a foreach_with_prefix block, and in the others because the return statement was in a misaligned line, which is now fixed. --- gdb/testsuite/gdb.arch/riscv-bp-infcall.exp | 2 +- gdb/testsuite/gdb.arch/riscv-info-fcsr.exp | 2 +- gdb/testsuite/gdb.arch/riscv-reg-aliases.exp | 2 +- gdb/testsuite/gdb.arch/riscv-unwind-long-insn.exp | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp b/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp index 7d5e27debda6..9e67e303dacb 100644 --- a/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp +++ b/gdb/testsuite/gdb.arch/riscv-bp-infcall.exp @@ -23,11 +23,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # Figure out where the breakpoint will be placed taking account for # stack alignment, and allocation of the dummy code area. set bp_addr [get_valueof "/x" "\$sp" 0] diff --git a/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp b/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp index 930f1b24c4e7..df9aa97025b7 100644 --- a/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp +++ b/gdb/testsuite/gdb.arch/riscv-info-fcsr.exp @@ -23,11 +23,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # Merge FFLAGS_VALUE and FRM_VALUE into a single hexadecimal value # that can be written to the fcsr register. The two arguments should # be the value of each of the two fields within the fcsr register. diff --git a/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp b/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp index 998f4f485d37..d1d98327403a 100644 --- a/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp +++ b/gdb/testsuite/gdb.arch/riscv-reg-aliases.exp @@ -20,11 +20,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # A list for all the integer register names and their aliases. The format is # a list with each entry being itself a list, the first item being the primary diff --git a/gdb/testsuite/gdb.arch/riscv-unwind-long-insn.exp b/gdb/testsuite/gdb.arch/riscv-unwind-long-insn.exp index 7be5316bcfb0..b49d466b15f2 100644 --- a/gdb/testsuite/gdb.arch/riscv-unwind-long-insn.exp +++ b/gdb/testsuite/gdb.arch/riscv-unwind-long-insn.exp @@ -31,15 +31,15 @@ foreach_with_prefix {insn_size} {6 8} { set flags [list debug additional_flags=-DBAD_INSN_LEN=${insn_size}] set testfile "${testfile}-${insn_size}" if {[prepare_for_testing "failed to prepare" $testfile \ "$srcfile $srcfile2" $flags]} { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_breakpoint "bar" gdb_continue_to_breakpoint "bar" From patchwork Wed Apr 29 23:04:00 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134197 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 4AE854358A66 for ; Wed, 29 Apr 2026 23:05:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4AE854358A66 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=fpDa2pN1 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x934.google.com (mail-ua1-x934.google.com [IPv6:2607:f8b0:4864:20::934]) by sourceware.org (Postfix) with ESMTPS id A17C44BB3BD2 for ; Wed, 29 Apr 2026 23:05:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A17C44BB3BD2 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org A17C44BB3BD2 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::934 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503906; cv=none; b=d9yvu3Q+ZWZawwZxAN2ApRhBWqGFRR4HnEEiJspnlHQwSMQJCtftIZl54cBOea7arso5YeQBj0GsroIXWjHu6EXeR1WXz0+nJi37AF5b9MZTDPC77lYbu+6OF2GCyhi/6PpllZ9s7uAX2O2FbsuPtQihMfOalIV4hbBPTSFgJgE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503906; c=relaxed/simple; bh=zjvFrUKBO4kM/a29gD6yj8RBlABhmGwIWG0aA8rMjtk=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=pVXY1AqAO1gvQdAlWlJJpoBmW2T/p4zRLqyTwDX5/UXPJ9UMLV2xJk7kPaVjyAgIw9dXnM7PKzksBMubQ4u78IQgw71XRDylZ6VlqCEuc/wm+bZHVvOBihOtvhZ2zvu2O3OfyL0QDfDC88ehb2Zwa75vbm1EPUPcAoFHlWE74lc= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A17C44BB3BD2 Received: by mail-ua1-x934.google.com with SMTP id a1e0cc1a2514c-9568159ee07so182362241.1 for ; Wed, 29 Apr 2026 16:05:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503906; x=1778108706; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=CsU0LQin+LfbYXRIeWWU3SgienS7tnBPt1+2bWCMU3s=; b=fpDa2pN1sNIYbEVw71bNKChp4KzOnm2E0Dlt/IwV76sie8l24uCPibehGxOquifqRI 8NQ24m1plGPEkdG6BKoFNIzya4MpC1SHIVNdtfra//yjF6FawRAkC8sG6bKAZpmqKFd4 +dpAf0hyVmOckYB2Bdqodzi6oSMz3Hpv2tMqzfYKDNyPJOMkebEIGSf6EsOXwC5yU2z2 mtDJ26XY0MyjiUL7oD/k8yzI6pHLnA+xyVCJynVhgZ2Nac1Kxc5wVb3WbA5tYyTptvpa 4TkcDic31GY8EcW2Pas/wBszVbSX9e2YWepdt1gBvnGKivIIXqUBUHfHhrC4aDitmVR9 LAaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503906; x=1778108706; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=CsU0LQin+LfbYXRIeWWU3SgienS7tnBPt1+2bWCMU3s=; b=CFBg/1Yy/nGonQaSu3Oipl/8WzeC+adDMvlQB2m+2AkRLIuYy44vuBjQ/6zpu8vcC8 c35HCLhFL3VcVeqiDVEyveS1JYzvTu096K1YuQPrqOBjORY+qYwp27fF2jHyWhxNyo7Y 3DFW8JOWLF2ydhdcS0tpZgxQR6svTXxLVxNCvTOZYXp9413ljnKNAd7+0ukiIGwazWZj WFa9u38stq28yMEFzCtdXtJxMFrwdnca2UEmVxDpTem3Ep9QIzNQNmB6vPWXt4VUwRbZ oLIetWkQpXnhCVVbQD9D5ZneY/4rULzLYhns6cia1BmAotGNNjRB+BwnjQdo0GmtSGJA G0YQ== X-Gm-Message-State: AOJu0YwRahw3XTDgW1wtWdrHGoSSa9wVSCnHRwh5r/S3KSiNhmc4OcpI IvegDednwnKwPiaEd7mBv8K+XiLiuIzbvsvrmjuF03yke9Npg5GM6McSXAGdusfD8Xj+BClnw3E PT9Od X-Gm-Gg: AeBDieu3DO2dEWRBrqwFJied8W/PXNnM/agCjBRQiW1OdqtXXZHiWzwxGIb61leboRn 6oWa6OPuLeNSXc0JniMBk3JHYGyGJwFTAJSCn/AduN7zB+shwWjhSyH346cmEW71JbSbbzAeXz/ DsJgbQIjW6KLLw0ujktdpP9GKJpIecMhngeStXRB+USZz/84Fx7FWcUy0hacqqjlZXQq1+NYhtx r+sWoIdajX+mo3adRPAtr4OehVHG5FiXzH45I7GoeWgMBJtgfwuU9SUOVJejK2pCVDXlLH442L7 IWgTHBVyI590RcoX3Ywjogsb2YaXZs3rmw27SmV9uRThANDGMQcA14A1PmFlIf5xeXlIye4ty+u h1iB75g4TIFgbiIK+Nd8upsOUGsrYmtkCTNgVqnVG2PGxPsVkpCLzvJqb5fpLI91LLO2lqrbozX HCY0kGf/uVI4bKyfzKwE/M1PtNymzDhdiATpohYbxn49zGIL6MA6l50Rc= X-Received: by 2002:a05:6102:3310:b0:628:6648:faa7 with SMTP id ada2fe7eead31-62ad498b9f7mr300080137.20.1777503905959; Wed, 29 Apr 2026 16:05:05 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-6298433531bsm1930643137.9.2026.04.29.16.05.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:05 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 09/37] GDB: testsuite: s390: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:04:00 -0300 Message-ID: <20260429230432.60487-10-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' s390*.exp* and $ sed -i 's/^ return 0/ return/' s390*.exp* inside gdb/testsuite/gdb.arch. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.arch/s390-stackless.exp | 2 +- gdb/testsuite/gdb.arch/s390-tdbregs.exp | 4 ++-- gdb/testsuite/gdb.arch/s390-vregs.exp | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/gdb.arch/s390-stackless.exp b/gdb/testsuite/gdb.arch/s390-stackless.exp index ba7e70faf95d..567f37c41abd 100644 --- a/gdb/testsuite/gdb.arch/s390-stackless.exp +++ b/gdb/testsuite/gdb.arch/s390-stackless.exp @@ -16,11 +16,11 @@ require {istarget "s390*-*-*"} standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Run until SIGSEGV. gdb_run_cmd diff --git a/gdb/testsuite/gdb.arch/s390-tdbregs.exp b/gdb/testsuite/gdb.arch/s390-tdbregs.exp index e0b9284874f4..d9bccb8009b5 100644 --- a/gdb/testsuite/gdb.arch/s390-tdbregs.exp +++ b/gdb/testsuite/gdb.arch/s390-tdbregs.exp @@ -26,15 +26,15 @@ standard_testfile .c # the transaction. Thus tell the compiler to use soft float, so it # doesn't emit them. Some GCC versions may otherwise do so, and an # endless loop would result. if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list "debug" "additional_flags=-msoft-float"]] } { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_test_multiple "next" "check for TE support" { -re "Program received signal SIGILL,.*\r\n$gdb_prompt $" { unsupported "no TE support." diff --git a/gdb/testsuite/gdb.arch/s390-vregs.exp b/gdb/testsuite/gdb.arch/s390-vregs.exp index 99dd3b219750..33da5f340f97 100644 --- a/gdb/testsuite/gdb.arch/s390-vregs.exp +++ b/gdb/testsuite/gdb.arch/s390-vregs.exp @@ -26,15 +26,15 @@ if {[isnative]} { remote_exec build "mkdir $coredir" } if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list "additional_flags=-mzarch"]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Run to the first vector instruction and step it. If the inferior # doesn't crash, we have vector support. @@ -183,11 +183,11 @@ gdb_exit set cores [glob -nocomplain -directory $coredir *core*] if {[llength $cores] != 1} { untested "core file not found" remote_exec build "rm -rf $coredir" - return -1 + return } set destcore [standard_output_file ${testfile}.core] remote_exec build "mv [file join $coredir [lindex $cores 0]] $destcore" remote_exec build "rm -rf $coredir" From patchwork Wed Apr 29 23:04:01 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134206 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 4FA004358A47 for ; Wed, 29 Apr 2026 23:07:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4FA004358A47 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=gaMn8pQd X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vs1-xe2a.google.com (mail-vs1-xe2a.google.com [IPv6:2607:f8b0:4864:20::e2a]) by sourceware.org (Postfix) with ESMTPS id 116704358A69 for ; Wed, 29 Apr 2026 23:05:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 116704358A69 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 116704358A69 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::e2a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503910; cv=none; b=b4kOiQmbs5yUSqM9F/GZUdJKYnn8yu50r0WE85hPegE09K01w3s7h3q8FBgAzVGYSe4LWCUr152KqxuZEzuRbmheMahnEaE4sRmgFU4Q3WncPhNipxdjMma69M39L/iIg7mTvzIbwAKiHAMkHy0SR3JT5qi0r1MgVXX8nGdNsCI= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503910; c=relaxed/simple; bh=wEyUwVFrvg79E/jHQCSgSGuV4d1uQiTeWi4v6CRMXvQ=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=cxgHuHtsJgfUQCyy1JHZF0CpYs1iV17wTsLUL21fg9uyMizEeS6kvOlocLkwMqbXimwvpOgGWkoqfa03QGYYbzLQGpEcuif/HJD5t2gJRXRiWiRCsCv8RdzlrprICdJy5O0gbAcBJsqBNx+bRdBE5uXbNbUbrWoe4dQQcj2MCkc= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 116704358A69 Received: by mail-vs1-xe2a.google.com with SMTP id ada2fe7eead31-6058ac0ebceso190221137.2 for ; Wed, 29 Apr 2026 16:05:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503909; x=1778108709; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=clh9nSSV67SGYKbsIHX7nc8GdmoV1zXoXkGZCySixPQ=; b=gaMn8pQdSfCYou31fW+KYuLen6FnE4K071PSZlZdIKchM3aM3ojpnWvpgU9PKZUvLt NaW4AbXrO4Hz3eEQwqDxGWm39g2/6om5S3Yak+J4RGp5Aqo3hCXZcMOne/LPqxtEGEar X8BrobWGl5FcAuWlbdKQ4P6ASMVw7p7nRF/V75NyjO/BPacj6YLnOm4a2zQzEWghS8v5 gO9NK4kAfQZvu9l7b7fsPpBuK3hMH5FY6wslwglQ5z6eoBT/3nO2kC/2RheXSJuaT8ZX uLU45pKIgnTDHXWZtmyH2rRyDlUqbHcRMdIhZ1LbqKna99NAapQ7MHv+Y9hvC7XDdXue uhOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503909; x=1778108709; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=clh9nSSV67SGYKbsIHX7nc8GdmoV1zXoXkGZCySixPQ=; b=W8sZj9X3hfyF2LMLwOjDtjSn8IShf3SDq24BYwvOYhzqewHYLxqephcCeHkOQK0AY+ awNU0sTbiUOojim/Ry5MuO1RvQzvryV43cKbNCuaM3H4HC89DmjefdRYRC3nNfAoVWBo 76okqt1n1PIegqivgQJWYb1epZStv9FqDS6QO0lZe1oq4o4q0HpimTCNfRARwX+Dj5n3 wbKmMaxiE8hYgSXBjymJC4kSJcl0gaITNpTxU906QEADUFcca7+i3C5jDSc71FuQbcmK ZOGpDdgckxcD5Y/lM8JjVcXZduDU3Pbx1sP4CulM5arpokvebzsbsJBLm5cbnc9th0cs BRQA== X-Gm-Message-State: AOJu0YxgAwG07Hk/3E8qi3IS+ghQIIRiKLLNZJMZbsua1ae+gPT14rIj 554XsQRgQb0tfPIcmXte7Yh4NRXSGMiA5Pd95Pm4M6q5h80l203SKnMfMPPTRqGMidkVuwYQC93 KcLkZ X-Gm-Gg: AeBDietArJgxR5iUZ2IEav+k6BSbM+NlVZsbNFV/EwMPkVVUHQ44Nd7KYEabCfmxMgi UvfnVA8outu3adu1AqN8gXNypppU5BWN9L+GZNbCOxILFME64n/aty6rS7eqBbCpqwvc3azqGKS MBdjoBP6u1mDYfD2B5wxhIU92pkyHVOcrZHhW7EA11F3tCJ7A7HI849qVPMW9hLOWEpE211GpMO 25ksTf+xM4Kwsx+JrkxAOWwiaaOHgAWctMV2Q1ZQYYMVLfjrsUvmVsRXAP0fJTqpQAyUoJ70bDz wgK2SjBVCAMQML0CHJI/pF+fdrDSZMpD32N9x8dOmc6lZysLJVvnrqt2xqQdgeJlB9xDr+NZREx D+rPnXsDkrpagIswqtBRk7YZrugJgoIBlzO2KoKDlQc4hSt/x9QRlVU530q9ITIUu2HiYmOD+42 rkWAjrM3n8eYVbPzmcGxpJcinFpLceLN7QjfnY3ghkYqDq X-Received: by 2002:a05:6102:3312:b0:5f7:2568:abb2 with SMTP id ada2fe7eead31-62ad1e3e071mr309831137.6.1777503909450; Wed, 29 Apr 2026 16:05:09 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-629847677b0sm1972474137.10.2026.04.29.16.05.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:09 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 10/37] GDB: testsuite: sparc: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:04:01 -0300 Message-ID: <20260429230432.60487-11-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' sparc*.exp* and $ sed -i 's/^ return 0/ return/' sparc*.exp* inside gdb/testsuite/gdb.arch. --- gdb/testsuite/gdb.arch/sparc-sysstep.exp | 4 ++-- gdb/testsuite/gdb.arch/sparc64-adi.exp | 4 ++-- gdb/testsuite/gdb.arch/sparc64-regs.exp | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/gdb.arch/sparc-sysstep.exp b/gdb/testsuite/gdb.arch/sparc-sysstep.exp index 2ae7719ae39d..9a8c292611af 100644 --- a/gdb/testsuite/gdb.arch/sparc-sysstep.exp +++ b/gdb/testsuite/gdb.arch/sparc-sysstep.exp @@ -27,15 +27,15 @@ set testfile sparc-sysstep set srcfile ${testfile}.c set binfile ${objdir}/${subdir}/${testfile} set opts {} if {[prepare_for_testing "failed to prepare" $testfile $srcfile {additional_flags=-g}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Watching the global variable will guarantee that gdb will # single-step through the whole program. diff --git a/gdb/testsuite/gdb.arch/sparc64-adi.exp b/gdb/testsuite/gdb.arch/sparc64-adi.exp index 3024527d48d9..9fc7084e4a12 100644 --- a/gdb/testsuite/gdb.arch/sparc64-adi.exp +++ b/gdb/testsuite/gdb.arch/sparc64-adi.exp @@ -22,15 +22,15 @@ require {istarget "sparc64*-*-linux*"} standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug libs=-ladi]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break [gdb_get_line_number "line breakpoint here"]" \ "Breakpoint .* at .*${srcfile}.*" \ "set line breakpoint in main" diff --git a/gdb/testsuite/gdb.arch/sparc64-regs.exp b/gdb/testsuite/gdb.arch/sparc64-regs.exp index 28948aec966c..427c7d93493f 100644 --- a/gdb/testsuite/gdb.arch/sparc64-regs.exp +++ b/gdb/testsuite/gdb.arch/sparc64-regs.exp @@ -21,15 +21,15 @@ require {istarget "sparc64*-*-linux*"} standard_testfile .S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return 0 + return } ########################################## gdb_test "break $srcfile:test_ccr" "Breakpoint \[0-9\] at .*" gdb_test "continue" "Continuing.*" From patchwork Wed Apr 29 23:04:02 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134199 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 4A4194B920D5 for ; Wed, 29 Apr 2026 23:06:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4A4194B920D5 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=O00hrFIM X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vs1-xe29.google.com (mail-vs1-xe29.google.com [IPv6:2607:f8b0:4864:20::e29]) by sourceware.org (Postfix) with ESMTPS id 7E7EC4358A66 for ; Wed, 29 Apr 2026 23:05:13 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7E7EC4358A66 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 7E7EC4358A66 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::e29 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503913; cv=none; b=Mpr7NXJUtkwmKUzJ4+8NKYtxTIrd7dgch13h9/U6FDp+hvZ4sU9A1gDMmEy4aLjoKYgLk3eA/yW5eA7fIqMEvo56UqzIlBL3iI0nBEl8Zz2OI1js3VRPthcvShXIf66fn++hjfJj+vRiHQQ/J1+FM3TFC2vyQsUUlOVPIq3aBNM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503913; c=relaxed/simple; bh=2/33fmdHq/LyFU7QZRpIq3HBdDuT9YeMlQlW4GYtZkw=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=iBNLfzd8aQdBBWnSB9ce5sakivssvPn4NuxaFh1Kd0xQl5t8Kcb5vfjkrcfM2WSvlf0XTb7ZDq7stu5jLeLHqBjJmZBBL6ss/OJYrjM6soOAryq1pclq8mfNUmfRnGSj+rdxLWOeQdV+j4y0SxFqqZetjjFvFXfsZmq6OVM8+TM= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7E7EC4358A66 Received: by mail-vs1-xe29.google.com with SMTP id ada2fe7eead31-6201fc9ac0eso111433137.0 for ; Wed, 29 Apr 2026 16:05:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503913; x=1778108713; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Hi/hkKrCEXrIeTd/C2k2JXJsD4G+TxWpG+We4XAIuHo=; b=O00hrFIMvAIhRQdaISfqvrinSKY41bY77r79DmtBEdA0IdUS5cDeBr34vWcO0bgIas /QFtc+xKgSWJ+423cDW8CIo06lMTf+BErbSUwMXtcZshK3lTIx9bXt4D/U0H1gR2vD9V pEY4IGm5jYwk5FBp4DEc2tGUUqXm/uF9bvF/lIE9zNbUKxNoTnzo59IB7dAvF3CcChWU hs/LdPnqZd1TJenq5ASbcF/Vo0s/zyGMkxv6t9W2PF13X3WpXRj99pSl7byoCzi95/ZQ fsi764ZFLmU2EOcnICVo9F3WAymkwatEo69i6dABxkcyHS1YGnP3nFHOSs8so+jAEqLE zpqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503913; x=1778108713; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=Hi/hkKrCEXrIeTd/C2k2JXJsD4G+TxWpG+We4XAIuHo=; b=iVaUMwyuJljAKyUpYDC3lf9a/NRxx9vbsGmC4YfDrVL1wC74iyBxKbMTwLTHfs7ks9 8/6HH+u+/P+5KtpzeCjlAvkXXHQ20GOFwtOuQlhvEm5CH5PJE71ZMAOuD1unr1zhJW4m sroFc1x3IIuLkFIMO9l1is1Y0ATQC7NAsza+qlkpB3zkWZGNwuvZVlbRLBzF57wkE0CF WZKI3iXg+y6jSNY1slNAIz7VBdVp9VyYl5oL51g1fnQCZt8S7YurCCmiuaC9vM2g6zto AnK3YFJPy4KX8IpS+hrSViaAkHrOvothb0hBpr9a2t6hE5hJDSu/23FA6QwAbaWmh8kK G+kQ== X-Gm-Message-State: AOJu0YyzX4WshE/wQHNlZTLju25Cd/WqULzofZKGx5e1oaCp6YtCjucB 3Sr0RUCiK7pvyQGCv8DUokzoetuYGc3xKf1THIel5DkDmO5UpuvWQTQctoVXTBhBB4pl1LZnd5v JZ/Iy X-Gm-Gg: AeBDieu81fIWQMo78qAxGqhc+zTdVOlt/dKk6x88i8vRCHRKcYjVfk1M5iwDCIHPHEb LIuD5l9ApbNzHRjsCftsQT8J2VqG4m88Oxfv3MTX9ic0o5DdC/dluYxeHJORWei0+vWvRl9Ip9t exBITqFZTYV0Fe3ugKs7ln6/Mp5ab/oj2rFjHx9HQSx1u0x16OPJ6TRPPbDjGRUq29QZuEyKLSN rUYUY9aPYhYnyO7KKiR4yW1dXwob1ApKLNFVSDmLlXZhi2uNPoGcSmNgMWjPBI2LZN/oGskZ4r6 zFLcYsmgcpv8EH09WvRbDbrKGe2pHf9ohgsOLcE2Hy3Xu4azMCieIsfI0gSWtLWl3S/ZK174ejh SICHyGyiM4RrPbN26pxVNcSnKfjzSL3q2RDTJimXhlkm2GecsdtBbGf9WnNMCgeS+6BdbKRqbm/ XEEaq1sfhZdDpDTTmDwOsmwjUD/Tsm4dYOkbInKNtzrDfd X-Received: by 2002:a05:6102:f9b:b0:608:9a34:c8ea with SMTP id ada2fe7eead31-62ad2344c5amr307441137.10.1777503912833; Wed, 29 Apr 2026 16:05:12 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-62982736ba5sm2025724137.5.2026.04.29.16.05.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:12 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 11/37] GDB: testsuite: Don't return value from top-level in tests of various arches Date: Wed, 29 Apr 2026 20:04:02 -0300 Message-ID: <20260429230432.60487-12-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, PROLO_LEO1, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch contains fixes for alpha, arc, avr, hppa and sh architectures. Some changes are the result of running: $ sed -i 's/^ return -1/ return/' *.exp and $ sed -i 's/^ return 0/ return/' *.exp inside gdb/testsuite/gdb.arch and some are manual changes. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.arch/alpha-step.exp | 2 +- gdb/testsuite/gdb.arch/arc-analyze-prologue.exp | 4 ++-- gdb/testsuite/gdb.arch/arc-dbnz.exp | 4 ++-- gdb/testsuite/gdb.arch/arc-decode-insn.exp | 4 ++-- gdb/testsuite/gdb.arch/avr-flash-qualifier.exp | 10 +++++----- gdb/testsuite/gdb.arch/gdb1291.exp | 4 ++-- gdb/testsuite/gdb.arch/gdb1431.exp | 4 ++-- gdb/testsuite/gdb.arch/gdb1558.exp | 2 +- gdb/testsuite/gdb.arch/pa-nullify.exp | 8 ++++---- 9 files changed, 21 insertions(+), 21 deletions(-) diff --git a/gdb/testsuite/gdb.arch/alpha-step.exp b/gdb/testsuite/gdb.arch/alpha-step.exp index a15f86ea6567..d47b359c08d1 100644 --- a/gdb/testsuite/gdb.arch/alpha-step.exp +++ b/gdb/testsuite/gdb.arch/alpha-step.exp @@ -20,11 +20,11 @@ set testfile "alpha-step" set srcfile ${testfile}.c set binfile ${objdir}/${subdir}/${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {}] != "" } { unsupported "failed to compile" - return -1 + return } clean_restart gdb_load $binfile diff --git a/gdb/testsuite/gdb.arch/arc-analyze-prologue.exp b/gdb/testsuite/gdb.arch/arc-analyze-prologue.exp index 01699016dd67..693e5efe2260 100644 --- a/gdb/testsuite/gdb.arch/arc-analyze-prologue.exp +++ b/gdb/testsuite/gdb.arch/arc-analyze-prologue.exp @@ -24,15 +24,15 @@ standard_testfile .S # debug information (which does not exist for .S code!) instead of analyzing # frames manually. set options {} if { [prepare_for_testing "failed to prepare" $testfile $srcfile $options] } { - return -1 + return } if {![runto_main]} { - return 0 + return } # Convert list of saved registers and their offsets to a GDB string. proc saved_regs_to_str { savedregs funcname } { set str "" diff --git a/gdb/testsuite/gdb.arch/arc-dbnz.exp b/gdb/testsuite/gdb.arch/arc-dbnz.exp index ce93a6202933..2c091e45ecf1 100644 --- a/gdb/testsuite/gdb.arch/arc-dbnz.exp +++ b/gdb/testsuite/gdb.arch/arc-dbnz.exp @@ -32,15 +32,15 @@ require {istarget "arc*-*-*"} standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_test "break dbnz1" \ "Breakpoint $decimal at .*" \ "set breakpoint on the 1st dbnz" diff --git a/gdb/testsuite/gdb.arch/arc-decode-insn.exp b/gdb/testsuite/gdb.arch/arc-decode-insn.exp index 0a7582d03a2a..4247c0215b82 100644 --- a/gdb/testsuite/gdb.arch/arc-decode-insn.exp +++ b/gdb/testsuite/gdb.arch/arc-decode-insn.exp @@ -34,15 +34,15 @@ require {istarget "arc*-*-*"} standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return 0 + return } # Helper function that reads properties of instruction from the ELF file via # its symbols and then confirms that decoder output aligns to the expected # values. diff --git a/gdb/testsuite/gdb.arch/avr-flash-qualifier.exp b/gdb/testsuite/gdb.arch/avr-flash-qualifier.exp index a62e629f9209..e9a523a5d05a 100644 --- a/gdb/testsuite/gdb.arch/avr-flash-qualifier.exp +++ b/gdb/testsuite/gdb.arch/avr-flash-qualifier.exp @@ -20,22 +20,22 @@ require {istarget "avr*"} # The __flash qualifier was added in GCC 4.7. if {[test_compiler_info {gcc-[0-4]-[0-6]}]} { - verbose "Skipping ${gdb_test_file_name}." - return + verbose "Skipping ${gdb_test_file_name}." + return } standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto [gdb_get_line_number "break here."]]} { - untested "could not run to \"break here.\"" - return -1 + untested "could not run to \"break here.\"" + return } gdb_test "print pointer_to_flash" \ " = $hex .*" diff --git a/gdb/testsuite/gdb.arch/gdb1291.exp b/gdb/testsuite/gdb.arch/gdb1291.exp index 82f9d52e08ba..ba4b88d75112 100644 --- a/gdb/testsuite/gdb.arch/gdb1291.exp +++ b/gdb/testsuite/gdb.arch/gdb1291.exp @@ -28,22 +28,22 @@ require {istarget "sh-*-*"} set testfile "gdb1291" set srcfile ${testfile}.s set binfile ${objdir}/${subdir}/${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable ""] != "" } { untested "failed to compile" - return -1 + return } clean_restart gdb_load $binfile # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } gdb_test "b sub1" "Breakpoint 2.*" "set breakpoint" gdb_test "c" "Breakpoint 2.* sub1 .*" "get to sub1" diff --git a/gdb/testsuite/gdb.arch/gdb1431.exp b/gdb/testsuite/gdb.arch/gdb1431.exp index 89952275d193..aedf66183186 100644 --- a/gdb/testsuite/gdb.arch/gdb1431.exp +++ b/gdb/testsuite/gdb.arch/gdb1431.exp @@ -30,22 +30,22 @@ require {istarget "sh-*-*"} set testfile "gdb1431" set srcfile ${testfile}.s set binfile ${objdir}/${subdir}/${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable ""] != "" } { untested "failed to compile" - return -1 + return } clean_restart gdb_load $binfile # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } gdb_test "advance sub1" "hello world\r\n$hex in sub1 \\(\\)" "get to sub1" gdb_test "advance sub2" "$hex in main \\(\\)" "advance returns from sub1 frame" gdb_test "advance sub2" "$hex in sub2 \\(\\)" "get to sub2" diff --git a/gdb/testsuite/gdb.arch/gdb1558.exp b/gdb/testsuite/gdb.arch/gdb1558.exp index 5fbf86f5889a..7a3f44756452 100644 --- a/gdb/testsuite/gdb.arch/gdb1558.exp +++ b/gdb/testsuite/gdb.arch/gdb1558.exp @@ -27,11 +27,11 @@ set testfile "gdb1558" set srcfile ${testfile}.c set binfile ${objdir}/${subdir}/${testfile} # Note we have to compile WITH optimization and WITHOUT debugging information to expose the bug. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {"additional_flags=-O2"}] != "" } { untested "failed to compile" - return -1 + return } clean_restart gdb_load $binfile diff --git a/gdb/testsuite/gdb.arch/pa-nullify.exp b/gdb/testsuite/gdb.arch/pa-nullify.exp index 1606d44afbf1..e527fe0955d8 100644 --- a/gdb/testsuite/gdb.arch/pa-nullify.exp +++ b/gdb/testsuite/gdb.arch/pa-nullify.exp @@ -35,11 +35,11 @@ set srcfile ${testfile}.s set binfile ${objdir}/${subdir}/${testfile} set gcorefile ${objdir}/${subdir}/${testfile}.gcore if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {}] != "" } { unsupported "failed to compile" - return -1 + return } clean_restart gdb_load $binfile @@ -85,11 +85,11 @@ proc get_addr_of_sym { sym } { return $addr } if {![runto_main]} { - return 0 + return } set foo [get_addr_of_sym "foo"] set bar [get_addr_of_sym "bar"] set foo_last "(bar - 4)" @@ -121,21 +121,21 @@ proc test_core_bt { test } { gdb_test "backtrace" ".*in foo.*in main.*" "$test: backtrace in gcore" } set test "core at last insn in foo" if {![runto_main]} { - return 0 + return } gdb_breakpoint "*$foo_last" gdb_test "continue" "Breakpoint \[0-9\]*,.* in foo.*" "$test: continue to breakpoint" if {[gen_core $test]} { test_core_bt $test } set test "core at nullified insn" if {![runto_main]} { - return 0 + return } gdb_breakpoint "*$foo_last" gdb_test "continue" "Breakpoint \[0-9\]*,.* in foo.*" "$test: continue to breakpoint" gdb_test "stepi" ".*in foo.*" "$test: step to nullified instruction" if {[gen_core $test]} { From patchwork Wed Apr 29 23:04:03 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134202 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 323254BAE7CE for ; Wed, 29 Apr 2026 23:06:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 323254BAE7CE Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=sY8dl25l X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa30.google.com (mail-vk1-xa30.google.com [IPv6:2607:f8b0:4864:20::a30]) by sourceware.org (Postfix) with ESMTPS id 9866B4358A5B for ; Wed, 29 Apr 2026 23:05:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 9866B4358A5B Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 9866B4358A5B Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a30 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503917; cv=none; b=VlzQQtekXS5oUmeWrOApiXNgXq92Jsg3SsGh2kRvCtvfcWT5eI1rdelpU/85VXu1ZN5xXDirw/CEclnySsEek2pi0UAiGj2795CFFoL2mCVdTUH10+qG9JWCAsDXN5kChGAXINxrSr83nidQ+SZi0mwOMRWAQCVQldryorWzeIw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503917; c=relaxed/simple; bh=XFY7Bbbucvxagq4gQoQcRe9nCUlvsQYNlmMwzAPBxQc=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=JE9IQxUNsFPfMBB6DVgzMbLpAtm+j7QGyX1iWtu2+wbN5gLSb+e1XMYqSh+J3U/fO9voj6TDSGSYTPZG8yHIn67s8PWGLNARM7vTWGf5nBseQDAsucI8W9JDICGrtS6u8zT8hfHcTaxuI37SVZYqWiivPliIez/E/IfP7QR24v8= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9866B4358A5B Received: by mail-vk1-xa30.google.com with SMTP id 71dfb90a1353d-56f3e6bbecdso115159e0c.2 for ; Wed, 29 Apr 2026 16:05:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503917; x=1778108717; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=pdJUlCur7UqlIrvrFi6XN6hY4duIIahDuy9OP+BaKsY=; b=sY8dl25lLACCHWdGhk9+Wxf9QazOGjmo7mPdDIm7GlyI+VXIh5r+7/qyy1CzLESN7x 18th5R06dYdIX+SB3H0lOIo119T/9wYHCCNpe9WAWi68V/AtD+3Dfdzj6/csklPHpp8a mEiOL/JezH/Eraw1ngjdTuWHRDdmcbZlxcOFinzJ5XY5xPTWpMPsuJw1wOtKFYuwxuRQ GWganthIEpychHPnL6UA3Npbb9xw9pAEJZXrBL8HzKmhe69nUOh2ACOxZD/sXAxUt6Ue TM4oyG1iUpHqeEwRzV3WnNEc965dLAqTYJ06VXRn+x1HeOWJwVpOC5z7/bsMc3g2hRPC //Vg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503917; x=1778108717; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=pdJUlCur7UqlIrvrFi6XN6hY4duIIahDuy9OP+BaKsY=; b=kgpHjbFfQMgioFeSk6uVezaudLkdpEEdaM+np7ev31NOFwJbcWcZrmI7u402vQYEtK ws+a1QEHkM2XQSLLquxfSBm7cFJKERGEVrffu8DRcRkklOOrDISpTS4zo7hdnefXMCe8 TWfVpr5sRq6RLf3vw3ophb1tuYqXgL7e1u1TJ3PcZKn9rvZoel3gO3LCihUIypk8wDvO MD/rqzFICJsix6Jj4LU9GvBHLdw4QNCrQmLoZsriOUkKN12R4+5hkHDeEIa5URU6fNtf agxhETLR00r3lbuvxVjIBRWhmJ+PvtNJzPsfWTanjTnUuc4HN5XcAo/SIzvx4bTDDKO+ e1wQ== X-Gm-Message-State: AOJu0YyqVq5DsYINPrS81egjGiB8/nel7Kdh94rinDZfFGRPUlrNiiAL LWrygeEquJ9wXihQ2TFlZOngGQs8NNs8V26ddwlwHY96uPDJYd1DmmgpLgD8t1XwbrTsNCz0HLj aBbfD X-Gm-Gg: AeBDievUfH9Mppe7w0OXqHFJQVp6fhqG/noj4xjKaxRpo8smQGnQqZSrqJ6+LrGo6sm AAoS8L7ho6/ZjzTCNVRGpNOBPMtD9UvfjVHgtCM/zIWf7GGiNqY6hnSmm5VMKluinSTFEmRjmH9 6XXH6xkl/KpPuv2byc++EZGYUPrJbupUOz7cjpPIOxuCw7EmNt3fwSoS7Cy451De2l4S8o5v/KR BaVI+Q1LVgJ8A+ZPV4GNmVMTlwRa6jui9rzPb/6B+JMFMinLA7fX244wI12h7+o7XHmLkQFiVQz zeT2QHUeaZR0h0hOwtEHMwtOFwv4g7HPHZ79zG6C2g19hTenx1CSr3N6FovsRRoSB02xjBlqDPO pIZ6mJDdZjcFDBKiifF439mXlOMXHnpxRfQHw/HPkcbZkqCPXXVselSUJl+hNU6ezS+z0G8o3tE mPoN9XcPOpKpty3ltTc4Ff+V9HXpdMXruOj0nEfGvKyNJa X-Received: by 2002:a05:6122:e266:b0:56b:5e7e:d3fa with SMTP id 71dfb90a1353d-573c9607b49mr89951e0c.7.1777503916948; Wed, 29 Apr 2026 16:05:16 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb717d119sm1911173241.0.2026.04.29.16.05.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:16 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 12/37] GDB: testsuite: Don't return value from top-level in multi-arch tests Date: Wed, 29 Apr 2026 20:04:03 -0300 Message-ID: <20260429230432.60487-13-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org Oddly enough, there are multi-arch arch tests. This patch contains fixes for them. Some changes are the result of running: $ sed -i 's/^ return -1/ return/' *.exp inside gdb/testsuite/gdb.arch and the others are manual changes. --- gdb/testsuite/gdb.arch/disp-step-insn-reloc.exp | 6 +++--- gdb/testsuite/gdb.arch/ftrace-insn-reloc.exp | 14 +++++++------- gdb/testsuite/gdb.arch/skip-prologue.exp | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/gdb/testsuite/gdb.arch/disp-step-insn-reloc.exp b/gdb/testsuite/gdb.arch/disp-step-insn-reloc.exp index 7d26244129ce..87440a1b28e8 100644 --- a/gdb/testsuite/gdb.arch/disp-step-insn-reloc.exp +++ b/gdb/testsuite/gdb.arch/disp-step-insn-reloc.exp @@ -21,15 +21,15 @@ require support_displaced_stepping # Some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $executable $srcfile \ [list debug $additional_flags]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Read function name from testcases[N]. proc read_testcase { n } { @@ -47,11 +47,11 @@ proc read_testcase { n } { } set n_testcases [get_integer_valueof "n_testcases" 0] if { ${n_testcases} == 0 } { untested "no instruction relocation to test" - return 1 + return } # Set a fast tracepoint on each set_point${i} symbol. There is one for # each testcase. for { set i 0 } { ${i} < ${n_testcases} } { incr i } { diff --git a/gdb/testsuite/gdb.arch/ftrace-insn-reloc.exp b/gdb/testsuite/gdb.arch/ftrace-insn-reloc.exp index 0846e0365d42..06eb5a691bdf 100644 --- a/gdb/testsuite/gdb.arch/ftrace-insn-reloc.exp +++ b/gdb/testsuite/gdb.arch/ftrace-insn-reloc.exp @@ -19,20 +19,20 @@ standard_testfile insn-reloc.c # Some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $testfile-no-ipa $srcfile \ [list debug $additional_flags]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } if {![gdb_target_supports_trace]} { unsupported "target does not support trace" - return -1 + return } require allow_in_proc_agent set libipa [get_in_proc_agent] @@ -41,24 +41,24 @@ set libipa [get_in_proc_agent] # file unused because linking not done" when building the object. if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ executable [list debug $additional_flags shlib=$libipa] ] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile set remote_libipa [gdb_load_shlib $libipa] if {![runto_main]} { - return 0 + return } gdb_reinitialize_dir $srcdir/$subdir if { [gdb_test "info sharedlibrary" ".*[file tail $libipa].*" "IPA loaded"] != 0 } { untested "could not find IPA lib loaded" - return 1 + return } # Read function name from testcases[N]. proc read_testcase { n } { @@ -77,11 +77,11 @@ proc read_testcase { n } { set n_testcases [gdb_readexpr "n_testcases"] if { ${n_testcases} == 0 } { untested "no instruction relocation to test" - return 1 + return } # Set a fast tracepoint on each set_point${i} symbol. There is one for # each testcase. for { set i 0 } { ${i} < ${n_testcases} } { incr i } { diff --git a/gdb/testsuite/gdb.arch/skip-prologue.exp b/gdb/testsuite/gdb.arch/skip-prologue.exp index c805356d8746..c53f86250c84 100644 --- a/gdb/testsuite/gdb.arch/skip-prologue.exp +++ b/gdb/testsuite/gdb.arch/skip-prologue.exp @@ -17,11 +17,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ {nodebug}] } { - return -1 + return } proc do_test { f } { set bp_addr "" gdb_test_multiple "break $f" "" { From patchwork Wed Apr 29 23:04:04 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134215 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 052664358A4D for ; Wed, 29 Apr 2026 23:09:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 052664358A4D Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=A32y874g X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x929.google.com (mail-ua1-x929.google.com [IPv6:2607:f8b0:4864:20::929]) by sourceware.org (Postfix) with ESMTPS id AA0044358A49 for ; Wed, 29 Apr 2026 23:05:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org AA0044358A49 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org AA0044358A49 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::929 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503924; cv=none; b=TxKhMhMxRrOsDyzXFntd5jPK6JzSASkSNvW+lRwTO7l8qLzXxOR7dPQWvRk5WZUUrDOH1SYoIHiGB0o4X9iZV8DlE8d2Cuvl7l4XEbVDPqbjnMSQRIkV2RnT7gc57Ap8ZJPMdxWomRxY6tJHFPnQSVco8R6tYVBw5cIwuH/tJCo= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503924; c=relaxed/simple; bh=FxRLl8iKZ9awl5/2fxC6U841n9wPFf2clNDsnRcvdcA=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=VSzGCx+bbvvtaZOXwFqGWxktxD74XZwp+36vDLBewbfL0UM+itp71hAp4XYxuco9GXROd6dJ76wSvspV2Vam7NUuVVGG2FoiLklxukYxvfF+K0AeAYQl3S5G+CmmcZ3o6kfFY/DH0eOJstBdU1ECgmGO7VZeHRtdNSO4Vi1b8ik= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org AA0044358A49 Received: by mail-ua1-x929.google.com with SMTP id a1e0cc1a2514c-95699e8e26aso97523241.0 for ; Wed, 29 Apr 2026 16:05:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503924; x=1778108724; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=xKKnBr7t4p4UZTD5nI0R0ky2LZhv7zu4ifr33vmeoFA=; b=A32y874g3/cbRARakW39IYIRtgytSa69/RMjB32TaBujNWQ2p3mnND2mIfQEFW9Rln SKnU0tRd3XJVxy3QReSRmlBiExqJmltBegzd6mf0A76nW5NvI4oq4rASO5OR9dt22u+q Uoy4yK63s7E3wHRP7qXAdK463zRUV3zrJUsEugaz57GFaTpEeI2kkDPGlXc8lf52Wl7W UHp7umf+9RlcNC7CIvkRrrzqbBYD0XYzcvYdCYEPhRXFSf2HNHSdZgO88o9F14/3mzMz n+ukarVmmeLT6e6On8wGdsDwtCmNMpjgpwjdT8yRS2CI+kFZHzx9xNWg+gt0VPsOLEPC KCsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503924; x=1778108724; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=xKKnBr7t4p4UZTD5nI0R0ky2LZhv7zu4ifr33vmeoFA=; b=NnPpQXgafy77m5Fk2+wG7JHIgS/6uuFYn+K1m8rQzc1rCvynqxy/cuhu7qghnRTt/n okmsGGZiJD2R5s+OGIZHtdy3k1na/OMiB1TSl4sJY4YXMW59tt1JhbhAparK42NlsOTU M+9ON1reJ82zT097vtj2iAjBSfRWJOwukGjNnXVkcNmToWTbDZxuOjBDjks34SIyhG9E DQu6UTHBqH4QFkxwzN5eoTUHPrvQIlbHrIXD3uPwGN5q1clgHGETal+fLhBm8kgYurZ1 4zy9tOeRynP+4JsuXxPShybteygU8GLEIiQ0GIVLRm3CTg9I5boBrj+JfpFBXTHs5ZXs RxgQ== X-Gm-Message-State: AOJu0YzE4S24uDbsToUKl7V+lz2lRduKxxpndSMUki1gEU9dXsUidoyh sYv4rhDTFogxwpXlr/0sUeuvFDIzmZgtQ3aFWHnHcDdWI4Lt9D0gj/g10VQCWVx2xhaIgNtcA6k LMvk5 X-Gm-Gg: AeBDievEKHLuL4VQwVmq9Iw3zS6W8DGg+8pelsq4LAKUtrwF5BxmzAw0Ivh9C68cfeB WWzNKNsCSCgNoo3HuQE8+I0Bjtkg4UrP1Kpm4rYJDRboN6ehndNuov29hyfQYjNvNKZQ7sLsrAq AO9Fpp5QKe52BkJbANxftalZMcQ3HzUA009J6O0tIofBAd2nn2wJ49n7nXj4CKuhpwpCCp1sU8s GQqz5EC290v/+MPHclAvw80TTKMd1aXuqO9wReB2bnBJS0cdfpMawSMUAGCGZH2oMNJI+UWnNez IbpYN4nmcbvnA3PImbsPnTA+9qSw9tjc7iOub9Dq5XT3hwU6U7bqZm1linN4jRjCUHeXecfswhr bKt1F7cMDVlAP2pkyTl1/9hu5tiExLTfw9AisxheJxMe/kUvl50rVRUwvDG/W1zLVnraQ9YJgK2 7Uz7H2ySe8cDGP5+iwm28hwffh60FXDwwagkNc51qLCzFOIpHFq6CH40U= X-Received: by 2002:a05:6102:5547:b0:607:a394:1841 with SMTP id ada2fe7eead31-62aceacc2a8mr350472137.0.1777503921941; Wed, 29 Apr 2026 16:05:21 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb7584409sm1854846241.3.2026.04.29.16.05.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:21 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 13/37] GDB: testsuite: base: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:04 -0300 Message-ID: <20260429230432.60487-14-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.base. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.base/a2-run.exp | 2 +- gdb/testsuite/gdb.base/access-mem-running.exp | 2 +- .../gdb.base/add-symbol-file-attach.exp | 2 +- .../advance-until-multiple-locations.exp | 2 +- gdb/testsuite/gdb.base/advance.exp | 2 +- gdb/testsuite/gdb.base/all-bin.exp | 2 +- .../gdb.base/annota-input-while-running.exp | 2 +- gdb/testsuite/gdb.base/annota1.exp | 2 +- gdb/testsuite/gdb.base/annota3.exp | 2 +- gdb/testsuite/gdb.base/annotate-symlink.exp | 6 +++--- gdb/testsuite/gdb.base/anon.exp | 2 +- gdb/testsuite/gdb.base/args.exp | 2 +- gdb/testsuite/gdb.base/argv0-symlink.exp | 2 +- gdb/testsuite/gdb.base/arithmet.exp | 2 +- gdb/testsuite/gdb.base/array-indices.exp.tcl | 2 +- gdb/testsuite/gdb.base/array-repeat.exp.tcl | 2 +- gdb/testsuite/gdb.base/asmlabel.exp | 2 +- gdb/testsuite/gdb.base/async.exp | 2 +- .../gdb.base/attach-deleted-exec.exp | 2 +- gdb/testsuite/gdb.base/attach-fail-twice.exp | 2 +- .../gdb.base/attach-non-pgrp-leader.exp | 2 +- gdb/testsuite/gdb.base/attach-pie-misread.exp | 4 ++-- gdb/testsuite/gdb.base/attach-pie-noexec.exp | 2 +- gdb/testsuite/gdb.base/attach-twice.exp | 2 +- gdb/testsuite/gdb.base/attach-wait-input.exp | 2 +- gdb/testsuite/gdb.base/attach.exp | 6 +++--- .../gdb.base/auto-connect-native-target.exp | 2 +- gdb/testsuite/gdb.base/auto-load.exp | 2 +- gdb/testsuite/gdb.base/auxv.exp | 2 +- gdb/testsuite/gdb.base/backtrace.exp | 2 +- gdb/testsuite/gdb.base/bang.exp | 2 +- .../gdb.base/batch-preserve-term-settings.exp | 2 +- gdb/testsuite/gdb.base/bfd-errors.exp | 8 ++++---- .../gdb.base/bg-exec-sigint-bp-cond.exp | 2 +- .../gdb.base/bg-execution-repeat.exp | 2 +- gdb/testsuite/gdb.base/bitfields.exp | 2 +- gdb/testsuite/gdb.base/bitfields2.exp | 2 +- .../gdb.base/bp-cmds-continue-ctrl-c.exp | 2 +- .../gdb.base/bp-cmds-execution-x-script.exp | 2 +- .../gdb.base/bp-cmds-run-with-ex.exp | 2 +- .../gdb.base/bp-cmds-sourced-script.exp | 2 +- gdb/testsuite/gdb.base/bp-cond-failure.exp | 2 +- gdb/testsuite/gdb.base/bp-permanent.exp | 2 +- gdb/testsuite/gdb.base/branch-to-self.exp | 2 +- gdb/testsuite/gdb.base/break-always.exp | 2 +- gdb/testsuite/gdb.base/break-caller-line.exp | 2 +- gdb/testsuite/gdb.base/break-entry.exp | 2 +- gdb/testsuite/gdb.base/break-include.exp | 2 +- gdb/testsuite/gdb.base/break-inline.exp | 2 +- gdb/testsuite/gdb.base/break-interp.exp | 4 ++-- .../gdb.base/break-main-file-remove-fail.exp | 2 +- .../gdb.base/break-on-linker-gcd-function.exp | 2 +- gdb/testsuite/gdb.base/break-probes.exp | 8 ++++---- gdb/testsuite/gdb.base/break-unload-file.exp | 2 +- gdb/testsuite/gdb.base/break.exp | 4 ++-- .../gdb.base/breakpoint-in-ro-region.exp | 6 +++--- gdb/testsuite/gdb.base/breakpoint-shadow.exp | 4 ++-- .../gdb.base/bt-on-error-and-warning.exp | 4 ++-- gdb/testsuite/gdb.base/bt-on-fatal-signal.exp | 4 ++-- gdb/testsuite/gdb.base/bt-selected-frame.exp | 2 +- gdb/testsuite/gdb.base/build-id-seqno.exp | 4 ++-- gdb/testsuite/gdb.base/c-linkage-name.exp | 2 +- gdb/testsuite/gdb.base/cached-source-file.exp | 6 +++--- gdb/testsuite/gdb.base/call-ar-st.exp | 2 +- gdb/testsuite/gdb.base/call-strs.exp | 2 +- gdb/testsuite/gdb.base/cast-call.exp | 4 ++-- gdb/testsuite/gdb.base/cast-indirection.exp | 4 ++-- gdb/testsuite/gdb.base/catch-fork-static.exp | 2 +- .../gdb.base/catch-gdb-caused-signals.exp | 4 ++-- gdb/testsuite/gdb.base/catch-load.exp | 4 ++-- gdb/testsuite/gdb.base/catch-signal-fork.exp | 4 ++-- .../gdb.base/catch-signal-siginfo-cond.exp | 4 ++-- gdb/testsuite/gdb.base/catch-signal.exp | 2 +- gdb/testsuite/gdb.base/catch-syscall.exp | 2 +- gdb/testsuite/gdb.base/charset.exp | 4 ++-- gdb/testsuite/gdb.base/commands.exp | 2 +- gdb/testsuite/gdb.base/compare-sections.exp | 2 +- gdb/testsuite/gdb.base/complete-empty.exp | 2 +- gdb/testsuite/gdb.base/completion.exp | 4 ++-- gdb/testsuite/gdb.base/complex-parts.exp | 2 +- gdb/testsuite/gdb.base/complex.exp | 2 +- gdb/testsuite/gdb.base/cond-eval-mode.exp | 2 +- .../gdb.base/condbreak-call-false.exp | 2 +- gdb/testsuite/gdb.base/condbreak.exp | 2 +- .../gdb.base/consecutive-step-over.exp | 2 +- gdb/testsuite/gdb.base/consecutive.exp | 2 +- .../continue-after-aborted-step-over.exp | 2 +- .../gdb.base/coredump-filter-build-id.exp | 8 ++++---- gdb/testsuite/gdb.base/coredump-filter.exp | 8 ++++---- .../gdb.base/corefile-exec-context.exp | 4 ++-- gdb/testsuite/gdb.base/corefile-find-exec.exp | 2 +- gdb/testsuite/gdb.base/corefile.exp | 2 +- gdb/testsuite/gdb.base/corefile2.exp | 2 +- gdb/testsuite/gdb.base/ctf-ptype.exp | 8 ++++---- gdb/testsuite/gdb.base/ctxobj.exp | 8 ++++---- gdb/testsuite/gdb.base/cursal.exp | 8 ++++---- gdb/testsuite/gdb.base/dcache-flush.exp | 4 ++-- .../gdb.base/dcache-line-read-error.exp | 4 ++-- gdb/testsuite/gdb.base/debug-expr.exp | 4 ++-- gdb/testsuite/gdb.base/debug-frame.exp | 4 ++-- gdb/testsuite/gdb.base/decl-before-def.exp | 2 +- gdb/testsuite/gdb.base/default-args.exp | 2 +- gdb/testsuite/gdb.base/define.exp | 2 +- gdb/testsuite/gdb.base/del.exp | 2 +- gdb/testsuite/gdb.base/disabled-location.exp | 2 +- gdb/testsuite/gdb.base/disasm-end-cu.exp | 6 +++--- gdb/testsuite/gdb.base/disasm-optim.exp | 4 ++-- .../gdb.base/displaced-step-closure.exp | 4 ++-- gdb/testsuite/gdb.base/display.exp | 2 +- gdb/testsuite/gdb.base/dmsym.exp | 2 +- gdb/testsuite/gdb.base/document.exp | 2 +- .../gdb.base/dprintf-bp-same-addr.exp | 2 +- gdb/testsuite/gdb.base/dprintf-detach.exp | 2 +- .../gdb.base/dprintf-execution-x-script.exp | 4 ++-- gdb/testsuite/gdb.base/dprintf-next.exp | 4 ++-- gdb/testsuite/gdb.base/dprintf-non-stop.exp | 4 ++-- gdb/testsuite/gdb.base/dprintf-pending.exp | 2 +- gdb/testsuite/gdb.base/dprintf.exp | 4 ++-- gdb/testsuite/gdb.base/dump.exp | 2 +- gdb/testsuite/gdb.base/dup-sect.exp | 2 +- gdb/testsuite/gdb.base/duplicate-bp.exp | 2 +- gdb/testsuite/gdb.base/early-init-file.exp | 2 +- gdb/testsuite/gdb.base/eh_return.exp | 2 +- gdb/testsuite/gdb.base/ena-dis-br.exp | 2 +- gdb/testsuite/gdb.base/endianity.exp | 2 +- gdb/testsuite/gdb.base/ending-run.exp | 2 +- gdb/testsuite/gdb.base/enum_cond.exp | 2 +- gdb/testsuite/gdb.base/enumval.exp | 2 +- gdb/testsuite/gdb.base/eu-strip-infcall.exp | 4 ++-- .../gdb.base/eval-avoid-side-effects.exp | 4 ++-- gdb/testsuite/gdb.base/examine-backward.exp | 4 ++-- gdb/testsuite/gdb.base/exe-lock.exp | 2 +- .../gdb.base/execl-update-breakpoints.exp | 8 ++++---- gdb/testsuite/gdb.base/execution-termios.exp | 2 +- gdb/testsuite/gdb.base/exitsignal.exp | 8 ++++---- gdb/testsuite/gdb.base/expand-psymtabs.exp | 2 +- gdb/testsuite/gdb.base/fileio.exp | 2 +- gdb/testsuite/gdb.base/filesym.exp | 4 ++-- gdb/testsuite/gdb.base/find-unmapped.exp | 4 ++-- gdb/testsuite/gdb.base/finish-pretty.exp | 2 +- gdb/testsuite/gdb.base/finish.exp | 2 +- gdb/testsuite/gdb.base/float.exp | 2 +- gdb/testsuite/gdb.base/float128.exp | 2 +- gdb/testsuite/gdb.base/floatn.exp | 2 +- gdb/testsuite/gdb.base/foll-fork-syscall.exp | 2 +- gdb/testsuite/gdb.base/foll-fork.exp | 2 +- gdb/testsuite/gdb.base/foll-vfork.exp | 6 +++--- .../gdb.base/fork-print-inferior-events.exp | 2 +- gdb/testsuite/gdb.base/fortran-sym-case.exp | 4 ++-- .../gdb.base/frame-info-consistent.exp | 2 +- gdb/testsuite/gdb.base/frame-selection.exp | 2 +- .../gdb.base/frame-unwind-disable.exp | 2 +- gdb/testsuite/gdb.base/frameapply.exp | 2 +- gdb/testsuite/gdb.base/freebpcmd.exp | 2 +- gdb/testsuite/gdb.base/fullname.exp | 6 +++--- gdb/testsuite/gdb.base/fullpath-expand.exp | 4 ++-- gdb/testsuite/gdb.base/func-ptr.exp | 2 +- gdb/testsuite/gdb.base/func-ptrs.exp | 4 ++-- gdb/testsuite/gdb.base/funcargs.exp | 2 +- .../gdb.base/gcore-buffer-overflow.exp | 2 +- gdb/testsuite/gdb.base/gcore-memory-usage.exp | 2 +- gdb/testsuite/gdb.base/gcore-relro-pie.exp | 8 ++++---- gdb/testsuite/gdb.base/gcore-tls-pie.exp | 10 +++++----- gdb/testsuite/gdb.base/gcore.exp | 4 ++-- gdb/testsuite/gdb.base/gdb-index-err.exp | 4 ++-- gdb/testsuite/gdb.base/gdb-sigterm.exp | 2 +- gdb/testsuite/gdb.base/gdb1090.exp | 2 +- gdb/testsuite/gdb.base/gdb11530.exp | 2 +- gdb/testsuite/gdb.base/gdb11531.exp | 2 +- gdb/testsuite/gdb.base/gdb1821.exp | 2 +- gdb/testsuite/gdb.base/gdbvars.exp | 2 +- gdb/testsuite/gdb.base/gnu-debugdata.exp | 20 +++++++++---------- gdb/testsuite/gdb.base/gnu_vector.exp | 2 +- gdb/testsuite/gdb.base/gstack.exp | 2 +- gdb/testsuite/gdb.base/hashline1.exp | 2 +- gdb/testsuite/gdb.base/hashline2.exp | 2 +- gdb/testsuite/gdb.base/hashline3.exp | 2 +- .../gdb.base/hbreak-in-shr-unsupported.exp | 2 +- gdb/testsuite/gdb.base/hbreak-unmapped.exp | 4 ++-- gdb/testsuite/gdb.base/hbreak.exp | 4 ++-- gdb/testsuite/gdb.base/hbreak2.exp | 4 ++-- gdb/testsuite/gdb.base/history-duplicates.exp | 2 +- gdb/testsuite/gdb.base/hook-stop.exp | 2 +- .../gdb.base/hw-sw-break-same-address.exp | 4 ++-- gdb/testsuite/gdb.base/include-main.exp | 2 +- gdb/testsuite/gdb.base/included.exp | 2 +- gdb/testsuite/gdb.base/infcall-exec.exp | 6 +++--- gdb/testsuite/gdb.base/infcall-input.exp | 4 ++-- gdb/testsuite/gdb.base/inferior-died.exp | 2 +- gdb/testsuite/gdb.base/infnan.exp | 2 +- .../info-locals-unused-static-var.exp | 2 +- gdb/testsuite/gdb.base/info-macros.exp | 4 ++-- gdb/testsuite/gdb.base/info-os.exp | 6 +++--- gdb/testsuite/gdb.base/info-proc.exp | 2 +- gdb/testsuite/gdb.base/info-shared.exp | 6 +++--- gdb/testsuite/gdb.base/info-target.exp | 2 +- gdb/testsuite/gdb.base/info-var.exp | 2 +- gdb/testsuite/gdb.base/info_minsym.exp | 2 +- gdb/testsuite/gdb.base/info_qt.exp | 2 +- gdb/testsuite/gdb.base/info_sources.exp | 4 ++-- gdb/testsuite/gdb.base/info_sources_2.exp | 2 +- .../infoline-reloc-main-from-zero.exp | 2 +- gdb/testsuite/gdb.base/infoline.exp | 2 +- .../gdb.base/inline-frame-cycle-unwind.exp | 2 +- gdb/testsuite/gdb.base/interp.exp | 2 +- gdb/testsuite/gdb.base/interrupt-a.exp | 4 ++-- .../gdb.base/interrupt-daemon-attach.exp | 2 +- gdb/testsuite/gdb.base/interrupt-daemon.exp | 2 +- gdb/testsuite/gdb.base/interrupt-noterm.exp | 4 ++-- gdb/testsuite/gdb.base/interrupt.exp | 2 +- gdb/testsuite/gdb.base/jit-attach-pie.exp | 2 +- gdb/testsuite/gdb.base/jit-reader-simple.exp | 4 ++-- gdb/testsuite/gdb.base/jit-reader.exp | 4 ++-- gdb/testsuite/gdb.base/jump-inline.exp | 4 ++-- gdb/testsuite/gdb.base/jump.exp | 4 ++-- .../gdb.base/jump_multiple_objfiles.exp | 4 ++-- gdb/testsuite/gdb.base/kill-after-signal.exp | 4 ++-- .../gdb.base/kill-detach-inferiors-cmd.exp | 2 +- gdb/testsuite/gdb.base/kill-during-detach.exp | 2 +- gdb/testsuite/gdb.base/killed-outside.exp | 2 +- .../gdb.base/label-without-address.exp | 4 ++-- gdb/testsuite/gdb.base/label.exp | 2 +- gdb/testsuite/gdb.base/langs.exp | 2 +- gdb/testsuite/gdb.base/ldbl_e308.exp | 4 ++-- gdb/testsuite/gdb.base/limited-length.exp | 2 +- gdb/testsuite/gdb.base/line-symtabs.exp | 4 ++-- gdb/testsuite/gdb.base/line65535.exp | 2 +- gdb/testsuite/gdb.base/list-ambiguous.exp | 2 +- gdb/testsuite/gdb.base/list-before-start.exp | 2 +- .../gdb.base/list-missing-source.exp | 2 +- gdb/testsuite/gdb.base/list-nodebug.exp | 2 +- gdb/testsuite/gdb.base/list.exp | 2 +- gdb/testsuite/gdb.base/load-command.exp | 4 ++-- .../gdb.base/long-inferior-output.exp | 2 +- gdb/testsuite/gdb.base/longest-types.exp | 2 +- gdb/testsuite/gdb.base/macscp.exp | 2 +- gdb/testsuite/gdb.base/main-c.exp | 2 +- .../maint-expand-symbols-header-file.exp | 4 ++-- .../maint-info-inline-frames-and-blocks.exp | 2 +- .../gdb.base/maint-info-sections.exp | 4 ++-- .../gdb.base/maint-print-frame-id.exp | 4 ++-- gdb/testsuite/gdb.base/maint.exp | 2 +- gdb/testsuite/gdb.base/many-completions.exp | 2 +- gdb/testsuite/gdb.base/many-headers.exp | 4 ++-- gdb/testsuite/gdb.base/max-value-size.exp | 2 +- gdb/testsuite/gdb.base/memattr.exp | 2 +- gdb/testsuite/gdb.base/memops-watchpoint.exp | 4 ++-- gdb/testsuite/gdb.base/memtag.exp | 6 +++--- gdb/testsuite/gdb.base/mips_pro.exp | 2 +- gdb/testsuite/gdb.base/morestack.exp | 4 ++-- gdb/testsuite/gdb.base/msym-lang.exp | 2 +- gdb/testsuite/gdb.base/nested-addr.exp | 4 ++-- gdb/testsuite/gdb.base/nested-subp1.exp | 4 ++-- gdb/testsuite/gdb.base/nested-subp2.exp | 4 ++-- gdb/testsuite/gdb.base/nested-subp3.exp | 4 ++-- gdb/testsuite/gdb.base/new-ui-echo.exp | 2 +- .../gdb.base/new-ui-pending-input.exp | 2 +- gdb/testsuite/gdb.base/new-ui.exp | 2 +- gdb/testsuite/gdb.base/nextoverexit.exp | 4 ++-- .../gdb.base/non-lazy-array-index.exp | 4 ++-- gdb/testsuite/gdb.base/noreturn-finish.exp | 2 +- gdb/testsuite/gdb.base/noreturn-return.exp | 2 +- gdb/testsuite/gdb.base/offsets.exp | 2 +- gdb/testsuite/gdb.base/opaque.exp | 2 +- gdb/testsuite/gdb.base/options.exp | 4 ++-- .../paginate-after-ctrl-c-running.exp | 2 +- .../gdb.base/paginate-bg-execution.exp | 2 +- .../gdb.base/paginate-execution-startup.exp | 2 +- .../gdb.base/paginate-inferior-exit.exp | 2 +- gdb/testsuite/gdb.base/patch.exp | 2 +- gdb/testsuite/gdb.base/pc-fp.exp | 2 +- gdb/testsuite/gdb.base/pending.exp | 2 +- gdb/testsuite/gdb.base/permissions.exp | 2 +- gdb/testsuite/gdb.base/persistent-lang.exp | 2 +- gdb/testsuite/gdb.base/pie-execl.exp | 4 ++-- gdb/testsuite/gdb.base/pr10179.exp | 4 ++-- gdb/testsuite/gdb.base/prelink.exp | 8 ++++---- .../premature-dummy-frame-removal.exp | 2 +- gdb/testsuite/gdb.base/pretty-array.exp | 4 ++-- gdb/testsuite/gdb.base/pretty-print.exp | 4 ++-- .../gdb.base/print-internal-string.exp | 2 +- .../gdb.base/print-symbol-loading.exp | 8 ++++---- gdb/testsuite/gdb.base/printf-wchar_t.exp | 4 ++-- gdb/testsuite/gdb.base/prologue-include.exp | 2 +- gdb/testsuite/gdb.base/psym-external-decl.exp | 4 ++-- gdb/testsuite/gdb.base/psymtab.exp | 2 +- gdb/testsuite/gdb.base/ptype-offsets-c.exp | 2 +- gdb/testsuite/gdb.base/ptype-offsets.exp | 2 +- gdb/testsuite/gdb.base/ptype.exp | 10 +++++----- gdb/testsuite/gdb.base/random-signal.exp | 2 +- gdb/testsuite/gdb.base/randomize.exp | 4 ++-- gdb/testsuite/gdb.base/range-stepping.exp | 6 +++--- gdb/testsuite/gdb.base/readline-ask.exp | 4 ++-- .../gdb.base/readline-commands-eof.exp | 4 ++-- gdb/testsuite/gdb.base/readnever.exp | 2 +- gdb/testsuite/gdb.base/realname-expand.exp | 4 ++-- gdb/testsuite/gdb.base/recpar.exp | 4 ++-- gdb/testsuite/gdb.base/recurse.exp | 2 +- gdb/testsuite/gdb.base/reggroups.exp | 2 +- gdb/testsuite/gdb.base/relational.exp | 2 +- gdb/testsuite/gdb.base/remote.exp | 2 +- gdb/testsuite/gdb.base/reread-readsym.exp | 2 +- gdb/testsuite/gdb.base/restore.exp | 4 ++-- gdb/testsuite/gdb.base/return-3.exp | 4 ++-- gdb/testsuite/gdb.base/return.exp | 2 +- .../gdb.base/retval-large-struct.exp | 4 ++-- gdb/testsuite/gdb.base/rtld-step.exp | 6 +++--- gdb/testsuite/gdb.base/run-after-attach.exp | 2 +- gdb/testsuite/gdb.base/run-fail-twice.exp | 2 +- gdb/testsuite/gdb.base/save-bp.exp | 6 +++--- .../gdb.base/scope-hw-watch-disable.exp | 4 ++-- gdb/testsuite/gdb.base/scope.exp | 2 +- gdb/testsuite/gdb.base/sect-cmd.exp | 2 +- gdb/testsuite/gdb.base/sepdebug.exp | 4 ++-- gdb/testsuite/gdb.base/sepsymtab.exp | 4 ++-- gdb/testsuite/gdb.base/server-del-break.exp | 2 +- gdb/testsuite/gdb.base/set-cwd.exp | 2 +- gdb/testsuite/gdb.base/set-inferior-tty.exp | 2 +- gdb/testsuite/gdb.base/set-lang-auto.exp | 2 +- gdb/testsuite/gdb.base/set-noassign.exp | 2 +- gdb/testsuite/gdb.base/settings.exp | 4 ++-- gdb/testsuite/gdb.base/setvar.exp | 2 +- .../gdb.base/share-env-with-gdbserver.exp | 2 +- gdb/testsuite/gdb.base/share-psymtabs-bt.exp | 6 +++--- gdb/testsuite/gdb.base/sigall.exp | 2 +- gdb/testsuite/gdb.base/sigbpt.exp | 2 +- gdb/testsuite/gdb.base/siginfo-addr.exp | 2 +- gdb/testsuite/gdb.base/siginfo-infcall.exp | 4 ++-- gdb/testsuite/gdb.base/siginfo-obj.exp | 2 +- gdb/testsuite/gdb.base/siginfo.exp | 2 +- .../gdb.base/signals-state-child.exp | 8 ++++---- gdb/testsuite/gdb.base/signals.exp | 2 +- .../gdb.base/signed-builtin-types.exp | 8 ++++---- gdb/testsuite/gdb.base/signest.exp | 6 +++--- gdb/testsuite/gdb.base/sigstep.exp | 2 +- gdb/testsuite/gdb.base/sizeof.exp | 2 +- gdb/testsuite/gdb.base/skip-inline.exp | 2 +- gdb/testsuite/gdb.base/skip-solib.exp | 6 +++--- gdb/testsuite/gdb.base/skip.exp | 2 +- gdb/testsuite/gdb.base/skipcxx.exp | 2 +- gdb/testsuite/gdb.base/solib-corrupted.exp | 2 +- gdb/testsuite/gdb.base/solib-nodir.exp | 2 +- .../gdb.base/solib-probes-nosharedlibrary.exp | 2 +- gdb/testsuite/gdb.base/solib-search.exp | 4 ++-- gdb/testsuite/gdb.base/solib-vanish.exp | 4 ++-- gdb/testsuite/gdb.base/source-execution.exp | 2 +- gdb/testsuite/gdb.base/source-open.exp | 2 +- .../gdb.base/sss-bp-on-user-bp-2.exp | 2 +- gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp | 4 ++-- gdb/testsuite/gdb.base/stale-infcall.exp | 4 ++-- gdb/testsuite/gdb.base/start-cpp.exp | 4 ++-- gdb/testsuite/gdb.base/start.exp | 4 ++-- gdb/testsuite/gdb.base/starti.exp | 4 ++-- gdb/testsuite/gdb.base/startup-with-shell.exp | 2 +- gdb/testsuite/gdb.base/step-bt.exp | 2 +- .../gdb.base/step-indirect-call-thunk.exp | 4 ++-- .../gdb.base/step-into-other-file.exp | 4 ++-- gdb/testsuite/gdb.base/step-line.exp | 2 +- gdb/testsuite/gdb.base/step-over-exit.exp | 6 +++--- .../gdb.base/step-over-no-symbols.exp | 2 +- gdb/testsuite/gdb.base/step-over-syscall.exp | 4 ++-- .../gdb.base/step-resume-infcall.exp | 6 +++--- .../gdb.base/step-sw-breakpoint-adjust-pc.exp | 2 +- gdb/testsuite/gdb.base/step-symless.exp | 4 ++-- gdb/testsuite/gdb.base/store.exp | 2 +- gdb/testsuite/gdb.base/structs2.exp | 2 +- gdb/testsuite/gdb.base/structs3.exp | 4 ++-- gdb/testsuite/gdb.base/style.exp | 2 +- gdb/testsuite/gdb.base/symbol-alias.exp | 2 +- .../symbol-without-target_section.exp | 4 ++-- gdb/testsuite/gdb.base/symfile-warn.exp | 2 +- gdb/testsuite/gdb.base/symlink-sourcefile.exp | 4 ++-- .../gdb.base/symtab-search-order.exp | 2 +- gdb/testsuite/gdb.base/term.exp | 2 +- .../gdb.base/thread-bp-multi-loc.exp | 6 +++--- gdb/testsuite/gdb.base/tls-dlobj.exp | 12 +++++------ gdb/testsuite/gdb.base/tls-multiobj.exp | 6 +++--- gdb/testsuite/gdb.base/traced-thread.exp | 2 +- gdb/testsuite/gdb.base/ui-redirect.exp | 4 ++-- gdb/testsuite/gdb.base/until-nodebug.exp | 2 +- .../gdb.base/until-trailing-insns.exp | 6 +++--- gdb/testsuite/gdb.base/until.exp | 2 +- .../gdb.base/unwind-on-each-insn.exp.tcl | 2 +- gdb/testsuite/gdb.base/unwindonsignal.exp | 2 +- gdb/testsuite/gdb.base/utf8-identifiers.exp | 4 ++-- gdb/testsuite/gdb.base/valgrind-bt.exp | 4 ++-- gdb/testsuite/gdb.base/valgrind-disp-step.exp | 4 ++-- gdb/testsuite/gdb.base/valgrind-infcall-2.exp | 4 ++-- gdb/testsuite/gdb.base/valgrind-infcall.exp | 4 ++-- gdb/testsuite/gdb.base/value-double-free.exp | 4 ++-- .../gdb.base/value-history-unavailable.exp | 2 +- gdb/testsuite/gdb.base/vdso-warning.exp | 2 +- .../gdb.base/vfork-follow-parent.exp | 2 +- gdb/testsuite/gdb.base/vla-datatypes.exp | 4 ++-- gdb/testsuite/gdb.base/vla-ptr.exp | 4 ++-- gdb/testsuite/gdb.base/vla-sideeffect.exp | 4 ++-- gdb/testsuite/gdb.base/vla-struct-fields.exp | 4 ++-- gdb/testsuite/gdb.base/vla-stub.exp | 2 +- gdb/testsuite/gdb.base/volatile.exp | 2 +- gdb/testsuite/gdb.base/watch-bitfields.exp | 2 +- gdb/testsuite/gdb.base/watch-cond-infcall.exp | 2 +- gdb/testsuite/gdb.base/watch-cond.exp | 2 +- gdb/testsuite/gdb.base/watch-non-mem.exp | 2 +- gdb/testsuite/gdb.base/watch-read.exp | 2 +- gdb/testsuite/gdb.base/watch-vfork.exp | 2 +- .../gdb.base/watchpoint-cond-gone.exp | 4 ++-- gdb/testsuite/gdb.base/watchpoint-delete.exp | 4 ++-- .../gdb.base/watchpoint-hw-attach.exp | 2 +- .../gdb.base/watchpoint-hw-hit-once.exp | 4 ++-- gdb/testsuite/gdb.base/watchpoint-hw.exp | 4 ++-- .../gdb.base/watchpoint-reuse-slot.exp | 2 +- gdb/testsuite/gdb.base/watchpoint-running.exp | 2 +- .../watchpoint-stops-at-right-insn.exp | 2 +- .../gdb.base/watchpoint-unaligned.exp | 4 ++-- gdb/testsuite/gdb.base/watchpoints.exp | 2 +- gdb/testsuite/gdb.base/wchar.exp | 2 +- gdb/testsuite/gdb.base/whatis-exp.exp | 2 +- gdb/testsuite/gdb.base/with-mf.exp | 4 ++-- gdb/testsuite/gdb.base/with.exp | 2 +- gdb/testsuite/gdb.base/write_mem.exp | 2 +- .../gdb.base/wrong_frame_bt_full.exp | 4 ++-- 421 files changed, 648 insertions(+), 648 deletions(-) diff --git a/gdb/testsuite/gdb.base/a2-run.exp b/gdb/testsuite/gdb.base/a2-run.exp index c5df2cce4695..725f8fac5349 100644 --- a/gdb/testsuite/gdb.base/a2-run.exp +++ b/gdb/testsuite/gdb.base/a2-run.exp @@ -29,11 +29,11 @@ standard_testfile run.c set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if { [prepare_for_testing "failed to prepare" $testfile $srcfile $flags] } { - return -1 + return } # Run with no arguments. gdb_run_cmd diff --git a/gdb/testsuite/gdb.base/access-mem-running.exp b/gdb/testsuite/gdb.base/access-mem-running.exp index 7a5468d5307f..11dea64a6338 100644 --- a/gdb/testsuite/gdb.base/access-mem-running.exp +++ b/gdb/testsuite/gdb.base/access-mem-running.exp @@ -16,11 +16,11 @@ # Test that we can access memory while the inferior is running. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug}] == -1} { - return -1 + return } # The test proper. NON_STOP indicates whether we're testing in # non-stop, or all-stop mode. diff --git a/gdb/testsuite/gdb.base/add-symbol-file-attach.exp b/gdb/testsuite/gdb.base/add-symbol-file-attach.exp index 44faa8dbd3cf..b76c4d588d95 100644 --- a/gdb/testsuite/gdb.base/add-symbol-file-attach.exp +++ b/gdb/testsuite/gdb.base/add-symbol-file-attach.exp @@ -34,11 +34,11 @@ require can_spawn_for_attach standard_testfile if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { untested "failed to compile" - return -1 + return } # Use 'spawn_wait_for_attach' to start the test program running. It'll # also sleep for a short time in order to make sure that it's running # so that GDB may attach to it. diff --git a/gdb/testsuite/gdb.base/advance-until-multiple-locations.exp b/gdb/testsuite/gdb.base/advance-until-multiple-locations.exp index 85fd20ae6984..102c68bf9f53 100644 --- a/gdb/testsuite/gdb.base/advance-until-multiple-locations.exp +++ b/gdb/testsuite/gdb.base/advance-until-multiple-locations.exp @@ -20,11 +20,11 @@ standard_testfile .cc require allow_cplus_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug c++}] } { - return -1 + return } set lineno [gdb_get_line_number "multiple locations here"] # advance/until to an inlined line number, which has been inlined diff --git a/gdb/testsuite/gdb.base/advance.exp b/gdb/testsuite/gdb.base/advance.exp index dda32c05c830..fe05dd3a3c37 100644 --- a/gdb/testsuite/gdb.base/advance.exp +++ b/gdb/testsuite/gdb.base/advance.exp @@ -16,11 +16,11 @@ # advance.exp -- Expect script to test 'advance' in gdb standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/all-bin.exp b/gdb/testsuite/gdb.base/all-bin.exp index 9c8345218d14..12b530be77d8 100644 --- a/gdb/testsuite/gdb.base/all-bin.exp +++ b/gdb/testsuite/gdb.base/all-bin.exp @@ -28,11 +28,11 @@ # standard_testfile all-types.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.base/annota-input-while-running.exp b/gdb/testsuite/gdb.base/annota-input-while-running.exp index a1908d449605..747175f0ab5f 100644 --- a/gdb/testsuite/gdb.base/annota-input-while-running.exp +++ b/gdb/testsuite/gdb.base/annota-input-while-running.exp @@ -17,11 +17,11 @@ # into effect when we run a foreground command. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug] == -1} { - return -1 + return } # Because runto_main doesn't know how to handle the prompt with annotations, # run to main before we set the annotation level. if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/annota1.exp b/gdb/testsuite/gdb.base/annota1.exp index d8c8abcbf569..35eaf26103e2 100644 --- a/gdb/testsuite/gdb.base/annota1.exp +++ b/gdb/testsuite/gdb.base/annota1.exp @@ -33,11 +33,11 @@ set breakpoints_invalid "\r\n\032\032breakpoints-invalid\r\n" # standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # # break in main # diff --git a/gdb/testsuite/gdb.base/annota3.exp b/gdb/testsuite/gdb.base/annota3.exp index 6824e4d70980..8a69350f1d5d 100644 --- a/gdb/testsuite/gdb.base/annota3.exp +++ b/gdb/testsuite/gdb.base/annota3.exp @@ -27,11 +27,11 @@ require target_can_use_run_cmd # standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # # break in main diff --git a/gdb/testsuite/gdb.base/annotate-symlink.exp b/gdb/testsuite/gdb.base/annotate-symlink.exp index acf4b540e804..9d6f8fe3a680 100644 --- a/gdb/testsuite/gdb.base/annotate-symlink.exp +++ b/gdb/testsuite/gdb.base/annotate-symlink.exp @@ -24,23 +24,23 @@ set srcfilelink [build_standard_output_file realname-expand-link.c] remote_exec build "ln -sf ${srcdirabs}/${subdir}/${srcfile2} $srcfilelink" if { [file type $srcfilelink] != "link" } { unsupported "target directory cannot have symbolic links" - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${srcfile} ${srcfilelink}" "${binfile}" \ executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart ${testfile} if {![runto_main]} { - return -1 + return } gdb_breakpoint func message gdb_test_no_output "set annotate 1" diff --git a/gdb/testsuite/gdb.base/anon.exp b/gdb/testsuite/gdb.base/anon.exp index 700744e6631b..6a077aa267cb 100644 --- a/gdb/testsuite/gdb.base/anon.exp +++ b/gdb/testsuite/gdb.base/anon.exp @@ -15,11 +15,11 @@ # standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/args.exp b/gdb/testsuite/gdb.base/args.exp index bd10c90b6cd7..d2d5a601b1ee 100644 --- a/gdb/testsuite/gdb.base/args.exp +++ b/gdb/testsuite/gdb.base/args.exp @@ -25,11 +25,11 @@ require {expr {[have_startup_shell] != -1}} standard_testfile if {[build_executable $testfile.exp $testfile $srcfile] == -1} { untested "failed to compile" - return -1 + return } # Assuming a running GDB. Check the status of the single inferior # argument feature. When this feature is on GDB passes inferior # arguments as a single combined string. When this feature is off GDB diff --git a/gdb/testsuite/gdb.base/argv0-symlink.exp b/gdb/testsuite/gdb.base/argv0-symlink.exp index 3ddc1f7356d4..6b05bba205d6 100644 --- a/gdb/testsuite/gdb.base/argv0-symlink.exp +++ b/gdb/testsuite/gdb.base/argv0-symlink.exp @@ -27,11 +27,11 @@ require {!is_remote host} standard_testfile set has_argv0 [gdb_has_argv0] if { [build_executable ${testfile}.exp ${testfile} ${srcfile}] == -1 } { - return -1 + return } with_test_prefix "file symlink" { set test "kept name" diff --git a/gdb/testsuite/gdb.base/arithmet.exp b/gdb/testsuite/gdb.base/arithmet.exp index 2d03a62c5306..2911d70afdb3 100644 --- a/gdb/testsuite/gdb.base/arithmet.exp +++ b/gdb/testsuite/gdb.base/arithmet.exp @@ -27,11 +27,11 @@ # standard_testfile int-type.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings}]} { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values diff --git a/gdb/testsuite/gdb.base/array-indices.exp.tcl b/gdb/testsuite/gdb.base/array-indices.exp.tcl index 8f3c0ad03d4e..82f1d2918992 100644 --- a/gdb/testsuite/gdb.base/array-indices.exp.tcl +++ b/gdb/testsuite/gdb.base/array-indices.exp.tcl @@ -17,11 +17,11 @@ standard_testfile ${srcdir}/gdb.base/array-repeat.c if {[prepare_for_testing ${testfile}.exp ${testfile} ${srcfile} \ [list debug ${lang}]]} { - return -1 + return } gdb_test_no_output "set print array-indexes on" if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/array-repeat.exp.tcl b/gdb/testsuite/gdb.base/array-repeat.exp.tcl index d10d441325b5..e4c19ac205c3 100644 --- a/gdb/testsuite/gdb.base/array-repeat.exp.tcl +++ b/gdb/testsuite/gdb.base/array-repeat.exp.tcl @@ -17,11 +17,11 @@ standard_testfile ${srcdir}/gdb.base/array-repeat.c if {[prepare_for_testing ${testfile}.exp ${testfile} ${srcfile} \ [list debug ${lang}]]} { - return -1 + return } if {![runto_main]} { perror "Could not run to main." continue diff --git a/gdb/testsuite/gdb.base/asmlabel.exp b/gdb/testsuite/gdb.base/asmlabel.exp index 163ef2dc5c8d..15f3695d796c 100644 --- a/gdb/testsuite/gdb.base/asmlabel.exp +++ b/gdb/testsuite/gdb.base/asmlabel.exp @@ -32,11 +32,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/async.exp b/gdb/testsuite/gdb.base/async.exp index c9318b9b2487..a3b40882f9b8 100644 --- a/gdb/testsuite/gdb.base/async.exp +++ b/gdb/testsuite/gdb.base/async.exp @@ -19,11 +19,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # # set it up at a breakpoint so we can play with it # diff --git a/gdb/testsuite/gdb.base/attach-deleted-exec.exp b/gdb/testsuite/gdb.base/attach-deleted-exec.exp index 7bd8db07ca49..61ee8647c9c4 100644 --- a/gdb/testsuite/gdb.base/attach-deleted-exec.exp +++ b/gdb/testsuite/gdb.base/attach-deleted-exec.exp @@ -21,11 +21,11 @@ require can_spawn_for_attach require {istarget *-linux*} standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile] } { - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.base/attach-fail-twice.exp b/gdb/testsuite/gdb.base/attach-fail-twice.exp index 226ade56f7dc..b3a40ca9a7d6 100644 --- a/gdb/testsuite/gdb.base/attach-fail-twice.exp +++ b/gdb/testsuite/gdb.base/attach-fail-twice.exp @@ -18,11 +18,11 @@ require can_spawn_for_attach standard_testfile if {[build_executable "failed to build" $testfile $srcfile {debug}]} { - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.base/attach-non-pgrp-leader.exp b/gdb/testsuite/gdb.base/attach-non-pgrp-leader.exp index 3a9730d99c7c..ded09db5d137 100644 --- a/gdb/testsuite/gdb.base/attach-non-pgrp-leader.exp +++ b/gdb/testsuite/gdb.base/attach-non-pgrp-leader.exp @@ -21,11 +21,11 @@ require can_spawn_for_attach standard_testfile if { [build_executable ${testfile}.exp ${testfile} $srcfile {debug}] == -1 } { - return -1 + return } proc do_test {} { global binfile global decimal diff --git a/gdb/testsuite/gdb.base/attach-pie-misread.exp b/gdb/testsuite/gdb.base/attach-pie-misread.exp index be10db7e3a1e..a8002119d962 100644 --- a/gdb/testsuite/gdb.base/attach-pie-misread.exp +++ b/gdb/testsuite/gdb.base/attach-pie-misread.exp @@ -24,11 +24,11 @@ standard_testfile .c set genfile [standard_output_file ${testfile}-gen.h] set executable $testfile if {[build_executable_own_libs ${testfile}.exp $executable $srcfile \ {pie}] == ""} { - return -1 + return } # Program Headers: # Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align # LOAD 0x000000 0x0000000000400000 0x0000000000400000 0x134f5ec 0x134f5ec R E 0x200000 @@ -108,11 +108,11 @@ file delete -- $genfile set phdr [read_phdr $binfile "readelf rebuilt with stub_size"] set dynamic_vaddr_prelinkno [lindex $phdr 0] if {![prelink_yes $prelink_args]} { - return -1 + return } set phdr [read_phdr $binfile "readelf with prelink -R"] set dynamic_vaddr_prelinkyes [lindex $phdr 0] diff --git a/gdb/testsuite/gdb.base/attach-pie-noexec.exp b/gdb/testsuite/gdb.base/attach-pie-noexec.exp index ab613d2543ad..54a4b0bffae7 100644 --- a/gdb/testsuite/gdb.base/attach-pie-noexec.exp +++ b/gdb/testsuite/gdb.base/attach-pie-noexec.exp @@ -17,11 +17,11 @@ require can_spawn_for_attach standard_testfile .c set executable ${testfile} if { [prepare_for_testing "failed to prepare" $executable "" [list debug pie]] } { - return -1 + return } set arch "" set test "show architecture" gdb_test_multiple $test $test { diff --git a/gdb/testsuite/gdb.base/attach-twice.exp b/gdb/testsuite/gdb.base/attach-twice.exp index 96292d12818a..a3677f2fad92 100644 --- a/gdb/testsuite/gdb.base/attach-twice.exp +++ b/gdb/testsuite/gdb.base/attach-twice.exp @@ -17,11 +17,11 @@ require can_spawn_for_attach standard_testfile set executable ${testfile} if { [prepare_for_testing "failed to prepare" $executable] } { - return -1 + return } # Start the program running and then wait for a bit, to be sure # that it can be attached to. diff --git a/gdb/testsuite/gdb.base/attach-wait-input.exp b/gdb/testsuite/gdb.base/attach-wait-input.exp index f7651abdcfd8..68979b3c9f97 100644 --- a/gdb/testsuite/gdb.base/attach-wait-input.exp +++ b/gdb/testsuite/gdb.base/attach-wait-input.exp @@ -32,11 +32,11 @@ require !use_gdb_stub standard_testfile if {[build_executable "failed to build" $testfile $srcfile debug]} { - return -1 + return } # Start the program running, and return its PID, ready for attaching. proc start_program {testfile} { diff --git a/gdb/testsuite/gdb.base/attach.exp b/gdb/testsuite/gdb.base/attach.exp index bffdfd9b1aa9..9b7814b40baf 100644 --- a/gdb/testsuite/gdb.base/attach.exp +++ b/gdb/testsuite/gdb.base/attach.exp @@ -28,25 +28,25 @@ remote_exec build "rm -f ${binfile} ${binfile2} ${binfile3}" # build the first test case # if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } # Build the in-system-call test if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable {debug}] != "" } { untested "failed to compile in-system-call test" - return -1 + return } # Build the third file, used to check attach when the exec-file has changed. if { [gdb_compile "${srcdir}/${subdir}/${srcfile3}" "${binfile3}" executable {debug}] != "" } { untested "failed to compile attach exec-file changed test" - return -1 + return } # This is a test of the error cases for gdb's ability to attach to a # running process. diff --git a/gdb/testsuite/gdb.base/auto-connect-native-target.exp b/gdb/testsuite/gdb.base/auto-connect-native-target.exp index 26434396cc6a..4529d68e16c6 100644 --- a/gdb/testsuite/gdb.base/auto-connect-native-target.exp +++ b/gdb/testsuite/gdb.base/auto-connect-native-target.exp @@ -17,11 +17,11 @@ # native targets. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } require have_native_target # Returns the topmost target pushed on the target stack. TEST is used diff --git a/gdb/testsuite/gdb.base/auto-load.exp b/gdb/testsuite/gdb.base/auto-load.exp index c890117bd951..0b974d43d6d9 100644 --- a/gdb/testsuite/gdb.base/auto-load.exp +++ b/gdb/testsuite/gdb.base/auto-load.exp @@ -23,11 +23,11 @@ set targetscriptdir "${targetdir}/[file dirname ${binfile}]" set targetscript "${targetscriptdir}/${testfile}-gdb.gdb" remote_exec host "rm -rf ${targetdir}" if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } remote_exec host "mkdir -p ${targetscriptdir}" remote_exec host "cp ${sourcescript} ${targetscript}" diff --git a/gdb/testsuite/gdb.base/auxv.exp b/gdb/testsuite/gdb.base/auxv.exp index ec0172c88bb7..79e897078e5d 100644 --- a/gdb/testsuite/gdb.base/auxv.exp +++ b/gdb/testsuite/gdb.base/auxv.exp @@ -28,11 +28,11 @@ set gcorefile ${binfile}.gcore if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ {debug additional_flags=-DUSE_RLIMIT}] != "" && [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ {debug}] != "" } { untested "failed to compile" - return -1 + return } # Use a fresh directory to confine the native core dumps. # Make it the working directory for the inferior. set coredir [standard_output_file coredir.[getpid]] diff --git a/gdb/testsuite/gdb.base/backtrace.exp b/gdb/testsuite/gdb.base/backtrace.exp index 00e4681b93aa..612dd2ad6a87 100644 --- a/gdb/testsuite/gdb.base/backtrace.exp +++ b/gdb/testsuite/gdb.base/backtrace.exp @@ -16,11 +16,11 @@ # A place for miscellaneous tests related to backtrace. standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/bang.exp b/gdb/testsuite/gdb.base/bang.exp index d6d7adf9d8e7..8a341d95fe56 100644 --- a/gdb/testsuite/gdb.base/bang.exp +++ b/gdb/testsuite/gdb.base/bang.exp @@ -18,11 +18,11 @@ standard_testfile args.c if {[prepare_for_testing "failed to prepare" ${testfile}! $srcfile \ {debug nowarnings}]} { - return -1 + return } # Verify that we can run the program and that it terminates normally. runto_main diff --git a/gdb/testsuite/gdb.base/batch-preserve-term-settings.exp b/gdb/testsuite/gdb.base/batch-preserve-term-settings.exp index 6587e71fd7ed..2aae194e1187 100644 --- a/gdb/testsuite/gdb.base/batch-preserve-term-settings.exp +++ b/gdb/testsuite/gdb.base/batch-preserve-term-settings.exp @@ -17,11 +17,11 @@ # wrong state. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug] == -1} { - return -1 + return } set file_arg $binfile if {[is_remote host]} { set file_arg [remote_download host $file_arg] diff --git a/gdb/testsuite/gdb.base/bfd-errors.exp b/gdb/testsuite/gdb.base/bfd-errors.exp index 93d108cc1488..d4e12f78d99e 100644 --- a/gdb/testsuite/gdb.base/bfd-errors.exp +++ b/gdb/testsuite/gdb.base/bfd-errors.exp @@ -55,11 +55,11 @@ set binfile_lib [standard_output_file ${lib_basename}.so] set lib_flags debug # Compile shared library: if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib} $lib_flags] != "" } { untested "failed to compile" - return -1 + return } # Open the shared library and determine some basic facts. The key # things that we need to learn are 1) whether the solib is 32-bit or # 64-bit ELF file, and 2) the endianness. @@ -69,11 +69,11 @@ fconfigure $solib_fp -translation binary # Read and check EI_MAG to verify that it's really an ELF file. set data [read $solib_fp 4] if { ![string equal $data "\x7fELF"] } { close $solib_fp untested "shared library is not an ELF file" - return -1 + return } # Read EI_CLASS for ELF32 versus ELF64. set data [read $solib_fp 1] set is_elf64 [string equal $data "\x02"] @@ -91,11 +91,11 @@ if { [catch {exec $objcopy_program \ --dump-section .dynsym=${binfile_lib}.dynsym \ --dump-section .dynstr=${binfile_lib}.dynstr \ ${binfile_lib}} output] } { untested "failed objcopy dump-section" verbose -log "objcopy output: $output" - return -1 + return } # Determine length of .dynstr. We'll use the length for creating invalid # offsets into .dynstr. set dynstr_len [file size ${binfile_lib}.dynstr] @@ -142,11 +142,11 @@ close $dynsym_fp if { [catch {exec $objcopy_program \ --update-section .dynsym=${binfile_lib}.dynsym \ ${binfile_lib}} output] } { untested "failed objcopy update-section" verbose -log "objcopy output: $output" - return -1 + return } clean_restart # Count number of distinct BFD error messages via 'bfd_error_count' diff --git a/gdb/testsuite/gdb.base/bg-exec-sigint-bp-cond.exp b/gdb/testsuite/gdb.base/bg-exec-sigint-bp-cond.exp index 43ef98e16da6..44b84b3755dc 100644 --- a/gdb/testsuite/gdb.base/bg-exec-sigint-bp-cond.exp +++ b/gdb/testsuite/gdb.base/bg-exec-sigint-bp-cond.exp @@ -21,11 +21,11 @@ require {!is_remote host} standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Run the test. Sets a breakpoint with a condition that sends a # SIGINT to GDB, and ensures that that doesn't make the breakpoint hit # cause a premature stop. This emulates pressing Ctrl-C just while diff --git a/gdb/testsuite/gdb.base/bg-execution-repeat.exp b/gdb/testsuite/gdb.base/bg-execution-repeat.exp index 7567a0fbba55..48d650c02533 100644 --- a/gdb/testsuite/gdb.base/bg-execution-repeat.exp +++ b/gdb/testsuite/gdb.base/bg-execution-repeat.exp @@ -18,11 +18,11 @@ # PR gdb/17471. standard_testfile if { [build_executable "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } set linenum [gdb_get_line_number "set break here"] # Run the test proper. CONTINUE_CMD is the background continue diff --git a/gdb/testsuite/gdb.base/bitfields.exp b/gdb/testsuite/gdb.base/bitfields.exp index 6f4ace22371a..8ec8e00393c7 100644 --- a/gdb/testsuite/gdb.base/bitfields.exp +++ b/gdb/testsuite/gdb.base/bitfields.exp @@ -17,11 +17,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # # Test bitfield locating and uniqueness. # For each member, set that member to 1 and verify that the member (and only diff --git a/gdb/testsuite/gdb.base/bitfields2.exp b/gdb/testsuite/gdb.base/bitfields2.exp index 0f86a56db97b..dac6a32fc9fe 100644 --- a/gdb/testsuite/gdb.base/bitfields2.exp +++ b/gdb/testsuite/gdb.base/bitfields2.exp @@ -25,11 +25,11 @@ standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } set has_signed_bitfields 1 # diff --git a/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp b/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp index 4163c4c32b3d..368507b2409c 100644 --- a/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp +++ b/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp @@ -25,11 +25,11 @@ require {!target_info exists gdb,nosignals} require {!target_info exists gdb,nointerrupts} standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # See intro. proc do_test {} { diff --git a/gdb/testsuite/gdb.base/bp-cmds-execution-x-script.exp b/gdb/testsuite/gdb.base/bp-cmds-execution-x-script.exp index 491f1e2609f6..7204a3736c09 100644 --- a/gdb/testsuite/gdb.base/bp-cmds-execution-x-script.exp +++ b/gdb/testsuite/gdb.base/bp-cmds-execution-x-script.exp @@ -18,11 +18,11 @@ # that has "continue" in its command list, and then does "run". standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } set x_file ${srcdir}/${subdir}/$testfile.gdb # Run the test proper. diff --git a/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp b/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp index 698c85c3e409..95c2811a3e03 100644 --- a/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp +++ b/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp @@ -20,11 +20,11 @@ # '-ex' option. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile]} { - return -1 + return } set script_file $srcdir/$subdir/$testfile.gdb save_vars { GDBFLAGS } { diff --git a/gdb/testsuite/gdb.base/bp-cmds-sourced-script.exp b/gdb/testsuite/gdb.base/bp-cmds-sourced-script.exp index e12016f2fc5e..2fa46d5bc093 100644 --- a/gdb/testsuite/gdb.base/bp-cmds-sourced-script.exp +++ b/gdb/testsuite/gdb.base/bp-cmds-sourced-script.exp @@ -17,11 +17,11 @@ # expected when the commands are defined for multiple breakpoints. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } set script_file ${srcdir}/${subdir}/$testfile.gdb gdb_test "source $script_file" \ diff --git a/gdb/testsuite/gdb.base/bp-cond-failure.exp b/gdb/testsuite/gdb.base/bp-cond-failure.exp index bde1eab21bd8..f6ca85027e4c 100644 --- a/gdb/testsuite/gdb.base/bp-cond-failure.exp +++ b/gdb/testsuite/gdb.base/bp-cond-failure.exp @@ -34,11 +34,11 @@ if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ # Run to main so that we connect to the target if using 'target # remote'. This means that the is_address_zero_readable, and the # 'show breakpoint condition-evaluation' checks below will be # performed with the remote connection in place. if { ![runto_main] } { - return -1 + return } # This test relies on reading address zero triggering a SIGSEGV. if { [is_address_zero_readable] } { return diff --git a/gdb/testsuite/gdb.base/bp-permanent.exp b/gdb/testsuite/gdb.base/bp-permanent.exp index eb716cac6b5b..dac54fadef1c 100644 --- a/gdb/testsuite/gdb.base/bp-permanent.exp +++ b/gdb/testsuite/gdb.base/bp-permanent.exp @@ -23,11 +23,11 @@ set options { debug } if { ![target_info exists gdb,nosignals] } { lappend options "additional_flags=-DSIGNALS" } if {[build_executable "failed to prepare" $testfile $srcfile $options]} { - return -1 + return } set line_bp [gdb_get_line_number "write permanent bp"] # The test proper. ALWAYS_INSERTED indicates whether testing in diff --git a/gdb/testsuite/gdb.base/branch-to-self.exp b/gdb/testsuite/gdb.base/branch-to-self.exp index 03758ebb9427..ffd15780d724 100644 --- a/gdb/testsuite/gdb.base/branch-to-self.exp +++ b/gdb/testsuite/gdb.base/branch-to-self.exp @@ -18,11 +18,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if { [build_executable ${testfile}.exp ${testfile} $srcfile {debug}] == -1 } { - return -1 + return } with_test_prefix "single-step" { global testfile diff --git a/gdb/testsuite/gdb.base/break-always.exp b/gdb/testsuite/gdb.base/break-always.exp index 050eac05942a..f2eb1a3ba8b9 100644 --- a/gdb/testsuite/gdb.base/break-always.exp +++ b/gdb/testsuite/gdb.base/break-always.exp @@ -16,11 +16,11 @@ # Test that 'set breakpoint always-inserted 1' is not a brick # Also verifies that breakpoint enabling/disabling works properly # with duplicated breakpoints. if { [prepare_for_testing "failed to prepare" break-always break-always.c] } { - return -1 + return } set bar_location [gdb_get_line_number "break in bar" break-always.c] gdb_test_no_output "set breakpoint always-inserted on" diff --git a/gdb/testsuite/gdb.base/break-caller-line.exp b/gdb/testsuite/gdb.base/break-caller-line.exp index 0bdda52caab8..7fdef95cc607 100644 --- a/gdb/testsuite/gdb.base/break-caller-line.exp +++ b/gdb/testsuite/gdb.base/break-caller-line.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto callee]} { return 0 } diff --git a/gdb/testsuite/gdb.base/break-entry.exp b/gdb/testsuite/gdb.base/break-entry.exp index 2b51c822c0c4..2629d99c7ef0 100644 --- a/gdb/testsuite/gdb.base/break-entry.exp +++ b/gdb/testsuite/gdb.base/break-entry.exp @@ -28,11 +28,11 @@ standard_testfile start.c require !use_gdb_stub if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile {additional_flags=-static}] } { - return -1 + return } set test "info files" set entry "" gdb_test_multiple $test $test { diff --git a/gdb/testsuite/gdb.base/break-include.exp b/gdb/testsuite/gdb.base/break-include.exp index d9b0a6b64413..5a66dbf1fced 100644 --- a/gdb/testsuite/gdb.base/break-include.exp +++ b/gdb/testsuite/gdb.base/break-include.exp @@ -16,11 +16,11 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing ${testfile}.exp $testfile] } { - return -1 + return } set bp_line [gdb_get_line_number "break here" ${testfile}.c] set bp_line_actual [gdb_get_line_number "ANCHOR" ${testfile}.inc] diff --git a/gdb/testsuite/gdb.base/break-inline.exp b/gdb/testsuite/gdb.base/break-inline.exp index 99f55f64f837..057dd3b03b91 100644 --- a/gdb/testsuite/gdb.base/break-inline.exp +++ b/gdb/testsuite/gdb.base/break-inline.exp @@ -13,11 +13,11 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . if { [prepare_for_testing "failed to prepare" "break-inline" {} {debug nowarnings optimize=-O2}] } { - return -1 + return } gdb_breakpoint "main" "temporary" gdb_run_cmd gdb_test "" "Temporary breakpoint.*foo\\(\\).*" diff --git a/gdb/testsuite/gdb.base/break-interp.exp b/gdb/testsuite/gdb.base/break-interp.exp index 2b9a66d9aa1c..527eece5d867 100644 --- a/gdb/testsuite/gdb.base/break-interp.exp +++ b/gdb/testsuite/gdb.base/break-interp.exp @@ -29,15 +29,15 @@ set binfile_lib ${binprefix}.so set srcfile "${test}-main.c" set srcfile_lib "${test}-lib.c" if {[build_executable "build library" ${binfile_lib} ${srcfile_lib} \ {debug shlib}] == -1} { - return -1 + return } if {[build_executable ${test}.exp $binfile_test ${srcfile_test} {}] == -1} { - return -1 + return } # Note: The separate debug info file content build-id/crc32 are not verified # contrary to the GDB search algorithm skipping non-matching ones. proc system_debug_get {exec} { diff --git a/gdb/testsuite/gdb.base/break-main-file-remove-fail.exp b/gdb/testsuite/gdb.base/break-main-file-remove-fail.exp index face6205da77..b0a22962bba8 100644 --- a/gdb/testsuite/gdb.base/break-main-file-remove-fail.exp +++ b/gdb/testsuite/gdb.base/break-main-file-remove-fail.exp @@ -19,11 +19,11 @@ # PROGRAM". standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Run the test proper. INITIAL_LOAD determines whether the program is # initially loaded by the "file" command or by passing it to GDB on # the command line. diff --git a/gdb/testsuite/gdb.base/break-on-linker-gcd-function.exp b/gdb/testsuite/gdb.base/break-on-linker-gcd-function.exp index 780b226a3731..f430c51f946e 100644 --- a/gdb/testsuite/gdb.base/break-on-linker-gcd-function.exp +++ b/gdb/testsuite/gdb.base/break-on-linker-gcd-function.exp @@ -29,11 +29,11 @@ standard_testfile .cc if {[build_executable_from_specs $testfile.exp $testfile \ {c++ ldflags=-Wl,--gc-sections} \ $srcfile {debug c++ additional_flags=-ffunction-sections}]} { untested "failed to compile" - return -1 + return } clean_restart $testfile proc set_breakpoint_on_gcd_function {} { diff --git a/gdb/testsuite/gdb.base/break-probes.exp b/gdb/testsuite/gdb.base/break-probes.exp index 81ceb99d9836..12a3c55b081f 100644 --- a/gdb/testsuite/gdb.base/break-probes.exp +++ b/gdb/testsuite/gdb.base/break-probes.exp @@ -21,18 +21,18 @@ set libname $testfile-solib set srcfile_lib $srcdir/$subdir/$libname.c set binfile_lib [standard_output_file $libname.so] if { [gdb_compile_shlib $srcfile_lib $binfile_lib {}] != "" } { untested "failed to compile shared library" - return -1 + return } set binfile_lib_target [gdb_download_shlib $binfile_lib] if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug shlib_load additional_flags=-DSHLIB_NAME=\"$binfile_lib_target\"]] } { - return -1 + return } gdb_locate_shlib $binfile_lib # Enable stop-on-solib-events @@ -55,11 +55,11 @@ gdb_test_multiple "p /x \$pc" "" { -re -wrap "" { } } if { $pc == "" } { unsupported "Couldn't get $pc" - return -1 + return } regsub "0x0*" $pc "" pc # Verify that pc is at info_start probe address. gdb_test_multiple "info probes stap rtld" "" { @@ -70,11 +70,11 @@ gdb_test_multiple "info probes stap rtld" "" { } } if { ! $using_probes } { unsupported "probes not present on this system" - return -1 + return } set sysroot "" set test "show sysroot" gdb_test_multiple $test $test { diff --git a/gdb/testsuite/gdb.base/break-unload-file.exp b/gdb/testsuite/gdb.base/break-unload-file.exp index 63e0c9462a15..1b7e8b0a5b01 100644 --- a/gdb/testsuite/gdb.base/break-unload-file.exp +++ b/gdb/testsuite/gdb.base/break-unload-file.exp @@ -17,11 +17,11 @@ # target. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Run the test proper. INITIAL_LOAD determines whether the program is # initially loaded by the "file" command or by passing it to GDB on # the command line. ALWAYS_INSERT determines whether always-inserted diff --git a/gdb/testsuite/gdb.base/break.exp b/gdb/testsuite/gdb.base/break.exp index d5f92e469ac9..2f5fa3d8e59a 100644 --- a/gdb/testsuite/gdb.base/break.exp +++ b/gdb/testsuite/gdb.base/break.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . # This file was written by Rob Savoye. (rob@cygnus.com) if { [build_executable "failed to prepare" "break" {break.c break1.c} {debug nowarnings}] } { - return -1 + return } set srcfile break.c set srcfile1 break1.c set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] @@ -803,11 +803,11 @@ test_next_with_recursion # build a new file with optimization enabled so that we can try breakpoints # on targets with optimized prologues if { [build_executable "failed to prepare" "breako2" {break.c break1.c} {debug nowarnings optimize=-O2}] } { - return -1 + return } proc_with_prefix test_break_optimized_prologue {} { clean_restart breako2 diff --git a/gdb/testsuite/gdb.base/breakpoint-in-ro-region.exp b/gdb/testsuite/gdb.base/breakpoint-in-ro-region.exp index 2ab0354ee8c2..b7ae91155d4b 100644 --- a/gdb/testsuite/gdb.base/breakpoint-in-ro-region.exp +++ b/gdb/testsuite/gdb.base/breakpoint-in-ro-region.exp @@ -20,15 +20,15 @@ require !gdb_debug_enabled standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Delete all target-supplied memory regions. delete_memory_regions @@ -139,11 +139,11 @@ proc get_next_insn {} { set hw_step [probe_target_hardware_step] if {![get_function_bounds "main" main_lo main_hi]} { # Can't do the following tests if main's bounds are unknown. - return -1 + return } # Manually create a read-only memory region that covers 'main'. gdb_test_no_output "mem $main_lo $main_hi ro" \ "create read-only mem region covering main" diff --git a/gdb/testsuite/gdb.base/breakpoint-shadow.exp b/gdb/testsuite/gdb.base/breakpoint-shadow.exp index 9d270e8b148f..1be637848eb5 100644 --- a/gdb/testsuite/gdb.base/breakpoint-shadow.exp +++ b/gdb/testsuite/gdb.base/breakpoint-shadow.exp @@ -14,16 +14,16 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # We need to start the inferior to place the breakpoints in the memory at all. if {![runto_main]} { - return -1 + return } # The default "auto" mode removes all the breakpoints when we stop (and not # running the nonstop mode). We would not be able to test the shadow. gdb_test_no_output "set breakpoint always-inserted on" diff --git a/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp b/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp index a710b9c5908a..a9a1db344d21 100644 --- a/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp +++ b/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp @@ -18,17 +18,17 @@ # switched off. standard_testfile bt-on-fatal-signal.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } # Check we can run to main. If this works this time then we just # assume that it will work later on (when we repeatedly restart GDB). if {![runto_main]} { - return -1 + return } # Check that the backtrace-on-fatal-signal feature is supported. If # this target doesn't have the backtrace function available then # trying to turn this on will give an error, in which case we just diff --git a/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp b/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp index ae9463f2369c..9bf5f09c566f 100644 --- a/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp +++ b/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp @@ -24,17 +24,17 @@ standard_testfile # established the connection to the remote host?), so just skip this # test for remote host setups. require {!is_remote host} if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } # Check we can run to main. If this works this time then we just # assume that it will work later on (when we repeatedly restart GDB). if {![runto_main]} { - return -1 + return } # Check that the backtrace-on-fatal-signal feature is supported. If # this target doesn't have the backtrace function available then # trying to turn this on will give an error, in which case we just diff --git a/gdb/testsuite/gdb.base/bt-selected-frame.exp b/gdb/testsuite/gdb.base/bt-selected-frame.exp index f6c34b1a1815..0bd1024e9874 100644 --- a/gdb/testsuite/gdb.base/bt-selected-frame.exp +++ b/gdb/testsuite/gdb.base/bt-selected-frame.exp @@ -16,11 +16,11 @@ # Check that the selected stack frame doesn't change after a backtrace. standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } proc check_selected_frame_after_bt { bt_cmd stack_pattern } { clean_restart $::testfile diff --git a/gdb/testsuite/gdb.base/build-id-seqno.exp b/gdb/testsuite/gdb.base/build-id-seqno.exp index 907c4b74cafc..68ac4208f1d8 100644 --- a/gdb/testsuite/gdb.base/build-id-seqno.exp +++ b/gdb/testsuite/gdb.base/build-id-seqno.exp @@ -29,16 +29,16 @@ require {!is_remote host} standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile \ {debug build-id}] == -1} { - return -1 + return } # Split out BINFILE.debug. Remove debug from BINFILE. if {[gdb_gnu_strip_debug $binfile] != 0} { - return -1 + return } # Get the '.build-id/xx/xxx...xxx' part of the filename. set build_id_filename [build_id_debug_filename_get $binfile] diff --git a/gdb/testsuite/gdb.base/c-linkage-name.exp b/gdb/testsuite/gdb.base/c-linkage-name.exp index f0c0f6e87ecb..70115709e3dd 100644 --- a/gdb/testsuite/gdb.base/c-linkage-name.exp +++ b/gdb/testsuite/gdb.base/c-linkage-name.exp @@ -20,11 +20,11 @@ standard_testfile c-linkage-name.c c-linkage-name-2.c set sources "${srcdir}/${subdir}/${srcfile} ${srcdir}/${subdir}/${srcfile2}" if { [gdb_compile "${sources}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart gdb_test_no_output "set language c" gdb_load ${binfile} diff --git a/gdb/testsuite/gdb.base/cached-source-file.exp b/gdb/testsuite/gdb.base/cached-source-file.exp index 19b62a4a3760..ec523b298305 100644 --- a/gdb/testsuite/gdb.base/cached-source-file.exp +++ b/gdb/testsuite/gdb.base/cached-source-file.exp @@ -24,22 +24,22 @@ standard_testfile # Only run on native boards. require !use_gdb_stub if { [target_info gdb_protocol] == "extended-remote" } { - return -1 + return } # Because we need to modify the source file later, it's better if we # just copy it to our output directory (instead of messing with the # user's source directory). set newsrc [standard_output_file $testfile].c file copy -force -- $srcdir/$subdir/$srcfile $newsrc set srcfile $newsrc if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Get the line number for the line with the "break-here" marker. set bp_line [gdb_get_line_number "break-here" $srcfile] @@ -77,11 +77,11 @@ file rename -force -- $bkpsrc $srcfile sleep 1 # Recompile the modified source. We use "gdb_compile" here instead of # "prepare_for_testing" because we don't want to call "clean_restart". if { [gdb_compile "${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } # Rerun the program. This should not only force GDB to reload the # source cache, but also to break at BP_LINE again, which now has # different contents. diff --git a/gdb/testsuite/gdb.base/call-ar-st.exp b/gdb/testsuite/gdb.base/call-ar-st.exp index 9337c2433c9b..0f8d65d2eaa4 100644 --- a/gdb/testsuite/gdb.base/call-ar-st.exp +++ b/gdb/testsuite/gdb.base/call-ar-st.exp @@ -31,11 +31,11 @@ set allow_float_test [allow_float_test] set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } set oldtimeout $timeout set timeout [expr {$timeout + 60}] diff --git a/gdb/testsuite/gdb.base/call-strs.exp b/gdb/testsuite/gdb.base/call-strs.exp index dff0e95be11d..d9d011ed8113 100644 --- a/gdb/testsuite/gdb.base/call-strs.exp +++ b/gdb/testsuite/gdb.base/call-strs.exp @@ -32,11 +32,11 @@ require {!target_info exists gdb,cannot_call_functions} set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } gdb_test_no_output "set print sevenbit-strings" gdb_test_no_output "set print address off" gdb_test_no_output "set print symbol off" diff --git a/gdb/testsuite/gdb.base/cast-call.exp b/gdb/testsuite/gdb.base/cast-call.exp index de2f77da19cf..9f6d526f6a0c 100644 --- a/gdb/testsuite/gdb.base/cast-call.exp +++ b/gdb/testsuite/gdb.base/cast-call.exp @@ -19,15 +19,15 @@ require {!target_info exists gdb,cannot_call_functions} standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "STOP"] gdb_continue_to_breakpoint "STOP" diff --git a/gdb/testsuite/gdb.base/cast-indirection.exp b/gdb/testsuite/gdb.base/cast-indirection.exp index c446a54021bc..193c02a66253 100644 --- a/gdb/testsuite/gdb.base/cast-indirection.exp +++ b/gdb/testsuite/gdb.base/cast-indirection.exp @@ -17,15 +17,15 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ {nodebug}] == -1} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "p a_loc ()" \ "'a_loc' has unknown return type; cast the call to its declared return type" diff --git a/gdb/testsuite/gdb.base/catch-fork-static.exp b/gdb/testsuite/gdb.base/catch-fork-static.exp index cad0cf885328..1b4a6b860080 100644 --- a/gdb/testsuite/gdb.base/catch-fork-static.exp +++ b/gdb/testsuite/gdb.base/catch-fork-static.exp @@ -26,11 +26,11 @@ require allow_fork_tests # Reusing foll-fork.c since it's a simple forking program. standard_testfile foll-fork.c if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile \ {additional_flags=-static}] } { - return -1 + return } gdb_test "catch fork" "Catchpoint \[0-9\]* \\(fork\\)" gdb_run_cmd diff --git a/gdb/testsuite/gdb.base/catch-gdb-caused-signals.exp b/gdb/testsuite/gdb.base/catch-gdb-caused-signals.exp index 1fa567ad3ca7..21f0e9bc98cc 100644 --- a/gdb/testsuite/gdb.base/catch-gdb-caused-signals.exp +++ b/gdb/testsuite/gdb.base/catch-gdb-caused-signals.exp @@ -31,15 +31,15 @@ set bp_location [gdb_get_line_number "set breakpoint here"] set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "handle SIGSEGV nostop noprint" \ "Signal\[ \t\]+Stop\[ \t\]+Print\[ \t\]+Pass to program\[ \t\]+Description\r\nSIGSEGV\[ \t\]+No\[ \t\]+No\[ \t\]+Yes\[ \t\].*" gdb_test "handle SIGILL nostop noprint" \ diff --git a/gdb/testsuite/gdb.base/catch-load.exp b/gdb/testsuite/gdb.base/catch-load.exp index dbf45941f5e7..eac42ba9f0af 100644 --- a/gdb/testsuite/gdb.base/catch-load.exp +++ b/gdb/testsuite/gdb.base/catch-load.exp @@ -16,20 +16,20 @@ require allow_shlib_tests standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug shlib_load}] != "" } { untested "failed to compile" - return -1 + return } set testfile2 catch-load-so set srcfile2 ${testfile2}.c set binfile2 [standard_output_file ${testfile2}.so] set binfile2_dlopen [shlib_target_file ${testfile2}.so] if { [gdb_compile_shlib "${srcdir}/${subdir}/${srcfile2}" ${binfile2} {debug}] != "" } { untested "failed to compile shared library" - return -1 + return } # Run one set of tests. # SCENARIO is the name of the test scenario, it is just used in test # names. diff --git a/gdb/testsuite/gdb.base/catch-signal-fork.exp b/gdb/testsuite/gdb.base/catch-signal-fork.exp index 2ed6929848d4..fd872ecb3186 100644 --- a/gdb/testsuite/gdb.base/catch-signal-fork.exp +++ b/gdb/testsuite/gdb.base/catch-signal-fork.exp @@ -17,15 +17,15 @@ require {!target_info exists gdb,nosignals} require allow_fork_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Test "catch signal SIGHUP" gdb_test "catch signal SIGHUP" "Catchpoint .*" gdb_breakpoint ${srcfile}:[gdb_get_line_number "first HUP"] diff --git a/gdb/testsuite/gdb.base/catch-signal-siginfo-cond.exp b/gdb/testsuite/gdb.base/catch-signal-siginfo-cond.exp index 0cca484dd574..dc0e77076df0 100644 --- a/gdb/testsuite/gdb.base/catch-signal-siginfo-cond.exp +++ b/gdb/testsuite/gdb.base/catch-signal-siginfo-cond.exp @@ -30,15 +30,15 @@ require {!target_info exists gdb,nosignals} require supports_get_siginfo_type standard_testfile if { [prepare_for_testing "failed to prepare" "${testfile}" $srcfile {debug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "set breakpoint here"] gdb_test "catch signal" diff --git a/gdb/testsuite/gdb.base/catch-signal.exp b/gdb/testsuite/gdb.base/catch-signal.exp index 7b46d8bbe387..6da1b6aeda79 100644 --- a/gdb/testsuite/gdb.base/catch-signal.exp +++ b/gdb/testsuite/gdb.base/catch-signal.exp @@ -16,11 +16,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc test_catch_signal {signame} { global srcfile diff --git a/gdb/testsuite/gdb.base/catch-syscall.exp b/gdb/testsuite/gdb.base/catch-syscall.exp index 31a42e33b5ff..673fca4a9984 100644 --- a/gdb/testsuite/gdb.base/catch-syscall.exp +++ b/gdb/testsuite/gdb.base/catch-syscall.exp @@ -793,11 +793,11 @@ proc setup_all_syscalls {} { } return 1 } if { ![setup_all_syscalls] } { - return -1 + return } # Fill all the syscalls numbers before starting anything. fill_all_syscalls_numbers diff --git a/gdb/testsuite/gdb.base/charset.exp b/gdb/testsuite/gdb.base/charset.exp index f7ee7a76bb7b..13e874ec9553 100644 --- a/gdb/testsuite/gdb.base/charset.exp +++ b/gdb/testsuite/gdb.base/charset.exp @@ -22,11 +22,11 @@ standard_testfile .c charset-malloc.c if { [prepare_for_testing "failed to prepare" ${testfile} [list $srcfile $srcfile2]] } { - return -1 + return } # Parse the output from a `show charset' command. Return the host # and target charset as a two-element list. proc parse_show_charset_output {testname} { @@ -156,11 +156,11 @@ gdb_expect { # If gdb was built with a phony iconv, it will only have two character # sets: "auto" and the default. In this situation, this set of tests # is pointless. if {[llength [array names charsets]] < 3} { untested "fewer than 3 charsets" - return -1 + return } send_gdb "set target-charset\n" gdb_expect { -re "Requires an argument. Valid arguments are (.*)\\.\r\n$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.base/commands.exp b/gdb/testsuite/gdb.base/commands.exp index b8b44d8f874f..c64c5fa31356 100644 --- a/gdb/testsuite/gdb.base/commands.exp +++ b/gdb/testsuite/gdb.base/commands.exp @@ -31,11 +31,11 @@ set flags {} lappend flags debug lappend flags additional_flags=-DFAKEARGV lappend_include_file flags $srcdir/lib/unbuffer_output.c if { [prepare_for_testing "failed to prepare" $testfile $srcfile $flags] } { - return -1 + return } # Run to FUNCTION. If that fails, issue a FAIL and make the caller # return. diff --git a/gdb/testsuite/gdb.base/compare-sections.exp b/gdb/testsuite/gdb.base/compare-sections.exp index 56f0b2a6ca80..f647cc5a8491 100644 --- a/gdb/testsuite/gdb.base/compare-sections.exp +++ b/gdb/testsuite/gdb.base/compare-sections.exp @@ -16,11 +16,11 @@ # Test the compare-sections command. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug}]} { - return -1 + return } set is_pie [exec_is_pie $binfile] # Run the compare-sections command along with any options as specified diff --git a/gdb/testsuite/gdb.base/complete-empty.exp b/gdb/testsuite/gdb.base/complete-empty.exp index 7a77224857cb..295f44591ad9 100644 --- a/gdb/testsuite/gdb.base/complete-empty.exp +++ b/gdb/testsuite/gdb.base/complete-empty.exp @@ -23,11 +23,11 @@ gdb_start # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } # Start of tests. # Test TAB with no input. diff --git a/gdb/testsuite/gdb.base/completion.exp b/gdb/testsuite/gdb.base/completion.exp index 4469f0dbbc35..e7407e75ee09 100644 --- a/gdb/testsuite/gdb.base/completion.exp +++ b/gdb/testsuite/gdb.base/completion.exp @@ -52,11 +52,11 @@ standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } if {![runto_main]} { return } @@ -163,11 +163,11 @@ gdb_assert {$all_regs eq $completed_regs} "complete 'info registers '" # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { - return -1 + return } # The bulk of this test script pre-dates the completion-support # library, and should probably (where possible) be converted. # However, for now, new tests are being added using this library. diff --git a/gdb/testsuite/gdb.base/complex-parts.exp b/gdb/testsuite/gdb.base/complex-parts.exp index c010ffee1ca1..56260996bdb6 100644 --- a/gdb/testsuite/gdb.base/complex-parts.exp +++ b/gdb/testsuite/gdb.base/complex-parts.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/complex.exp b/gdb/testsuite/gdb.base/complex.exp index c4be874e3767..0d7a83fb667e 100644 --- a/gdb/testsuite/gdb.base/complex.exp +++ b/gdb/testsuite/gdb.base/complex.exp @@ -15,11 +15,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {[runto f2]} { get_debug_format if {[test_compiler_info gcc-2-*] && [test_debug_format "DWARF \[0-9\]"]} { diff --git a/gdb/testsuite/gdb.base/cond-eval-mode.exp b/gdb/testsuite/gdb.base/cond-eval-mode.exp index b963ae45a750..e2afc3a95939 100644 --- a/gdb/testsuite/gdb.base/cond-eval-mode.exp +++ b/gdb/testsuite/gdb.base/cond-eval-mode.exp @@ -24,11 +24,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/condbreak-call-false.exp b/gdb/testsuite/gdb.base/condbreak-call-false.exp index 767d6d181e7c..32113e3b9501 100644 --- a/gdb/testsuite/gdb.base/condbreak-call-false.exp +++ b/gdb/testsuite/gdb.base/condbreak-call-false.exp @@ -17,11 +17,11 @@ # false works as expected. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/condbreak.exp b/gdb/testsuite/gdb.base/condbreak.exp index ed76c261dbe5..6a6c9c1d4f8d 100644 --- a/gdb/testsuite/gdb.base/condbreak.exp +++ b/gdb/testsuite/gdb.base/condbreak.exp @@ -23,11 +23,11 @@ standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" $testfile [list $srcfile $srcfile2] \ {debug nowarnings}]} { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location6 [gdb_get_line_number "set breakpoint 6 here"] set bp_location8 [gdb_get_line_number "set breakpoint 8 here" $srcfile2] diff --git a/gdb/testsuite/gdb.base/consecutive-step-over.exp b/gdb/testsuite/gdb.base/consecutive-step-over.exp index 9a10f19c0400..d7efec8f418d 100644 --- a/gdb/testsuite/gdb.base/consecutive-step-over.exp +++ b/gdb/testsuite/gdb.base/consecutive-step-over.exp @@ -19,11 +19,11 @@ # over another breakpoint, without a user visible stop in between. # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/consecutive.exp b/gdb/testsuite/gdb.base/consecutive.exp index 71d207c95bf3..4c657a8f897c 100644 --- a/gdb/testsuite/gdb.base/consecutive.exp +++ b/gdb/testsuite/gdb.base/consecutive.exp @@ -21,11 +21,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/continue-after-aborted-step-over.exp b/gdb/testsuite/gdb.base/continue-after-aborted-step-over.exp index 488677413862..1285c4f14158 100644 --- a/gdb/testsuite/gdb.base/continue-after-aborted-step-over.exp +++ b/gdb/testsuite/gdb.base/continue-after-aborted-step-over.exp @@ -35,11 +35,11 @@ # *GDB hangs forever* standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # DISPLACED indicates whether to use displaced-stepping. proc do_test {displaced breakpoint_always_inserted} { global gdb_prompt decimal diff --git a/gdb/testsuite/gdb.base/coredump-filter-build-id.exp b/gdb/testsuite/gdb.base/coredump-filter-build-id.exp index 1eba93c0f6ad..d267221e1bfe 100644 --- a/gdb/testsuite/gdb.base/coredump-filter-build-id.exp +++ b/gdb/testsuite/gdb.base/coredump-filter-build-id.exp @@ -24,28 +24,28 @@ standard_testfile "normal.c" # This test is Linux x86_64 only. if { ![istarget *-*-linux*] } { untested "$testfile.exp" - return -1 + return } require is_x86_64_m64_target gcore_cmd_available if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug build-id}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # First we need to generate a corefile. set corefilename "[standard_output_file gcore.test]" if { ![gdb_gcore_cmd "$corefilename" "save corefile"] } { verbose -log "Could not save corefile" untested "$testfile.exp" - return -1 + return } # Determine if GDB dumped the mapping containing the build-id. This # is done by invoking an external program (eu-unstrip). if { [catch {exec [gdb_find_eu-unstrip] -n --core $corefilename} output] == 0 } { diff --git a/gdb/testsuite/gdb.base/coredump-filter.exp b/gdb/testsuite/gdb.base/coredump-filter.exp index e2ce86d48e8a..6bf26f1643ab 100644 --- a/gdb/testsuite/gdb.base/coredump-filter.exp +++ b/gdb/testsuite/gdb.base/coredump-filter.exp @@ -16,19 +16,19 @@ standard_testfile # This test is Linux-only. if {![istarget *-*-linux*]} { untested "coredump-filter.exp" - return -1 + return } if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" ".* break-here .*" @@ -182,11 +182,11 @@ set all_anon_corefiles { { "non-Private-Anonymous" "0x7e" \ # If corefile loading is not supported, we do not even try to run the # tests. set core_supported [gdb_gcore_cmd "$non_private_anon_core" "save a corefile"] if { !$core_supported } { untested "corefile generation is not supported" - return -1 + return } gdb_test_multiple "info inferiors" "getting inferior pid" { -re "process $decimal.*\r\n$gdb_prompt $" { } diff --git a/gdb/testsuite/gdb.base/corefile-exec-context.exp b/gdb/testsuite/gdb.base/corefile-exec-context.exp index 17d7e23f333a..bf935a795e7d 100644 --- a/gdb/testsuite/gdb.base/corefile-exec-context.exp +++ b/gdb/testsuite/gdb.base/corefile-exec-context.exp @@ -22,11 +22,11 @@ require {is_any_target "*-*-linux*" "*-*-freebsd*"} standard_testfile if {[build_executable $testfile.exp $testfile $srcfile] == -1} { untested "failed to compile" - return -1 + return } # Linux core files can encore upto 80 characters for the command and # arguments in the psinfo. If BINFILE is less than 80 characters in # length then lets try to make it longer. @@ -134,11 +134,11 @@ for { set i 0 } { $i < 10 } { incr i } { } } if { $env_var_name eq "" } { unsupported "couldn't find suitable environment variable name" - return -1 + return } # Generate a core file with this environment variable set. set env_var_value "TEST VALUE" save_vars { ::env($env_var_name) } { diff --git a/gdb/testsuite/gdb.base/corefile-find-exec.exp b/gdb/testsuite/gdb.base/corefile-find-exec.exp index d766aa69f1bc..7d79b70c41b7 100644 --- a/gdb/testsuite/gdb.base/corefile-find-exec.exp +++ b/gdb/testsuite/gdb.base/corefile-find-exec.exp @@ -22,11 +22,11 @@ require {is_any_target "*-*-linux*" "*-*-freebsd*"} standard_testfile if {[build_executable $testfile.exp $testfile $srcfile {debug build-id}] == -1} { untested "failed to compile" - return -1 + return } # Load the COREFILE and confirm that GDB auto-loads the executable. # The symbols should be read from SYMBOL_FILE and the core file should # be reported as generated by GEN_FROM_FILE. diff --git a/gdb/testsuite/gdb.base/corefile.exp b/gdb/testsuite/gdb.base/corefile.exp index f6a0a7a1ecad..31249355353f 100644 --- a/gdb/testsuite/gdb.base/corefile.exp +++ b/gdb/testsuite/gdb.base/corefile.exp @@ -21,11 +21,11 @@ require isnative standard_testfile coremaker.c if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { untested "failed to compile" - return -1 + return } # Do not delete coremap.data when calling core_find. This file is # required for GDB to find mmap'd data in the "accessing read-only # mmapped data in core file" test. diff --git a/gdb/testsuite/gdb.base/corefile2.exp b/gdb/testsuite/gdb.base/corefile2.exp index 4ad218b34627..805e08973f6b 100644 --- a/gdb/testsuite/gdb.base/corefile2.exp +++ b/gdb/testsuite/gdb.base/corefile2.exp @@ -33,11 +33,11 @@ if { ![istarget *-linux*] } { standard_testfile coremaker2.c if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { untested "failed to compile" - return -1 + return } set corefile [core_find $binfile {}] if {$corefile == ""} { untested "unable to create or find corefile" diff --git a/gdb/testsuite/gdb.base/ctf-ptype.exp b/gdb/testsuite/gdb.base/ctf-ptype.exp index e6bae63562b5..d3c3b46140c5 100644 --- a/gdb/testsuite/gdb.base/ctf-ptype.exp +++ b/gdb/testsuite/gdb.base/ctf-ptype.exp @@ -86,20 +86,20 @@ gdb_test "ptype struct t_struct" \ # Test the equivalence between '.' and '->' for struct member references. if {[gdb_test "ptype v_struct1.v_float_member" "type = float"] < 0} { - return -1 + return } if {[gdb_test "ptype v_struct1->v_float_member" "type = float"] < 0} { - return -1 + return } if {[gdb_test "ptype v_t_struct_p.v_float_member" "type = float"] < 0} { - return -1 + return } if {[gdb_test "ptype v_t_struct_p->v_float_member" "type = float"] < 0} { - return -1 + return } gdb_test "ptype struct link" \ [multi_line \ "type = struct link {" \ diff --git a/gdb/testsuite/gdb.base/ctxobj.exp b/gdb/testsuite/gdb.base/ctxobj.exp index 567c4292aafb..3b1b12a9b186 100644 --- a/gdb/testsuite/gdb.base/ctxobj.exp +++ b/gdb/testsuite/gdb.base/ctxobj.exp @@ -37,29 +37,29 @@ set libobj1_opts { debug set libobj2_opts { debug additional_flags=-DVERSION=203 additional_flags=-DGET_VERSION=get_version_2 } if { [gdb_compile_shlib $libsrc $libobj1 $libobj1_opts ] != "" } { - return -1 + return } if { [gdb_compile_shlib $libsrc $libobj2 $libobj2_opts ] != "" } { - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${executable}.c" \ [standard_output_file ${executable}] \ executable \ [list debug shlib=${libobj1} shlib=${libobj2}]] != ""} { - return -1 + return } clean_restart $executable gdb_load_shlib $libobj1 gdb_load_shlib $libobj2 if {![runto_main]} { - return -1 + return } set bp_location [gdb_get_line_number "STOP" "ctxobj-f.c"] gdb_test "break ctxobj-f.c:$bp_location" \ "Breakpoint ${::decimal} at ${::hex}: .*" \ diff --git a/gdb/testsuite/gdb.base/cursal.exp b/gdb/testsuite/gdb.base/cursal.exp index 1385a30632b6..a52ec3f844e7 100644 --- a/gdb/testsuite/gdb.base/cursal.exp +++ b/gdb/testsuite/gdb.base/cursal.exp @@ -16,11 +16,11 @@ standard_testfile if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != ""} { untested "failed to compile" - return -1 + return } clean_restart gdb_file_cmd ${binfile} gdb_test_no_output "set listsize 1" @@ -30,19 +30,19 @@ gdb_test "list" \ "{ /\\* main prologue \\*/" \ "list before run" gdb_load ${binfile} if {! [runto_main]} { - return -1 + return } gdb_test "list" \ "v0 = 0;" \ "list in main" if {! [runto "func2"]} { - return -1 + return } gdb_test "list" \ "v2 = 2;" \ "list in func2" @@ -56,10 +56,10 @@ gdb_test "list -1" \ # check the window gdb_test_no_output "set listsize 3" if {! [runto_main]} { - return -1 + return } gdb_test "list" \ "func1 \\(\\);" \ "list size 3" diff --git a/gdb/testsuite/gdb.base/dcache-flush.exp b/gdb/testsuite/gdb.base/dcache-flush.exp index 7ed60e3e913a..df05ab554b66 100644 --- a/gdb/testsuite/gdb.base/dcache-flush.exp +++ b/gdb/testsuite/gdb.base/dcache-flush.exp @@ -16,15 +16,15 @@ # Test that the dcache can be flushed. standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto func]} { - return -1 + return } gdb_test "up" ".* main .*" gdb_test "p var1" " = 4" gdb_test "p var2" " = 3" diff --git a/gdb/testsuite/gdb.base/dcache-line-read-error.exp b/gdb/testsuite/gdb.base/dcache-line-read-error.exp index 207724af756e..98095c188663 100644 --- a/gdb/testsuite/gdb.base/dcache-line-read-error.exp +++ b/gdb/testsuite/gdb.base/dcache-line-read-error.exp @@ -16,15 +16,15 @@ # Test that dcache behaves correctly when reading a cache line fails. standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto breakpt]} { - return -1 + return } # Issue the "delete mem" command. This makes GDB ignore the # target-provided list, if any. diff --git a/gdb/testsuite/gdb.base/debug-expr.exp b/gdb/testsuite/gdb.base/debug-expr.exp index 80f6d5a968b1..b9377541847e 100644 --- a/gdb/testsuite/gdb.base/debug-expr.exp +++ b/gdb/testsuite/gdb.base/debug-expr.exp @@ -20,15 +20,15 @@ require !gdb_debug_enabled standard_testfile .c if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } for { set i 0 } { $i < 4 } { incr i } { gdb_test_no_output "set variable array\[$i\] = $i" } diff --git a/gdb/testsuite/gdb.base/debug-frame.exp b/gdb/testsuite/gdb.base/debug-frame.exp index 1f5f015f5ddb..2038fa992d23 100644 --- a/gdb/testsuite/gdb.base/debug-frame.exp +++ b/gdb/testsuite/gdb.base/debug-frame.exp @@ -18,15 +18,15 @@ require !gdb_debug_enabled standard_testfile .c -2.c set srcfiles [list $srcfile $srcfile2] if {[prepare_for_testing "failed to prepare" $testfile $srcfiles]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Redirect debug output to file. set logfile [host_standard_output_file gdb.txt] gdb_test_no_output "set logging file $logfile" \ diff --git a/gdb/testsuite/gdb.base/decl-before-def.exp b/gdb/testsuite/gdb.base/decl-before-def.exp index 2c4de8f42f9f..66083d2aa710 100644 --- a/gdb/testsuite/gdb.base/decl-before-def.exp +++ b/gdb/testsuite/gdb.base/decl-before-def.exp @@ -15,11 +15,11 @@ standard_testfile decl-before-def-decl.c decl-before-def-def.c set sources [list $srcfile $srcfile2] if {[prepare_for_testing "failed to prepare" $testfile $sources]} { - return -1 + return } # This is required due to PR25764. gdb_test "maint expand-symtabs" diff --git a/gdb/testsuite/gdb.base/default-args.exp b/gdb/testsuite/gdb.base/default-args.exp index edd3bea3c33b..3046aaf7c5f8 100644 --- a/gdb/testsuite/gdb.base/default-args.exp +++ b/gdb/testsuite/gdb.base/default-args.exp @@ -20,11 +20,11 @@ load_lib completion-support.exp standard_testfile .c if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } clean_restart $testfile # Basic/core tests using user-visible commands. diff --git a/gdb/testsuite/gdb.base/define.exp b/gdb/testsuite/gdb.base/define.exp index 33aee1d46cf0..e0e440e455c6 100644 --- a/gdb/testsuite/gdb.base/define.exp +++ b/gdb/testsuite/gdb.base/define.exp @@ -22,11 +22,11 @@ standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location11 [gdb_get_line_number "set breakpoint 11 here"] diff --git a/gdb/testsuite/gdb.base/del.exp b/gdb/testsuite/gdb.base/del.exp index ea3c639e0dda..a34dba5845ea 100644 --- a/gdb/testsuite/gdb.base/del.exp +++ b/gdb/testsuite/gdb.base/del.exp @@ -18,11 +18,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # A function to test that ALIAS is working as a shortcut of the "delete" # command. diff --git a/gdb/testsuite/gdb.base/disabled-location.exp b/gdb/testsuite/gdb.base/disabled-location.exp index 300f73cd0c7d..17e8987ded18 100644 --- a/gdb/testsuite/gdb.base/disabled-location.exp +++ b/gdb/testsuite/gdb.base/disabled-location.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/disasm-end-cu.exp b/gdb/testsuite/gdb.base/disasm-end-cu.exp index dc0dc25882aa..66cd2f92d871 100644 --- a/gdb/testsuite/gdb.base/disasm-end-cu.exp +++ b/gdb/testsuite/gdb.base/disasm-end-cu.exp @@ -16,23 +16,23 @@ # This test tries to disassemble over the boundary between two compilation # units displaying source lines. This checks that the disassemble routine # can handle our use of line number 0 to mark the end of sequence. if { [prepare_for_testing "failed to prepare" "disasm-end-cu" {disasm-end-cu-1.c disasm-end-cu-2.c} {debug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set main_addr [get_hexadecimal_valueof "&main" "0"] set dummy_3_addr [get_hexadecimal_valueof "&dummy_3" "0"] if {$main_addr == 0 || $dummy_3_addr == 0 || $dummy_3_addr <= $main_addr} { fail "unable to extract required addresses, or addresses out of order" - return -1 + return } gdb_test_multiple "disassemble /m ${main_addr},${dummy_3_addr}" "disassemble address range with source" { -re "Dump of assembler code from ${main_addr} to ${dummy_3_addr}:\r\nEnd of assembler dump\." { fail "no output from the disassemble command" diff --git a/gdb/testsuite/gdb.base/disasm-optim.exp b/gdb/testsuite/gdb.base/disasm-optim.exp index 70841ac2723d..c926a0200759 100644 --- a/gdb/testsuite/gdb.base/disasm-optim.exp +++ b/gdb/testsuite/gdb.base/disasm-optim.exp @@ -18,15 +18,15 @@ require is_amd64_regs_target standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile ${testfile}.S {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_sequence "disassemble /s main" \ "Disassemble main with source" { "Dump of assembler code for function main:" diff --git a/gdb/testsuite/gdb.base/displaced-step-closure.exp b/gdb/testsuite/gdb.base/displaced-step-closure.exp index 358020fed85f..6d0521d3141a 100644 --- a/gdb/testsuite/gdb.base/displaced-step-closure.exp +++ b/gdb/testsuite/gdb.base/displaced-step-closure.exp @@ -19,15 +19,15 @@ # by address returns a match even if no displaced stepping is currently # taking place. standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # We have a breakpoint at the current pc (from stopping at main). Step over # the breakpoint. gdb_test "stepi" ".*" "step-over breakpoint" diff --git a/gdb/testsuite/gdb.base/display.exp b/gdb/testsuite/gdb.base/display.exp index 1eae678111b5..3acc512de0e0 100644 --- a/gdb/testsuite/gdb.base/display.exp +++ b/gdb/testsuite/gdb.base/display.exp @@ -27,11 +27,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug nowarnings}]} { - return -1 + return } # Preserve the old timeout, and set a new one that should be # sufficient to avoid timing out during this test. set oldtimeout $timeout diff --git a/gdb/testsuite/gdb.base/dmsym.exp b/gdb/testsuite/gdb.base/dmsym.exp index 89e38a29d453..3820b13bfdc7 100644 --- a/gdb/testsuite/gdb.base/dmsym.exp +++ b/gdb/testsuite/gdb.base/dmsym.exp @@ -33,11 +33,11 @@ if {[gdb_compile "${srcdir}/${subdir}/dmsym.c" \ if {[gdb_compile \ [list ${srcdir}/${subdir}/dmsym_main.c $dmsym_o] \ [standard_output_file ${testfile}] \ executable {debug}] != ""} { untested "failed to compile" - return -1 + return } clean_restart ${testfile} # Some convenient regular expressions... diff --git a/gdb/testsuite/gdb.base/document.exp b/gdb/testsuite/gdb.base/document.exp index a7d685e5f35f..905ce59af97b 100644 --- a/gdb/testsuite/gdb.base/document.exp +++ b/gdb/testsuite/gdb.base/document.exp @@ -15,11 +15,11 @@ standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } # test document command used within user command. gdb_test_multiple "define do-document" "" { -re "Type commands for definition of \"do-document\".\r\nEnd with a line saying just \"end\".\r\n>$" { diff --git a/gdb/testsuite/gdb.base/dprintf-bp-same-addr.exp b/gdb/testsuite/gdb.base/dprintf-bp-same-addr.exp index 6fc9ec99ebcb..b2cc3ddb144c 100644 --- a/gdb/testsuite/gdb.base/dprintf-bp-same-addr.exp +++ b/gdb/testsuite/gdb.base/dprintf-bp-same-addr.exp @@ -17,11 +17,11 @@ standard_testfile if {[build_executable "failed to prepare" \ ${testfile} ${srcfile} {debug}]} { - return -1 + return } set dp_location [gdb_get_line_number "set dprintf here"] proc test { style } { diff --git a/gdb/testsuite/gdb.base/dprintf-detach.exp b/gdb/testsuite/gdb.base/dprintf-detach.exp index 4aad0158291b..dd9bfde8f47c 100644 --- a/gdb/testsuite/gdb.base/dprintf-detach.exp +++ b/gdb/testsuite/gdb.base/dprintf-detach.exp @@ -26,11 +26,11 @@ require can_spawn_for_attach standard_testfile set escapedbinfile [string_to_regexp ${binfile}] if {[build_executable "failed to prepare for dprintf-detach" \ ${testfile} ${srcfile} {debug}]} { - return -1 + return } proc dprintf_detach_test { breakpoint_always_inserted dprintf_style disconnected_dprintf } { set test_prefix "bai=${breakpoint_always_inserted} ds=${dprintf_style} dd=${disconnected_dprintf}" global decimal gdb_prompt escapedbinfile diff --git a/gdb/testsuite/gdb.base/dprintf-execution-x-script.exp b/gdb/testsuite/gdb.base/dprintf-execution-x-script.exp index 3f149381f4f5..5263d15a83de 100644 --- a/gdb/testsuite/gdb.base/dprintf-execution-x-script.exp +++ b/gdb/testsuite/gdb.base/dprintf-execution-x-script.exp @@ -23,11 +23,11 @@ require target_can_use_run_cmd standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # This is the name of the GDB script to load. set x_file ${srcdir}/${subdir}/$testfile.gdb @@ -45,11 +45,11 @@ save_vars { GDBFLAGS } { } set test "load and run script with -x" if { $res != 0} { fail $test - return -1 + return } # The script loaded via -x contains a run command; while running, GDB # is expected to print three messages from dprintf breakpoints along # with three interspersed messages from an ordinary breakpoint (which diff --git a/gdb/testsuite/gdb.base/dprintf-next.exp b/gdb/testsuite/gdb.base/dprintf-next.exp index 6ddf949c531d..325478fb4717 100644 --- a/gdb/testsuite/gdb.base/dprintf-next.exp +++ b/gdb/testsuite/gdb.base/dprintf-next.exp @@ -19,15 +19,15 @@ set expfile $testfile.exp set dp_location [gdb_get_line_number "Set dprintf here"] if {[prepare_for_testing "failed to prepare for dprintf with next" \ ${testfile} ${srcfile} {debug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "dprintf $dp_location, \"%d\\n\", x" \ "Dprintf .*" diff --git a/gdb/testsuite/gdb.base/dprintf-non-stop.exp b/gdb/testsuite/gdb.base/dprintf-non-stop.exp index 3807a7b6623f..89b1c894c04b 100644 --- a/gdb/testsuite/gdb.base/dprintf-non-stop.exp +++ b/gdb/testsuite/gdb.base/dprintf-non-stop.exp @@ -16,20 +16,20 @@ standard_testfile set executable ${testfile} if {[build_executable "failed to prepare for dprintf with non-stop" \ ${testfile} ${srcfile} {debug}]} { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" clean_restart ${executable} } if {![runto_main]} { - return -1 + return } gdb_test "dprintf foo,\"At foo entry\\n\"" "Dprintf .*" gdb_test "continue &" "Continuing\\." diff --git a/gdb/testsuite/gdb.base/dprintf-pending.exp b/gdb/testsuite/gdb.base/dprintf-pending.exp index ec101f2bdc77..5b13cfda595a 100644 --- a/gdb/testsuite/gdb.base/dprintf-pending.exp +++ b/gdb/testsuite/gdb.base/dprintf-pending.exp @@ -25,11 +25,11 @@ set lib_opts debug set exec_opts [list debug shlib=$lib_sl] if { [gdb_compile_shlib $libsrc $lib_sl $lib_opts] != "" || [gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} { untested "failed to compile shared library" - return -1 + return } with_test_prefix "without format" { clean_restart diff --git a/gdb/testsuite/gdb.base/dprintf.exp b/gdb/testsuite/gdb.base/dprintf.exp index ef1f09443c1e..9896f2c19246 100644 --- a/gdb/testsuite/gdb.base/dprintf.exp +++ b/gdb/testsuite/gdb.base/dprintf.exp @@ -18,18 +18,18 @@ standard_testfile set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if { [prepare_for_testing "failed to prepare" $testfile $srcfile $flags] } { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set dp_location1 [gdb_get_line_number "set dprintf 1 here"] if {![runto_main]} { - return -1 + return } gdb_test "dprintf" "Format string required" gdb_test "dprintf foo" "Format string required" diff --git a/gdb/testsuite/gdb.base/dump.exp b/gdb/testsuite/gdb.base/dump.exp index 84be9df6d6ef..798cca9a6b0a 100644 --- a/gdb/testsuite/gdb.base/dump.exp +++ b/gdb/testsuite/gdb.base/dump.exp @@ -92,11 +92,11 @@ remote_exec host "rm -f $filenames" # Run target program until data structs are initialized. if {![runto checkpoint1]} { untested "couldn't run to checkpoint" - return -1 + return } # Get the endianness for the later use with endianless formats. set endian [get_endianness] diff --git a/gdb/testsuite/gdb.base/dup-sect.exp b/gdb/testsuite/gdb.base/dup-sect.exp index a2c74f51a6cd..ef9ba340ae24 100644 --- a/gdb/testsuite/gdb.base/dup-sect.exp +++ b/gdb/testsuite/gdb.base/dup-sect.exp @@ -35,11 +35,11 @@ if {![istarget *-*-linux*] standard_testfile .S set srcmainfile start.c set executable ${testfile} if {[build_executable ${testfile}.exp $executable [list ${srcfile} ${srcmainfile}] {}] == -1} { - return -1 + return } set test "rename section" set objcopy_program [gdb_find_objcopy] set result [catch {exec $objcopy_program --rename-section sect2=sect1 $binfile} output] diff --git a/gdb/testsuite/gdb.base/duplicate-bp.exp b/gdb/testsuite/gdb.base/duplicate-bp.exp index 959eb7697d93..5fd96928e2e9 100644 --- a/gdb/testsuite/gdb.base/duplicate-bp.exp +++ b/gdb/testsuite/gdb.base/duplicate-bp.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if { [build_executable "failed to prepare" ${testfile}] } { - return -1 + return } # Setup for the test, create COUNT breakpoints at the function BREAKPT. proc test_setup { count } { global srcfile diff --git a/gdb/testsuite/gdb.base/early-init-file.exp b/gdb/testsuite/gdb.base/early-init-file.exp index b609e2c19920..cbbfefa6912f 100644 --- a/gdb/testsuite/gdb.base/early-init-file.exp +++ b/gdb/testsuite/gdb.base/early-init-file.exp @@ -20,11 +20,11 @@ require {!is_remote host} standard_testfile # Compile the test executable. if {[build_executable "failed to build" $testfile $srcfile]} { - return -1 + return } set custom_signal_handle_re \ "warning: Found custom handler for signal $decimal \(\[^\r\n\]+\) preinstalled\." set signal_dispositions_re \ diff --git a/gdb/testsuite/gdb.base/eh_return.exp b/gdb/testsuite/gdb.base/eh_return.exp index 55cca9362d38..c6f1d7375c58 100644 --- a/gdb/testsuite/gdb.base/eh_return.exp +++ b/gdb/testsuite/gdb.base/eh_return.exp @@ -52,11 +52,11 @@ if {[istarget "powerpc*"]} { set compile_flags {debug nopie} } if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ $compile_flags]} { - return -1 + return } set address -1 # Get the address of the last insn in function eh2. diff --git a/gdb/testsuite/gdb.base/ena-dis-br.exp b/gdb/testsuite/gdb.base/ena-dis-br.exp index bdf54d083f08..5f208644a366 100644 --- a/gdb/testsuite/gdb.base/ena-dis-br.exp +++ b/gdb/testsuite/gdb.base/ena-dis-br.exp @@ -21,11 +21,11 @@ standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location7 [gdb_get_line_number "set breakpoint 7 here"] set bp_location8 [gdb_get_line_number "set breakpoint 8 here" $srcfile2] diff --git a/gdb/testsuite/gdb.base/endianity.exp b/gdb/testsuite/gdb.base/endianity.exp index 661a83d5e543..0da319a824cd 100644 --- a/gdb/testsuite/gdb.base/endianity.exp +++ b/gdb/testsuite/gdb.base/endianity.exp @@ -43,10 +43,10 @@ gdb_test "print o" "= {v = 4, w = 3, x = 2, f = 1.5, cplx = 1.25 \\+ 7.25i, d = if { !$test_sso } { # The rest of the testcase requires Scalar Storage Order support. # This compiler does not support it, so skip the rest. unsupported "No scalar storage order support" - return -1 + return } gdb_test "x/x &o.v" "0x04000000" gdb_test "x/xh &o.w" "0x0300" diff --git a/gdb/testsuite/gdb.base/ending-run.exp b/gdb/testsuite/gdb.base/ending-run.exp index 4dac31eb0596..c8d3672cd87d 100644 --- a/gdb/testsuite/gdb.base/ending-run.exp +++ b/gdb/testsuite/gdb.base/ending-run.exp @@ -26,11 +26,11 @@ standard_testfile set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if { [prepare_for_testing "failed to prepare" $testfile $srcfile $flags] } { - return -1 + return } remote_exec build "rm -f core" set break1_line [gdb_get_line_number "-break1-"] gdb_test "b ending-run.c:$break1_line" \ diff --git a/gdb/testsuite/gdb.base/enum_cond.exp b/gdb/testsuite/gdb.base/enum_cond.exp index 9d660fe05576..0421ea37d8f7 100644 --- a/gdb/testsuite/gdb.base/enum_cond.exp +++ b/gdb/testsuite/gdb.base/enum_cond.exp @@ -33,11 +33,11 @@ lappend opts additional_flags=-fshort-enums lappend opts additional_flags=-nostdlib lappend opts additional_flags=-DHAVE_BUILTIN_TRAP=[have_builtin_trap] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $opts] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/enumval.exp b/gdb/testsuite/gdb.base/enumval.exp index aab68ba07304..6942d0265b5b 100644 --- a/gdb/testsuite/gdb.base/enumval.exp +++ b/gdb/testsuite/gdb.base/enumval.exp @@ -16,11 +16,11 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Check the real contents. set test "print e" diff --git a/gdb/testsuite/gdb.base/eu-strip-infcall.exp b/gdb/testsuite/gdb.base/eu-strip-infcall.exp index be1793305dcc..73df0e5650bb 100644 --- a/gdb/testsuite/gdb.base/eu-strip-infcall.exp +++ b/gdb/testsuite/gdb.base/eu-strip-infcall.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[build_executable ${testfile}.exp $testfile] == -1} { - return -1 + return } set test "eu-strip" set status [remote_exec build "eu-strip -f ${binfile}.debug $binfile"] if {[lindex $status 0] != 0} { @@ -27,9 +27,9 @@ if {[lindex $status 0] != 0} { } clean_restart $testfile if {![runto_main]} { - return -1 + return } gdb_test "p callfunc (func)" " = 2" "infcall" diff --git a/gdb/testsuite/gdb.base/eval-avoid-side-effects.exp b/gdb/testsuite/gdb.base/eval-avoid-side-effects.exp index ce0e1cfa8738..1a6d76cad8d2 100644 --- a/gdb/testsuite/gdb.base/eval-avoid-side-effects.exp +++ b/gdb/testsuite/gdb.base/eval-avoid-side-effects.exp @@ -17,15 +17,15 @@ # flag set. standard_testfile int-type.c if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set sizeof_int [get_sizeof "int" 4] gdb_test_no_output "set variable x=42" "set variable x=42" diff --git a/gdb/testsuite/gdb.base/examine-backward.exp b/gdb/testsuite/gdb.base/examine-backward.exp index 76a904ad7a47..9f986374ebc8 100644 --- a/gdb/testsuite/gdb.base/examine-backward.exp +++ b/gdb/testsuite/gdb.base/examine-backward.exp @@ -17,15 +17,15 @@ # number in the 'x' command. standard_testfile if { [prepare_for_testing "failed to prepare for examine-backward" \ ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } proc get_first_mapped_address {} { global gdb_prompt diff --git a/gdb/testsuite/gdb.base/exe-lock.exp b/gdb/testsuite/gdb.base/exe-lock.exp index d6ad59172f3e..c4c6585cf7f8 100644 --- a/gdb/testsuite/gdb.base/exe-lock.exp +++ b/gdb/testsuite/gdb.base/exe-lock.exp @@ -29,11 +29,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { # Sanity-check: Verify that the executable exists. This is just to # make sure that, when we verify later that the file does not exist, # it really has been deleted. if { ! [file exists $binfile] } { fail "executable does not exist (${binfile})" - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/execl-update-breakpoints.exp b/gdb/testsuite/gdb.base/execl-update-breakpoints.exp index 5f96b7039978..98d38c9ccefa 100644 --- a/gdb/testsuite/gdb.base/execl-update-breakpoints.exp +++ b/gdb/testsuite/gdb.base/execl-update-breakpoints.exp @@ -29,25 +29,25 @@ set exec1 [standard_output_file $testfile1] set exec2 [standard_output_file $testfile2] if { [gdb_compile [file join $srcdir $subdir $srcfile] $objfile \ object [list debug]] != "" } { untested "failed to compile" - return -1 + return } if { [gdb_compile $objfile $exec1 executable {debug text_segment=0x1000000}] != "" || [gdb_compile $objfile $exec2 executable {debug text_segment=0x2000000}] != ""} { untested "link failed" - return -1 + return } # First check whether the address of "main" in exec1 is readable in # exec2. If it is, then skip the test as unsupported. clean_restart $testfile1 if {![runto_main]} { - return -1 + return } set addr "" set test "main address first" gdb_test_multiple "p/x &main" $test { @@ -57,11 +57,11 @@ gdb_test_multiple "p/x &main" $test { } } clean_restart $testfile2 if {![runto_main]} { - return -1 + return } set cannot_access 0 set test "probe memory access" gdb_test_multiple "x $addr" $test { diff --git a/gdb/testsuite/gdb.base/execution-termios.exp b/gdb/testsuite/gdb.base/execution-termios.exp index f82b62afc985..c448b1e29139 100644 --- a/gdb/testsuite/gdb.base/execution-termios.exp +++ b/gdb/testsuite/gdb.base/execution-termios.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . */ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Run to main, and execute BODY in the caller's context, with PREFIX # set as test message prefix. diff --git a/gdb/testsuite/gdb.base/exitsignal.exp b/gdb/testsuite/gdb.base/exitsignal.exp index 7bbf82db79c4..aa2710450b50 100644 --- a/gdb/testsuite/gdb.base/exitsignal.exp +++ b/gdb/testsuite/gdb.base/exitsignal.exp @@ -24,19 +24,19 @@ require {!target_info exists gdb,nosignals} standard_testfile segv.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Run to main. But, before, change cwd to get the core into the # output directory. set_inferior_cwd_to_output_dir if { ![runto_main] } { - return -1 + return } # Get the inferior's PID for later. set pid [get_inferior_pid] @@ -83,11 +83,11 @@ gdb_test "print \$_exitcode" " = void" \ # Now we test the behavior of $_exit{code,signal} during a normal # inferior execution. standard_testfile normal.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Checking $_exitsignal and $_exitcode, both should be void before the # inferior is executed. gdb_test "print \$_exitsignal" " = void" \ @@ -95,11 +95,11 @@ gdb_test "print \$_exitsignal" " = void" \ gdb_test "print \$_exitcode" " = void" \ "\$_exitcode is void before normal inferior is executed" # Run the inferior until the end. if { ![runto_main] } { - return -1 + return } gdb_continue_to_end # Checking $_exitcode. It should be 0. diff --git a/gdb/testsuite/gdb.base/expand-psymtabs.exp b/gdb/testsuite/gdb.base/expand-psymtabs.exp index cd29d1098f4b..fb670204dcb1 100644 --- a/gdb/testsuite/gdb.base/expand-psymtabs.exp +++ b/gdb/testsuite/gdb.base/expand-psymtabs.exp @@ -32,10 +32,10 @@ standard_testfile # We intentionally compile the source file in twice. if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug $srcfile {debug additional_flags=-DFIRST} \ $srcfile debug]]} { - return -1 + return } set foo_bp [gdb_get_line_number "Break here"] gdb_test "break $foo_bp" "Breakpoint.*" "expand psymtabs" diff --git a/gdb/testsuite/gdb.base/fileio.exp b/gdb/testsuite/gdb.base/fileio.exp index d33c8224a10f..b68645e8bb64 100644 --- a/gdb/testsuite/gdb.base/fileio.exp +++ b/gdb/testsuite/gdb.base/fileio.exp @@ -27,11 +27,11 @@ if {[is_remote host]} { if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable \ [list debug additional_flags=[quote_for_host -DOUTDIR=\"$outdir/\"]]] != "" } { untested "failed to compile" - return -1 + return } set dir2 [standard_output_file dir2.fileio.test] if {[file exists $dir2] && ![file writable $dir2]} { system "chmod +w $dir2" diff --git a/gdb/testsuite/gdb.base/filesym.exp b/gdb/testsuite/gdb.base/filesym.exp index 50018b6ae5a5..0ec92c2686d5 100644 --- a/gdb/testsuite/gdb.base/filesym.exp +++ b/gdb/testsuite/gdb.base/filesym.exp @@ -17,16 +17,16 @@ # on a name which is potentially both a symbol name and a file name. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if { ![readline_is_used] } { unsupported "completion doesn't work when readline isn't used." - return -1 + return } # Test completion list for "filesy". We expect the immediate result to # complete to "filesym"; completing again, we expect the symbol name and the diff --git a/gdb/testsuite/gdb.base/find-unmapped.exp b/gdb/testsuite/gdb.base/find-unmapped.exp index 3e67b4dd83e1..5c75db1680af 100644 --- a/gdb/testsuite/gdb.base/find-unmapped.exp +++ b/gdb/testsuite/gdb.base/find-unmapped.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto breakpt]} { - return -1 + return } # Basic attempt to read memory from globals. gdb_test "x/5w global_var_1" \ "$hex:\[ \t\]+0\[ \t\]+0\[ \t\]+0\[ \t\]+0\r\n$hex:\[ \t\]+Cannot access memory at address $hex" diff --git a/gdb/testsuite/gdb.base/finish-pretty.exp b/gdb/testsuite/gdb.base/finish-pretty.exp index ee87380a6706..6b79add3a204 100644 --- a/gdb/testsuite/gdb.base/finish-pretty.exp +++ b/gdb/testsuite/gdb.base/finish-pretty.exp @@ -23,11 +23,11 @@ lappend opts debug if { [have_fvar_tracking] } { lappend opts "additional_flags=-fvar-tracking" } if { [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] } { - return -1 + return } proc finish_pretty { } { if {![runto foo]} { return diff --git a/gdb/testsuite/gdb.base/finish.exp b/gdb/testsuite/gdb.base/finish.exp index f15106f1fd0f..973f4cf3f742 100644 --- a/gdb/testsuite/gdb.base/finish.exp +++ b/gdb/testsuite/gdb.base/finish.exp @@ -17,11 +17,11 @@ set allow_float_test [allow_float_test] # re-use the program from the "return2" test. if { [prepare_for_testing "failed to prepare" finish return2.c] } { - return -1 + return } proc finish_1 { type } { global gdb_prompt diff --git a/gdb/testsuite/gdb.base/float.exp b/gdb/testsuite/gdb.base/float.exp index 87e522c0983a..5777cbc3a310 100644 --- a/gdb/testsuite/gdb.base/float.exp +++ b/gdb/testsuite/gdb.base/float.exp @@ -22,11 +22,11 @@ # Test floating-point related functionality. # if { [prepare_for_testing "failed to prepare" float float.c] } { - return -1 + return } # Set it up at a breakpoint so we have its registers. if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/float128.exp b/gdb/testsuite/gdb.base/float128.exp index a02ae20f29c2..37aa51364161 100644 --- a/gdb/testsuite/gdb.base/float128.exp +++ b/gdb/testsuite/gdb.base/float128.exp @@ -25,11 +25,11 @@ proc do_compile { {opts {}} } { gdb_compile "${srcdir}/${subdir}/${srcfile}" "$binfile" executable $ccopts } if { [do_compile] != "" && [do_compile {-mfloat128}] != "" } { untested "compiler can't handle __float128 type?" - return -1 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/floatn.exp b/gdb/testsuite/gdb.base/floatn.exp index d086fcb9185b..8f6d4f03bafc 100644 --- a/gdb/testsuite/gdb.base/floatn.exp +++ b/gdb/testsuite/gdb.base/floatn.exp @@ -25,11 +25,11 @@ proc do_compile { {opts {}} } { gdb_compile "${srcdir}/${subdir}/${srcfile}" "$binfile" executable $ccopts } if { [do_compile] != "" && [do_compile {-mfloat128}] != "" } { untested "compiler can't handle _FloatN/_FloatNx types?" - return -1 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/foll-fork-syscall.exp b/gdb/testsuite/gdb.base/foll-fork-syscall.exp index 580a130bc520..0452d403c62a 100644 --- a/gdb/testsuite/gdb.base/foll-fork-syscall.exp +++ b/gdb/testsuite/gdb.base/foll-fork-syscall.exp @@ -23,11 +23,11 @@ require {is_any_target "i?86-*-*" "x86_64-*-*"} require allow_fork_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc setup_gdb {} { global testfile diff --git a/gdb/testsuite/gdb.base/foll-fork.exp b/gdb/testsuite/gdb.base/foll-fork.exp index 671bcf385431..0cd16001c336 100644 --- a/gdb/testsuite/gdb.base/foll-fork.exp +++ b/gdb/testsuite/gdb.base/foll-fork.exp @@ -20,11 +20,11 @@ require !gdb_debug_enabled require allow_fork_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Restart GDB and run the inferior to main. Return 1 on success, 0 on failure. proc setup {} { diff --git a/gdb/testsuite/gdb.base/foll-vfork.exp b/gdb/testsuite/gdb.base/foll-vfork.exp index 1a387772c4cc..d58b64095f7c 100644 --- a/gdb/testsuite/gdb.base/foll-vfork.exp +++ b/gdb/testsuite/gdb.base/foll-vfork.exp @@ -26,21 +26,21 @@ set binfile $testfile set binfile2 ${testfile}-exit set binfile3 vforked-prog if {[build_executable "compile $binfile" $binfile $srcfile] == -1} { untested "failed to compile first test binary" - return -1 + return } if {[build_executable "compile $binfile2" $binfile2 $srcfile2] == -1} { untested "failed to compile second test binary" - return -1 + return } if {[build_executable "compile $binfile3" $binfile3 $srcfile3] == -1} { untested "failed to compile third test binary" - return -1 + return } # If required, download the program that we exec after vfork to the # remote target. if { [is_remote target] } { diff --git a/gdb/testsuite/gdb.base/fork-print-inferior-events.exp b/gdb/testsuite/gdb.base/fork-print-inferior-events.exp index 1bb5d70d714f..27b71e7e9772 100644 --- a/gdb/testsuite/gdb.base/fork-print-inferior-events.exp +++ b/gdb/testsuite/gdb.base/fork-print-inferior-events.exp @@ -29,11 +29,11 @@ require !use_gdb_stub require !gdb_debug_enabled standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } # This is the expected output for each of the test combinations # below. The order here is important: # diff --git a/gdb/testsuite/gdb.base/fortran-sym-case.exp b/gdb/testsuite/gdb.base/fortran-sym-case.exp index 403ea46d75e2..2ebb358c82d5 100644 --- a/gdb/testsuite/gdb.base/fortran-sym-case.exp +++ b/gdb/testsuite/gdb.base/fortran-sym-case.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "set language fortran" {Warning: the current language does not match this frame\.} gdb_test "frame" ", aRGv=.*" diff --git a/gdb/testsuite/gdb.base/frame-info-consistent.exp b/gdb/testsuite/gdb.base/frame-info-consistent.exp index 5ad825c33e2b..f1ab8b0cc550 100644 --- a/gdb/testsuite/gdb.base/frame-info-consistent.exp +++ b/gdb/testsuite/gdb.base/frame-info-consistent.exp @@ -24,11 +24,11 @@ standard_testfile backtrace.c set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/attributes.h if { [build_executable "failed to prepare" $testfile $srcfile $flags] } { - return -1 + return } # Unwind to each function in FRAMES, and compare "info frame" output # to what was saved in the 'info_frame_before' array. proc compare_frames {frames} { diff --git a/gdb/testsuite/gdb.base/frame-selection.exp b/gdb/testsuite/gdb.base/frame-selection.exp index a7e99a4dffd8..b3fb5e13d251 100644 --- a/gdb/testsuite/gdb.base/frame-selection.exp +++ b/gdb/testsuite/gdb.base/frame-selection.exp @@ -17,11 +17,11 @@ # 'select-frame', and 'info frame' commands. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug}]} { - return -1 + return } runto_main gdb_breakpoint frame_2 gdb_continue_to_breakpoint frame_2 diff --git a/gdb/testsuite/gdb.base/frame-unwind-disable.exp b/gdb/testsuite/gdb.base/frame-unwind-disable.exp index e483b9e9904a..3d6e098abfdd 100644 --- a/gdb/testsuite/gdb.base/frame-unwind-disable.exp +++ b/gdb/testsuite/gdb.base/frame-unwind-disable.exp @@ -72,11 +72,11 @@ proc check_unwinder_class { unwinder_class state {testname ""} } { } } } if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { untested "couldn't run to main" return diff --git a/gdb/testsuite/gdb.base/frameapply.exp b/gdb/testsuite/gdb.base/frameapply.exp index 73650052ad9e..7525ba5085c5 100644 --- a/gdb/testsuite/gdb.base/frameapply.exp +++ b/gdb/testsuite/gdb.base/frameapply.exp @@ -19,11 +19,11 @@ # Test 'frame apply [all | COUNT | -COUNT | level LEVEL...] [FLAG]... COMMAND'. standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto setup_done]} { return 0 } diff --git a/gdb/testsuite/gdb.base/freebpcmd.exp b/gdb/testsuite/gdb.base/freebpcmd.exp index 0c545b671678..8fe8dab13e95 100644 --- a/gdb/testsuite/gdb.base/freebpcmd.exp +++ b/gdb/testsuite/gdb.base/freebpcmd.exp @@ -44,11 +44,11 @@ # suggestions for improving this. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "break ${srcfile}:[gdb_get_line_number "euphonium"]" ".*" \ "set breakpoint" diff --git a/gdb/testsuite/gdb.base/fullname.exp b/gdb/testsuite/gdb.base/fullname.exp index 8572eeaf5ab1..7f46cb56d858 100644 --- a/gdb/testsuite/gdb.base/fullname.exp +++ b/gdb/testsuite/gdb.base/fullname.exp @@ -25,16 +25,16 @@ require {!is_remote host} # Create a temporary file in the build directory. Use a different # filename in case ${srcdir} == ${objdir}. if { [catch {file copy -force ${srcdir}/${subdir}/${srcfile} \ [standard_output_file tmp-${srcfile}]}] != 0 } { error "Could not create temporary file" - return -1 + return } # Build the test executable using an absolute path. if { [gdb_compile [standard_output_file tmp-${srcfile}] "${binfile}" executable {debug}] != "" } { - return -1 + return } # Unlike most GDB tests, we do not use gdb_reinitialize_dir in this script. # We're testing GDB's ability to find files in other ways. @@ -65,11 +65,11 @@ if { [gdb_breakpoint [standard_output_file tmp-${srcfile}]:${line} {no-message}] } # Build the test executable using a relative path. if { [gdb_compile [relative_filename [pwd] [build_standard_output_file tmp-${srcfile}]] \ "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart $testfile set msg "set breakpoint by full path before loading symbols - built relative" diff --git a/gdb/testsuite/gdb.base/fullpath-expand.exp b/gdb/testsuite/gdb.base/fullpath-expand.exp index a470c1e2e978..053eb9b59f0a 100644 --- a/gdb/testsuite/gdb.base/fullpath-expand.exp +++ b/gdb/testsuite/gdb.base/fullpath-expand.exp @@ -19,11 +19,11 @@ standard_testfile .c fullpath-expand-func.c # directory. require {!is_remote host} if { [file pathtype $objdir] != "absolute" } { untested "objdir $objdir is not absolute" - return -1 + return } with_cwd $srcdir { set err [gdb_compile "${subdir}/${srcfile} ${subdir}/${srcfile2}" $binfile executable {debug}] @@ -34,11 +34,11 @@ with_cwd $srcdir { } set result [catch {exec realpath ${srcdir}/${subdir}/${srcfile2}} realsrcfile2] if { $result != 0 || $realsrcfile2 == "" } { untested "invalid realpath of ${srcfile2}: result $result output $realsrcfile2" - return -1 + return } clean_restart ${testfile} gdb_test "rbreak $realsrcfile2:func" \ diff --git a/gdb/testsuite/gdb.base/func-ptr.exp b/gdb/testsuite/gdb.base/func-ptr.exp index 8cc148ded9d3..0f656d127807 100644 --- a/gdb/testsuite/gdb.base/func-ptr.exp +++ b/gdb/testsuite/gdb.base/func-ptr.exp @@ -16,11 +16,11 @@ # This testcase exercises bug 15695. # Trying to print foo->bar if foo is a pointer to a typedef of a pointer # to a function will put gdb into an infinite loop. if { [prepare_for_testing "failed to prepare" "func-ptr" {func-ptr.c} {debug}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/func-ptrs.exp b/gdb/testsuite/gdb.base/func-ptrs.exp index 66c3daac7a91..a36bc2559c04 100644 --- a/gdb/testsuite/gdb.base/func-ptrs.exp +++ b/gdb/testsuite/gdb.base/func-ptrs.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . set testname func-ptrs set srcfile ${testname}.c if { [prepare_for_testing "failed to prepare" ${testname} ${srcfile}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # First set our breakpoints. diff --git a/gdb/testsuite/gdb.base/funcargs.exp b/gdb/testsuite/gdb.base/funcargs.exp index 4a2d96e1b3e4..fdfdf07b78c6 100644 --- a/gdb/testsuite/gdb.base/funcargs.exp +++ b/gdb/testsuite/gdb.base/funcargs.exp @@ -26,11 +26,11 @@ if {[support_complex_tests]} { } set allow_float_test [allow_float_test] if {[prepare_for_testing "failed to prepare" $testfile $srcfile $compile_flags]} { - return -1 + return } # # Locate actual args; integral types. # diff --git a/gdb/testsuite/gdb.base/gcore-buffer-overflow.exp b/gdb/testsuite/gdb.base/gcore-buffer-overflow.exp index 3dcc4f00d0a6..ad9bd89226df 100644 --- a/gdb/testsuite/gdb.base/gcore-buffer-overflow.exp +++ b/gdb/testsuite/gdb.base/gcore-buffer-overflow.exp @@ -30,10 +30,10 @@ if { [prepare_for_testing "prepare" $filename $srcfile] != 0 } { gdb_test_no_output "set args ${pattern}" \ "set buffer exceeding arguments" if {![runto_main]} { - return -1 + return } gdb_gcore_cmd [standard_output_file gcore-buffer-overflow.test] \ "save a corefile" diff --git a/gdb/testsuite/gdb.base/gcore-memory-usage.exp b/gdb/testsuite/gdb.base/gcore-memory-usage.exp index fc57d1604e29..e9a0f2a69e4b 100644 --- a/gdb/testsuite/gdb.base/gcore-memory-usage.exp +++ b/gdb/testsuite/gdb.base/gcore-memory-usage.exp @@ -19,11 +19,11 @@ require {istarget "*-*-linux*"} require can_spawn_for_attach standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug}] == -1} { - return -1 + return } # Read the proc_pid_status page, to find how much memory the given # PID is using. This is meant to be used to find the # memory usage for the GDB in this test. diff --git a/gdb/testsuite/gdb.base/gcore-relro-pie.exp b/gdb/testsuite/gdb.base/gcore-relro-pie.exp index 5730f89eadf6..85abc100dff6 100644 --- a/gdb/testsuite/gdb.base/gcore-relro-pie.exp +++ b/gdb/testsuite/gdb.base/gcore-relro-pie.exp @@ -19,20 +19,20 @@ standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pie "ldflags=-Wl,-z,relro"}]} { - return -1 + return } set stripped_binfile ${binfile}.stripped set gcorefile ${binfile}.gcore set strip_program [transform strip] remote_file host delete ${stripped_binfile} if {[run_on_host "strip" "$strip_program" "-g -o ${stripped_binfile} $binfile"]} { - return -1 + return } # Workaround PR binutils/10802: # Preserve the 'x' bit also for PIEs (Position Independent Executables). set perm [file attributes ${binfile} -permissions] @@ -41,15 +41,15 @@ file attributes ${stripped_binfile} -permissions $perm clean_restart gdb_load $stripped_binfile # The binary is stripped of debug info, but not minsyms. if {![runto break_here]} { - return -1 + return } if {![gdb_gcore_cmd $gcorefile "save a corefile"]} { - return -1 + return } # Now restart gdb with the unstripped binary and load the corefile. clean_restart $testfile diff --git a/gdb/testsuite/gdb.base/gcore-tls-pie.exp b/gdb/testsuite/gdb.base/gcore-tls-pie.exp index fa3cda88c3f4..8306142cc807 100644 --- a/gdb/testsuite/gdb.base/gcore-tls-pie.exp +++ b/gdb/testsuite/gdb.base/gcore-tls-pie.exp @@ -18,25 +18,25 @@ # and then try to debug the core with the unstripped version. standard_testfile if { [have_fuse_ld_gold] == 0} { - return -1 + return } if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pie "ldflags=-fuse-ld=gold"}]} { - return -1 + return } set stripped_binfile ${binfile}.stripped set gcorefile ${binfile}.gcore set strip_program [transform strip] remote_file host delete ${stripped_binfile} if {[run_on_host "strip" "$strip_program" "-g -o ${stripped_binfile} $binfile"]} { - return -1 + return } # Workaround PR binutils/10802: # Preserve the 'x' bit also for PIEs (Position Independent Executables). set perm [file attributes ${binfile} -permissions] @@ -45,15 +45,15 @@ file attributes ${stripped_binfile} -permissions $perm clean_restart gdb_load $stripped_binfile # The binary is stripped of debug info, but not minsyms. if {![runto break_here]} { - return -1 + return } if {![gdb_gcore_cmd $gcorefile "save a corefile"]} { - return -1 + return } # Now restart gdb with the unstripped binary and load the corefile. clean_restart $testfile diff --git a/gdb/testsuite/gdb.base/gcore.exp b/gdb/testsuite/gdb.base/gcore.exp index fa30f50a63c6..aa887b0da14d 100644 --- a/gdb/testsuite/gdb.base/gcore.exp +++ b/gdb/testsuite/gdb.base/gcore.exp @@ -19,15 +19,15 @@ require gcore_cmd_available standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break terminal_func" "Breakpoint .* at .*${srcfile}, line .*" \ "set breakpoint at terminal_func" diff --git a/gdb/testsuite/gdb.base/gdb-index-err.exp b/gdb/testsuite/gdb.base/gdb-index-err.exp index 6fcc8b6526de..4e6f15d5d9f1 100644 --- a/gdb/testsuite/gdb.base/gdb-index-err.exp +++ b/gdb/testsuite/gdb.base/gdb-index-err.exp @@ -17,20 +17,20 @@ # command. standard_testfile if {[prepare_for_testing "prepare for test" $testfile $srcfile] == -1} { - return -1 + return } # This test isn't going to work when the board file automatically adds # an index section, or if the debug information is split into a # separate objfile. set index_type [get_index_type $binfile "check debug style"] if { $index_type ne "cooked" } { unsupported "cannot test without a cooked index" - return -1 + return } # The name of a directory that doesn't exist. set bad_dir [standard_output_file "non-existent"] diff --git a/gdb/testsuite/gdb.base/gdb-sigterm.exp b/gdb/testsuite/gdb.base/gdb-sigterm.exp index ca3622d3462b..7c5b43de0855 100644 --- a/gdb/testsuite/gdb.base/gdb-sigterm.exp +++ b/gdb/testsuite/gdb.base/gdb-sigterm.exp @@ -24,11 +24,11 @@ standard_testfile # The test program exits after a while, in case GDB crashes. Make it # wait at least as long as we may wait before declaring a time out # failure. set options { "additional_flags=-DTIMEOUT=$timeout" debug } if { [build_executable ${testfile}.exp ${testfile} $srcfile $options] == -1 } { - return -1 + return } # Return 0 on success, non-zero otherwise. proc do_test { pass } { diff --git a/gdb/testsuite/gdb.base/gdb1090.exp b/gdb/testsuite/gdb.base/gdb1090.exp index 5e0e6e1047bc..2a2ff1a5ada2 100644 --- a/gdb/testsuite/gdb.base/gdb1090.exp +++ b/gdb/testsuite/gdb.base/gdb1090.exp @@ -23,11 +23,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 1 } diff --git a/gdb/testsuite/gdb.base/gdb11530.exp b/gdb/testsuite/gdb.base/gdb11530.exp index d27fde87d63e..fb293b986c7d 100644 --- a/gdb/testsuite/gdb.base/gdb11530.exp +++ b/gdb/testsuite/gdb.base/gdb11530.exp @@ -25,11 +25,11 @@ standard_testfile if { ![test_compiler_info gcc*] } { return 0 } if { [prepare_for_testing "failed to prepare" $testfile $testfile.c {debug}] } { - return -1 + return } if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.base/gdb11531.exp b/gdb/testsuite/gdb.base/gdb11531.exp index bbff1d2cea74..6ed23921f23e 100644 --- a/gdb/testsuite/gdb.base/gdb11531.exp +++ b/gdb/testsuite/gdb.base/gdb11531.exp @@ -28,11 +28,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $testfile.c {debug}] } { - return -1 + return } # Disable hardware watchpoints if necessary. if {!$allow_hw_watchpoint_tests_p} { gdb_test_no_output "set can-use-hw-watchpoints 0" "" diff --git a/gdb/testsuite/gdb.base/gdb1821.exp b/gdb/testsuite/gdb.base/gdb1821.exp index 1e79c0752dfb..a89fe9390ecb 100644 --- a/gdb/testsuite/gdb.base/gdb1821.exp +++ b/gdb/testsuite/gdb.base/gdb1821.exp @@ -23,11 +23,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/gdbvars.exp b/gdb/testsuite/gdb.base/gdbvars.exp index 1768b36c8b64..9522d5f2f39b 100644 --- a/gdb/testsuite/gdb.base/gdbvars.exp +++ b/gdb/testsuite/gdb.base/gdbvars.exp @@ -17,11 +17,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc test_convenience_variables {} { global gdb_prompt diff --git a/gdb/testsuite/gdb.base/gnu-debugdata.exp b/gdb/testsuite/gdb.base/gnu-debugdata.exp index e2addf418c9f..9bac264fce7c 100644 --- a/gdb/testsuite/gdb.base/gnu-debugdata.exp +++ b/gdb/testsuite/gdb.base/gnu-debugdata.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[build_executable ${testfile}.exp $testfile]} { - return -1 + return } set pipeline_counter 0 set objcopy_program [gdb_find_objcopy] @@ -67,72 +67,72 @@ proc pipeline {test args} { remote_file host delete ${binfile}.dynsyms if {[pipeline "nm -D" \ [list [transform nm] "-D ${binfile} --format=posix --defined-only"] \ [list awk "\\{print\\ \\\$1\\}"] \ [list sort "" "" "${binfile}.dynsyms"]]} { - return -1 + return } # Extract all the text (i.e. function) symbols from the debuginfo. # (Note that we actually also accept "D" symbols, for the benefit # of platforms like PowerPC64 that use function descriptors.) remote_file host delete ${binfile}.funcsyms if {[pipeline "nm" \ [list [transform nm] "${binfile} --format=posix --defined-only"] \ [list awk "\\{if(\\\$2==\"T\"||\\\$2==\"t\"||\\\$2==\"D\")print\\ \\\$1\\}"] \ [list sort "" "" "${binfile}.funcsyms"]]} { - return -1 + return } # Keep all the function symbols not already in the dynamic symbol # table. remote_file host delete ${binfile}.keep_symbols if {[run_on_host "comm" "comm" "-13 ${binfile}.dynsyms ${binfile}.funcsyms" "" \ "${binfile}.keep_symbols"]} { - return -1 + return } # GDB specific - we do not have split executable in advance. remote_file host delete ${binfile}.strip if {[run_on_host "strip" [transform strip] \ "--strip-all -R .comment -o ${binfile}.strip ${binfile}"]} { - return -1 + return } # Separate full debug info into ${binfile}.debug. remote_file host delete ${binfile}.debug if {[run_on_host "copydebug" ${objcopy_program} \ "--only-keep-debug ${binfile} ${binfile}.debug"]} { - return -1 + return } # Copy the full debuginfo, keeping only a minimal set of symbols and # removing some unnecessary sections. remote_file host delete ${binfile}.mini_debuginfo if {[run_on_host "objcopy 1" ${objcopy_program} "-S --remove-section .gdb_index --remove-section .comment --keep-symbols=${binfile}.keep_symbols ${binfile}.debug ${binfile}.mini_debuginfo"]} { - return -1 + return } # Add the .gnu_debuglink section to the .gnu_debugdata file. # .gnu_debuglink is normally not present in the .gnu_debugdata section but in # some files there may be PT_NOTE with NT_GNU_BUILD_ID and GDB could look up # the .debug file from it. This is only an additional test of GDB, such link # is not present in usual MiniDebugInfo sections. if {[run_on_host "addlink" ${objcopy_program} \ "--add-gnu-debuglink=${binfile}.debug ${binfile}.mini_debuginfo ${binfile}.mini_debuginfo-debuglink"]} { - return -1 + return } # Inject the compressed data into the .gnu_debugdata section of the # original binary. remote_file host delete ${binfile}.mini_debuginfo-debuglink.xz if {[run_on_host "xz" "xz" "-k ${binfile}.mini_debuginfo-debuglink"]} { - return -1 + return } remote_file host delete ${binfile}.test if {[run_on_host "objcopy 2" ${objcopy_program} "--add-section .gnu_debugdata=${binfile}.mini_debuginfo-debuglink.xz ${binfile}.strip ${binfile}.test"]} { - return -1 + return } clean_restart "$testfile.strip" gdb_test "p debugdata_function" \ diff --git a/gdb/testsuite/gdb.base/gnu_vector.exp b/gdb/testsuite/gdb.base/gnu_vector.exp index c1616fd32750..b92d82c3428c 100644 --- a/gdb/testsuite/gdb.base/gnu_vector.exp +++ b/gdb/testsuite/gdb.base/gnu_vector.exp @@ -41,11 +41,11 @@ if { [do_compile {-mcpu=native}] != "" } clean_restart $testfile if { ![runto_main] } { - return -1 + return } # Get endianess for the scalar->vector casts set endian [get_endianness] diff --git a/gdb/testsuite/gdb.base/gstack.exp b/gdb/testsuite/gdb.base/gstack.exp index 4297b5b4efac..bc524215d50b 100644 --- a/gdb/testsuite/gdb.base/gstack.exp +++ b/gdb/testsuite/gdb.base/gstack.exp @@ -17,11 +17,11 @@ require !gdb_protocol_is_remote require can_spawn_for_attach standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug}] == -1} { - return -1 + return } set command "$binfile" set res [remote_spawn host $command] if { ![gdb_assert { ![expr {$res < 0 || $res == ""}] } "spawn inferior"] } { diff --git a/gdb/testsuite/gdb.base/hashline1.exp b/gdb/testsuite/gdb.base/hashline1.exp index 9e4b73654580..238f90f8c9df 100644 --- a/gdb/testsuite/gdb.base/hashline1.exp +++ b/gdb/testsuite/gdb.base/hashline1.exp @@ -32,11 +32,11 @@ close $fd # The choice of path name for the source file is important in order to trigger # the bug. Using $new_srcfile here won't trigger the bug. set compile_name [relative_filename $objdir $new_srcfile] if { [gdb_compile $compile_name "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile set bp_location [gdb_get_line_number "set breakpoint here" $new_srcfile] diff --git a/gdb/testsuite/gdb.base/hashline2.exp b/gdb/testsuite/gdb.base/hashline2.exp index 4881f33d8373..400c0cfcf8ac 100644 --- a/gdb/testsuite/gdb.base/hashline2.exp +++ b/gdb/testsuite/gdb.base/hashline2.exp @@ -29,11 +29,11 @@ puts $fd "#line 2 \"///${new_srcfile}\"" puts $fd "int main () { return 0; } /* set breakpoint here */" close $fd if { [gdb_compile $new_srcfile "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile set bp_location [gdb_get_line_number "set breakpoint here" ${new_srcfile}] diff --git a/gdb/testsuite/gdb.base/hashline3.exp b/gdb/testsuite/gdb.base/hashline3.exp index 08c9184526a6..e5c44041937f 100644 --- a/gdb/testsuite/gdb.base/hashline3.exp +++ b/gdb/testsuite/gdb.base/hashline3.exp @@ -30,11 +30,11 @@ puts $fd "#line 2 \"./$relative\"" puts $fd "int main () { return 0; } /* set breakpoint here */" close $fd if { [gdb_compile $new_srcfile "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile set bp_location [gdb_get_line_number "set breakpoint here" $new_srcfile] diff --git a/gdb/testsuite/gdb.base/hbreak-in-shr-unsupported.exp b/gdb/testsuite/gdb.base/hbreak-in-shr-unsupported.exp index c4e6a9282d2c..9a0d84536982 100644 --- a/gdb/testsuite/gdb.base/hbreak-in-shr-unsupported.exp +++ b/gdb/testsuite/gdb.base/hbreak-in-shr-unsupported.exp @@ -37,11 +37,11 @@ if { [prepare_for_testing "prepare" $testfile $main_src $exec_opts] != 0 } { } gdb_load_shlib $lib_so if {![runto_main]} { - return -1 + return } # Get main breakpoint out of the way. delete_breakpoints diff --git a/gdb/testsuite/gdb.base/hbreak-unmapped.exp b/gdb/testsuite/gdb.base/hbreak-unmapped.exp index 43e62f4a1f71..f8bfcdaafdf2 100644 --- a/gdb/testsuite/gdb.base/hbreak-unmapped.exp +++ b/gdb/testsuite/gdb.base/hbreak-unmapped.exp @@ -16,15 +16,15 @@ require allow_hw_breakpoint_tests standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # If we can read the memory at address 0, skip the test. if { [is_address_zero_readable] } { untested "memory at address 0 is readable" diff --git a/gdb/testsuite/gdb.base/hbreak.exp b/gdb/testsuite/gdb.base/hbreak.exp index 87a4f40defe4..09947f7c7248 100644 --- a/gdb/testsuite/gdb.base/hbreak.exp +++ b/gdb/testsuite/gdb.base/hbreak.exp @@ -16,15 +16,15 @@ require allow_hw_breakpoint_tests set test hbreak set srcfile ${test}.c if { [prepare_for_testing "failed to prepare" ${test} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set breakline [gdb_get_line_number "break-at-exit"] gdb_test "hbreak ${srcfile}:${breakline}" \ diff --git a/gdb/testsuite/gdb.base/hbreak2.exp b/gdb/testsuite/gdb.base/hbreak2.exp index 4d18a4f0cee1..f090aeefee9c 100644 --- a/gdb/testsuite/gdb.base/hbreak2.exp +++ b/gdb/testsuite/gdb.base/hbreak2.exp @@ -18,11 +18,11 @@ # Only one hardware breakpoint is set at a time as targets may limit # the number available. if { [prepare_for_testing "failed to prepare" "hbreak2" {break.c break1.c} {debug nowarnings}] } { - return -1 + return } set srcfile break.c set srcfile1 break1.c if {![runto_main]} { @@ -515,11 +515,11 @@ test_next_with_recursion # Build a new file with optimization enabled so that we can try breakpoints # on targets with optimized prologues. if { [prepare_for_testing "failed to prepare" "hbreak2o2" {break.c break1.c} {debug nowarnings optimize=-O2}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/history-duplicates.exp b/gdb/testsuite/gdb.base/history-duplicates.exp index 58684fb5d431..ab51e0d1519b 100644 --- a/gdb/testsuite/gdb.base/history-duplicates.exp +++ b/gdb/testsuite/gdb.base/history-duplicates.exp @@ -55,11 +55,11 @@ gdb_exit gdb_start # These tests require readline support. if { ![readline_is_used] } { unsupported "readline isn't used." - return -1 + return } # By default the option is set to 0. gdb_test "show history remove-duplicates" "is 0\\." diff --git a/gdb/testsuite/gdb.base/hook-stop.exp b/gdb/testsuite/gdb.base/hook-stop.exp index 70cef1be92d7..de2fd14c7035 100644 --- a/gdb/testsuite/gdb.base/hook-stop.exp +++ b/gdb/testsuite/gdb.base/hook-stop.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if { [build_executable ${testfile}.exp "${testfile}" $srcfile {debug nowarnings}] } { - return -1 + return } # Define the hook-stop that runs COMMANDS. proc define_hook_stop {commands} { diff --git a/gdb/testsuite/gdb.base/hw-sw-break-same-address.exp b/gdb/testsuite/gdb.base/hw-sw-break-same-address.exp index 3fdb5d16fb2a..08d894e8f424 100644 --- a/gdb/testsuite/gdb.base/hw-sw-break-same-address.exp +++ b/gdb/testsuite/gdb.base/hw-sw-break-same-address.exp @@ -21,15 +21,15 @@ require allow_hw_breakpoint_tests set test hbreak set srcfile ${test}.c if { [prepare_for_testing "failed to prepare" ${test} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } delete_breakpoints gdb_test_no_output "set breakpoint always-inserted on" diff --git a/gdb/testsuite/gdb.base/include-main.exp b/gdb/testsuite/gdb.base/include-main.exp index a3972675f7de..b78dd51cd62a 100644 --- a/gdb/testsuite/gdb.base/include-main.exp +++ b/gdb/testsuite/gdb.base/include-main.exp @@ -16,11 +16,11 @@ # C test-case that mimics gdb.ada/dgopt.exp. standard_testfile .c main.c if { [build_executable "failed to prepare" $testfile $srcfile {debug}] } { - return -1 + return } clean_restart # Set language explicitly, to avoid expanding the include-main.c CU for the diff --git a/gdb/testsuite/gdb.base/included.exp b/gdb/testsuite/gdb.base/included.exp index 0b5dd2a1ed23..23bfd96c8404 100644 --- a/gdb/testsuite/gdb.base/included.exp +++ b/gdb/testsuite/gdb.base/included.exp @@ -17,11 +17,11 @@ if { [is_remote host] } { gdb_remote_download host $srcdir/$subdir/included.h } standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test_no_output "set listsize 1" gdb_test "list -q main" ".*" diff --git a/gdb/testsuite/gdb.base/infcall-exec.exp b/gdb/testsuite/gdb.base/infcall-exec.exp index 6b8bd605c090..1b47c6f5d6f9 100644 --- a/gdb/testsuite/gdb.base/infcall-exec.exp +++ b/gdb/testsuite/gdb.base/infcall-exec.exp @@ -22,23 +22,23 @@ set testfile2 "infcall-exec2" set srcfile2 "${testfile2}.c" set binfile2 [standard_output_file $testfile2] # Build the two executables for the test. if {[build_executable "build exec'd file" $testfile2 $srcfile2] != 0} { - return -1 + return } if {[prepare_for_testing "prepare" $testfile $srcfile] != 0} { - return -1 + return } if { [is_remote target] } { set binfile2 [gdb_remote_download target $binfile2] } if {![runto_main]} { - return -1 + return } set linenr [gdb_get_line_number "break here"] gdb_breakpoint $linenr gdb_continue_to_breakpoint "Ensure PATH is set" ".* break here .*" diff --git a/gdb/testsuite/gdb.base/infcall-input.exp b/gdb/testsuite/gdb.base/infcall-input.exp index c60e65bb4c52..a0b6ab28df3a 100644 --- a/gdb/testsuite/gdb.base/infcall-input.exp +++ b/gdb/testsuite/gdb.base/infcall-input.exp @@ -19,15 +19,15 @@ standard_testfile require {!target_info exists gdb,cannot_call_functions} if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Run an infcall that takes a little bit to complete. send_gdb "print some_function()\n" diff --git a/gdb/testsuite/gdb.base/inferior-died.exp b/gdb/testsuite/gdb.base/inferior-died.exp index a5006b363f5a..34434c82c20a 100644 --- a/gdb/testsuite/gdb.base/inferior-died.exp +++ b/gdb/testsuite/gdb.base/inferior-died.exp @@ -18,11 +18,11 @@ require allow_fork_tests require support_displaced_stepping standard_testfile .c if { [build_executable "failed to build" ${testfile} ${testfile}.c] } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" clean_restart $testfile diff --git a/gdb/testsuite/gdb.base/infnan.exp b/gdb/testsuite/gdb.base/infnan.exp index 18a0d235525d..6d635f268779 100644 --- a/gdb/testsuite/gdb.base/infnan.exp +++ b/gdb/testsuite/gdb.base/infnan.exp @@ -16,11 +16,11 @@ # Script to test floating point infinities and NaNs. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } runto_main gdb_test "print a" "${::valnum_re} = inf" diff --git a/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp b/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp index 674e48e3ee92..a1fffc51ea2b 100644 --- a/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp +++ b/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp @@ -27,11 +27,11 @@ # ... standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/info-macros.exp b/gdb/testsuite/gdb.base/info-macros.exp index 0b1e4a9ffdb6..1c2fcfb26641 100644 --- a/gdb/testsuite/gdb.base/info-macros.exp +++ b/gdb/testsuite/gdb.base/info-macros.exp @@ -17,15 +17,15 @@ standard_testfile .c # Fission doesn't support macros yet. Bug 15954. require !using_fission if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug macros}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Test various error messages. gdb_test "info macro -- -all" \ "The symbol `-all' has no definition .*\r\nat .*$srcfile:${::decimal}" diff --git a/gdb/testsuite/gdb.base/info-os.exp b/gdb/testsuite/gdb.base/info-os.exp index 632fa314cde8..0f14202ca0ea 100644 --- a/gdb/testsuite/gdb.base/info-os.exp +++ b/gdb/testsuite/gdb.base/info-os.exp @@ -16,23 +16,23 @@ standard_testfile .c # This test is Linux-only. if {![istarget *-*-linux*]} { unsupported "info-os.exp" - return -1 + return } # Support for XML-output is needed to run this test. require allow_xml_test # Compile test program. if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Get PID of test program. set inferior_pid "" set test "get inferior process ID" diff --git a/gdb/testsuite/gdb.base/info-proc.exp b/gdb/testsuite/gdb.base/info-proc.exp index 1210bcb9af1e..f1b435e249f3 100644 --- a/gdb/testsuite/gdb.base/info-proc.exp +++ b/gdb/testsuite/gdb.base/info-proc.exp @@ -58,11 +58,11 @@ if { ! [use_gdb_stub] } { # Set another environment variable, this time using a GDB command, # to test "info proc environ". gdb_test "set environment GDB_INFO_PROC_ENVIRON_2 TWO" if {![runto_main]} { - return -1 + return } gdb_test "info proc" "process ${decimal}.*" "info proc with process" gdb_test "info proc mapping" \ diff --git a/gdb/testsuite/gdb.base/info-shared.exp b/gdb/testsuite/gdb.base/info-shared.exp index e792b4f98210..41a47a30d7d6 100644 --- a/gdb/testsuite/gdb.base/info-shared.exp +++ b/gdb/testsuite/gdb.base/info-shared.exp @@ -25,16 +25,16 @@ set lib2name $testfile-solib2 set srcfile_lib2 $srcdir/$subdir/$lib2name.c set binfile_lib2 [standard_output_file $lib2name.so] if { [gdb_compile_shlib $srcfile_lib1 $binfile_lib1 {}] != "" } { untested "failed to compile shared library 1" - return -1 + return } if { [gdb_compile_shlib $srcfile_lib2 $binfile_lib2 {}] != "" } { untested "failed to compile shared library 2" - return -1 + return } set binfile_lib1_target [gdb_download_shlib $binfile_lib1] set binfile_lib2_target [gdb_download_shlib $binfile_lib2] @@ -42,11 +42,11 @@ set define2 -DSHLIB2_NAME=\"$binfile_lib2_target\" set define1 -DSHLIB1_NAME=\"$binfile_lib1_target\" set cflags "$define1 $define2" if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list additional_flags=$cflags shlib_load]] } { - return -1 + return } gdb_locate_shlib $binfile_lib1 gdb_locate_shlib $binfile_lib2 diff --git a/gdb/testsuite/gdb.base/info-target.exp b/gdb/testsuite/gdb.base/info-target.exp index 3427f175dd0e..91c89cbc4f8f 100644 --- a/gdb/testsuite/gdb.base/info-target.exp +++ b/gdb/testsuite/gdb.base/info-target.exp @@ -15,11 +15,11 @@ standard_testfile start.c if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } set eol "\r\n" # Check the output of "info target". Note that we are not interested diff --git a/gdb/testsuite/gdb.base/info-var.exp b/gdb/testsuite/gdb.base/info-var.exp index 4b3abcf04fcb..a112a30092f2 100644 --- a/gdb/testsuite/gdb.base/info-var.exp +++ b/gdb/testsuite/gdb.base/info-var.exp @@ -17,11 +17,11 @@ standard_testfile info-var-f1.c info-var-f2.c if {[prepare_for_testing "failed to prepare" \ "${testfile}" "$srcfile $srcfile2" "debug"]} { - return -1 + return } # Note: we do not run to main, as otherwise, the output of info variables # can be very long, showing thousands of glibc variables. # This long output then causes expect's buffer to overflow. diff --git a/gdb/testsuite/gdb.base/info_minsym.exp b/gdb/testsuite/gdb.base/info_minsym.exp index d99b1ada0ae9..43e3fd14eb0e 100644 --- a/gdb/testsuite/gdb.base/info_minsym.exp +++ b/gdb/testsuite/gdb.base/info_minsym.exp @@ -22,11 +22,11 @@ set testfile info_minsym standard_testfile info_minsym.c # Compile the program without debugging information, to have minimal symbols. if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c}]} { - return -1 + return } gdb_test_no_output "info variables -q -t int minsym" \ "minsym variables do not match type" gdb_test_no_output "info functions -q -t int minsym" \ diff --git a/gdb/testsuite/gdb.base/info_qt.exp b/gdb/testsuite/gdb.base/info_qt.exp index 471f12235885..40cd9547bae8 100644 --- a/gdb/testsuite/gdb.base/info_qt.exp +++ b/gdb/testsuite/gdb.base/info_qt.exp @@ -22,11 +22,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } if {![runto setup_done]} { return 0 } diff --git a/gdb/testsuite/gdb.base/info_sources.exp b/gdb/testsuite/gdb.base/info_sources.exp index ddf6e254a5b9..e661b0fc49ff 100644 --- a/gdb/testsuite/gdb.base/info_sources.exp +++ b/gdb/testsuite/gdb.base/info_sources.exp @@ -18,11 +18,11 @@ standard_testfile .c info_sources_base.c if {[prepare_for_testing $testfile.exp $testfile \ [list $srcfile $srcfile2] debug]} { untested $testfile.exp - return -1 + return } # Executes "info sources ARGS". # # EXPECT_SEEN_INFO_SOURCES 1 indicates that the source file info_sources.c @@ -67,11 +67,11 @@ proc test_info_sources {args expect_seen_info_sources \ } } } if {![runto_main]} { - return -1 + return } # List both files with no regexp: with_test_prefix "in main" { test_info_sources "" 1 1 diff --git a/gdb/testsuite/gdb.base/info_sources_2.exp b/gdb/testsuite/gdb.base/info_sources_2.exp index 8af48eeb3c49..3c8df2edc9d6 100644 --- a/gdb/testsuite/gdb.base/info_sources_2.exp +++ b/gdb/testsuite/gdb.base/info_sources_2.exp @@ -35,11 +35,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile \ set solib_name [gdb_load_shlib $solib_name] if {![runto foo]} { untested "failed to run to function foo" - return -1 + return } # Invoke 'info sources EXTRA_ARGS' and extract the results. # The results are then compared to the list ARGS. # diff --git a/gdb/testsuite/gdb.base/infoline-reloc-main-from-zero.exp b/gdb/testsuite/gdb.base/infoline-reloc-main-from-zero.exp index 02fc1dd89b0c..85bbe06c15fb 100644 --- a/gdb/testsuite/gdb.base/infoline-reloc-main-from-zero.exp +++ b/gdb/testsuite/gdb.base/infoline-reloc-main-from-zero.exp @@ -36,11 +36,11 @@ if { [gdb_can_simple_compile ld-flags {int main () { return 0; }} executable \ lappend opts $ld_flags } if {[build_executable $testfile.exp $testfile $srcfile $opts] == -1} { untested "failed to compile" - return -1 + return } clean_restart # Load symbols at an offset 0xffff0000 using add-symbol-file diff --git a/gdb/testsuite/gdb.base/infoline.exp b/gdb/testsuite/gdb.base/infoline.exp index 111e96e65603..3795f741cbcc 100644 --- a/gdb/testsuite/gdb.base/infoline.exp +++ b/gdb/testsuite/gdb.base/infoline.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } # Verify that the "info line" command does not skip function prologues. # If it did, GDB would tell us that the line we're interested in starts # at where N is different from zero. diff --git a/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp b/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp index fd9cba78f9ab..4bda78dd27d6 100644 --- a/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp +++ b/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp @@ -52,11 +52,11 @@ standard_testfile require allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/interp.exp b/gdb/testsuite/gdb.base/interp.exp index b47e717b0f73..d19d0e3ceca6 100644 --- a/gdb/testsuite/gdb.base/interp.exp +++ b/gdb/testsuite/gdb.base/interp.exp @@ -16,11 +16,11 @@ # interp.exp Test interpreter-exec command standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile {debug}] } { - return -1 + return } # Do not use gdb_test for this test, since it has two prompts. gdb_test_multiple "interpreter-exec mi \"-var-update *\"" "" { -re "\\^done,changelist=\\\[\\\]\r\n$gdb_prompt " { diff --git a/gdb/testsuite/gdb.base/interrupt-a.exp b/gdb/testsuite/gdb.base/interrupt-a.exp index fa5f5a281ab8..4599aa5eb5a1 100644 --- a/gdb/testsuite/gdb.base/interrupt-a.exp +++ b/gdb/testsuite/gdb.base/interrupt-a.exp @@ -17,15 +17,15 @@ standard_testfile .c set executable ${testfile} if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_multiple "continue &" "" { -re "Continuing\\.\r\n$gdb_prompt " { pass $gdb_test_name diff --git a/gdb/testsuite/gdb.base/interrupt-daemon-attach.exp b/gdb/testsuite/gdb.base/interrupt-daemon-attach.exp index d8411593e306..d6b241ea57a6 100644 --- a/gdb/testsuite/gdb.base/interrupt-daemon-attach.exp +++ b/gdb/testsuite/gdb.base/interrupt-daemon-attach.exp @@ -21,11 +21,11 @@ require {!target_info exists gdb,nointerrupts} require can_spawn_for_attach standard_testfile if { [build_executable ${testfile}.exp ${testfile} $srcfile {debug}] == -1 } { - return -1 + return } proc do_test {} { global binfile global decimal diff --git a/gdb/testsuite/gdb.base/interrupt-daemon.exp b/gdb/testsuite/gdb.base/interrupt-daemon.exp index 7b6276556c2b..fd9f2f8eefb8 100644 --- a/gdb/testsuite/gdb.base/interrupt-daemon.exp +++ b/gdb/testsuite/gdb.base/interrupt-daemon.exp @@ -19,11 +19,11 @@ require allow_fork_tests standard_testfile if {[build_executable "failed to build" $testfile $srcfile {debug}]} { - return -1 + return } # The test proper. proc do_test {} { diff --git a/gdb/testsuite/gdb.base/interrupt-noterm.exp b/gdb/testsuite/gdb.base/interrupt-noterm.exp index f4252cc90a72..afdb317964f0 100644 --- a/gdb/testsuite/gdb.base/interrupt-noterm.exp +++ b/gdb/testsuite/gdb.base/interrupt-noterm.exp @@ -15,18 +15,18 @@ standard_testfile if {[prepare_for_testing "failed to prepare for testing" \ ${testfile} ${srcfile} {debug}]} { - return -1 + return } # Pretend there's no terminal. gdb_test_no_output "set interactive-mode off" if {![runto_main]} { - return -1 + return } # Delete breakpoints so that the next resume is a plain continue, # instead of a step-over-breakpoint sequence just while GDB sends the # interrupt request. If that's buggy on some targets (and it was on diff --git a/gdb/testsuite/gdb.base/interrupt.exp b/gdb/testsuite/gdb.base/interrupt.exp index 9d1264843a8f..44a27434bc2b 100644 --- a/gdb/testsuite/gdb.base/interrupt.exp +++ b/gdb/testsuite/gdb.base/interrupt.exp @@ -27,11 +27,11 @@ if { ! [target_info exists gdb,nosignals] } { lappend options "additional_flags=-DSIGNALS" } if {[build_executable $testfile.exp $testfile $srcfile $options] == -1} { untested "failed to compile" - return -1 + return } gdb_start diff --git a/gdb/testsuite/gdb.base/jit-attach-pie.exp b/gdb/testsuite/gdb.base/jit-attach-pie.exp index 4c1e854f1c34..c47535c79145 100644 --- a/gdb/testsuite/gdb.base/jit-attach-pie.exp +++ b/gdb/testsuite/gdb.base/jit-attach-pie.exp @@ -18,11 +18,11 @@ require can_spawn_for_attach standard_testfile .c set executable ${testfile} if { [build_executable ${testfile}.exp $executable $srcfile \ [list debug pthreads pie]] } { - return -1 + return } # Start the program running and then wait for a bit, to be sure # that it can be attached to. diff --git a/gdb/testsuite/gdb.base/jit-reader-simple.exp b/gdb/testsuite/gdb.base/jit-reader-simple.exp index c97009857220..445e2b053fd2 100644 --- a/gdb/testsuite/gdb.base/jit-reader-simple.exp +++ b/gdb/testsuite/gdb.base/jit-reader-simple.exp @@ -79,20 +79,20 @@ set srcfile_dl $testfile-dl.c set binfile_dl $binfile-dl set options [list debug shlib=${binfile_lib}] if {[gdb_compile ${srcdir}/${subdir}/${srcfile_dl} $binfile_dl executable \ $options] == -1 } { untested "failed to compile" - return -1 + return } # Build the program that loads *two* JIT libraries. set binfile_dl2 $binfile-dl2 set options [list debug shlib=${binfile_lib} shlib=${binfile_lib2}] if {[gdb_compile ${srcdir}/${subdir}/${srcfile_dl} $binfile_dl2 executable \ $options] == -1 } { untested "failed to compile two-jitter binary" - return -1 + return } # STANDALONE is true when the JIT reader is included directly in the # main program. False when the JIT reader is in a separate shared # library. If CHANGE_ADDR is true, force changing the JIT descriptor diff --git a/gdb/testsuite/gdb.base/jit-reader.exp b/gdb/testsuite/gdb.base/jit-reader.exp index 26656549e31a..e9b3f2672ae9 100644 --- a/gdb/testsuite/gdb.base/jit-reader.exp +++ b/gdb/testsuite/gdb.base/jit-reader.exp @@ -35,21 +35,21 @@ set jit_reader_header [standard_output_file "../../../../../gdb/jit-reader.h"] set jit_reader_flag "-DJIT_READER_H=\"$jit_reader_header\"" if { [gdb_compile "${srcdir}/${subdir}/${jit_host_src}" "${jit_host_bin}" \ executable [list debug additional_flags=$jit_reader_flag]] != "" } { untested "failed to compile" - return -1 + return } set jit_reader jit-reader set jit_reader_src ${jit_reader}.c set jit_reader_bin [standard_output_file ${jit_reader}.so] if { [gdb_compile_shlib "${srcdir}/${subdir}/${jit_reader_src}" "${jit_reader_bin}" \ [list debug additional_flags=$jit_reader_flag]] != "" } { untested "failed to compile" - return -1 + return } # Test "info registers" in the current frame, expecting RSP's value to # be SP. diff --git a/gdb/testsuite/gdb.base/jump-inline.exp b/gdb/testsuite/gdb.base/jump-inline.exp index 07853ffcb82f..15bc6fa70d7a 100644 --- a/gdb/testsuite/gdb.base/jump-inline.exp +++ b/gdb/testsuite/gdb.base/jump-inline.exp @@ -16,15 +16,15 @@ # Test support for jump in inline functions. standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_breakpoint [gdb_get_line_number "inline-funct"] gdb_continue_to_breakpoint "inline-funct" ".*inline-funct.*" diff --git a/gdb/testsuite/gdb.base/jump.exp b/gdb/testsuite/gdb.base/jump.exp index 15900520214c..3139b081aa25 100644 --- a/gdb/testsuite/gdb.base/jump.exp +++ b/gdb/testsuite/gdb.base/jump.exp @@ -17,11 +17,11 @@ clear_xfail "*-*-*" standard_testfile .c if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } # General testing of the 'jump' command. GDB is already started. # There might be multiple inferior in the current debug session, in # which case, the relevant inferior is already selected. @@ -97,11 +97,11 @@ if {![use_gdb_stub]} { set num_inferiors 2 } # Run to main, add inferiors if needed. if {![runto_main]} { - return -1 + return } for {set inf 2} {$inf <= $num_inferiors} {incr inf} { # Start a new inferior, and run it with the same executable. gdb_test "add-inferior -exec ${binfile}" \ "Added inferior ${inf}.*" \ diff --git a/gdb/testsuite/gdb.base/jump_multiple_objfiles.exp b/gdb/testsuite/gdb.base/jump_multiple_objfiles.exp index 5345f256118e..ddc34b6ff3b5 100755 --- a/gdb/testsuite/gdb.base/jump_multiple_objfiles.exp +++ b/gdb/testsuite/gdb.base/jump_multiple_objfiles.exp @@ -20,15 +20,15 @@ standard_testfile .c -foo.c .h if { [prepare_for_testing "failed to prepare" $testfile \ [list ${srcfile} ${srcfile2}]] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } set bar_first_line [gdb_get_line_number "bar-first-line" ${srcfile3}] set bar_middle_line [gdb_get_line_number "bar-middle-line" ${srcfile3}] diff --git a/gdb/testsuite/gdb.base/kill-after-signal.exp b/gdb/testsuite/gdb.base/kill-after-signal.exp index 58f9c395bb96..f55aa8b81f3c 100644 --- a/gdb/testsuite/gdb.base/kill-after-signal.exp +++ b/gdb/testsuite/gdb.base/kill-after-signal.exp @@ -18,17 +18,17 @@ standard_testfile .c require can_single_step_to_signal_handler require {!target_info exists gdb,nosignals} if {[prepare_for_testing "failed to prepare" ${testfile}]} { - return -1 + return } gdb_test "handle SIGUSR1 stop print pass" "SIGUSR1\[ \t\]+Yes\[ \t\]+Yes\[ \t\]+Yes\[ \t\]+.*" if {![runto_main]} { - return -1 + return } gdb_test "continue" "Program received signal SIGUSR1, .*" set test "handler" diff --git a/gdb/testsuite/gdb.base/kill-detach-inferiors-cmd.exp b/gdb/testsuite/gdb.base/kill-detach-inferiors-cmd.exp index 80fd913ddab4..ec086b785f14 100644 --- a/gdb/testsuite/gdb.base/kill-detach-inferiors-cmd.exp +++ b/gdb/testsuite/gdb.base/kill-detach-inferiors-cmd.exp @@ -23,11 +23,11 @@ require allow_multi_inferior_tests standard_testfile set executable $testfile if {[prepare_for_testing "failed to prepare" $executable]} { - return -1 + return } runto_main # Add another forked inferior process. diff --git a/gdb/testsuite/gdb.base/kill-during-detach.exp b/gdb/testsuite/gdb.base/kill-during-detach.exp index 20a4f3481c42..f5e3a9022112 100644 --- a/gdb/testsuite/gdb.base/kill-during-detach.exp +++ b/gdb/testsuite/gdb.base/kill-during-detach.exp @@ -42,11 +42,11 @@ if { [istarget "*-*-linux*"] && [target_info gdb_protocol] == ""} { set flags {} lappend flags debug lappend flags additional_flags=-DBINFILE=$binfile if {[build_executable "failed to prepare" $testfile $srcfile $flags] == -1} { - return -1 + return } set checkpoint_line [gdb_get_line_number "Checkpoint here"] # Start an inferior, which blocks in a spin loop. Setup a Python diff --git a/gdb/testsuite/gdb.base/killed-outside.exp b/gdb/testsuite/gdb.base/killed-outside.exp index e48137d4bd43..5fb818ec076b 100644 --- a/gdb/testsuite/gdb.base/killed-outside.exp +++ b/gdb/testsuite/gdb.base/killed-outside.exp @@ -78,11 +78,11 @@ proc test {cmds_after_kill} { } } } if {[build_executable "failed to prepare" $testfile $srcfile] == -1} { - return -1 + return } # The actual output GDB prints in response to commands after the # inferior is gone isn't very well defined, and will depend on target. # What we're trying to make sure is that GDB doesn't internal error or diff --git a/gdb/testsuite/gdb.base/label-without-address.exp b/gdb/testsuite/gdb.base/label-without-address.exp index dbd590362d22..7796de94c078 100644 --- a/gdb/testsuite/gdb.base/label-without-address.exp +++ b/gdb/testsuite/gdb.base/label-without-address.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . */ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } @@ -33,9 +33,9 @@ gdb_test_multiple "l main:L1" "" { set supported 1 } } if { ! $supported } { - return -1 + return } gdb_test "break main:L1" "Location main:L1 not available" diff --git a/gdb/testsuite/gdb.base/label.exp b/gdb/testsuite/gdb.base/label.exp index da4a369caf6a..418841961c8d 100644 --- a/gdb/testsuite/gdb.base/label.exp +++ b/gdb/testsuite/gdb.base/label.exp @@ -18,11 +18,11 @@ # standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile ${srcfile} debug] } { - return -1 + return } if {![runto_main]} { return -1 diff --git a/gdb/testsuite/gdb.base/langs.exp b/gdb/testsuite/gdb.base/langs.exp index 8bfe377c60ce..5705446f2580 100644 --- a/gdb/testsuite/gdb.base/langs.exp +++ b/gdb/testsuite/gdb.base/langs.exp @@ -22,11 +22,11 @@ if {[is_remote host]} { } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2 $srcfile3] {debug}]} { - return -1 + return } set oldtimeout $timeout set timeout 10 diff --git a/gdb/testsuite/gdb.base/ldbl_e308.exp b/gdb/testsuite/gdb.base/ldbl_e308.exp index 2f70dba56246..6351f5ffa7c3 100644 --- a/gdb/testsuite/gdb.base/ldbl_e308.exp +++ b/gdb/testsuite/gdb.base/ldbl_e308.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . set testfile ldbl_e308 set srcfile ${testfile}.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set variable ldbl_308 = 1.6e+308l" gdb_test "print ldbl_308" \ diff --git a/gdb/testsuite/gdb.base/limited-length.exp b/gdb/testsuite/gdb.base/limited-length.exp index 8a55dd2540b4..e5f894cd2c57 100644 --- a/gdb/testsuite/gdb.base/limited-length.exp +++ b/gdb/testsuite/gdb.base/limited-length.exp @@ -16,11 +16,11 @@ # Test GDB's limited array printing. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } if {![runto_main]} { perror "couldn't run to breakpoint" continue diff --git a/gdb/testsuite/gdb.base/line-symtabs.exp b/gdb/testsuite/gdb.base/line-symtabs.exp index 856d00de99c9..02265a5dfc89 100644 --- a/gdb/testsuite/gdb.base/line-symtabs.exp +++ b/gdb/testsuite/gdb.base/line-symtabs.exp @@ -19,15 +19,15 @@ standard_testfile .c line-symtabs.h if { [is_remote host] } { gdb_remote_download host $srcdir/$subdir/$srcfile2 } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # PR 17559: gdb_disassembly was using the wrong symtab lookup function. # It was expecting the symtab of the source file containing $pc, # instead it was getting the primary symtab of that compilation unit. diff --git a/gdb/testsuite/gdb.base/line65535.exp b/gdb/testsuite/gdb.base/line65535.exp index c01d9bc1526c..b62355b8a608 100644 --- a/gdb/testsuite/gdb.base/line65535.exp +++ b/gdb/testsuite/gdb.base/line65535.exp @@ -18,11 +18,11 @@ # command succeeds, we will not try to actually run to that line. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "break $srcfile:65535" \ ".*Breakpoint 1 at .*: file .*$srcfile, line 65535\\..*" \ "break at line 65535" diff --git a/gdb/testsuite/gdb.base/list-ambiguous.exp b/gdb/testsuite/gdb.base/list-ambiguous.exp index 00e5e114978b..45bc479c1c4c 100644 --- a/gdb/testsuite/gdb.base/list-ambiguous.exp +++ b/gdb/testsuite/gdb.base/list-ambiguous.exp @@ -22,11 +22,11 @@ standard_testfile list-ambiguous0.c list-ambiguous1.c # editor. setenv EDITOR true if {[prepare_for_testing "failed to prepare" $testfile [list $srcfile $srcfile2] \ {debug}]} { - return -1 + return } # Build source listing pattern based on an inclusive line range. proc line_range_pattern { range_start range_end } { diff --git a/gdb/testsuite/gdb.base/list-before-start.exp b/gdb/testsuite/gdb.base/list-before-start.exp index 4ed3856904c0..d332d41b2d73 100644 --- a/gdb/testsuite/gdb.base/list-before-start.exp +++ b/gdb/testsuite/gdb.base/list-before-start.exp @@ -17,11 +17,11 @@ # program is started. standard_testfile list-ambiguous0.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } set fill "${decimal}\\s+\[^\n\r\]+" gdb_test_no_output "set listsize 10" diff --git a/gdb/testsuite/gdb.base/list-missing-source.exp b/gdb/testsuite/gdb.base/list-missing-source.exp index ac053a6b3ba8..fb78c85ffb08 100644 --- a/gdb/testsuite/gdb.base/list-missing-source.exp +++ b/gdb/testsuite/gdb.base/list-missing-source.exp @@ -34,11 +34,11 @@ set srcfile [remote_download host $srcfile] # Compile the source file. set options "debug" if { [gdb_compile "${srcfile}" "${binfile}" \ executable $options] != "" } { untested "failed to compile" - return -1 + return } # Now delete the source file. remote_file host delete $srcfile diff --git a/gdb/testsuite/gdb.base/list-nodebug.exp b/gdb/testsuite/gdb.base/list-nodebug.exp index e0ba56db4855..53c31ca08916 100644 --- a/gdb/testsuite/gdb.base/list-nodebug.exp +++ b/gdb/testsuite/gdb.base/list-nodebug.exp @@ -21,11 +21,11 @@ standard_testfile .c -2.c if { [prepare_for_testing_full "failed to prepare" \ [list \ $testfile {} \ $srcfile {nodebug} \ $srcfile2 {debug}]] } { - return -1 + return } if {![runto_main]} { untested "couldn't run to main" return diff --git a/gdb/testsuite/gdb.base/list.exp b/gdb/testsuite/gdb.base/list.exp index 71419acfcf7e..77161305e04d 100644 --- a/gdb/testsuite/gdb.base/list.exp +++ b/gdb/testsuite/gdb.base/list.exp @@ -21,11 +21,11 @@ standard_testfile list0.c list1.c # Need to download the header to the host. gdb_remote_download host ${srcdir}/${subdir}/list0.h if {[build_executable "failed to prepare" $testfile [list $srcfile $srcfile2] \ {debug}]} { - return -1 + return } # The last line in the file. set last_line [gdb_get_line_number "last line" "list0.c"] diff --git a/gdb/testsuite/gdb.base/load-command.exp b/gdb/testsuite/gdb.base/load-command.exp index f20de4d07fd4..0329b33137de 100644 --- a/gdb/testsuite/gdb.base/load-command.exp +++ b/gdb/testsuite/gdb.base/load-command.exp @@ -26,15 +26,15 @@ if {[gdb_protocol_is_native]} { # would have to manually specify an offset to load. set opts {debug nopie} if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Manually change the value of the_variable. gdb_test "print/x the_variable" " = 0x1234" "check initial value of the_variable" gdb_test_no_output "set the_variable = 0x5555" "manually change the_variable" diff --git a/gdb/testsuite/gdb.base/long-inferior-output.exp b/gdb/testsuite/gdb.base/long-inferior-output.exp index 70fe78486183..f2de534ec208 100644 --- a/gdb/testsuite/gdb.base/long-inferior-output.exp +++ b/gdb/testsuite/gdb.base/long-inferior-output.exp @@ -31,11 +31,11 @@ require {!target_info exists gdb,noinferiorio} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile {} {debug}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/longest-types.exp b/gdb/testsuite/gdb.base/longest-types.exp index a21c65157524..42bec222ed6e 100644 --- a/gdb/testsuite/gdb.base/longest-types.exp +++ b/gdb/testsuite/gdb.base/longest-types.exp @@ -16,10 +16,10 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile {debug quiet}] } { - return -1 + return } # 64-bit array size should not overflow gdb_test "print &f->buf" {= \(char \(\*\)\[1099494850560\]\) 0x0} diff --git a/gdb/testsuite/gdb.base/macscp.exp b/gdb/testsuite/gdb.base/macscp.exp index 26ca0ce578d1..44debe1e7f87 100644 --- a/gdb/testsuite/gdb.base/macscp.exp +++ b/gdb/testsuite/gdb.base/macscp.exp @@ -24,11 +24,11 @@ set options {debug macros additional_flags=-DFROM_COMMANDLINE=ARG} # have access to the .debug_macinfo section. if {[gdb_compile "${srcdir}/${subdir}/macscp1.c" "${objfile}" \ object $options] != "" || [gdb_compile "${objfile}" "${binfile}" executable $options] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile diff --git a/gdb/testsuite/gdb.base/main-c.exp b/gdb/testsuite/gdb.base/main-c.exp index 1ae8a44a64e4..46e80b056796 100644 --- a/gdb/testsuite/gdb.base/main-c.exp +++ b/gdb/testsuite/gdb.base/main-c.exp @@ -19,11 +19,11 @@ standard_testfile main.c require !readnow if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } require {string eq [have_index $binfile] ""} gdb_test_no_output "maint info symtabs" diff --git a/gdb/testsuite/gdb.base/maint-expand-symbols-header-file.exp b/gdb/testsuite/gdb.base/maint-expand-symbols-header-file.exp index 96c2575bd9b9..55ab4c7e1da8 100644 --- a/gdb/testsuite/gdb.base/maint-expand-symbols-header-file.exp +++ b/gdb/testsuite/gdb.base/maint-expand-symbols-header-file.exp @@ -18,11 +18,11 @@ standard_testfile .c if {[build_executable "failed to prepare" $testfile \ $srcfile {debug nowarnings}]} { - return -1 + return } clean_restart # Make sure that no symtabs are expanded, by setting language before # loading exec. @@ -30,11 +30,11 @@ gdb_test_no_output "set language c" gdb_load ${binfile} set test "verify no symtabs are expanded" if { [readnow] } { unsupported $test - return -1 + return } gdb_test_no_output "maint info symtabs" $test # Expand the header file symtab. gdb_test_no_output "maint expand-symtabs maint-expand-symbols-header-file.h" diff --git a/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp b/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp index e672e0b67bf4..b123162d6e5b 100644 --- a/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp +++ b/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp @@ -18,11 +18,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug nopie}]} { - return -1 + return } if {![runto normal_func]} { return 0 } diff --git a/gdb/testsuite/gdb.base/maint-info-sections.exp b/gdb/testsuite/gdb.base/maint-info-sections.exp index 65a761c6cb98..ac712137cc63 100644 --- a/gdb/testsuite/gdb.base/maint-info-sections.exp +++ b/gdb/testsuite/gdb.base/maint-info-sections.exp @@ -20,15 +20,15 @@ load_lib completion-support.exp standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Check the output of 'maint info target-sections' command. proc check_maint_info_target_sections_output {prefix} { global hex gdb_prompt diff --git a/gdb/testsuite/gdb.base/maint-print-frame-id.exp b/gdb/testsuite/gdb.base/maint-print-frame-id.exp index 18f9a6b3a166..9d857c8b45a7 100644 --- a/gdb/testsuite/gdb.base/maint-print-frame-id.exp +++ b/gdb/testsuite/gdb.base/maint-print-frame-id.exp @@ -17,15 +17,15 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile \ $srcfile {debug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint foo gdb_continue_to_breakpoint "run to foo" diff --git a/gdb/testsuite/gdb.base/maint.exp b/gdb/testsuite/gdb.base/maint.exp index 87216181382f..0099eb672dcb 100644 --- a/gdb/testsuite/gdb.base/maint.exp +++ b/gdb/testsuite/gdb.base/maint.exp @@ -45,11 +45,11 @@ standard_testfile break.c break1.c if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } # Check "maint set per-command" warnings. We do this early so that # the following tests don't need to expect them, as GDB only warns # once. diff --git a/gdb/testsuite/gdb.base/many-completions.exp b/gdb/testsuite/gdb.base/many-completions.exp index eb2736a9564b..edb61c2d7f48 100644 --- a/gdb/testsuite/gdb.base/many-completions.exp +++ b/gdb/testsuite/gdb.base/many-completions.exp @@ -65,11 +65,11 @@ proc prepare_test_source_file { count } { # Build a source file and compile it. set filename [prepare_test_source_file 250] standard_testfile $filename if {[prepare_for_testing "failed to prepare" "$testfile" $srcfile \ { debug }]} { - return -1 + return } # Start the test. if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.base/many-headers.exp b/gdb/testsuite/gdb.base/many-headers.exp index 72a9e07a3e55..6b13db61e740 100644 --- a/gdb/testsuite/gdb.base/many-headers.exp +++ b/gdb/testsuite/gdb.base/many-headers.exp @@ -25,11 +25,11 @@ if { [target_info gdb_protocol] != "" } { } standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Generate core file. set corefile [core_find $binfile] if {$corefile == ""} { @@ -47,11 +47,11 @@ catch { "ulimit -s $stack_limit;" \ ")"] } msg if { "$msg" != "" } { untested "Can't set stack limit" - return -1 + return } set cmd \ [concat \ "(" \ diff --git a/gdb/testsuite/gdb.base/max-value-size.exp b/gdb/testsuite/gdb.base/max-value-size.exp index f10e39d51065..ba5266401ee8 100644 --- a/gdb/testsuite/gdb.base/max-value-size.exp +++ b/gdb/testsuite/gdb.base/max-value-size.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/memattr.exp b/gdb/testsuite/gdb.base/memattr.exp index e333f37c668b..a399111cd34f 100644 --- a/gdb/testsuite/gdb.base/memattr.exp +++ b/gdb/testsuite/gdb.base/memattr.exp @@ -18,11 +18,11 @@ # Test the memory attribute commands. standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main # Delete all target-supplied memory regions. diff --git a/gdb/testsuite/gdb.base/memops-watchpoint.exp b/gdb/testsuite/gdb.base/memops-watchpoint.exp index faa4f6e1c4a0..17c14fdee065 100644 --- a/gdb/testsuite/gdb.base/memops-watchpoint.exp +++ b/gdb/testsuite/gdb.base/memops-watchpoint.exp @@ -19,16 +19,16 @@ standard_testfile set options "-fno-builtin-memset -fno-builtin-memcpy -fno-builtin-memmove" if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug additional_flags=$options]] } { - return -1 + return } set linespec ${srcfile}:[gdb_get_line_number "Break here"] if {![runto ${linespec}]} { - return -1 + return } gdb_test "watch -location a\[28\]" \ "(Hardware w|W)atchpoint ${decimal}: -location a\\\[28\\\]" \ "set watch on a" diff --git a/gdb/testsuite/gdb.base/memtag.exp b/gdb/testsuite/gdb.base/memtag.exp index 0e032bb61fd9..f630615ebac2 100644 --- a/gdb/testsuite/gdb.base/memtag.exp +++ b/gdb/testsuite/gdb.base/memtag.exp @@ -17,11 +17,11 @@ set u_msg "Memory tagging not supported or disabled by the current architecture\." standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {[target_info gdb_protocol] == "extended-remote"} { # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. @@ -38,18 +38,18 @@ with_test_prefix "before program execution" { } clean_restart $testfile if {![runto_main]} { - return -1 + return } # Targets that don't support memory tagging should not execute the # runtime memory tagging tests. if {![supports_memtag]} { unsupported "memory tagging unsupported" - return -1 + return } # With the program running, try to use the memory tagging commands. with_test_prefix "during program execution" { set msg "Argument required \\(address or pointer\\)\." diff --git a/gdb/testsuite/gdb.base/mips_pro.exp b/gdb/testsuite/gdb.base/mips_pro.exp index 411457a8f765..4000a06d51a6 100644 --- a/gdb/testsuite/gdb.base/mips_pro.exp +++ b/gdb/testsuite/gdb.base/mips_pro.exp @@ -22,11 +22,11 @@ set options debug if {[test_compiler_info gcc-*-*]} { lappend options additional_flags=-O2 additional_flags=-fno-inline } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options]} { - return -1 + return } if {[runto middle]} { # PR 3016 # warning: Hit heuristic-fence-post without finding diff --git a/gdb/testsuite/gdb.base/morestack.exp b/gdb/testsuite/gdb.base/morestack.exp index 979500a4370c..9b5ad1456598 100644 --- a/gdb/testsuite/gdb.base/morestack.exp +++ b/gdb/testsuite/gdb.base/morestack.exp @@ -20,15 +20,15 @@ require {have_compile_flag -fsplit-stack} standard_testfile set opts "additional_flags=-fsplit-stack" if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile \ [list $opts]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "marker_hit" gdb_breakpoint "marker_miss" diff --git a/gdb/testsuite/gdb.base/msym-lang.exp b/gdb/testsuite/gdb.base/msym-lang.exp index 15e40105110e..d0beddea4175 100644 --- a/gdb/testsuite/gdb.base/msym-lang.exp +++ b/gdb/testsuite/gdb.base/msym-lang.exp @@ -15,9 +15,9 @@ standard_testfile msym-lang-main.c msym-lang.c if {[prepare_for_testing "failed to prepare" $testfile [list $srcfile $srcfile2] \ {c++}]} { - return -1 + return } gdb_test "info func foo" ".* foo\\(\\).* foo\\(\\).*" diff --git a/gdb/testsuite/gdb.base/nested-addr.exp b/gdb/testsuite/gdb.base/nested-addr.exp index f20d7df1613a..6701aba3eacf 100644 --- a/gdb/testsuite/gdb.base/nested-addr.exp +++ b/gdb/testsuite/gdb.base/nested-addr.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . */ standard_testfile if {[prepare_for_testing "failed to prepare" "${testfile}" "${srcfile}"]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "BREAK"] gdb_continue_to_breakpoint "BREAK" diff --git a/gdb/testsuite/gdb.base/nested-subp1.exp b/gdb/testsuite/gdb.base/nested-subp1.exp index 22ecb8f1f21c..ed783aa0e7d3 100644 --- a/gdb/testsuite/gdb.base/nested-subp1.exp +++ b/gdb/testsuite/gdb.base/nested-subp1.exp @@ -24,18 +24,18 @@ standard_testfile set testcase "nested-subp1" if {![support_nested_function_tests]} { untested "compiler does not support nested functions" - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${testcase}.c" \ [standard_output_file "${testcase}"] \ executable \ [list debug "additional_flags=-std=gnu99"]] != "" } { - return -1 + return } # Run until the variables we are interested in are visible. diff --git a/gdb/testsuite/gdb.base/nested-subp2.exp b/gdb/testsuite/gdb.base/nested-subp2.exp index 23d36e77efc1..7a5ff89a4187 100644 --- a/gdb/testsuite/gdb.base/nested-subp2.exp +++ b/gdb/testsuite/gdb.base/nested-subp2.exp @@ -24,11 +24,11 @@ standard_testfile set testcase "nested-subp2" if {![support_nested_function_tests]} { untested "compiler does not support nested functions" - return -1 + return } set flags {} lappend flags debug lappend flags additional_flags=-std=gnu99 @@ -40,11 +40,11 @@ if { [gdb_can_simple_compile ld-flags {int main () { return 0; }} executable \ } if { [gdb_compile "${srcdir}/${subdir}/${testcase}.c" \ [standard_output_file "${testcase}"] \ executable $flags] != "" } { - return -1 + return } # Run until the variables we are interested in are visible. diff --git a/gdb/testsuite/gdb.base/nested-subp3.exp b/gdb/testsuite/gdb.base/nested-subp3.exp index 8e145bee7650..5cb49b8dbce9 100644 --- a/gdb/testsuite/gdb.base/nested-subp3.exp +++ b/gdb/testsuite/gdb.base/nested-subp3.exp @@ -24,11 +24,11 @@ standard_testfile set testcase "nested-subp3" if {![support_nested_function_tests]} { untested "compiler does not support nested functions" - return -1 + return } set flags {} lappend flags debug lappend flags additional_flags=-std=gnu99 @@ -40,11 +40,11 @@ if { [gdb_can_simple_compile ld-flags {int main () { return 0; }} executable \ } if { [gdb_compile "${srcdir}/${subdir}/${testcase}.c" \ [standard_output_file "${testcase}"] \ executable $flags] != "" } { - return -1 + return } # Run until the variables we are interested in are visible. diff --git a/gdb/testsuite/gdb.base/new-ui-echo.exp b/gdb/testsuite/gdb.base/new-ui-echo.exp index a57225add133..2dfbf66c81a4 100644 --- a/gdb/testsuite/gdb.base/new-ui-echo.exp +++ b/gdb/testsuite/gdb.base/new-ui-echo.exp @@ -23,11 +23,11 @@ standard_testfile set compile_options "debug" if {[build_executable $testfile.exp $testfile ${srcfile} ${compile_options}] == -1} { untested "failed to compile" - return -1 + return } # Start gdb and create an extra console UI. Start the inferior in the # DRIVER console (either "main" or "extra"), and then enter a # synchronous execution command in the extra console. Before PR 20494 diff --git a/gdb/testsuite/gdb.base/new-ui-pending-input.exp b/gdb/testsuite/gdb.base/new-ui-pending-input.exp index 5d147bcfe1c7..cbc2c6d3b706 100644 --- a/gdb/testsuite/gdb.base/new-ui-pending-input.exp +++ b/gdb/testsuite/gdb.base/new-ui-pending-input.exp @@ -20,11 +20,11 @@ standard_testfile set compile_options "debug" if {[build_executable $testfile.exp $testfile ${srcfile} ${compile_options}] == -1} { untested "failed to compile" - return -1 + return } # See intro. proc test_command_line_new_ui_pending_input {} { diff --git a/gdb/testsuite/gdb.base/new-ui.exp b/gdb/testsuite/gdb.base/new-ui.exp index 6bc45392733c..b5ee322dc04f 100644 --- a/gdb/testsuite/gdb.base/new-ui.exp +++ b/gdb/testsuite/gdb.base/new-ui.exp @@ -16,11 +16,11 @@ standard_testfile set compile_options "debug" if {[build_executable $testfile.exp $testfile ${srcfile} ${compile_options}] == -1} { untested "failed to compile" - return -1 + return } # Ensure no output has been sent. Use MESSAGE as test message. proc ensure_no_output {message} { diff --git a/gdb/testsuite/gdb.base/nextoverexit.exp b/gdb/testsuite/gdb.base/nextoverexit.exp index 5fbb4efa51b5..91c78ba60e37 100644 --- a/gdb/testsuite/gdb.base/nextoverexit.exp +++ b/gdb/testsuite/gdb.base/nextoverexit.exp @@ -13,15 +13,15 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $testfile.c]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Make sure we do not see any warnings. gdb_test_multiple "next" "next over exit" { -re "$inferior_exited_re normally.\[\r\n\]+$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.base/non-lazy-array-index.exp b/gdb/testsuite/gdb.base/non-lazy-array-index.exp index 48eb7db77c11..0de2e59a9b92 100644 --- a/gdb/testsuite/gdb.base/non-lazy-array-index.exp +++ b/gdb/testsuite/gdb.base/non-lazy-array-index.exp @@ -17,15 +17,15 @@ # when fetching elements from an array in the C language. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Load 'global_foo' into a history variable. gdb_test "p global_foo" "\\{f = 1, array = \\{1, 2, 3, 4, 5\\}\\}" diff --git a/gdb/testsuite/gdb.base/noreturn-finish.exp b/gdb/testsuite/gdb.base/noreturn-finish.exp index 3894b3e770ef..0574733cde74 100644 --- a/gdb/testsuite/gdb.base/noreturn-finish.exp +++ b/gdb/testsuite/gdb.base/noreturn-finish.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug}]} { - return -1 + return } proc noreturn_finish_test { } { global gdb_prompt diff --git a/gdb/testsuite/gdb.base/noreturn-return.exp b/gdb/testsuite/gdb.base/noreturn-return.exp index e2ea8690771d..c761f141cddb 100644 --- a/gdb/testsuite/gdb.base/noreturn-return.exp +++ b/gdb/testsuite/gdb.base/noreturn-return.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug}]} { - return -1 + return } proc noreturn_test { } { global gdb_prompt diff --git a/gdb/testsuite/gdb.base/offsets.exp b/gdb/testsuite/gdb.base/offsets.exp index 2286f0c2276a..a7480f692d5f 100644 --- a/gdb/testsuite/gdb.base/offsets.exp +++ b/gdb/testsuite/gdb.base/offsets.exp @@ -17,11 +17,11 @@ standard_testfile offsets.c if { [prepare_for_testing "failed to prepare for testing large offsets" \ ${testfile} ${srcfile}] } { - return -1 + return } set test "print &big_struct test" gdb_test_multiple "print &big_struct" "$test" { -re "${::valnum_re} = .* (0x\[0-9a-fA-F\]*) .*\[\r\n\]*$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.base/opaque.exp b/gdb/testsuite/gdb.base/opaque.exp index 489b0e451ee6..ded6f8c88e30 100644 --- a/gdb/testsuite/gdb.base/opaque.exp +++ b/gdb/testsuite/gdb.base/opaque.exp @@ -20,11 +20,11 @@ standard_testfile opaque0.c opaque1.c # Some tests require GCC. set gcc_compiled [is_c_compiler_gcc] if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] debug]} { - return -1 + return } # # Test basic opaque structure handling (statically). # The ordering of the tests is significant. We first try the things that diff --git a/gdb/testsuite/gdb.base/options.exp b/gdb/testsuite/gdb.base/options.exp index 0b8dda51d4d0..35487ead6a77 100644 --- a/gdb/testsuite/gdb.base/options.exp +++ b/gdb/testsuite/gdb.base/options.exp @@ -35,18 +35,18 @@ load_lib compile-support.exp load_lib completion-support.exp standard_testfile .c if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } clean_restart if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } set tui_supported_p [allow_tui_tests] # Check the completion result, as returned by the "maintenance show diff --git a/gdb/testsuite/gdb.base/paginate-after-ctrl-c-running.exp b/gdb/testsuite/gdb.base/paginate-after-ctrl-c-running.exp index 3ab1e06c6e31..54a922187b84 100644 --- a/gdb/testsuite/gdb.base/paginate-after-ctrl-c-running.exp +++ b/gdb/testsuite/gdb.base/paginate-after-ctrl-c-running.exp @@ -16,11 +16,11 @@ require {!target_info exists gdb,nointerrupts} standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug] == -1} { - return -1 + return } # Send a ctrl-c while the target is running and check that the output # does not cause a pagination prompt. diff --git a/gdb/testsuite/gdb.base/paginate-bg-execution.exp b/gdb/testsuite/gdb.base/paginate-bg-execution.exp index e369fa7ad046..9f9e44fb4dc7 100644 --- a/gdb/testsuite/gdb.base/paginate-bg-execution.exp +++ b/gdb/testsuite/gdb.base/paginate-bg-execution.exp @@ -17,11 +17,11 @@ # does not trigger pagination. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug] == -1} { - return -1 + return } # Check that we handle a stop event coming from a background execution # command without getting caught in pagination. diff --git a/gdb/testsuite/gdb.base/paginate-execution-startup.exp b/gdb/testsuite/gdb.base/paginate-execution-startup.exp index e1de36ca022f..03647520c157 100644 --- a/gdb/testsuite/gdb.base/paginate-execution-startup.exp +++ b/gdb/testsuite/gdb.base/paginate-execution-startup.exp @@ -17,11 +17,11 @@ # execution commands directly from the command line, with "-ex". standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug] == -1} { - return -1 + return } set file_arg $binfile if {[is_remote host]} { set file_arg [remote_download host $file_arg] diff --git a/gdb/testsuite/gdb.base/paginate-inferior-exit.exp b/gdb/testsuite/gdb.base/paginate-inferior-exit.exp index e6557f947a76..eb274b091f99 100644 --- a/gdb/testsuite/gdb.base/paginate-inferior-exit.exp +++ b/gdb/testsuite/gdb.base/paginate-inferior-exit.exp @@ -16,11 +16,11 @@ # Test that an inferior exit event does not trigger pagination. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug] == -1} { - return -1 + return } # Test paginating while printing about the inferior having exited. # proc test_paginate_inferior_exited {} { diff --git a/gdb/testsuite/gdb.base/patch.exp b/gdb/testsuite/gdb.base/patch.exp index ed6d268f6bd0..e998ef4334c0 100644 --- a/gdb/testsuite/gdb.base/patch.exp +++ b/gdb/testsuite/gdb.base/patch.exp @@ -16,11 +16,11 @@ # Test patching executables and core files, with "set write on". standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Check that we can patch an executable. with_test_prefix "exec" { diff --git a/gdb/testsuite/gdb.base/pc-fp.exp b/gdb/testsuite/gdb.base/pc-fp.exp index 3f4fafee237f..fd44942bfe87 100644 --- a/gdb/testsuite/gdb.base/pc-fp.exp +++ b/gdb/testsuite/gdb.base/pc-fp.exp @@ -25,11 +25,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug nowarnings}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/pending.exp b/gdb/testsuite/gdb.base/pending.exp index 62894063ee6b..161287226f86 100644 --- a/gdb/testsuite/gdb.base/pending.exp +++ b/gdb/testsuite/gdb.base/pending.exp @@ -30,11 +30,11 @@ set lib_opts debug set exec_opts [list debug shlib=$lib_sl] if { [gdb_compile_shlib $libsrc $lib_sl $lib_opts] != "" || [gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} { untested "failed to compile" - return -1 + return } clean_restart gdb_test_multiple "break pendfunc1" "set pending breakpoint" { diff --git a/gdb/testsuite/gdb.base/permissions.exp b/gdb/testsuite/gdb.base/permissions.exp index 6835ed5a4c68..4db6521bea1a 100644 --- a/gdb/testsuite/gdb.base/permissions.exp +++ b/gdb/testsuite/gdb.base/permissions.exp @@ -21,11 +21,11 @@ standard_testfile start.c if {[build_executable $testfile.exp $testfile \ $srcfile {debug nowarnings}] == -1} { untested "failed to compile" - return -1 + return } clean_restart with_test_prefix "observer mode off" { diff --git a/gdb/testsuite/gdb.base/persistent-lang.exp b/gdb/testsuite/gdb.base/persistent-lang.exp index 880dbb2d9eea..4099459ca383 100644 --- a/gdb/testsuite/gdb.base/persistent-lang.exp +++ b/gdb/testsuite/gdb.base/persistent-lang.exp @@ -18,11 +18,11 @@ standard_testfile .cc set flags {} lappend flags debug lappend flags c++ if {[build_executable "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } clean_restart set auto_c \ diff --git a/gdb/testsuite/gdb.base/pie-execl.exp b/gdb/testsuite/gdb.base/pie-execl.exp index 60d2270f8873..62f3bc100921 100644 --- a/gdb/testsuite/gdb.base/pie-execl.exp +++ b/gdb/testsuite/gdb.base/pie-execl.exp @@ -40,19 +40,19 @@ set binfile2_test_msg OBJDIR/${subdir}/${executable2} # file name of the breakpoint. set opts [list debug pie] if {[build_executable ${testfile}.exp $executable1 $srcfile [concat $opts {additional_flags=-DBIN=1}]] == -1 || [build_executable ${testfile}.exp $executable2 $srcfile [concat $opts {additional_flags=-DBIN=2}]] == -1} { - return -1 + return } clean_restart ${executable1} gdb_test_no_output "set args ${binfile2}" "set args ${binfile2_test_msg}" if {![runto_main]} { - return -1 + return } # Do not stop on `main' after re-exec. delete_breakpoints diff --git a/gdb/testsuite/gdb.base/pr10179.exp b/gdb/testsuite/gdb.base/pr10179.exp index 55808e42285f..b3129d43ef91 100644 --- a/gdb/testsuite/gdb.base/pr10179.exp +++ b/gdb/testsuite/gdb.base/pr10179.exp @@ -15,17 +15,17 @@ set testname pr10179 set sources "pr10179-a.c pr10179-b.c" if {[build_executable ${testname}.exp $testname $sources {debug}] == -1} { - return -1 + return } clean_restart ${testname} if {![runto_main]} { - return -1 + return } gdb_test "rbreak foo.*" "Breakpoint ${::decimal}\[^\\n\]*\\nint foo\[12\]\[^\\n\]*\\nBreakpoint ${::decimal}\[^\\n\]*\\nint foo\[12\].*" delete_breakpoints diff --git a/gdb/testsuite/gdb.base/prelink.exp b/gdb/testsuite/gdb.base/prelink.exp index cfbb511c7d97..4f18af4739c2 100644 --- a/gdb/testsuite/gdb.base/prelink.exp +++ b/gdb/testsuite/gdb.base/prelink.exp @@ -29,19 +29,19 @@ set testfile "prelink" set libsrcfile ${testfile}-lib.c set libfile [standard_output_file ${testfile}.so] if {[build_executable "build library" ${libfile} ${libsrcfile} \ {debug shlib}] == -1} { - return -1 + return } set srcfile ${testfile}.c set executable ${testfile}t set binfile [standard_output_file ${executable}] set prelink_args [build_executable_own_libs ${testfile}.exp $executable $srcfile [list debug "ldflags=-Wl,${libfile},-rpath,[file dirname ${libfile}]"]] if {$prelink_args == ""} { - return -1 + return } set test "split debug of executable" if {[gdb_gnu_strip_debug $binfile]} { fail $test @@ -49,11 +49,11 @@ if {[gdb_gnu_strip_debug $binfile]} { pass $test } if {![prelink_yes $prelink_args]} { # Maybe we don't have prelink. - return -1 + return } set found 0 set coredir "[standard_output_file coredir.[getpid]]" file mkdir $coredir @@ -84,11 +84,11 @@ if { $found == 0 } { return 0 } # Relink $libfile to a different address. if {![prelink_yes $prelink_args]} { - return -1 + return } # Start with a fresh gdb clean_restart $executable diff --git a/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp b/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp index 079f5c83e3a5..c3e9fdbc6b9e 100644 --- a/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp +++ b/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp @@ -37,11 +37,11 @@ standard_testfile .c require allow_python_tests if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/pretty-array.exp b/gdb/testsuite/gdb.base/pretty-array.exp index f484286f931e..e1a8428d842a 100644 --- a/gdb/testsuite/gdb.base/pretty-array.exp +++ b/gdb/testsuite/gdb.base/pretty-array.exp @@ -17,15 +17,15 @@ standard_testfile if {[prepare_for_testing $testfile.exp $testfile $srcfile debug]} { untested $testfile.exp - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print nums" \ "= \\{\\{11, 12, 13\\}, \\{21, 22, 23\\}\\}" diff --git a/gdb/testsuite/gdb.base/pretty-print.exp b/gdb/testsuite/gdb.base/pretty-print.exp index 5aaa4cafaff7..efe9cbae11d6 100644 --- a/gdb/testsuite/gdb.base/pretty-print.exp +++ b/gdb/testsuite/gdb.base/pretty-print.exp @@ -17,15 +17,15 @@ standard_testfile if {[prepare_for_testing $testfile.exp $testfile $srcfile debug]} { untested $testfile.exp - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set print pretty on" gdb_test "print s1" \ diff --git a/gdb/testsuite/gdb.base/print-internal-string.exp b/gdb/testsuite/gdb.base/print-internal-string.exp index 3ff2a6708fa5..7ebf8ed9b4d4 100644 --- a/gdb/testsuite/gdb.base/print-internal-string.exp +++ b/gdb/testsuite/gdb.base/print-internal-string.exp @@ -18,11 +18,11 @@ # the thing that is read back is correctly interpreted as a string. standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/print-symbol-loading.exp b/gdb/testsuite/gdb.base/print-symbol-loading.exp index c4cb501932d2..77c6145201e9 100644 --- a/gdb/testsuite/gdb.base/print-symbol-loading.exp +++ b/gdb/testsuite/gdb.base/print-symbol-loading.exp @@ -25,27 +25,27 @@ set gcorefile ${binfile}.gcore set objfile [standard_output_file ${testfile}.o] if { [gdb_compile_shlib ${srcdir}/${subdir}/${srcfile_lib} ${binfile_lib} {debug}] != "" || [gdb_compile ${srcdir}/${subdir}/${srcfile} ${objfile} object {debug}] != "" } { untested "failed to compile" - return -1 + return } set opts [list debug shlib=${binfile_lib}] if { [gdb_compile ${objfile} ${binfile} executable $opts] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile gdb_load_shlib ${binfile_lib} if {![runto lib]} { - return -1 + return } if {![gdb_gcore_cmd $gcorefile "save a corefile"]} { - return -1 + return } proc test_load_core { print_symbol_loading } { global binfile binfile_lib gcorefile srcdir subdir with_test_prefix "core ${print_symbol_loading}" { diff --git a/gdb/testsuite/gdb.base/printf-wchar_t.exp b/gdb/testsuite/gdb.base/printf-wchar_t.exp index db331a3e3280..37fee25996a6 100644 --- a/gdb/testsuite/gdb.base/printf-wchar_t.exp +++ b/gdb/testsuite/gdb.base/printf-wchar_t.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test {printf "%ls\n", wide_str} "^wide string" # Check that if the max-value-size will kick in when using printf on strings. diff --git a/gdb/testsuite/gdb.base/prologue-include.exp b/gdb/testsuite/gdb.base/prologue-include.exp index 9e92221b3a7a..d25df5953cc1 100644 --- a/gdb/testsuite/gdb.base/prologue-include.exp +++ b/gdb/testsuite/gdb.base/prologue-include.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { - return -1 + return } set bp_main [gdb_get_line_number "break main" ${testfile}.h] gdb_test "break -q main" \ diff --git a/gdb/testsuite/gdb.base/psym-external-decl.exp b/gdb/testsuite/gdb.base/psym-external-decl.exp index b4b62f21b13e..bbe8a043fabf 100644 --- a/gdb/testsuite/gdb.base/psym-external-decl.exp +++ b/gdb/testsuite/gdb.base/psym-external-decl.exp @@ -14,21 +14,21 @@ # along with this program. If not, see . */ standard_testfile .c psym-external-decl-2.c if { [test_compiler_info "clang-*"] } { - return -1 + return } set srcfiles [list $srcfile $srcfile2] if { [build_executable_from_specs \ "failed to prepare" \ $testfile [list] \ $srcfile [list debug] \ $srcfile2 [list]] == -1 } { - return -1 + return } clean_restart $testfile gdb_test "print aaa" " = 33" diff --git a/gdb/testsuite/gdb.base/psymtab.exp b/gdb/testsuite/gdb.base/psymtab.exp index 9a979cdce971..2103ace870e6 100644 --- a/gdb/testsuite/gdb.base/psymtab.exp +++ b/gdb/testsuite/gdb.base/psymtab.exp @@ -28,11 +28,11 @@ require allow_cplus_tests standard_testfile psymtab1.c psymtab2.c if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] debug]} { - return -1 + return } # Disable the prompt for whether to set pending breakpoints. # We don't want a breakpoint, we just want to verify the symbol # isn't found. diff --git a/gdb/testsuite/gdb.base/ptype-offsets-c.exp b/gdb/testsuite/gdb.base/ptype-offsets-c.exp index cffcbbeb2f7a..fd88514f5f6b 100644 --- a/gdb/testsuite/gdb.base/ptype-offsets-c.exp +++ b/gdb/testsuite/gdb.base/ptype-offsets-c.exp @@ -28,11 +28,11 @@ if { ![is_lp64_target] } { untested "test work only on lp64 targets" return 0 } if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Tests handling flexible array member. Regression tests for PR gdb/33966. set l { "ptype /o struct flexible_array_member" diff --git a/gdb/testsuite/gdb.base/ptype-offsets.exp b/gdb/testsuite/gdb.base/ptype-offsets.exp index 2ee3470ba10f..56dca939fb33 100644 --- a/gdb/testsuite/gdb.base/ptype-offsets.exp +++ b/gdb/testsuite/gdb.base/ptype-offsets.exp @@ -27,11 +27,11 @@ if { ![is_lp64_target] } { return 0 } if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ { debug c++ }] } { - return -1 + return } # Test general offset printing, ctor/dtor printing, union, formatting. gdb_test "ptype /o struct abc" \ [string_to_regexp [multi_line \ diff --git a/gdb/testsuite/gdb.base/ptype.exp b/gdb/testsuite/gdb.base/ptype.exp index 5602defba64e..0539b87ddfea 100644 --- a/gdb/testsuite/gdb.base/ptype.exp +++ b/gdb/testsuite/gdb.base/ptype.exp @@ -21,11 +21,11 @@ standard_testfile .c ptype1.c if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } # Some tests require GCC. set gcc_compiled [is_c_compiler_gcc] @@ -78,20 +78,20 @@ gdb_test "ptype struct t_struct" \ # Test the equivalence between '.' and '->' for struct member references. if {[gdb_test "ptype v_struct1.v_float_member" "type = float"] < 0} { - return -1 + return } if {[gdb_test "ptype v_struct1->v_float_member" "type = float"] < 0} { - return -1 + return } if {[gdb_test "ptype v_t_struct_p.v_float_member" "type = float"] < 0} { - return -1 + return } if {[gdb_test "ptype v_t_struct_p->v_float_member" "type = float"] < 0} { - return -1 + return } # IBM's xlc puts out bogus stabs--the stuff field is type 42, # which isn't defined. diff --git a/gdb/testsuite/gdb.base/random-signal.exp b/gdb/testsuite/gdb.base/random-signal.exp index 77d106477209..e0c5e669c2f2 100644 --- a/gdb/testsuite/gdb.base/random-signal.exp +++ b/gdb/testsuite/gdb.base/random-signal.exp @@ -19,11 +19,11 @@ require {!target_info exists gdb,nosignals} require {!target_info exists gdb,nointerrupts} standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Set a software watchpoint, continue, wait a bit and stop the target # with ctrl-c. A software watchpoint forces the target to # single-step. diff --git a/gdb/testsuite/gdb.base/randomize.exp b/gdb/testsuite/gdb.base/randomize.exp index 52c2ff71ab12..58c2c78ee26a 100644 --- a/gdb/testsuite/gdb.base/randomize.exp +++ b/gdb/testsuite/gdb.base/randomize.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc address_get { testname } { global gdb_prompt @@ -60,11 +60,11 @@ gdb_test "show disable-randomization" \ set addr1 [address_get "randomized first address"] set addr2 [address_get "randomized second address"] set test "randomized addresses should not match" if {[string equal $addr1 $addr2]} { untested "no randomization detected on this system" - return -1 + return } else { pass $test } gdb_test_no_output "set disable-randomization on" diff --git a/gdb/testsuite/gdb.base/range-stepping.exp b/gdb/testsuite/gdb.base/range-stepping.exp index 53083f066c35..06d976bdf255 100644 --- a/gdb/testsuite/gdb.base/range-stepping.exp +++ b/gdb/testsuite/gdb.base/range-stepping.exp @@ -17,20 +17,20 @@ load_lib "range-stepping-support.exp" standard_testfile set executable $testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } if {![gdb_range_stepping_enabled]} { unsupported "range stepping not supported by the target" - return -1 + return } # Check that range stepping can step a range of multiple instructions. with_test_prefix "multi insns" { diff --git a/gdb/testsuite/gdb.base/readline-ask.exp b/gdb/testsuite/gdb.base/readline-ask.exp index 0981860eacff..bee3fbba4e78 100644 --- a/gdb/testsuite/gdb.base/readline-ask.exp +++ b/gdb/testsuite/gdb.base/readline-ask.exp @@ -18,22 +18,22 @@ require {!is_remote host} standard_testfile .c set inputrc ${srcdir}/${subdir}/${testfile}.inputrc if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {debug}] != "" } { untested "failed to compile" - return -1 + return } setenv TERM dumb # INPUTRC gets reset for the next testfile. setenv INPUTRC $inputrc clean_restart $testfile if { ![readline_is_used] } { unsupported "completion doesn't work when readline isn't used." - return -1 + return } gdb_test_no_output "set width 50" gdb_test_no_output "set height 3" diff --git a/gdb/testsuite/gdb.base/readline-commands-eof.exp b/gdb/testsuite/gdb.base/readline-commands-eof.exp index 6fa6cf96e656..7da5f08fc7b5 100644 --- a/gdb/testsuite/gdb.base/readline-commands-eof.exp +++ b/gdb/testsuite/gdb.base/readline-commands-eof.exp @@ -21,20 +21,20 @@ # lines in the output. standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # The fix for this issue relies on GDB being able to adjust the EOF # flag state within readline. Access to this state was added for # readline 8.2, but was also backported to out internal readline. If # this feature is not available then this test might not pass. if { ![readline_supports_eof_flag] } { unsupported "readline is not eof flag aware" - return -1 + return } # Create a breakpoint then issue the 'commands' commands. When the # secondary prompt is displayed, use Ctrl+d to send EOF to readline # and cancel the input. diff --git a/gdb/testsuite/gdb.base/readnever.exp b/gdb/testsuite/gdb.base/readnever.exp index 427b9a82c85d..9f74b8b005d5 100644 --- a/gdb/testsuite/gdb.base/readnever.exp +++ b/gdb/testsuite/gdb.base/readnever.exp @@ -19,11 +19,11 @@ require !readnow standard_testfile .c if { [build_executable "failed to build" $testfile $srcfile { debug }] == -1 } { untested "couldn't compile ${srcfile}" - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " --readnever" if { [clean_restart $testfile] == -1 } { diff --git a/gdb/testsuite/gdb.base/realname-expand.exp b/gdb/testsuite/gdb.base/realname-expand.exp index 5c8e8acb1298..5817cd57d9db 100644 --- a/gdb/testsuite/gdb.base/realname-expand.exp +++ b/gdb/testsuite/gdb.base/realname-expand.exp @@ -24,17 +24,17 @@ set srcfilelink [standard_output_file realname-expand-link.c] remote_exec build "ln -sf ${srcdirabs}/${subdir}/${srcfile2} $srcfilelink" if { [file type $srcfilelink] != "link" } { unsupported "target directory cannot have symbolic links" - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${srcfile} ${srcfilelink}" "${binfile}" \ executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart ${testfile} gdb_test_no_output "set basenames-may-differ on" diff --git a/gdb/testsuite/gdb.base/recpar.exp b/gdb/testsuite/gdb.base/recpar.exp index b325002b2d38..3812884dc468 100644 --- a/gdb/testsuite/gdb.base/recpar.exp +++ b/gdb/testsuite/gdb.base/recpar.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break $srcfile:[gdb_get_line_number BREAK $srcfile] if n == 3" \ "Breakpoint $decimal at $hex: file .*recpar\\.c, line $decimal\\." diff --git a/gdb/testsuite/gdb.base/recurse.exp b/gdb/testsuite/gdb.base/recurse.exp index f96e1e3072a3..4a59cecf8fba 100644 --- a/gdb/testsuite/gdb.base/recurse.exp +++ b/gdb/testsuite/gdb.base/recurse.exp @@ -24,11 +24,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc recurse_tests {} { # Disable hardware watchpoints if necessary. diff --git a/gdb/testsuite/gdb.base/reggroups.exp b/gdb/testsuite/gdb.base/reggroups.exp index ce5cb50d85c7..f3866ec51cf4 100644 --- a/gdb/testsuite/gdb.base/reggroups.exp +++ b/gdb/testsuite/gdb.base/reggroups.exp @@ -18,11 +18,11 @@ # Test listing reggroups and the registers in each group. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/relational.exp b/gdb/testsuite/gdb.base/relational.exp index 01b635f9694a..f75043643ec2 100644 --- a/gdb/testsuite/gdb.base/relational.exp +++ b/gdb/testsuite/gdb.base/relational.exp @@ -24,11 +24,11 @@ # # test running programs # if { [prepare_for_testing "failed to prepare" relational int-type.c {debug nowarnings}] } { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.base/remote.exp b/gdb/testsuite/gdb.base/remote.exp index 9fa50611ed5b..da13e9f13fe7 100644 --- a/gdb/testsuite/gdb.base/remote.exp +++ b/gdb/testsuite/gdb.base/remote.exp @@ -23,11 +23,11 @@ if {[target_info gdb_protocol] != "remote" standard_testfile .c set result [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] if {$result != ""} { untested "failed to compile" - return -1 + return } gdb_start # Make sure we're disconnected, in case we're testing with an diff --git a/gdb/testsuite/gdb.base/reread-readsym.exp b/gdb/testsuite/gdb.base/reread-readsym.exp index 6db4eacc1b92..8457d2e4fbba 100644 --- a/gdb/testsuite/gdb.base/reread-readsym.exp +++ b/gdb/testsuite/gdb.base/reread-readsym.exp @@ -39,11 +39,11 @@ proc generate_cmd_file {gdbfile binfile} { } require !use_gdb_stub if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Using the source command to read commands from a file is important, # otherwise section data is freed and reallocated using the same # memory locations and the bug is not exposed. diff --git a/gdb/testsuite/gdb.base/restore.exp b/gdb/testsuite/gdb.base/restore.exp index d5e78238575c..ce7fe5b3ca11 100644 --- a/gdb/testsuite/gdb.base/restore.exp +++ b/gdb/testsuite/gdb.base/restore.exp @@ -23,11 +23,11 @@ standard_testfile set executable $testfile if { [prepare_for_testing "failed to prepare" $executable $srcfile] } { - return -1 + return } proc restore_tests { } { global gdb_prompt @@ -96,9 +96,9 @@ restore_tests set timeout $prev_timeout # Test PR cli/23785 clean_restart $testfile if { ![runto_main] } { - return -1 + return } gdb_test "restore non-existent-file binary" \ "Failed to open non-existent-file: .*" diff --git a/gdb/testsuite/gdb.base/return-3.exp b/gdb/testsuite/gdb.base/return-3.exp index d2f7739b1e3c..8c958a2245ac 100644 --- a/gdb/testsuite/gdb.base/return-3.exp +++ b/gdb/testsuite/gdb.base/return-3.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if { ![runto bar] } { - return -1 + return } with_test_prefix "in bar" { gdb_test "return" \ [string_to_regexp "Can not force return from an inlined function."] diff --git a/gdb/testsuite/gdb.base/return.exp b/gdb/testsuite/gdb.base/return.exp index 2899ce9dbbbb..7b4f6fea320d 100644 --- a/gdb/testsuite/gdb.base/return.exp +++ b/gdb/testsuite/gdb.base/return.exp @@ -16,11 +16,11 @@ # This file was written by Jeff Law. (law@cs.utah.edu) set allow_float_test [allow_float_test] if { [prepare_for_testing "failed to prepare" "return"] } { - return -1 + return } proc return_tests { } { global gdb_prompt allow_float_test diff --git a/gdb/testsuite/gdb.base/retval-large-struct.exp b/gdb/testsuite/gdb.base/retval-large-struct.exp index 0ba13810cd6e..7bdc8af2a0f4 100644 --- a/gdb/testsuite/gdb.base/retval-large-struct.exp +++ b/gdb/testsuite/gdb.base/retval-large-struct.exp @@ -25,15 +25,15 @@ set additional_flags "" if {[have_fvar_tracking]} { set additional_flags "additional_flags= -fvar-tracking" } if {[prepare_for_testing "failed to prepare" $testfile $srcfile [list debug $additional_flags]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } set pattern ".* = \\{int_array = \\{1, 2, 3, 4, 5\\}, double_array = \\{3.25, 5, 6.25, 1.325, -1.95\\}, char_array = \"abcde\"\\}" gdb_test "p return_large_struct ()" $pattern diff --git a/gdb/testsuite/gdb.base/rtld-step.exp b/gdb/testsuite/gdb.base/rtld-step.exp index 3beab5ee334e..57f878dfb395 100644 --- a/gdb/testsuite/gdb.base/rtld-step.exp +++ b/gdb/testsuite/gdb.base/rtld-step.exp @@ -91,11 +91,11 @@ if { ![gdb_can_simple_compile static-pie-static-libc \ void _start (void) { _exit (0); } } \ executable $rtld_flags] } { set reason "-static-pie not supported or static libc missing" untested "failed to compile ($reason)" - return -1 + return } # Main program file names and flags: set main_basename ${::gdb_test_file_name}-main set srcfile_main ${srcdir}/${subdir}/${main_basename}.c @@ -106,17 +106,17 @@ lappend main_flags \ additional_flags=[quote_for_host -Wl,--dynamic-linker=$binfile_rtld] # Compile pretend RTLD: if { [gdb_compile ${srcfile_rtld} ${binfile_rtld} executable $rtld_flags] != "" } { untested "failed to compile" - return -1 + return } # Compile main program: if { [gdb_compile ${srcfile_main} ${binfile_main} executable $main_flags] != "" } { untested "failed to compile" - return -1 + return } clean_restart gdb_load $binfile_main diff --git a/gdb/testsuite/gdb.base/run-after-attach.exp b/gdb/testsuite/gdb.base/run-after-attach.exp index 4a170b88c71d..256f2fbcdd1a 100644 --- a/gdb/testsuite/gdb.base/run-after-attach.exp +++ b/gdb/testsuite/gdb.base/run-after-attach.exp @@ -20,11 +20,11 @@ require can_spawn_for_attach standard_testfile set executable $testfile if {[prepare_for_testing "failed to prepare" $executable]} { - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set test_pid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.base/run-fail-twice.exp b/gdb/testsuite/gdb.base/run-fail-twice.exp index 57a7c437e40b..8fcfee9eee00 100644 --- a/gdb/testsuite/gdb.base/run-fail-twice.exp +++ b/gdb/testsuite/gdb.base/run-fail-twice.exp @@ -18,11 +18,11 @@ require target_can_use_run_cmd standard_testfile if {[build_executable "failed to build" $testfile $srcfile {debug}]} { - return -1 + return } proc test_run {testname} { gdb_test_multiple "run" $testname { -re -wrap "During startup program exited with code 126\\." { diff --git a/gdb/testsuite/gdb.base/save-bp.exp b/gdb/testsuite/gdb.base/save-bp.exp index 2e27f9ebbf8a..0c0eb860d286 100644 --- a/gdb/testsuite/gdb.base/save-bp.exp +++ b/gdb/testsuite/gdb.base/save-bp.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Delete all breakpoints, watchpoints, tracepoints, and catchpoints so that # the "runto_main" breakpoint above does not interfere with our testing. delete_breakpoints @@ -60,11 +60,11 @@ remote_file host delete "$bps" gdb_test "save breakpoint $bps" "" "save breakpoint bps" # Now start a new debugger session... clean_restart $testfile if {![runto_main]} { - return -1 + return } # Delete all breakpoints, watchpoints, tracepoints, and catchpoints so that # the "runto_main" breakpoint above does not interfere with our testing. delete_breakpoints diff --git a/gdb/testsuite/gdb.base/scope-hw-watch-disable.exp b/gdb/testsuite/gdb.base/scope-hw-watch-disable.exp index 67305ebb87b7..e45d10dc7b00 100644 --- a/gdb/testsuite/gdb.base/scope-hw-watch-disable.exp +++ b/gdb/testsuite/gdb.base/scope-hw-watch-disable.exp @@ -18,17 +18,17 @@ # successfully after several attempts to insert a hardware watchpoint. standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } gdb_test_no_output "set can-use-hw-watchpoints 0" if {![runto_main]} { - return -1 + return } gdb_test_multiple "maint info break" "maint info break before" { -re -wrap "watchpoint.*" { fail $gdb_test_name diff --git a/gdb/testsuite/gdb.base/scope.exp b/gdb/testsuite/gdb.base/scope.exp index b82465a1184d..338e4a4b4467 100644 --- a/gdb/testsuite/gdb.base/scope.exp +++ b/gdb/testsuite/gdb.base/scope.exp @@ -18,11 +18,11 @@ standard_testfile scope0.c scope1.c if {[build_executable "failed to build" ${testfile} \ [list $srcfile $srcfile2] {debug}]} { - return -1 + return } # Test locating various things when stopped just inside main, after # running init0(). To prevent cascading of errors, we report the # first one and quit. If all pass, then we print the pass results. diff --git a/gdb/testsuite/gdb.base/sect-cmd.exp b/gdb/testsuite/gdb.base/sect-cmd.exp index 0c2a413b6943..c6300aa52992 100644 --- a/gdb/testsuite/gdb.base/sect-cmd.exp +++ b/gdb/testsuite/gdb.base/sect-cmd.exp @@ -15,11 +15,11 @@ # Test the 'section NAME ADDRESS' command. if { [prepare_for_testing "failed to prepare" "sect-cmd" \ {break.c break1.c} {debug nowarnings}] } { - return -1 + return } set srcfile break.c set srcfile1 break1.c if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/sepdebug.exp b/gdb/testsuite/gdb.base/sepdebug.exp index bbb9eb7cd16b..1ada019ea434 100644 --- a/gdb/testsuite/gdb.base/sepdebug.exp +++ b/gdb/testsuite/gdb.base/sepdebug.exp @@ -31,11 +31,11 @@ standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug nowarnings}] != "" } { untested "failed to compile" - return -1 + return } # Note: the procedure gdb_gnu_strip_debug will produce an executable called # ${binfile}, which is just like the executable ($binfile) but without # the debuginfo. Instead $binfile has a .gnu_debuglink section which contains @@ -43,11 +43,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb # gdb.base/ subdirectory. if {[gdb_gnu_strip_debug $binfile$EXEEXT]} { # check that you have a recent version of strip and objcopy installed unsupported "cannot produce separate debug info files" - return -1 + return } # # PR gdb/9538. Verify that symlinked executable still finds the separate # debuginfo. diff --git a/gdb/testsuite/gdb.base/sepsymtab.exp b/gdb/testsuite/gdb.base/sepsymtab.exp index 0677ef57b4fb..aecb1b93f32f 100644 --- a/gdb/testsuite/gdb.base/sepsymtab.exp +++ b/gdb/testsuite/gdb.base/sepsymtab.exp @@ -20,17 +20,17 @@ standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[gdb_gnu_strip_debug $binfile no-main]} { # check that you have a recent version of strip and objcopy installed unsupported "cannot produce separate debug info files" - return -1 + return } clean_restart $testfile set command "info sym main" diff --git a/gdb/testsuite/gdb.base/server-del-break.exp b/gdb/testsuite/gdb.base/server-del-break.exp index 6bc95d5bd7f0..4401a848589f 100644 --- a/gdb/testsuite/gdb.base/server-del-break.exp +++ b/gdb/testsuite/gdb.base/server-del-break.exp @@ -19,11 +19,11 @@ # command to demonstrate the behavior. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "break -q main" \ "Breakpoint.*at.* file .*$srcfile, line .*" diff --git a/gdb/testsuite/gdb.base/set-cwd.exp b/gdb/testsuite/gdb.base/set-cwd.exp index 3fbffdc6136f..279004596a1e 100644 --- a/gdb/testsuite/gdb.base/set-cwd.exp +++ b/gdb/testsuite/gdb.base/set-cwd.exp @@ -18,11 +18,11 @@ require !use_gdb_stub standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } # Test that tilde expansion works fine. proc_with_prefix test_tilde_expansion { } { diff --git a/gdb/testsuite/gdb.base/set-inferior-tty.exp b/gdb/testsuite/gdb.base/set-inferior-tty.exp index 1d0ee21b4cba..be82eeed6b18 100644 --- a/gdb/testsuite/gdb.base/set-inferior-tty.exp +++ b/gdb/testsuite/gdb.base/set-inferior-tty.exp @@ -16,11 +16,11 @@ standard_testfile set compile_options "debug" if {[build_executable $testfile.exp $testfile ${srcfile} ${compile_options}] == -1} { untested "failed to compile" - return -1 + return } proc test_set_inferior_tty { command } { clean_restart $::testfile diff --git a/gdb/testsuite/gdb.base/set-lang-auto.exp b/gdb/testsuite/gdb.base/set-lang-auto.exp index 2cbc5930f6de..f003c2307e9b 100644 --- a/gdb/testsuite/gdb.base/set-lang-auto.exp +++ b/gdb/testsuite/gdb.base/set-lang-auto.exp @@ -15,11 +15,11 @@ standard_testfile start.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Do not run the inferior as the purpose of this testcase is to test # the behavior of the "set language" command when there is no inferior. diff --git a/gdb/testsuite/gdb.base/set-noassign.exp b/gdb/testsuite/gdb.base/set-noassign.exp index 41a3f096cafa..0f3b843cd1fe 100644 --- a/gdb/testsuite/gdb.base/set-noassign.exp +++ b/gdb/testsuite/gdb.base/set-noassign.exp @@ -13,11 +13,11 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . if { [prepare_for_testing "failed to prepare" "set-noassign" start.c {debug nowarnings}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/settings.exp b/gdb/testsuite/gdb.base/settings.exp index 48c015a3552a..2da8d47405bb 100644 --- a/gdb/testsuite/gdb.base/settings.exp +++ b/gdb/testsuite/gdb.base/settings.exp @@ -22,18 +22,18 @@ load_lib completion-support.exp standard_testfile .c if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } clean_restart if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } # Test the show command SHOW_CMD. EXPECTED_RE is the expected output. # Also verifies that $_gdb_maint_setting_str produces an equivalent output, # matching it with EXPECTED_RE. EXPECTED_RE double quotes are escaped diff --git a/gdb/testsuite/gdb.base/setvar.exp b/gdb/testsuite/gdb.base/setvar.exp index 8a3b88631d01..14fba5497a87 100644 --- a/gdb/testsuite/gdb.base/setvar.exp +++ b/gdb/testsuite/gdb.base/setvar.exp @@ -25,11 +25,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # # set it up at a breakpoint so we canplay with the variable values # diff --git a/gdb/testsuite/gdb.base/share-env-with-gdbserver.exp b/gdb/testsuite/gdb.base/share-env-with-gdbserver.exp index e1b3540d5d7e..60875224de2f 100644 --- a/gdb/testsuite/gdb.base/share-env-with-gdbserver.exp +++ b/gdb/testsuite/gdb.base/share-env-with-gdbserver.exp @@ -19,11 +19,11 @@ require !use_gdb_stub standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } set test_var_name "GDB_TEST_VAR" # Helper function that performs a check on the output of "getenv". diff --git a/gdb/testsuite/gdb.base/share-psymtabs-bt.exp b/gdb/testsuite/gdb.base/share-psymtabs-bt.exp index 8fd40cdaecd7..6984e70354e4 100644 --- a/gdb/testsuite/gdb.base/share-psymtabs-bt.exp +++ b/gdb/testsuite/gdb.base/share-psymtabs-bt.exp @@ -28,23 +28,23 @@ standard_testfile .c share-psymtabs-bt-2.c if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" \ {debug}] } { untested "failed to compile" - return -1 + return } # Load $binfile a second time. The second created objfile will re-use the # partial symtabs created by the first one. if { [gdb_file_cmd $binfile] != 0 } { fail "file command failed" - return -1 + return } gdb_breakpoint "bar" if { ![runto "bar"] } { - return -1 + return } # A buggy GDB would fail to find the full symbol associated to this frame's # address, so would just show "foo ()" (from the minimal symbol). gdb_test "bt" "foo \\(x=12345\\).*" diff --git a/gdb/testsuite/gdb.base/sigall.exp b/gdb/testsuite/gdb.base/sigall.exp index 51cd91ed41ef..a550d1f71dda 100644 --- a/gdb/testsuite/gdb.base/sigall.exp +++ b/gdb/testsuite/gdb.base/sigall.exp @@ -16,11 +16,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc test_one_sig {nextsig} { global sig_supported global gdb_prompt diff --git a/gdb/testsuite/gdb.base/sigbpt.exp b/gdb/testsuite/gdb.base/sigbpt.exp index 02f907bdea6d..c3f17e0e9707 100644 --- a/gdb/testsuite/gdb.base/sigbpt.exp +++ b/gdb/testsuite/gdb.base/sigbpt.exp @@ -32,11 +32,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # # Run to `main' where we begin our tests. # diff --git a/gdb/testsuite/gdb.base/siginfo-addr.exp b/gdb/testsuite/gdb.base/siginfo-addr.exp index 0f7026d4a93c..93ce7a227909 100644 --- a/gdb/testsuite/gdb.base/siginfo-addr.exp +++ b/gdb/testsuite/gdb.base/siginfo-addr.exp @@ -23,11 +23,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "display/i \$pc" # Advance to main diff --git a/gdb/testsuite/gdb.base/siginfo-infcall.exp b/gdb/testsuite/gdb.base/siginfo-infcall.exp index f581989caaff..caf43d1ac4c3 100644 --- a/gdb/testsuite/gdb.base/siginfo-infcall.exp +++ b/gdb/testsuite/gdb.base/siginfo-infcall.exp @@ -16,15 +16,15 @@ require {!target_info exists gdb,nosignals} standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "pass" gdb_breakpoint "fail" diff --git a/gdb/testsuite/gdb.base/siginfo-obj.exp b/gdb/testsuite/gdb.base/siginfo-obj.exp index bf59dd937946..daf160bc162b 100644 --- a/gdb/testsuite/gdb.base/siginfo-obj.exp +++ b/gdb/testsuite/gdb.base/siginfo-obj.exp @@ -27,11 +27,11 @@ require supports_get_siginfo_type standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Advance to main if {![runto_main]} { return 0 diff --git a/gdb/testsuite/gdb.base/siginfo.exp b/gdb/testsuite/gdb.base/siginfo.exp index 92d712053f05..f5a00220f12a 100644 --- a/gdb/testsuite/gdb.base/siginfo.exp +++ b/gdb/testsuite/gdb.base/siginfo.exp @@ -27,11 +27,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "display/i \$pc" # Advance to main diff --git a/gdb/testsuite/gdb.base/signals-state-child.exp b/gdb/testsuite/gdb.base/signals-state-child.exp index 0c3da466af45..5c0be259c00a 100644 --- a/gdb/testsuite/gdb.base/signals-state-child.exp +++ b/gdb/testsuite/gdb.base/signals-state-child.exp @@ -45,17 +45,17 @@ remote_file target delete $gdb_txt remote_file target delete $standalone_txt set options [list debug "additional_flags=-DOUTPUT_TXT=\"$gdb_txt\""] if {[build_executable $testfile.exp $testfile $srcfile $options]} { untested "failed to compile" - return -1 + return } set options [list debug "additional_flags=-DOUTPUT_TXT=\"$standalone_txt\""] if {[build_executable $testfile.exp $testfile-standalone $srcfile $options]} { untested "failed to compile" - return -1 + return } # Run the program directly, and dump its initial signal actions and # mask in "standalone.txt". @@ -98,19 +98,19 @@ remote_close target # and mask in "gdb.txt". clean_restart $testfile if {![runto_main]} { - return -1 + return } gdb_continue_to_end "collect signals state under gdb" set test "signals states are identical" if { ! $have_standalone } { untested $test - return -1 + return } if {!$purely_local} { # Copy file from target to host through build. remote_download host [remote_upload target gdb.txt] gdb.txt diff --git a/gdb/testsuite/gdb.base/signals.exp b/gdb/testsuite/gdb.base/signals.exp index 56aa73aa5500..da3eb6dae5ba 100644 --- a/gdb/testsuite/gdb.base/signals.exp +++ b/gdb/testsuite/gdb.base/signals.exp @@ -18,11 +18,11 @@ require {!target_info exists gdb,nosignals} standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } gdb_exit gdb_start diff --git a/gdb/testsuite/gdb.base/signed-builtin-types.exp b/gdb/testsuite/gdb.base/signed-builtin-types.exp index 29e2f9853532..abe4a9c4cbad 100644 --- a/gdb/testsuite/gdb.base/signed-builtin-types.exp +++ b/gdb/testsuite/gdb.base/signed-builtin-types.exp @@ -21,26 +21,26 @@ standard_testfile .c -lib.c set srcdso [file join $srcdir $subdir $srcfile2] set libname "lib${gdb_test_file_name}.so" set objdso [standard_output_file $libname] if {[gdb_compile_shlib $srcdso $objdso {debug}] != ""} { untested "failed to compile dso" - return -1 + return } # Build the test executable and runto main. set opts [list debug shlib=$objdso] if { [prepare_for_testing "failed to " $testfile $srcfile $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } if {[readnow]} { untested "this test checks for delayed symtab expansion" - return -1 + return } # Use 'info sources' to check if the debug information for the shared # library has been fully expanded or not. Return true if the debug # information has NOT been fully expanded (which is what we want for this diff --git a/gdb/testsuite/gdb.base/signest.exp b/gdb/testsuite/gdb.base/signest.exp index 920cdb907e74..465c8452d62d 100644 --- a/gdb/testsuite/gdb.base/signest.exp +++ b/gdb/testsuite/gdb.base/signest.exp @@ -18,26 +18,26 @@ standard_testfile require {!target_info exists gdb,nosignals} if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # If we can examine what's at memory address 0, it is possible that we # could also execute it. This could probably make us run away, # executing random code, which could have all sorts of ill effects, # especially on targets without an MMU. Don't run the tests in that # case. if { [is_address_zero_readable] } { untested "memory at address 0 is possibly executable" - return -1 + return } # Run until we hit the SIGSEGV (or SIGBUS on some platforms). gdb_test "continue" \ ".*Program received signal (SIGBUS|SIGSEGV).*bowler.*" \ diff --git a/gdb/testsuite/gdb.base/sigstep.exp b/gdb/testsuite/gdb.base/sigstep.exp index 2507504c5ccb..9199216b051b 100644 --- a/gdb/testsuite/gdb.base/sigstep.exp +++ b/gdb/testsuite/gdb.base/sigstep.exp @@ -26,11 +26,11 @@ require {!target_info exists gdb,nosignals} standard_testfile if {[build_executable $testfile.exp $testfile $srcfile debug]} { untested "failed to compile" - return -1 + return } set clear_done [gdb_get_line_number {done = 0}] set infinite_loop [gdb_get_line_number {while (!done)}] set other_handler_location [gdb_get_line_number "other handler location"] diff --git a/gdb/testsuite/gdb.base/sizeof.exp b/gdb/testsuite/gdb.base/sizeof.exp index 50930c82c6a4..48caebe2f16d 100644 --- a/gdb/testsuite/gdb.base/sizeof.exp +++ b/gdb/testsuite/gdb.base/sizeof.exp @@ -20,11 +20,11 @@ # standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.base/skip-inline.exp b/gdb/testsuite/gdb.base/skip-inline.exp index c2fd05808bd6..a0223efa2eb5 100644 --- a/gdb/testsuite/gdb.base/skip-inline.exp +++ b/gdb/testsuite/gdb.base/skip-inline.exp @@ -18,11 +18,11 @@ standard_testfile set epilogue [have_epilogue_line_info] if { [prepare_for_testing "failed to prepare" "skip-inline" \ {skip-inline.c skip1.c } \ {debug nowarnings}] } { - return -1 + return } set srcfile skip-inline.c set srcfile1 skip1.c diff --git a/gdb/testsuite/gdb.base/skip-solib.exp b/gdb/testsuite/gdb.base/skip-solib.exp index e8890288fa3c..1382c7ce831c 100644 --- a/gdb/testsuite/gdb.base/skip-solib.exp +++ b/gdb/testsuite/gdb.base/skip-solib.exp @@ -39,22 +39,22 @@ set binfile_lib [standard_output_file ${libname}.so] # the main program. # if {[gdb_compile_shlib ${srcdir}/${subdir}/${srcfile_lib} ${binfile_lib} \ [list debug]] != ""} { - return -1 + return } if {[gdb_compile "${srcdir}/${subdir}/${srcfile_main}" "${binfile_main}.o" \ object debug] != ""} { - return -1 + return } set testobjdir [standard_output_file {}] if {[gdb_compile "${binfile_main}.o" "${binfile_main}" executable \ [list debug shlib=$binfile_lib]] != ""} { - return -1 + return } # # Test ignoring of a file inside a solib. # diff --git a/gdb/testsuite/gdb.base/skip.exp b/gdb/testsuite/gdb.base/skip.exp index 3807fb333255..8ba6e8cda569 100644 --- a/gdb/testsuite/gdb.base/skip.exp +++ b/gdb/testsuite/gdb.base/skip.exp @@ -21,11 +21,11 @@ load_lib completion-support.exp standard_testfile if { [prepare_for_testing "failed to prepare" "skip" \ {skip.c skip1.c } \ {debug nowarnings}] } { - return -1 + return } set srcfile skip.c set srcfile1 skip1.c diff --git a/gdb/testsuite/gdb.base/skipcxx.exp b/gdb/testsuite/gdb.base/skipcxx.exp index 06f9912d763e..9e1c0f293c8d 100644 --- a/gdb/testsuite/gdb.base/skipcxx.exp +++ b/gdb/testsuite/gdb.base/skipcxx.exp @@ -18,11 +18,11 @@ standard_testfile .cc set flags {} lappend flags debug lappend flags c++ if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/solib-corrupted.exp b/gdb/testsuite/gdb.base/solib-corrupted.exp index 19be38f77388..f733579809f6 100644 --- a/gdb/testsuite/gdb.base/solib-corrupted.exp +++ b/gdb/testsuite/gdb.base/solib-corrupted.exp @@ -21,11 +21,11 @@ require {!is_remote target} set testfile "solib-corrupted" set srcfile start.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # With probes interface GDB no longer scans the inferior library list so its # corruption cannot be tested. Disable the probes interface. gdb_test "maint ignore-probes rtld" diff --git a/gdb/testsuite/gdb.base/solib-nodir.exp b/gdb/testsuite/gdb.base/solib-nodir.exp index 29b641b43e2b..4189e1abd5b3 100644 --- a/gdb/testsuite/gdb.base/solib-nodir.exp +++ b/gdb/testsuite/gdb.base/solib-nodir.exp @@ -40,11 +40,11 @@ if { [build_executable "build library" ${binlibfile} ${srclibfile} \ {debug shlib}] == -1 || [gdb_gnu_strip_debug $binlibfile] || [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug}] != "" || [gdb_compile "${objfile} ${binlibfile}" "${binfile}" executable {}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $executable gdb_load_shlib ${binlibfile} diff --git a/gdb/testsuite/gdb.base/solib-probes-nosharedlibrary.exp b/gdb/testsuite/gdb.base/solib-probes-nosharedlibrary.exp index 44617f42a8b1..9b4c339cb92d 100644 --- a/gdb/testsuite/gdb.base/solib-probes-nosharedlibrary.exp +++ b/gdb/testsuite/gdb.base/solib-probes-nosharedlibrary.exp @@ -19,11 +19,11 @@ # would deference a dangling solib event probe pointer. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {$use_gdb_stub && [target_info exists gdb,do_reload_on_run]} { # This is the path taken by gdbserver "target remote" boards. if { [gdb_reload] != 0 } { diff --git a/gdb/testsuite/gdb.base/solib-search.exp b/gdb/testsuite/gdb.base/solib-search.exp index c4b2730e8f2d..43f54b41df0e 100644 --- a/gdb/testsuite/gdb.base/solib-search.exp +++ b/gdb/testsuite/gdb.base/solib-search.exp @@ -63,20 +63,20 @@ remote_exec build "mkdir [standard_output_file ${right_lib_subdir}]" if { [gdb_compile_shlib ${srcfile1_lib} ${wrong_binfile1_lib} $wrong_lib_flags] != "" || [gdb_compile_shlib ${srcfile2_lib} ${wrong_binfile2_lib} $wrong_lib_flags] != "" || [gdb_compile_shlib ${srcfile1_lib} ${right_binfile1_lib} $right_lib_flags] != "" || [gdb_compile_shlib ${srcfile2_lib} ${right_binfile2_lib} $right_lib_flags] != "" } { untested "failed to compile shared library" - return -1 + return } # Build the test binary using the right copies of the libraries. remote_exec build "ln -sf ${right_lib_subdir}/${libname1}.so ${binfile1_lib}" remote_exec build "ln -sf ${right_lib_subdir}/${libname2}.so ${binfile2_lib}" if { [gdb_compile $srcdir/$subdir/${srcfile} ${binfile} \ executable $bin_flags] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile if { ![runto_main] } { diff --git a/gdb/testsuite/gdb.base/solib-vanish.exp b/gdb/testsuite/gdb.base/solib-vanish.exp index 152e41760a02..80e28638b2d2 100644 --- a/gdb/testsuite/gdb.base/solib-vanish.exp +++ b/gdb/testsuite/gdb.base/solib-vanish.exp @@ -68,11 +68,11 @@ set binfile_lib1 [standard_output_file ${lib1name}.so] set lib1_flags [list debug shlib=${binfile_lib2}] if { [gdb_compile_shlib ${srcfile_lib2} ${binfile_lib2} $lib2_flags] != "" || [gdb_compile_shlib ${srcfile_lib1} ${binfile_lib1} $lib1_flags] != "" } { untested "failed to compile" - return -1 + return } # Main program set testfile "solib-vanish-main" set srcfile ${srcdir}/${subdir}/${testfile}.c @@ -86,11 +86,11 @@ if {[is_remote target]} { lappend cleanfiles_target $binfile_lib1_target.renamed } if { [gdb_compile ${srcfile} ${binfile} executable $bin_flags] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile gdb_locate_shlib $binfile_lib1 diff --git a/gdb/testsuite/gdb.base/source-execution.exp b/gdb/testsuite/gdb.base/source-execution.exp index 8f5e88540d93..a16535e97e4c 100644 --- a/gdb/testsuite/gdb.base/source-execution.exp +++ b/gdb/testsuite/gdb.base/source-execution.exp @@ -18,11 +18,11 @@ # Test sourcing a script that runs execution commands. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/source-open.exp b/gdb/testsuite/gdb.base/source-open.exp index e222c6420638..38802489247c 100644 --- a/gdb/testsuite/gdb.base/source-open.exp +++ b/gdb/testsuite/gdb.base/source-open.exp @@ -16,11 +16,11 @@ # Test the 'set source open on|off' command. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "show source open" "Source opening is \"on\"\\." \ "source opening is initially on" gdb_test_no_output "set listsize 1" diff --git a/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp b/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp index 691946d35f5f..6b299b3bc05a 100644 --- a/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp +++ b/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp @@ -36,11 +36,11 @@ require !gdb_debug_enabled standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp b/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp index 89fdb486a9c0..042caf6c27bb 100644 --- a/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp +++ b/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp @@ -19,11 +19,11 @@ standard_testfile set executable ${testfile} if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } @@ -40,11 +40,11 @@ gdb_test_multiple $test $test { pass $test } } if { $next_insn_addr == "" } { - return -1 + return } gdb_test "b *$next_insn_addr" "Breakpoint .*" "set breakpoint on address" # So that GDB doesn't try to remove the regular breakpoint when the diff --git a/gdb/testsuite/gdb.base/stale-infcall.exp b/gdb/testsuite/gdb.base/stale-infcall.exp index b602bea56cfc..cb7c09972032 100644 --- a/gdb/testsuite/gdb.base/stale-infcall.exp +++ b/gdb/testsuite/gdb.base/stale-infcall.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "test-next"] temporary gdb_continue_to_breakpoint "test-next" ".* test-next .*" gdb_breakpoint [gdb_get_line_number "test-fail"] diff --git a/gdb/testsuite/gdb.base/start-cpp.exp b/gdb/testsuite/gdb.base/start-cpp.exp index 58269005e517..3dbd860a0b9d 100644 --- a/gdb/testsuite/gdb.base/start-cpp.exp +++ b/gdb/testsuite/gdb.base/start-cpp.exp @@ -20,11 +20,11 @@ standard_testfile .cc set flags {} lappend flags debug lappend flags c++ if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } # This is a testcase specifically for the `start' GDB command. For regular # stop-in-main goal in the testcases consider using `runto_main' instead. @@ -33,11 +33,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { # location, even if we have a function named "main" in a non-root namespace. # For C++ programs, "start" should stop in main(). if { [gdb_start_cmd] < 0 } { fail start - return -1 + return } gdb_test "" \ "Temporary breakpoint $decimal at $hex: file.*main \\(\\) at .*start-cpp.cc:.*" \ "start" diff --git a/gdb/testsuite/gdb.base/start.exp b/gdb/testsuite/gdb.base/start.exp index b747e42efc6a..546926d32262 100644 --- a/gdb/testsuite/gdb.base/start.exp +++ b/gdb/testsuite/gdb.base/start.exp @@ -16,20 +16,20 @@ require !use_gdb_stub standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # This is a testcase specifically for the `start' GDB command. For regular # stop-in-main goal in the testcases consider using `runto_main' instead. # For C programs, "start" should stop in main(). if { [gdb_start_cmd] < 0 } { fail start - return -1 + return } gdb_test "" \ "main \\(\\) at .*start.c.*" \ "start" diff --git a/gdb/testsuite/gdb.base/starti.exp b/gdb/testsuite/gdb.base/starti.exp index 302be7aea6ee..ab0cfc2e9378 100644 --- a/gdb/testsuite/gdb.base/starti.exp +++ b/gdb/testsuite/gdb.base/starti.exp @@ -15,11 +15,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Define a stop hook that outputs the value of 'x' gdb_test_multiple "define hook-stop" "hook-stop" { @@ -28,11 +28,11 @@ gdb_test_multiple "define hook-stop" "hook-stop" { } } if { [gdb_starti_cmd] < 0 } { untested starti - return -1 + return } # The program should stop at the first instruction, so the constructor # should not have run yet and 'x' should be 0. diff --git a/gdb/testsuite/gdb.base/startup-with-shell.exp b/gdb/testsuite/gdb.base/startup-with-shell.exp index b27cdce63d73..6f30841bdb8d 100644 --- a/gdb/testsuite/gdb.base/startup-with-shell.exp +++ b/gdb/testsuite/gdb.base/startup-with-shell.exp @@ -25,11 +25,11 @@ require {!is_remote target} require {expr {[have_startup_shell] != -1}} standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } set unique_file [standard_output_file "unique-file.unique-extension"] set unique_file_dir [standard_output_file ""] diff --git a/gdb/testsuite/gdb.base/step-bt.exp b/gdb/testsuite/gdb.base/step-bt.exp index 5273234a7515..f7be4c2bec91 100644 --- a/gdb/testsuite/gdb.base/step-bt.exp +++ b/gdb/testsuite/gdb.base/step-bt.exp @@ -18,11 +18,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } gdb_test "break *hello" \ "Breakpoint.*at.* file .*$srcfile, line .*" \ "breakpoint at first instruction of hello()" diff --git a/gdb/testsuite/gdb.base/step-indirect-call-thunk.exp b/gdb/testsuite/gdb.base/step-indirect-call-thunk.exp index 877a0a61dbb2..30d0e6932a5d 100644 --- a/gdb/testsuite/gdb.base/step-indirect-call-thunk.exp +++ b/gdb/testsuite/gdb.base/step-indirect-call-thunk.exp @@ -22,15 +22,15 @@ set cflags "-mindirect-branch=thunk -mfunction-return=thunk" if { [gcc_major_version] >= 8 } { append cflags " -fcf-protection=none" } if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug "additional_flags=$cflags"]] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # Do repeated instruction steps in order to reach TARGET from CURRENT # # CURRENT is a string matching the current location diff --git a/gdb/testsuite/gdb.base/step-into-other-file.exp b/gdb/testsuite/gdb.base/step-into-other-file.exp index 775ab991d6ef..178224a1bed3 100644 --- a/gdb/testsuite/gdb.base/step-into-other-file.exp +++ b/gdb/testsuite/gdb.base/step-into-other-file.exp @@ -21,15 +21,15 @@ set flags {} lappend flags debug lappend_include_file flags $srcdir/$subdir/$srcfile2 if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ $flags] == -1 } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test step $srcfile:$decimal\r\n.* # Regression test for PR32011. diff --git a/gdb/testsuite/gdb.base/step-line.exp b/gdb/testsuite/gdb.base/step-line.exp index a1bcc7522e6a..e0a758357384 100644 --- a/gdb/testsuite/gdb.base/step-line.exp +++ b/gdb/testsuite/gdb.base/step-line.exp @@ -22,11 +22,11 @@ standard_testfile set linefile ${testfile}.inp if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/step-over-exit.exp b/gdb/testsuite/gdb.base/step-over-exit.exp index 263c640e876f..427ada57c90d 100644 --- a/gdb/testsuite/gdb.base/step-over-exit.exp +++ b/gdb/testsuite/gdb.base/step-over-exit.exp @@ -29,19 +29,19 @@ if { [istarget "i\[34567\]86-*-linux*"] || [istarget "x86_64-*-linux*"] } { set syscall_insn "\[ \t\](int|syscall|sysenter)\[ \t\]*" } elseif { [istarget "aarch64*-*-linux*"] || [istarget "arm*-*-linux*"] } { set syscall_insn "\[ \t\](swi|svc)\[ \t\]" } else { unsupported "unknown syscall instruction" - return -1 + return } if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "set follow-fork-mode child" gdb_test "set detach-on-fork off" diff --git a/gdb/testsuite/gdb.base/step-over-no-symbols.exp b/gdb/testsuite/gdb.base/step-over-no-symbols.exp index 18df1786039f..655b7a062d81 100644 --- a/gdb/testsuite/gdb.base/step-over-no-symbols.exp +++ b/gdb/testsuite/gdb.base/step-over-no-symbols.exp @@ -17,11 +17,11 @@ # symbols for the main binary. PR gdb/13858. standard_testfile start.c if { [build_executable "failed to build" ${testfile} $srcfile] } { - return -1 + return } # Get the current PC. MSG is used as test message. proc get_pc { msg } { diff --git a/gdb/testsuite/gdb.base/step-over-syscall.exp b/gdb/testsuite/gdb.base/step-over-syscall.exp index 335736f56850..12eff194efc4 100644 --- a/gdb/testsuite/gdb.base/step-over-syscall.exp +++ b/gdb/testsuite/gdb.base/step-over-syscall.exp @@ -36,11 +36,11 @@ if { [istarget "i\[34567\]86-*-linux*"] || [istarget "x86_64-*-linux*"] } { } array set syscall_number {fork "(120|220)" vfork "(190|220)" \ clone "(120|220)"} } else { - return -1 + return } proc_with_prefix check_pc_after_cross_syscall { displaced syscall syscall_insn_next_addr } { set syscall_insn_next_addr_found [get_hexadecimal_valueof "\$pc" "0"] @@ -357,11 +357,11 @@ step_over_syscall "vfork" step_over_syscall "clone" set testfile "step-over-fork" clean_restart $testfile if {![runto_main]} { - return -1 + return } set cond_bp_target 1 set test "set breakpoint condition-evaluation target" diff --git a/gdb/testsuite/gdb.base/step-resume-infcall.exp b/gdb/testsuite/gdb.base/step-resume-infcall.exp index 9c7c9fbde65a..90ff43539f3f 100644 --- a/gdb/testsuite/gdb.base/step-resume-infcall.exp +++ b/gdb/testsuite/gdb.base/step-resume-infcall.exp @@ -14,23 +14,23 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "step" " in-func .*" gdb_test "up" " call-func .*" gdb_test_no_output {set $b=$pc} if {![runto_main]} { - return -1 + return } gdb_breakpoint {*$b if cond ()} set test {print $bpnum} diff --git a/gdb/testsuite/gdb.base/step-sw-breakpoint-adjust-pc.exp b/gdb/testsuite/gdb.base/step-sw-breakpoint-adjust-pc.exp index af825c1ffe83..d8cf9da97f71 100644 --- a/gdb/testsuite/gdb.base/step-sw-breakpoint-adjust-pc.exp +++ b/gdb/testsuite/gdb.base/step-sw-breakpoint-adjust-pc.exp @@ -20,11 +20,11 @@ # this in non-stop mode, and adjust the PC incorrectly. PR gdb/12623. standard_testfile if {[build_executable "failed to build" ${testfile} ${srcfile} {debug}]} { - return -1 + return } set linenum_for_user_bp [gdb_get_line_number "break for user-bp test here"] set linenum_for_step_resume [gdb_get_line_number "break for step-resume test here"] diff --git a/gdb/testsuite/gdb.base/step-symless.exp b/gdb/testsuite/gdb.base/step-symless.exp index 0dcfec7da5ca..1f4dd88a103e 100644 --- a/gdb/testsuite/gdb.base/step-symless.exp +++ b/gdb/testsuite/gdb.base/step-symless.exp @@ -13,11 +13,11 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . standard_testfile if {[build_executable ${testfile}.exp ${testfile} ${srcfile} {nodebug}] == -1} { - return -1 + return } # We need those symbols global to access them from the .S file. set test "strip stub symbols" set objcopy_program [gdb_find_objcopy] @@ -31,11 +31,11 @@ if {$result != 0} { pass $test clean_restart $testfile if {![runto_main]} { - return -1 + return } gdb_breakpoint symful gdb_test "step" "Single stepping until exit.*no line number information.*\r\nBreakpoint \[^\r\n\]* in \\.?symful \\(\\)" diff --git a/gdb/testsuite/gdb.base/store.exp b/gdb/testsuite/gdb.base/store.exp index bc8b11760020..d4165baed384 100644 --- a/gdb/testsuite/gdb.base/store.exp +++ b/gdb/testsuite/gdb.base/store.exp @@ -17,11 +17,11 @@ standard_testfile set executable $testfile if { [prepare_for_testing "failed to prepare" $executable $srcfile] } { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.base/structs2.exp b/gdb/testsuite/gdb.base/structs2.exp index 65655c70fb4a..76deeae53839 100644 --- a/gdb/testsuite/gdb.base/structs2.exp +++ b/gdb/testsuite/gdb.base/structs2.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/structs3.exp b/gdb/testsuite/gdb.base/structs3.exp index bdcf19a9932b..a7e0ede2e2a0 100644 --- a/gdb/testsuite/gdb.base/structs3.exp +++ b/gdb/testsuite/gdb.base/structs3.exp @@ -16,15 +16,15 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" "structs3" "" {debug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set vhn "${::valnum_re}" # Check the real contents. diff --git a/gdb/testsuite/gdb.base/style.exp b/gdb/testsuite/gdb.base/style.exp index a12f61884798..8b9512e1e4f7 100644 --- a/gdb/testsuite/gdb.base/style.exp +++ b/gdb/testsuite/gdb.base/style.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp standard_testfile # Compile the test executable. if {[build_executable "failed to build" $testfile $srcfile {debug macros}]} { - return -1 + return } # The tests in this file are run multiple times with GDB's styles # disabled one at a time. This variable is the style that is # currently disabled. diff --git a/gdb/testsuite/gdb.base/symbol-alias.exp b/gdb/testsuite/gdb.base/symbol-alias.exp index 624422bb2f35..0d9192730f0f 100644 --- a/gdb/testsuite/gdb.base/symbol-alias.exp +++ b/gdb/testsuite/gdb.base/symbol-alias.exp @@ -18,11 +18,11 @@ standard_testfile symbol-alias.c symbol-alias2.c # Clang versions prior to v15 do not emit debug info for aliases. set old_clang [expr {[test_compiler_info {clang-1[0-4]-*-*}] \ || [test_compiler_info {clang-[1-9]-*}]}] if { [prepare_for_testing "failed to prepare" ${testfile} [list $srcfile $srcfile2]] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/symbol-without-target_section.exp b/gdb/testsuite/gdb.base/symbol-without-target_section.exp index 420f5eeabf04..c61ccebc3162 100644 --- a/gdb/testsuite/gdb.base/symbol-without-target_section.exp +++ b/gdb/testsuite/gdb.base/symbol-without-target_section.exp @@ -22,14 +22,14 @@ standard_testfile start.c .c set binlibfile ${testfile}.x if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" \ [standard_output_file ${binlibfile}] object {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[build_executable ${testfile}.exp ${testfile} ${srcfile} {debug}] == -1} { - return -1 + return } clean_restart ${binlibfile} gdb_test "add-symbol-file [standard_output_file ${testfile}] 0" \ "Reading symbols from .*" \ diff --git a/gdb/testsuite/gdb.base/symfile-warn.exp b/gdb/testsuite/gdb.base/symfile-warn.exp index 17f51071cb6d..1dc5e6aee4ad 100644 --- a/gdb/testsuite/gdb.base/symfile-warn.exp +++ b/gdb/testsuite/gdb.base/symfile-warn.exp @@ -17,11 +17,11 @@ standard_testfile .c set ofile [standard_output_file ${testfile}.o] if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" \ $ofile object {debug}] != ""} { untested "failed to compile" - return -1 + return } clean_restart gdb_test "add-symbol-file $ofile 0" \ diff --git a/gdb/testsuite/gdb.base/symlink-sourcefile.exp b/gdb/testsuite/gdb.base/symlink-sourcefile.exp index 7870e16acc91..bc2249071eb5 100644 --- a/gdb/testsuite/gdb.base/symlink-sourcefile.exp +++ b/gdb/testsuite/gdb.base/symlink-sourcefile.exp @@ -30,15 +30,15 @@ if {[lindex $status 0] != 0} { unsupported "$test (host does not support symbolic links)" return 0 } if {[prepare_for_testing $testfile $testfile $srcfilelink]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Using a line number ensures that the default symtab is used. gdb_breakpoint [gdb_get_line_number "break here" $srcfile] message gdb_continue_to_breakpoint "run to breakpoint marker" diff --git a/gdb/testsuite/gdb.base/symtab-search-order.exp b/gdb/testsuite/gdb.base/symtab-search-order.exp index 5ea8c18e3f3a..9709548b1297 100644 --- a/gdb/testsuite/gdb.base/symtab-search-order.exp +++ b/gdb/testsuite/gdb.base/symtab-search-order.exp @@ -34,11 +34,11 @@ if { [prepare_for_testing "prepare" $testfile [list $srcfile $srcfile2] \ } gdb_load_shlib $lib1 if {![runto_main]} { - return -1 + return } # PR 17564 # Expand something in the shared library, # and then try to print static_global in the binary. diff --git a/gdb/testsuite/gdb.base/term.exp b/gdb/testsuite/gdb.base/term.exp index 320bf6f496a8..b615d9a410e9 100644 --- a/gdb/testsuite/gdb.base/term.exp +++ b/gdb/testsuite/gdb.base/term.exp @@ -15,11 +15,11 @@ # Test that GDB saves and restores terminal settings correctly. Also check # the output of the "info terminal" command. if { [prepare_for_testing "failed to prepare" term term.c] } { - return -1 + return } # Once before running the program. gdb_test "info terminal" \ "No saved terminal information.*" \ diff --git a/gdb/testsuite/gdb.base/thread-bp-multi-loc.exp b/gdb/testsuite/gdb.base/thread-bp-multi-loc.exp index ce8d6737b92b..91c0f320935b 100644 --- a/gdb/testsuite/gdb.base/thread-bp-multi-loc.exp +++ b/gdb/testsuite/gdb.base/thread-bp-multi-loc.exp @@ -18,24 +18,24 @@ # displayed correctly. standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { - return -1 + return } delete_breakpoints gdb_breakpoint "foo thread 1" set bp_number [get_integer_valueof "\$bpnum" 0] if { $bp_number == 0 } { unresolved "breakpoint not placed correctly" - return -1 + return } set saw_header false set saw_cond false set loc_count 0 diff --git a/gdb/testsuite/gdb.base/tls-dlobj.exp b/gdb/testsuite/gdb.base/tls-dlobj.exp index 2e1b50145413..2136af0fe7bc 100644 --- a/gdb/testsuite/gdb.base/tls-dlobj.exp +++ b/gdb/testsuite/gdb.base/tls-dlobj.exp @@ -316,33 +316,33 @@ proc do_tests {force_internal_tls} { } # Build shared objects for dlopen: if { [gdb_compile_shlib $libsrc $lib1obj [list debug additional_flags=-DN=1]] != "" } { untested "failed to compile shared object" - return -1 + return } if { [gdb_compile_shlib $libsrc $lib2obj [list debug additional_flags=-DN=2]] != "" } { untested "failed to compile shared object" - return -1 + return } if { [gdb_compile_shlib $libsrc $lib3obj [list debug additional_flags=-DN=3]] != "" } { untested "failed to compile shared object" - return -1 + return } if { [gdb_compile_shlib $libsrc $lib4obj [list debug additional_flags=-DN=4]] != "" } { untested "failed to compile shared object" - return -1 + return } # Build shared objects to link against main program: if { [gdb_compile_shlib $libsrc $lib10obj [list debug additional_flags=-DN=10]] != "" } { untested "failed to compile shared object" - return -1 + return } if { [gdb_compile_shlib $libsrc $lib11obj [list debug additional_flags=-DN=11]] != "" } { untested "failed to compile shared object" - return -1 + return } # Use gdb_compile_pthreads to build and link the main program for # testing. It's also possible to run the tests using plain old # gdb_compile, but this adds complexity with setting up additional diff --git a/gdb/testsuite/gdb.base/tls-multiobj.exp b/gdb/testsuite/gdb.base/tls-multiobj.exp index 56318b934382..c0ad83c1db90 100644 --- a/gdb/testsuite/gdb.base/tls-multiobj.exp +++ b/gdb/testsuite/gdb.base/tls-multiobj.exp @@ -165,19 +165,19 @@ proc do_tests {force_internal_tls {do_kfail_tls_access 0}} { } } if { [gdb_compile_shlib $lib1src $lib1obj {debug}] != "" } { untested "failed to compile shared object" - return -1 + return } if { [gdb_compile_shlib $lib2src $lib2obj {debug}] != "" } { untested "failed to compile shared object" - return -1 + return } if { [gdb_compile_shlib $lib3src $lib3obj {debug}] != "" } { untested "failed to compile shared object" - return -1 + return } # Certain linux target architectures implement support for internal # TLS lookup which is used when thread stratum support (via # libthread_db) is missing or when the linux-only GDB maintenance diff --git a/gdb/testsuite/gdb.base/traced-thread.exp b/gdb/testsuite/gdb.base/traced-thread.exp index 9bf4ea131d1d..b6d354907225 100644 --- a/gdb/testsuite/gdb.base/traced-thread.exp +++ b/gdb/testsuite/gdb.base/traced-thread.exp @@ -20,11 +20,11 @@ require {istarget *-linux*} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug pthreads}]} { - return -1 + return } if {![runto "parent_stop"]} { return -1 } diff --git a/gdb/testsuite/gdb.base/ui-redirect.exp b/gdb/testsuite/gdb.base/ui-redirect.exp index 5a37f485e74c..c1cb461496b8 100644 --- a/gdb/testsuite/gdb.base/ui-redirect.exp +++ b/gdb/testsuite/gdb.base/ui-redirect.exp @@ -15,15 +15,15 @@ # Do not run if gdb debug is enabled as it will interfere with log redirect. require !gdb_debug_enabled if { [prepare_for_testing "failed to prepare" ui-redirect start.c] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set test "commands" gdb_test_multiple $test $test { -re "End with a line saying just \"end\"\\.\r\n>$" { diff --git a/gdb/testsuite/gdb.base/until-nodebug.exp b/gdb/testsuite/gdb.base/until-nodebug.exp index e23a0c915da6..5980bc435ced 100644 --- a/gdb/testsuite/gdb.base/until-nodebug.exp +++ b/gdb/testsuite/gdb.base/until-nodebug.exp @@ -17,11 +17,11 @@ # until when there is no debug information. standard_testfile advance.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile nodebug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/until-trailing-insns.exp b/gdb/testsuite/gdb.base/until-trailing-insns.exp index 531bc46aefa2..86909aa6dc41 100644 --- a/gdb/testsuite/gdb.base/until-trailing-insns.exp +++ b/gdb/testsuite/gdb.base/until-trailing-insns.exp @@ -82,11 +82,11 @@ load_lib dwarf.exp require dwarf2_support standard_testfile .c .S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { global srcdir subdir srcfile @@ -155,15 +155,15 @@ Dwarf::assemble $asm_file { } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug} ] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "next" ".* TAG: loop code .*" "inside the loop" gdb_test "next" ".* TAG: loop line .*" "ending of loop" gdb_test "until" ".* TAG: main return .*" "left loop" diff --git a/gdb/testsuite/gdb.base/until.exp b/gdb/testsuite/gdb.base/until.exp index 7c16592fe6ae..58f9174af988 100644 --- a/gdb/testsuite/gdb.base/until.exp +++ b/gdb/testsuite/gdb.base/until.exp @@ -15,11 +15,11 @@ # until.exp -- Expect script to test 'until' in gdb set srcfile break.c if { [prepare_for_testing "failed to prepare" "until" {break.c break1.c} {debug nowarnings}] } { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location19 [gdb_get_line_number "set breakpoint 19 here"] set bp_location20 [gdb_get_line_number "set breakpoint 20 here"] diff --git a/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl b/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl index c037ff2071af..471342684aec 100644 --- a/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl +++ b/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl @@ -24,11 +24,11 @@ # value, can be calculated correctly. if {[prepare_for_testing_full "failed to prepare" \ [list ${testfile} $ldflags \ $srcfile $srcfile_flags $srcfile2 $srcfile2_flags]]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/unwindonsignal.exp b/gdb/testsuite/gdb.base/unwindonsignal.exp index 64f86bfd2820..cd98b9fdd02f 100644 --- a/gdb/testsuite/gdb.base/unwindonsignal.exp +++ b/gdb/testsuite/gdb.base/unwindonsignal.exp @@ -21,11 +21,11 @@ require {!target_info exists gdb,nosignals} require {!target_info exists gdb,cannot_call_functions} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if { ![runto_main] } { return 0 } diff --git a/gdb/testsuite/gdb.base/utf8-identifiers.exp b/gdb/testsuite/gdb.base/utf8-identifiers.exp index 95311b5494af..676cb2904c9e 100644 --- a/gdb/testsuite/gdb.base/utf8-identifiers.exp +++ b/gdb/testsuite/gdb.base/utf8-identifiers.exp @@ -31,11 +31,11 @@ standard_testfile # Enable basic use of UTF-8. LC_ALL gets reset for each testfile. setenv LC_ALL C.UTF-8 if { [prepare_for_testing "failed to prepare" ${testfile} [list $srcfile]] } { - return -1 + return } if {![runto done]} { return } @@ -64,11 +64,11 @@ gdb_test_no_output "nosharedlibrary" # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } # Test linespec completion. # A unique completion. diff --git a/gdb/testsuite/gdb.base/valgrind-bt.exp b/gdb/testsuite/gdb.base/valgrind-bt.exp index dd2b1ed83940..36614427cf9b 100644 --- a/gdb/testsuite/gdb.base/valgrind-bt.exp +++ b/gdb/testsuite/gdb.base/valgrind-bt.exp @@ -20,15 +20,15 @@ load_lib valgrind.exp require {!is_remote target} standard_testfile .c if {[build_executable $testfile.exp $testfile $srcfile {debug}] == -1} { - return -1 + return } if { [vgdb_start] == -1 } { - return -1 + return } set double_free [gdb_get_line_number "double-free"] gdb_breakpoint "main" diff --git a/gdb/testsuite/gdb.base/valgrind-disp-step.exp b/gdb/testsuite/gdb.base/valgrind-disp-step.exp index 13f36837d5e2..2b2d5b5b8e6e 100644 --- a/gdb/testsuite/gdb.base/valgrind-disp-step.exp +++ b/gdb/testsuite/gdb.base/valgrind-disp-step.exp @@ -25,15 +25,15 @@ load_lib valgrind.exp require {!is_remote target} standard_testfile .c if {[build_executable "failed to build" $testfile $srcfile {debug}] == -1} { - return -1 + return } if { [vgdb_start] == -1 } { - return -1 + return } gdb_test_no_output "set displaced-stepping off" gdb_breakpoint "main" "breakpoint at main" gdb_test "continue" " stop 0 .*" "continue to main" diff --git a/gdb/testsuite/gdb.base/valgrind-infcall-2.exp b/gdb/testsuite/gdb.base/valgrind-infcall-2.exp index 28fa2b78022f..77e92ce81f9d 100644 --- a/gdb/testsuite/gdb.base/valgrind-infcall-2.exp +++ b/gdb/testsuite/gdb.base/valgrind-infcall-2.exp @@ -36,16 +36,16 @@ load_lib valgrind.exp require {!is_remote target} standard_testfile .c if {[build_executable $testfile.exp $testfile $srcfile {debug}] == -1} { - return -1 + return } set active_at_startup 0 if { [vgdb_start $active_at_startup] == -1 } { - return -1 + return } # Determine whether we're at nanosleep. gdb_test_multiple "bt 1" "do printf" { -re -wrap "nanosleep.*" { diff --git a/gdb/testsuite/gdb.base/valgrind-infcall.exp b/gdb/testsuite/gdb.base/valgrind-infcall.exp index 0bd6c837a28c..c39d31819837 100644 --- a/gdb/testsuite/gdb.base/valgrind-infcall.exp +++ b/gdb/testsuite/gdb.base/valgrind-infcall.exp @@ -20,15 +20,15 @@ load_lib valgrind.exp require {!is_remote target} standard_testfile .c if {[build_executable $testfile.exp $testfile $srcfile {debug}] == -1} { - return -1 + return } if { [vgdb_start] == -1 } { - return -1 + return } set continue_count 1 set loop 1 while {$loop && $continue_count < 100} { diff --git a/gdb/testsuite/gdb.base/value-double-free.exp b/gdb/testsuite/gdb.base/value-double-free.exp index 1b566b5fdd51..277d9bfd096e 100644 --- a/gdb/testsuite/gdb.base/value-double-free.exp +++ b/gdb/testsuite/gdb.base/value-double-free.exp @@ -22,15 +22,15 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Disable hardware watchpoints if necessary. if {!$allow_hw_watchpoint_tests_p} { gdb_test_no_output "set can-use-hw-watchpoints 0" "" diff --git a/gdb/testsuite/gdb.base/value-history-unavailable.exp b/gdb/testsuite/gdb.base/value-history-unavailable.exp index 347271c22118..6e87bee29952 100644 --- a/gdb/testsuite/gdb.base/value-history-unavailable.exp +++ b/gdb/testsuite/gdb.base/value-history-unavailable.exp @@ -16,11 +16,11 @@ # Test GDB's value availability ranges. standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/vdso-warning.exp b/gdb/testsuite/gdb.base/vdso-warning.exp index 37c481054e9d..4f61554dc68a 100644 --- a/gdb/testsuite/gdb.base/vdso-warning.exp +++ b/gdb/testsuite/gdb.base/vdso-warning.exp @@ -18,11 +18,11 @@ # warning: Could not load shared library symbols for linux-vdso.so.1. standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } with_test_prefix "setup" { gdb_breakpoint "main" diff --git a/gdb/testsuite/gdb.base/vfork-follow-parent.exp b/gdb/testsuite/gdb.base/vfork-follow-parent.exp index 9e082ac91e49..40fd11ca8921 100644 --- a/gdb/testsuite/gdb.base/vfork-follow-parent.exp +++ b/gdb/testsuite/gdb.base/vfork-follow-parent.exp @@ -27,11 +27,11 @@ set binfile ${testfile}-exit set binfile2 ${testfile}-exec set binfile3 vforked-prog if { [build_executable "compile $binfile3" $binfile3 $srcfile2] } { untested "failed to compile third test binary" - return -1 + return } if { [is_remote target] } { gdb_remote_download target [standard_output_file $binfile3] } diff --git a/gdb/testsuite/gdb.base/vla-datatypes.exp b/gdb/testsuite/gdb.base/vla-datatypes.exp index ffc25bfa36b5..7453132bc6af 100644 --- a/gdb/testsuite/gdb.base/vla-datatypes.exp +++ b/gdb/testsuite/gdb.base/vla-datatypes.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "vlas_filled"] gdb_continue_to_breakpoint "vlas_filled" diff --git a/gdb/testsuite/gdb.base/vla-ptr.exp b/gdb/testsuite/gdb.base/vla-ptr.exp index 74a1dc098163..33e29d5c2d9a 100644 --- a/gdb/testsuite/gdb.base/vla-ptr.exp +++ b/gdb/testsuite/gdb.base/vla-ptr.exp @@ -15,15 +15,15 @@ standard_testfile set using_clang [test_compiler_info clang*] if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set sizeof_int [get_sizeof "int" 4] # Check that VLA passed to function (pointer) points to the first element. diff --git a/gdb/testsuite/gdb.base/vla-sideeffect.exp b/gdb/testsuite/gdb.base/vla-sideeffect.exp index 02a8db210927..34756b36feb9 100644 --- a/gdb/testsuite/gdb.base/vla-sideeffect.exp +++ b/gdb/testsuite/gdb.base/vla-sideeffect.exp @@ -17,15 +17,15 @@ # Based on gcc/testsuite/gcc.dg/vla-4.c; vla-15.c standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "vla-filled"] gdb_continue_to_breakpoint "vla-filled" diff --git a/gdb/testsuite/gdb.base/vla-struct-fields.exp b/gdb/testsuite/gdb.base/vla-struct-fields.exp index 9ed7762b8dc1..514ec9edff53 100644 --- a/gdb/testsuite/gdb.base/vla-struct-fields.exp +++ b/gdb/testsuite/gdb.base/vla-struct-fields.exp @@ -17,15 +17,15 @@ standard_testfile # Clang says it will never support variable length arrays in structures. require {!test_compiler_info clang*} if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "vlas_filled"] gdb_continue_to_breakpoint "vlas_filled" diff --git a/gdb/testsuite/gdb.base/vla-stub.exp b/gdb/testsuite/gdb.base/vla-stub.exp index 0258a629c9ed..6759a2655bce 100644 --- a/gdb/testsuite/gdb.base/vla-stub.exp +++ b/gdb/testsuite/gdb.base/vla-stub.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .c vla-stub-define.c if { [prepare_for_testing "failed to prepare for vla-stub.exp" \ ${testfile} [list ${srcfile} ${srcfile2}]] } { - return -1 + return } gdb_test "p *local_struct.ptr" { = {dynamic_field = 0x0}} gdb_test "whatis local_struct.here" "type = static_struct_t" diff --git a/gdb/testsuite/gdb.base/volatile.exp b/gdb/testsuite/gdb.base/volatile.exp index f244303a3de1..38b4588d568d 100644 --- a/gdb/testsuite/gdb.base/volatile.exp +++ b/gdb/testsuite/gdb.base/volatile.exp @@ -34,11 +34,11 @@ # # Use the same test program constvars.c. if { [prepare_for_testing "failed to prepare" volatile constvars.c] } { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.base/watch-bitfields.exp b/gdb/testsuite/gdb.base/watch-bitfields.exp index 83f33de12e4a..30e90fecf6b8 100644 --- a/gdb/testsuite/gdb.base/watch-bitfields.exp +++ b/gdb/testsuite/gdb.base/watch-bitfields.exp @@ -25,11 +25,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Set a watchpoint watching EXPR. proc watch { expr } { global decimal diff --git a/gdb/testsuite/gdb.base/watch-cond-infcall.exp b/gdb/testsuite/gdb.base/watch-cond-infcall.exp index 32a0632eae14..ed62a39926d3 100644 --- a/gdb/testsuite/gdb.base/watch-cond-infcall.exp +++ b/gdb/testsuite/gdb.base/watch-cond-infcall.exp @@ -28,11 +28,11 @@ standard_testfile require {!target_info exists gdb,cannot_call_functions} if { [build_executable ${testfile}.exp ${testfile} ${testfile}.c {debug}] } { untested "failed to compile" - return -1 + return } proc test_watchpoint { hw } { global testfile diff --git a/gdb/testsuite/gdb.base/watch-cond.exp b/gdb/testsuite/gdb.base/watch-cond.exp index 4b0a93be2075..0d283ad90582 100644 --- a/gdb/testsuite/gdb.base/watch-cond.exp +++ b/gdb/testsuite/gdb.base/watch-cond.exp @@ -26,11 +26,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Disable hardware watchpoints if necessary. if {!$allow_hw_watchpoint_tests_p} { gdb_test_no_output "set can-use-hw-watchpoints 0" "" diff --git a/gdb/testsuite/gdb.base/watch-non-mem.exp b/gdb/testsuite/gdb.base/watch-non-mem.exp index 95591301287b..42dc3c8a80ff 100644 --- a/gdb/testsuite/gdb.base/watch-non-mem.exp +++ b/gdb/testsuite/gdb.base/watch-non-mem.exp @@ -18,11 +18,11 @@ # standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/watch-read.exp b/gdb/testsuite/gdb.base/watch-read.exp index 49eb787347ec..378bae067752 100644 --- a/gdb/testsuite/gdb.base/watch-read.exp +++ b/gdb/testsuite/gdb.base/watch-read.exp @@ -25,11 +25,11 @@ standard_testfile .c require allow_hw_watchpoint_access_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/watch-vfork.exp b/gdb/testsuite/gdb.base/watch-vfork.exp index 588a94c8218a..6df3a7ddbacc 100644 --- a/gdb/testsuite/gdb.base/watch-vfork.exp +++ b/gdb/testsuite/gdb.base/watch-vfork.exp @@ -19,11 +19,11 @@ standard_testfile .c require allow_fork_tests if { [build_executable ${testfile}.exp ${testfile} $srcfile {debug}] } { untested "failed to compile" - return -1 + return } proc test_watchpoint_across_vfork { hw teststr } { global testfile diff --git a/gdb/testsuite/gdb.base/watchpoint-cond-gone.exp b/gdb/testsuite/gdb.base/watchpoint-cond-gone.exp index 546c2b4349f7..823334ec5034 100644 --- a/gdb/testsuite/gdb.base/watchpoint-cond-gone.exp +++ b/gdb/testsuite/gdb.base/watchpoint-cond-gone.exp @@ -19,18 +19,18 @@ standard_testfile .c watchpoint-cond-gone-stripped.c # Stepping into a dynamic function trampoline or stepping out of MAIN may work # but it is not a reliable FAIL case. if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug $srcfile debug $srcfile2 {}]]} { - return -1 + return } # Problem does not occur otherwise. gdb_test_no_output "set can-use-hw-watchpoints 0" if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "watchpoint-here"] gdb_continue_to_breakpoint "Place to set the watchpoint" diff --git a/gdb/testsuite/gdb.base/watchpoint-delete.exp b/gdb/testsuite/gdb.base/watchpoint-delete.exp index 91d28d705389..f410298a5ece 100644 --- a/gdb/testsuite/gdb.base/watchpoint-delete.exp +++ b/gdb/testsuite/gdb.base/watchpoint-delete.exp @@ -14,18 +14,18 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # It is more compatible this way. gdb_test_no_output "set can-use-hw-watchpoints 0" if {![runto_main]} { - return -1 + return } # Ensure there is a parent frame to create related bp_watchpoint_scope. gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.base/watchpoint-hw-attach.exp b/gdb/testsuite/gdb.base/watchpoint-hw-attach.exp index e87cc72dfc0e..2962f6964bf1 100644 --- a/gdb/testsuite/gdb.base/watchpoint-hw-attach.exp +++ b/gdb/testsuite/gdb.base/watchpoint-hw-attach.exp @@ -21,11 +21,11 @@ require allow_hw_watchpoint_tests require can_spawn_for_attach standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp b/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp index 60b8ed826404..c8723e9dafe0 100644 --- a/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp +++ b/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp @@ -16,15 +16,15 @@ require allow_hw_watchpoint_access_tests set test watchpoint-hw-hit-once set srcfile ${test}.c if { [prepare_for_testing "failed to prepare" ${test} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "rwatch watchee" gdb_breakpoint [gdb_get_line_number "dummy = 2"] diff --git a/gdb/testsuite/gdb.base/watchpoint-hw.exp b/gdb/testsuite/gdb.base/watchpoint-hw.exp index af5c6712b93b..537fceec9142 100644 --- a/gdb/testsuite/gdb.base/watchpoint-hw.exp +++ b/gdb/testsuite/gdb.base/watchpoint-hw.exp @@ -18,11 +18,11 @@ require !use_gdb_stub require allow_hw_watchpoint_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Create the watchpoint before the inferior gets started. Now the native CPU # target is still not active and its `to_can_use_hw_breakpoint' is not # installed, therefore only a software watchpoint gets created. @@ -31,11 +31,11 @@ gdb_test "watch watchee" "atchpoint 1: watchee" # `runto_main' or `runto main' would delete the watchpoint created above. if { [gdb_start_cmd] < 0 } { fail start - return -1 + return } gdb_test "" "main .* at .*" "start" # Check it is really a `hw'-watchpoint. gdb_test "info watchpoints" "1 *hw watchpoint .* watchee" diff --git a/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp b/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp index 44ede1e46546..85494e5463ed 100644 --- a/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp +++ b/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp @@ -33,11 +33,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] # starting the test. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.base/watchpoint-running.exp b/gdb/testsuite/gdb.base/watchpoint-running.exp index 95b506a80b61..232ecf5721c2 100644 --- a/gdb/testsuite/gdb.base/watchpoint-running.exp +++ b/gdb/testsuite/gdb.base/watchpoint-running.exp @@ -21,11 +21,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug}]} { - return -1 + return } # STOP_MODE is either "all-stop" or "non-stop". HW is true if we are # testing hardware watchpoints, and false if we're testing software # watchpoints. diff --git a/gdb/testsuite/gdb.base/watchpoint-stops-at-right-insn.exp b/gdb/testsuite/gdb.base/watchpoint-stops-at-right-insn.exp index bf4851ca6c82..53d1064c76de 100644 --- a/gdb/testsuite/gdb.base/watchpoint-stops-at-right-insn.exp +++ b/gdb/testsuite/gdb.base/watchpoint-stops-at-right-insn.exp @@ -72,11 +72,11 @@ standard_testfile # No use testing this if we can't use hardware watchpoints. require allow_hw_watchpoint_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/watchpoint-unaligned.exp b/gdb/testsuite/gdb.base/watchpoint-unaligned.exp index 8b929e5de4e6..e19a5c189c50 100644 --- a/gdb/testsuite/gdb.base/watchpoint-unaligned.exp +++ b/gdb/testsuite/gdb.base/watchpoint-unaligned.exp @@ -19,15 +19,15 @@ require allow_hw_watchpoint_tests standard_testfile if { [prepare_for_testing ${testfile}.exp ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "start_again"] "Breakpoint $decimal at $hex" "start_again" set sizes {1 2 4 8} diff --git a/gdb/testsuite/gdb.base/watchpoints.exp b/gdb/testsuite/gdb.base/watchpoints.exp index 89a7075f5f5e..969210ad625b 100644 --- a/gdb/testsuite/gdb.base/watchpoints.exp +++ b/gdb/testsuite/gdb.base/watchpoints.exp @@ -27,11 +27,11 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile set wp_set 1 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } with_test_prefix "before inferior start" { # Ensure that if we turn off hardware watchpoints and set a watch point # before starting the inferior the watchpoint created will not be a diff --git a/gdb/testsuite/gdb.base/wchar.exp b/gdb/testsuite/gdb.base/wchar.exp index e05cb4b0b03a..d3cfd09d5de4 100644 --- a/gdb/testsuite/gdb.base/wchar.exp +++ b/gdb/testsuite/gdb.base/wchar.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set bp_location [gdb_get_line_number "START"] if {![runto "wchar.c:$bp_location"]} { return -1 diff --git a/gdb/testsuite/gdb.base/whatis-exp.exp b/gdb/testsuite/gdb.base/whatis-exp.exp index 7ee69c3b2463..34652005a4f6 100644 --- a/gdb/testsuite/gdb.base/whatis-exp.exp +++ b/gdb/testsuite/gdb.base/whatis-exp.exp @@ -28,11 +28,11 @@ # # test running programs # if { [prepare_for_testing "failed to prepare" whatis-exp int-type.c {debug nowarnings}] } { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.base/with-mf.exp b/gdb/testsuite/gdb.base/with-mf.exp index 44c331102e6a..5a6e43e85d11 100644 --- a/gdb/testsuite/gdb.base/with-mf.exp +++ b/gdb/testsuite/gdb.base/with-mf.exp @@ -19,16 +19,16 @@ standard_testfile with-mf-main.c with-mf-inc.c if {[prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" \ debug]} { - return -1 + return } if { [ensure_gdb_index $binfile] == -1 } { untested "error adding gdb index" - return -1 + return } clean_restart $testfile gdb_test "with language ada -- print g_s" \ diff --git a/gdb/testsuite/gdb.base/with.exp b/gdb/testsuite/gdb.base/with.exp index c01804d5ea65..101c6dcccf93 100644 --- a/gdb/testsuite/gdb.base/with.exp +++ b/gdb/testsuite/gdb.base/with.exp @@ -20,11 +20,11 @@ load_lib completion-support.exp standard_testfile .c if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } clean_restart $testfile # Test "maint with". VALUES is a list of values. A nested "with" is diff --git a/gdb/testsuite/gdb.base/write_mem.exp b/gdb/testsuite/gdb.base/write_mem.exp index 6881211692a3..2c9509dd6583 100644 --- a/gdb/testsuite/gdb.base/write_mem.exp +++ b/gdb/testsuite/gdb.base/write_mem.exp @@ -22,11 +22,11 @@ global GDBFLAGS standard_testfile if {[build_executable $testfile.exp $testfile \ $srcfile [list debug nowarnings] ] == -1} { untested $testfile.exp - return -1 + return } save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS $binfile" clean_restart diff --git a/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp b/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp index 3087466c82aa..98680e5c5a32 100644 --- a/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp +++ b/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp @@ -35,18 +35,18 @@ if {[gdb_compile "${srcdir}/${subdir}/$opaque_testfile.c" \ if {[gdb_compile \ [list ${srcdir}/${subdir}/$main_testfile.c $opaque_objfile] \ [standard_output_file ${main_testfile}] \ executable {debug}] != ""} { untested "failed to build $main_testfile" - return -1 + return } clean_restart ${main_testfile} if {![runto opaque_routine]} { untested "could not run to opaque_routine" - return -1 + return } # Make sure that "bt full" command is capable of displaying MY_TABLE # correctly when frame #0 (the frame which does not have any debugging # info) is the selected frame. From patchwork Wed Apr 29 23:04:05 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134222 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 7B7884BB8F71 for ; Wed, 29 Apr 2026 23:10:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7B7884BB8F71 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=j6RZyd+Z X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vs1-xe32.google.com (mail-vs1-xe32.google.com [IPv6:2607:f8b0:4864:20::e32]) by sourceware.org (Postfix) with ESMTPS id 1CB954358A47 for ; Wed, 29 Apr 2026 23:05:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1CB954358A47 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1CB954358A47 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::e32 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503927; cv=none; b=cDCdNU8wyv2Jil4RMg3A18u17UcRnSBc7iXkRNwESeHNURp74Ngkl+2P9teTfhAWxaM39CmlQ+VVzyowbcdqRz/S1hF4/jkBvja3pFqHP2S0+CgzXlGaBkfN/7RF5Yw1nS8KZjb2JcdWi8sgcKKFOyhuDnJOfaRukooZlPYRraM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503927; c=relaxed/simple; bh=hlqtCgzidXMO3cB46fVmrYt7sOEf924k5Ek/ROwYBdw=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=M6NNZtS4WWhhRvQkXyZOwBCiSMhooywg+oLY7BjsTKgAHi1J626pEeIY7C6vSEpBt+OE6LZrfi/RX9bP1IfJVRh6iJ03wKqrHhgD+wHYdoj3FgogOJHeaUs7MouSCUSv8dFJD/pYtbZICGkukmNdiY2yaCmtZHADoxZaanF0LfQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1CB954358A47 Received: by mail-vs1-xe32.google.com with SMTP id ada2fe7eead31-60fce51aa55so108242137.3 for ; Wed, 29 Apr 2026 16:05:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503926; x=1778108726; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=7ddFJH+yoilkMVix/ne4/PABkgZ/8SwwqiocGj3TVqE=; b=j6RZyd+Za79kjO1FyUqTDktCJCVjxDGib8sWn698AMK/+KxrtsHGL8mujBTTcZbGgQ QAnZyeLx1hpLVYh4IFOELuJnScm8ebpQpcKZl4YVxRCOMM2nkREZsEk6N4LgNDCBUi5H P+N7PyrIk5l8mcL7D3C0vs7dgEB/cDX4Or4ZqHgUQnMPwiSO9rTlvIUQvAN+FgboDFvL X7a/0kj91iWXUL/BAFgFowRAYKJK3/552OJcQF84m75teJrhGoj47LLW3ivwUg+dGQYs LBUWQBQEZGXl/27x54fTT7g0RUDCYjV3t5T8jg/xObSsl3o57D2lZKK9u5q49ni9S0Ym P15g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503926; x=1778108726; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=7ddFJH+yoilkMVix/ne4/PABkgZ/8SwwqiocGj3TVqE=; b=B2YNDjVI0NX/PnQwUmx49GeuI6kdTNNPb87hRYFH5IrLXEpMN4SUkNjyqhssZTJNTt ghdwW5zXXOVxwCqJaqDG7s2eL4DUmImRxKMPLftDI3sDvYt94Z+N7/C11J+9XXRg6XCc 3h24D/AprIl5s6NH3+3GzEDX2KmqeUTCp5Qf8KzcbhMsWtR4Jq2J2PN8lgwen2tgRnJs zevw2Uf/q1VX45XA7/hpvt+830EXxN2/sW0/S1ehW9s+lb5TRE45CqBNfH9/CTpLX4CJ osy8fAmm5x1yqMJThrHfyDFMdoCAIsf8PaGhVZhHuYFR1uLLaAPfsU2t9nI79PTAi7hY GrRQ== X-Gm-Message-State: AOJu0YzZRc9ixYAfS4MeWDDBACgvp0X/+0tM/RBbblDNtFkNc1nRK8Ag bh1najIoSb/graJudCPxK5khfdzS6YYA4tlgOyhrTTTp4C6Doon8EOpzIvbwzR9QBWGBCLoR9Ay xwPPN X-Gm-Gg: AeBDieua5m/t+04NzPRNdOWNeOyD5hX3qlFYz2ZOjFup6KYW9XlsQxGyMvC6fK+YQn/ K3F3TM3q5+eXMwPep3hBKaan4Mqm4Eo380gpJWg2sxAkGhwv91NYzyt2hrutoUtMTkolMkCeYDk 3Z72Zs5o4zpysZ5O/Y2Y92P9T4kdlJDYfwUUip4WsghQVSuOAG92014WXAUt7eiR9qKwjmENeOn skEgu2Vk1CLb1BmRJ5pRW+ztg1h5/lrzx1eUX/VE7CVtW5Lm8mHSBF2W7lbZJHjJ3edGcmDul9y Pbl/T1N1t0FUw9k5KM7Wute81IUDysv/4pG0WeoCM8kRORW7WtFebIZrilluudSBum7vksAugdk 3MnON8HS2W5naOUCoF0YP5cKMNsxLH/JYSvVo5Ytn5bazMHkyM7BosbamZmyS11FOzjWjVLLYwl JLKDkTH4/Oio8mCo5CE5Ltn948BODoH3zMbXh3vULuahaJ X-Received: by 2002:a05:6102:2c0c:b0:60f:e47c:f052 with SMTP id ada2fe7eead31-62ad42647f4mr286718137.25.1777503925902; Wed, 29 Apr 2026 16:05:25 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-6297f4e2345sm2049055137.0.2026.04.29.16.05.24 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:25 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 14/37] GDB: testsuite: base: Don't return 0 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:05 -0300 Message-ID: <20260429230432.60487-15-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return 0/ return/' *.exp* inside gdb/testsuite/gdb.base. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.base/advance.exp | 2 +- gdb/testsuite/gdb.base/asmlabel.exp | 2 +- gdb/testsuite/gdb.base/attach-pie-noexec.exp | 4 ++-- gdb/testsuite/gdb.base/auto-connect-native-target.exp | 2 +- gdb/testsuite/gdb.base/auxv.exp | 2 +- gdb/testsuite/gdb.base/backtrace.exp | 2 +- gdb/testsuite/gdb.base/break-caller-line.exp | 4 ++-- gdb/testsuite/gdb.base/call-signal-resume.exp | 4 ++-- gdb/testsuite/gdb.base/callexit.exp | 2 +- gdb/testsuite/gdb.base/clear_non_user_bp.exp | 2 +- gdb/testsuite/gdb.base/compare-sections.exp | 2 +- gdb/testsuite/gdb.base/complex-parts.exp | 2 +- gdb/testsuite/gdb.base/cond-eval-mode.exp | 2 +- gdb/testsuite/gdb.base/condbreak-call-false.exp | 2 +- gdb/testsuite/gdb.base/consecutive-step-over.exp | 2 +- gdb/testsuite/gdb.base/corefile-exec-context.exp | 4 ++-- gdb/testsuite/gdb.base/corefile.exp | 2 +- gdb/testsuite/gdb.base/corefile2.exp | 2 +- gdb/testsuite/gdb.base/ctf-constvars.exp | 2 +- gdb/testsuite/gdb.base/ctf-ptype.exp | 2 +- gdb/testsuite/gdb.base/decl-before-def.exp | 2 +- gdb/testsuite/gdb.base/dup-sect.exp | 2 +- gdb/testsuite/gdb.base/eh_return.exp | 2 +- gdb/testsuite/gdb.base/eu-strip-infcall.exp | 2 +- gdb/testsuite/gdb.base/frameapply.exp | 2 +- gdb/testsuite/gdb.base/func-ptr.exp | 2 +- gdb/testsuite/gdb.base/gdb11530.exp | 2 +- gdb/testsuite/gdb.base/gdb1555.exp | 2 +- gdb/testsuite/gdb.base/info-locals-unused-static-var.exp | 2 +- gdb/testsuite/gdb.base/info-shared.exp | 2 +- gdb/testsuite/gdb.base/info_qt.exp | 2 +- gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp | 2 +- gdb/testsuite/gdb.base/interrupt.exp | 2 +- gdb/testsuite/gdb.base/label-without-address.exp | 2 +- gdb/testsuite/gdb.base/list-missing-source.exp | 2 +- gdb/testsuite/gdb.base/macscp.exp | 4 ++-- .../gdb.base/maint-info-inline-frames-and-blocks.exp | 2 +- gdb/testsuite/gdb.base/many-headers.exp | 2 +- gdb/testsuite/gdb.base/max-value-size.exp | 2 +- gdb/testsuite/gdb.base/overlays.exp | 2 +- gdb/testsuite/gdb.base/pr11022.exp | 2 +- gdb/testsuite/gdb.base/prelink.exp | 2 +- gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp | 2 +- gdb/testsuite/gdb.base/print-internal-string.exp | 2 +- gdb/testsuite/gdb.base/printcmds.exp | 2 +- gdb/testsuite/gdb.base/ptype-offsets-c.exp | 2 +- gdb/testsuite/gdb.base/ptype-offsets.exp | 2 +- gdb/testsuite/gdb.base/reggroups.exp | 2 +- gdb/testsuite/gdb.base/rtld-step.exp | 2 +- gdb/testsuite/gdb.base/savedregs.exp | 2 +- gdb/testsuite/gdb.base/set-noassign.exp | 2 +- gdb/testsuite/gdb.base/shreloc.exp | 2 +- gdb/testsuite/gdb.base/sigaltstack.exp | 2 +- gdb/testsuite/gdb.base/sigbpt.exp | 2 +- gdb/testsuite/gdb.base/siginfo-addr.exp | 2 +- gdb/testsuite/gdb.base/siginfo-obj.exp | 4 ++-- gdb/testsuite/gdb.base/siginfo-thread.exp | 2 +- gdb/testsuite/gdb.base/siginfo.exp | 2 +- gdb/testsuite/gdb.base/signull.exp | 2 +- gdb/testsuite/gdb.base/sigrepeat.exp | 2 +- gdb/testsuite/gdb.base/solib-disc.exp | 8 ++++---- gdb/testsuite/gdb.base/solib-weak.exp | 4 ++-- gdb/testsuite/gdb.base/source-execution.exp | 2 +- gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp | 2 +- gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp | 2 +- gdb/testsuite/gdb.base/stack-checking.exp | 2 +- gdb/testsuite/gdb.base/stack-protector.exp | 2 +- gdb/testsuite/gdb.base/structs2.exp | 2 +- gdb/testsuite/gdb.base/sym-file.exp | 2 +- gdb/testsuite/gdb.base/symlink-sourcefile.exp | 2 +- gdb/testsuite/gdb.base/term.exp | 2 +- gdb/testsuite/gdb.base/type-opaque.exp | 2 +- gdb/testsuite/gdb.base/until-nodebug.exp | 2 +- gdb/testsuite/gdb.base/until.exp | 2 +- gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl | 2 +- gdb/testsuite/gdb.base/unwindonsignal.exp | 4 ++-- gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp | 2 +- 77 files changed, 88 insertions(+), 88 deletions(-) diff --git a/gdb/testsuite/gdb.base/advance.exp b/gdb/testsuite/gdb.base/advance.exp index fe05dd3a3c37..9cde2de12b48 100644 --- a/gdb/testsuite/gdb.base/advance.exp +++ b/gdb/testsuite/gdb.base/advance.exp @@ -20,11 +20,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # Verify that "advance " works. (This is really just syntactic # sugar for "tbreak ; continue".) # diff --git a/gdb/testsuite/gdb.base/asmlabel.exp b/gdb/testsuite/gdb.base/asmlabel.exp index 15f3695d796c..cfda30085737 100644 --- a/gdb/testsuite/gdb.base/asmlabel.exp +++ b/gdb/testsuite/gdb.base/asmlabel.exp @@ -36,11 +36,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set L1_bploc [gdb_get_line_number "set L1 breakpoint here" $srcfile] set L2_bploc [gdb_get_line_number "set L2 breakpoint here" $srcfile] diff --git a/gdb/testsuite/gdb.base/attach-pie-noexec.exp b/gdb/testsuite/gdb.base/attach-pie-noexec.exp index 54a4b0bffae7..b332a092544c 100644 --- a/gdb/testsuite/gdb.base/attach-pie-noexec.exp +++ b/gdb/testsuite/gdb.base/attach-pie-noexec.exp @@ -29,11 +29,11 @@ gdb_test_multiple $test $test { set arch $expect_out(1,string) pass $test } } if {![runto_main]} { - return 0 + return } set test "sanity check info shared" gdb_test_multiple "info shared" $test { -re "From\[ \t\]+To(\\s+NS)?\[ \t\]+Syms Read\[ \t\]+Shared Object Library\r\n0x.*\r\n$gdb_prompt $" { pass $test @@ -44,11 +44,11 @@ gdb_test_multiple "info shared" $test { } gdb_exit if {$arch == ""} { untested "no architecture set" - return 0 + return } # Start the program running and then wait for a bit, to be sure # that it can be attached to. diff --git a/gdb/testsuite/gdb.base/auto-connect-native-target.exp b/gdb/testsuite/gdb.base/auto-connect-native-target.exp index 4529d68e16c6..a5a95b8b5a0a 100644 --- a/gdb/testsuite/gdb.base/auto-connect-native-target.exp +++ b/gdb/testsuite/gdb.base/auto-connect-native-target.exp @@ -51,11 +51,11 @@ if { $topmost != "exec" } { } # Check which target this board connects to. If testing with a native # target board, this should cause the native target to auto connect. if {![runto_main]} { - return 0 + return } # Returns true if the native target is pushed on the target stack. # TEST is used as test message. diff --git a/gdb/testsuite/gdb.base/auxv.exp b/gdb/testsuite/gdb.base/auxv.exp index 79e897078e5d..9d32cee85522 100644 --- a/gdb/testsuite/gdb.base/auxv.exp +++ b/gdb/testsuite/gdb.base/auxv.exp @@ -51,11 +51,11 @@ if {$core_works} { set core_works 0 } } if {![runto_main]} { - return 0 + return } set print_core_line [gdb_get_line_number "ABORT;"] gdb_test "tbreak $print_core_line" gdb_test continue ".*ABORT;.*" diff --git a/gdb/testsuite/gdb.base/backtrace.exp b/gdb/testsuite/gdb.base/backtrace.exp index 612dd2ad6a87..7aee6b1cebc3 100644 --- a/gdb/testsuite/gdb.base/backtrace.exp +++ b/gdb/testsuite/gdb.base/backtrace.exp @@ -20,11 +20,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { return } if {![runto_main]} { - return 0 + return } # Run to the breakpoint at return. gdb_breakpoint [gdb_get_line_number "Break here."] gdb_continue_to_breakpoint "Break here." diff --git a/gdb/testsuite/gdb.base/break-caller-line.exp b/gdb/testsuite/gdb.base/break-caller-line.exp index 7fdef95cc607..c7a136a6663e 100644 --- a/gdb/testsuite/gdb.base/break-caller-line.exp +++ b/gdb/testsuite/gdb.base/break-caller-line.exp @@ -18,11 +18,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { return } if {![runto callee]} { - return 0 + return } set test "up" gdb_test_multiple $test $test { -re "\r\n(${::decimal})\[ \t\]+callee \\(\\);\r\n$gdb_prompt $" { @@ -39,11 +39,11 @@ gdb_test_multiple $test $test { } } if {$notcurrent == $current} { untested "target arch has an instruction after call as part of the caller line" - return 0 + return } set test "break" gdb_test_multiple $test $test { -re "\r\nBreakpoint ${::decimal} at .*, line $current\\.\r\n$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.base/call-signal-resume.exp b/gdb/testsuite/gdb.base/call-signal-resume.exp index 8f12b1618be1..4ade8c2d245a 100644 --- a/gdb/testsuite/gdb.base/call-signal-resume.exp +++ b/gdb/testsuite/gdb.base/call-signal-resume.exp @@ -43,11 +43,11 @@ proc get_dummy_frame_number { } { } return "" } if { ![runto_main] } { - return 0 + return } gdb_test "break stop_one" "Breakpoint \[0-9\]* at .*" gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_one.*" \ "continue to breakpoint at stop_one" @@ -55,11 +55,11 @@ gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_one.*" \ # Call function (causing the program to get a signal), and see if gdb handles # it properly. if {[gdb_test "call gen_signal ()" \ "\[\r\n\]*The program being debugged was signaled.*" \ "inferior function call signaled"] != 0} { - return 0 + return } set frame_number [get_dummy_frame_number] if { "$frame_number" == "" } { fail "dummy stack frame number" diff --git a/gdb/testsuite/gdb.base/callexit.exp b/gdb/testsuite/gdb.base/callexit.exp index 986d225d3aad..376d1f0c14cb 100644 --- a/gdb/testsuite/gdb.base/callexit.exp +++ b/gdb/testsuite/gdb.base/callexit.exp @@ -22,11 +22,11 @@ standard_testfile .c if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { return } if { ![runto_main] } { - return 0 + return } # Verify set may-call-functions behavior. gdb_test_no_output "set may-call-functions off" gdb_test "call callexit()" \ diff --git a/gdb/testsuite/gdb.base/clear_non_user_bp.exp b/gdb/testsuite/gdb.base/clear_non_user_bp.exp index ead811f68546..22e67c935cd7 100644 --- a/gdb/testsuite/gdb.base/clear_non_user_bp.exp +++ b/gdb/testsuite/gdb.base/clear_non_user_bp.exp @@ -44,11 +44,11 @@ standard_testfile main.c if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { return } if {![runto_main]} { - return 0 + return } set bp_num [get_first_maint_bp_num] set bp_addr [gdb_get_bp_addr $bp_num] diff --git a/gdb/testsuite/gdb.base/compare-sections.exp b/gdb/testsuite/gdb.base/compare-sections.exp index f647cc5a8491..bf6207061778 100644 --- a/gdb/testsuite/gdb.base/compare-sections.exp +++ b/gdb/testsuite/gdb.base/compare-sections.exp @@ -78,11 +78,11 @@ gdb_test_multiple $command $test { } } # Now get past startup code. if {![runto_main]} { - return 0 + return } with_test_prefix "after run to main" { # Assume all targets' startup code changes some loaded variable. gdb_test "compare-sections" \ diff --git a/gdb/testsuite/gdb.base/complex-parts.exp b/gdb/testsuite/gdb.base/complex-parts.exp index 56260996bdb6..b156dcb2646c 100644 --- a/gdb/testsuite/gdb.base/complex-parts.exp +++ b/gdb/testsuite/gdb.base/complex-parts.exp @@ -18,11 +18,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set marker " Break Here. " gdb_breakpoint [gdb_get_line_number $marker] gdb_continue_to_breakpoint "breakpt" ".*[string_to_regexp $marker].*" diff --git a/gdb/testsuite/gdb.base/cond-eval-mode.exp b/gdb/testsuite/gdb.base/cond-eval-mode.exp index e2afc3a95939..e9463950eb54 100644 --- a/gdb/testsuite/gdb.base/cond-eval-mode.exp +++ b/gdb/testsuite/gdb.base/cond-eval-mode.exp @@ -28,11 +28,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set test_host "set breakpoint condition-evaluation host" set test_auto "set breakpoint condition-evaluation auto" set test_target "set breakpoint condition-evaluation target" diff --git a/gdb/testsuite/gdb.base/condbreak-call-false.exp b/gdb/testsuite/gdb.base/condbreak-call-false.exp index 32113e3b9501..0a240601b348 100644 --- a/gdb/testsuite/gdb.base/condbreak-call-false.exp +++ b/gdb/testsuite/gdb.base/condbreak-call-false.exp @@ -21,11 +21,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } gdb_test "break foo if zero()" "Breakpoint .*" gdb_test "break bar" "Breakpoint .*" diff --git a/gdb/testsuite/gdb.base/consecutive-step-over.exp b/gdb/testsuite/gdb.base/consecutive-step-over.exp index d7efec8f418d..12ef2dcc4d4f 100644 --- a/gdb/testsuite/gdb.base/consecutive-step-over.exp +++ b/gdb/testsuite/gdb.base/consecutive-step-over.exp @@ -23,11 +23,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # Make sure the target doesn't hide the breakpoint hits (that don't # cause a user visible stop) from GDB. gdb_test_no_output "set breakpoint condition-evaluation host" diff --git a/gdb/testsuite/gdb.base/corefile-exec-context.exp b/gdb/testsuite/gdb.base/corefile-exec-context.exp index bf935a795e7d..8c342171cecf 100644 --- a/gdb/testsuite/gdb.base/corefile-exec-context.exp +++ b/gdb/testsuite/gdb.base/corefile-exec-context.exp @@ -42,11 +42,11 @@ if { $binfile_len <= 80 } { # Generate a core file, this time the inferior has no additional # arguments. set corefile [core_find $binfile {}] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_1 "$binfile.1.core" remote_exec build "mv $corefile $corefile_1" # Load the core file and confirm that the full executable name is @@ -71,11 +71,11 @@ gdb_test_multiple "core-file $corefile_1" "load core file no args" { # Generate a core file, this time pass some arguments to the inferior. set args "aaaaa bbbbb ccccc ddddd e\\\\ e\\\\ e\\\\ e\\\\ e" set corefile [core_find $binfile {} $args] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_2 "$binfile.2.core" remote_exec build "mv $corefile $corefile_2" # Load the core file and confirm that the full executable name and diff --git a/gdb/testsuite/gdb.base/corefile.exp b/gdb/testsuite/gdb.base/corefile.exp index 31249355353f..4f36dc58b29c 100644 --- a/gdb/testsuite/gdb.base/corefile.exp +++ b/gdb/testsuite/gdb.base/corefile.exp @@ -30,11 +30,11 @@ if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { # required for GDB to find mmap'd data in the "accessing read-only # mmapped data in core file" test. set corefile [core_find $binfile {}] if {$corefile == ""} { untested "unable to create or find corefile" - return 0 + return } # Start GDB with COREFILE passed as a command line argument. COREOPT # is prefixed before COREFILE and is the command line flag to specify # the corefile, i.e. one of '--core=', '-core=', '-c '. diff --git a/gdb/testsuite/gdb.base/corefile2.exp b/gdb/testsuite/gdb.base/corefile2.exp index 805e08973f6b..d98e8b0bd301 100644 --- a/gdb/testsuite/gdb.base/corefile2.exp +++ b/gdb/testsuite/gdb.base/corefile2.exp @@ -39,11 +39,11 @@ if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { } set corefile [core_find $binfile {}] if {$corefile == ""} { untested "unable to create or find corefile" - return 0 + return } gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} diff --git a/gdb/testsuite/gdb.base/ctf-constvars.exp b/gdb/testsuite/gdb.base/ctf-constvars.exp index 0fc59f226e45..9a98aaebe68a 100644 --- a/gdb/testsuite/gdb.base/ctf-constvars.exp +++ b/gdb/testsuite/gdb.base/ctf-constvars.exp @@ -34,11 +34,11 @@ lappend opts additional_flags=-gctf lappend opts ldflags=-Wl,--ctf-variables lappend opts nowarnings if { [build_executable "failed to prepare" ${testfile} \ [list $srcfile] $opts] } { - return 0 + return } clean_restart gdb_test_no_output "set always-read-ctf on" gdb_load $binfile diff --git a/gdb/testsuite/gdb.base/ctf-ptype.exp b/gdb/testsuite/gdb.base/ctf-ptype.exp index d3c3b46140c5..aabe3c9187d5 100644 --- a/gdb/testsuite/gdb.base/ctf-ptype.exp +++ b/gdb/testsuite/gdb.base/ctf-ptype.exp @@ -28,11 +28,11 @@ lappend opts additional_flags=-gctf lappend opts ldflags=-Wl,--ctf-variables lappend opts nowarnings if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile] $opts] } { - return 0 + return } clean_restart gdb_test_no_output "set always-read-ctf on" gdb_load $binfile diff --git a/gdb/testsuite/gdb.base/decl-before-def.exp b/gdb/testsuite/gdb.base/decl-before-def.exp index 66083d2aa710..396fd31bb850 100644 --- a/gdb/testsuite/gdb.base/decl-before-def.exp +++ b/gdb/testsuite/gdb.base/decl-before-def.exp @@ -24,9 +24,9 @@ if {[prepare_for_testing "failed to prepare" $testfile $sources]} { gdb_test "maint expand-symtabs" gdb_test "p a" { = \{1, 2\}} "no running process: p a" if {![runto_main]} { - return 0 + return } gdb_test "p a" { = \{1, 2\}} "running process: p a" diff --git a/gdb/testsuite/gdb.base/dup-sect.exp b/gdb/testsuite/gdb.base/dup-sect.exp index ef9ba340ae24..b20c0e8ca731 100644 --- a/gdb/testsuite/gdb.base/dup-sect.exp +++ b/gdb/testsuite/gdb.base/dup-sect.exp @@ -27,11 +27,11 @@ if {![istarget *-*-linux*] && ![istarget *-*-gnu*] && ![istarget *-*-elf*] && ![istarget arm*-*-eabi*] && ![istarget powerpc-*-eabi*]} { - return 0 + return } standard_testfile .S set srcmainfile start.c set executable ${testfile} diff --git a/gdb/testsuite/gdb.base/eh_return.exp b/gdb/testsuite/gdb.base/eh_return.exp index c6f1d7375c58..5a32ab0d2b89 100644 --- a/gdb/testsuite/gdb.base/eh_return.exp +++ b/gdb/testsuite/gdb.base/eh_return.exp @@ -66,11 +66,11 @@ gdb_test_multiple "disassemble eh2" "" { pass $gdb_test_name } } if { $address == -1 } { - return 0 + return } clean_restart $testfile gdb_assert [gdb_breakpoint "*$address" no-message] "set breakpoint on address" diff --git a/gdb/testsuite/gdb.base/eu-strip-infcall.exp b/gdb/testsuite/gdb.base/eu-strip-infcall.exp index 73df0e5650bb..6cc079e81688 100644 --- a/gdb/testsuite/gdb.base/eu-strip-infcall.exp +++ b/gdb/testsuite/gdb.base/eu-strip-infcall.exp @@ -21,11 +21,11 @@ if {[build_executable ${testfile}.exp $testfile] == -1} { set test "eu-strip" set status [remote_exec build "eu-strip -f ${binfile}.debug $binfile"] if {[lindex $status 0] != 0} { untested "failed to compile" - return 0 + return } clean_restart $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.base/frameapply.exp b/gdb/testsuite/gdb.base/frameapply.exp index 7525ba5085c5..2ca2ce0461ff 100644 --- a/gdb/testsuite/gdb.base/frameapply.exp +++ b/gdb/testsuite/gdb.base/frameapply.exp @@ -23,11 +23,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { return } if {![runto setup_done]} { - return 0 + return } set any "\[^\r\n\]*" set ws "\[ \t\]\+" set number "\[0-9]\+" diff --git a/gdb/testsuite/gdb.base/func-ptr.exp b/gdb/testsuite/gdb.base/func-ptr.exp index 0f656d127807..ba2807704aba 100644 --- a/gdb/testsuite/gdb.base/func-ptr.exp +++ b/gdb/testsuite/gdb.base/func-ptr.exp @@ -20,10 +20,10 @@ if { [prepare_for_testing "failed to prepare" "func-ptr" {func-ptr.c} {debug}] } { return } if {![runto_main]} { - return 0 + return } # This would put gdb into an infinite loop. gdb_test "print pbar->baz" "Attempt to extract .*" diff --git a/gdb/testsuite/gdb.base/gdb11530.exp b/gdb/testsuite/gdb.base/gdb11530.exp index fb293b986c7d..678b1184d30c 100644 --- a/gdb/testsuite/gdb.base/gdb11530.exp +++ b/gdb/testsuite/gdb.base/gdb11530.exp @@ -21,11 +21,11 @@ standard_testfile # Unnamed union is a GNU extension, thus we restrict the test # to gcc compiler. if { ![test_compiler_info gcc*] } { - return 0 + return } if { [prepare_for_testing "failed to prepare" $testfile $testfile.c {debug}] } { return } diff --git a/gdb/testsuite/gdb.base/gdb1555.exp b/gdb/testsuite/gdb.base/gdb1555.exp index 9b463b75d541..6402a8f4e291 100644 --- a/gdb/testsuite/gdb.base/gdb1555.exp +++ b/gdb/testsuite/gdb.base/gdb1555.exp @@ -38,11 +38,11 @@ if { [prepare_for_testing "prepare" $testfile $execsrc\ } gdb_load_shlib $libobj if {![runto_main]} { - return 0 + return } # PR/1555 (was shlib 1280) set name "Step into shared lib function" gdb_test_multiple "s" $name \ diff --git a/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp b/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp index a1fffc51ea2b..8834b73fdf6d 100644 --- a/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp +++ b/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp @@ -31,9 +31,9 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } gdb_test "info locals" "\r\nb = .*" diff --git a/gdb/testsuite/gdb.base/info-shared.exp b/gdb/testsuite/gdb.base/info-shared.exp index 41a47a30d7d6..993e64f64a27 100644 --- a/gdb/testsuite/gdb.base/info-shared.exp +++ b/gdb/testsuite/gdb.base/info-shared.exp @@ -83,11 +83,11 @@ proc check_info_shared { test expect1 expect2 } { check_info_shared "info sharedlibrary before running" 0 0 # Start the inferior, and check neither of the libraries are loaded at # the start. if {![runto_main]} { - return 0 + return } check_info_shared "info sharedlibrary #1" 0 0 # Set up breakpoints. gdb_breakpoint "stop" diff --git a/gdb/testsuite/gdb.base/info_qt.exp b/gdb/testsuite/gdb.base/info_qt.exp index 40cd9547bae8..6ae4fc3bf7ac 100644 --- a/gdb/testsuite/gdb.base/info_qt.exp +++ b/gdb/testsuite/gdb.base/info_qt.exp @@ -26,11 +26,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { return } if {![runto setup_done]} { - return 0 + return } set any "\[^\r\n\]*" set ws "\[ \t\]\+" set number "\[0-9]\+" diff --git a/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp b/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp index 4bda78dd27d6..3a378cd69601 100644 --- a/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp +++ b/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp @@ -56,11 +56,11 @@ require allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { return } if {![runto_main]} { - return 0 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] # Run to the breakpoint where we will carry out the test. diff --git a/gdb/testsuite/gdb.base/interrupt.exp b/gdb/testsuite/gdb.base/interrupt.exp index 44a27434bc2b..884a66a0d561 100644 --- a/gdb/testsuite/gdb.base/interrupt.exp +++ b/gdb/testsuite/gdb.base/interrupt.exp @@ -34,11 +34,11 @@ if {[build_executable $testfile.exp $testfile $srcfile $options] == -1} { gdb_start if {![file exists $binfile]} { - return 0 + return } else { gdb_reinitialize_dir $srcdir/$subdir gdb_load $binfile # Hope this is unix :-) gdb_test "shell stty intr '^C'" ".*" \ diff --git a/gdb/testsuite/gdb.base/label-without-address.exp b/gdb/testsuite/gdb.base/label-without-address.exp index 7796de94c078..1a6a5f611426 100644 --- a/gdb/testsuite/gdb.base/label-without-address.exp +++ b/gdb/testsuite/gdb.base/label-without-address.exp @@ -18,11 +18,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set supported 0 gdb_test_multiple "l main:L1" "" { -wrap -re "No label \"L1\" defined in function \"main\"\." { diff --git a/gdb/testsuite/gdb.base/list-missing-source.exp b/gdb/testsuite/gdb.base/list-missing-source.exp index fb78c85ffb08..b5b1919073fd 100644 --- a/gdb/testsuite/gdb.base/list-missing-source.exp +++ b/gdb/testsuite/gdb.base/list-missing-source.exp @@ -44,11 +44,11 @@ remote_file host delete $srcfile # Now start GDB, run to main and try to list the source. clean_restart $testfile if {![runto_main]} { - return 0 + return } gdb_test "list" "1\[ \t\]+in\[ \t\]+$srcfile" gdb_test "info source" \ diff --git a/gdb/testsuite/gdb.base/macscp.exp b/gdb/testsuite/gdb.base/macscp.exp index 44debe1e7f87..e40bfb633378 100644 --- a/gdb/testsuite/gdb.base/macscp.exp +++ b/gdb/testsuite/gdb.base/macscp.exp @@ -203,11 +203,11 @@ gdb_test_multiple "info source" "test macro information" { warning "couldn't check macro support (no valid response)." } } if {$macro_support == 0} { unsupported "skipping test because debug information does not include macro information." - return 0 + return } list_and_check_macro main WHERE {macscp1.c {before macscp1_3}} list_and_check_macro macscp2_2 WHERE {macscp2.h macscp1.c {before macscp2_2}} list_and_check_macro macscp3_2 WHERE {macscp3.h macscp1.c {before macscp3_2}} @@ -332,11 +332,11 @@ proc maybe_kfail { func test_name } { } } # Start the program running. if {! [runto_main]} { - return 0 + return } # Set a breakpoint on each of the functions. foreach func_entry $funcs { set func [lindex $func_entry 0] diff --git a/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp b/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp index b123162d6e5b..f6e4c27e4581 100644 --- a/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp +++ b/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp @@ -22,11 +22,11 @@ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug nopie}]} { return } if {![runto normal_func]} { - return 0 + return } # Make a pattern to match 'maint info blocks' output. ARGS is the # list of function names we expect to see. If the function name # starts with 'inline_func' then we expect to see an inline block, diff --git a/gdb/testsuite/gdb.base/many-headers.exp b/gdb/testsuite/gdb.base/many-headers.exp index 6b13db61e740..049c601cf675 100644 --- a/gdb/testsuite/gdb.base/many-headers.exp +++ b/gdb/testsuite/gdb.base/many-headers.exp @@ -32,11 +32,11 @@ if {[build_executable "failed to prepare" $testfile $srcfile debug]} { # Generate core file. set corefile [core_find $binfile] if {$corefile == ""} { untested "unable to create or find corefile" - return 0 + return } # Limit is in kb, so this is 4MB. set stack_limit 4096 diff --git a/gdb/testsuite/gdb.base/max-value-size.exp b/gdb/testsuite/gdb.base/max-value-size.exp index ba5266401ee8..ddd38d84004e 100644 --- a/gdb/testsuite/gdb.base/max-value-size.exp +++ b/gdb/testsuite/gdb.base/max-value-size.exp @@ -18,11 +18,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # Run "show max-value-size" and return the interesting bit of the # result. This is either the maximum size in bytes, or the string # "unlimited". diff --git a/gdb/testsuite/gdb.base/overlays.exp b/gdb/testsuite/gdb.base/overlays.exp index 3f584ee83c3a..1cb452b77142 100644 --- a/gdb/testsuite/gdb.base/overlays.exp +++ b/gdb/testsuite/gdb.base/overlays.exp @@ -43,11 +43,11 @@ gdb_load ${binfile} # # set it up at a breakpoint so we can play with the variable values # if {![runto_main]} { - return 0 + return } # couple of convenience variables set fptrcast [string_to_regexp "{int (int)}"] set iptrcast [string_to_regexp "(int *)"] diff --git a/gdb/testsuite/gdb.base/pr11022.exp b/gdb/testsuite/gdb.base/pr11022.exp index 524d6901c94a..4d85a8ad28a2 100644 --- a/gdb/testsuite/gdb.base/pr11022.exp +++ b/gdb/testsuite/gdb.base/pr11022.exp @@ -20,11 +20,11 @@ standard_testfile .c if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { return } if {![runto_main]} { - return 0 + return } gdb_test "break [gdb_get_line_number "break here"]" \ ".*Breakpoint.* at .*" \ "set breakpoint" diff --git a/gdb/testsuite/gdb.base/prelink.exp b/gdb/testsuite/gdb.base/prelink.exp index 4f18af4739c2..e05bc55d6070 100644 --- a/gdb/testsuite/gdb.base/prelink.exp +++ b/gdb/testsuite/gdb.base/prelink.exp @@ -79,11 +79,11 @@ if { $found == 0 } { remote_file build delete [file join $coredir coremmap.data] remote_exec build "rmdir $coredir" if { $found == 0 } { warning "can't generate a core file - prelink tests suppressed - check ulimit -c" - return 0 + return } # Relink $libfile to a different address. if {![prelink_yes $prelink_args]} { return diff --git a/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp b/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp index c3e9fdbc6b9e..9f16d5db42c9 100644 --- a/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp +++ b/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp @@ -41,11 +41,11 @@ require allow_python_tests if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { return } if {![runto_main]} { - return 0 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_test_no_output "source ${pyfile}" "load python file" diff --git a/gdb/testsuite/gdb.base/print-internal-string.exp b/gdb/testsuite/gdb.base/print-internal-string.exp index 7ebf8ed9b4d4..d3d694480955 100644 --- a/gdb/testsuite/gdb.base/print-internal-string.exp +++ b/gdb/testsuite/gdb.base/print-internal-string.exp @@ -22,11 +22,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { return } if {![runto_main]} { - return 0 + return } if {[allow_python_tests]} { # The $_as_string convenience function is implemented in Python. gdb_test {printf "%s\n", $_as_string("aabbcc")} "\"aabbcc\"" diff --git a/gdb/testsuite/gdb.base/printcmds.exp b/gdb/testsuite/gdb.base/printcmds.exp index 631cfd891fcf..0be8f170d19f 100644 --- a/gdb/testsuite/gdb.base/printcmds.exp +++ b/gdb/testsuite/gdb.base/printcmds.exp @@ -1211,11 +1211,11 @@ if { [test_compiler_info "armcc-*"] } { gdb_test "p ctable1\[120\]" "120 'x'" "p ctable1\[120\] #1" gdb_load ${binfile} if {![runto_main]} { - return 0 + return } # With a running target, printf convenience vars should of course work. test_printf_convenience_var "with target" diff --git a/gdb/testsuite/gdb.base/ptype-offsets-c.exp b/gdb/testsuite/gdb.base/ptype-offsets-c.exp index fd88514f5f6b..9bee7b3f65b9 100644 --- a/gdb/testsuite/gdb.base/ptype-offsets-c.exp +++ b/gdb/testsuite/gdb.base/ptype-offsets-c.exp @@ -24,11 +24,11 @@ standard_testfile .c # Test only works on LP64 targets. That's how we guarantee that the # expected holes will be present in the struct. if { ![is_lp64_target] } { untested "test work only on lp64 targets" - return 0 + return } if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { return } diff --git a/gdb/testsuite/gdb.base/ptype-offsets.exp b/gdb/testsuite/gdb.base/ptype-offsets.exp index 56dca939fb33..bfee676e112f 100644 --- a/gdb/testsuite/gdb.base/ptype-offsets.exp +++ b/gdb/testsuite/gdb.base/ptype-offsets.exp @@ -22,11 +22,11 @@ standard_testfile .cc # Test only works on LP64 targets. That's how we guarantee that the # expected holes will be present in the struct. if { ![is_lp64_target] } { untested "test work only on lp64 targets" - return 0 + return } if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ { debug c++ }] } { return diff --git a/gdb/testsuite/gdb.base/reggroups.exp b/gdb/testsuite/gdb.base/reggroups.exp index f3866ec51cf4..2ff8d0940998 100644 --- a/gdb/testsuite/gdb.base/reggroups.exp +++ b/gdb/testsuite/gdb.base/reggroups.exp @@ -22,11 +22,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set invalid_register_re "Invalid register \[^\r\n\]*" # Fetch all reggroups from 'maint print reggroups'. diff --git a/gdb/testsuite/gdb.base/rtld-step.exp b/gdb/testsuite/gdb.base/rtld-step.exp index 57f878dfb395..12e1cabc44db 100644 --- a/gdb/testsuite/gdb.base/rtld-step.exp +++ b/gdb/testsuite/gdb.base/rtld-step.exp @@ -119,11 +119,11 @@ if { [gdb_compile ${srcfile_main} ${binfile_main} executable $main_flags] != "" clean_restart gdb_load $binfile_main if {![runto_main]} { - return 0 + return } # Running the command 'info sharedlibrary' should output a path to # the pretend/fake RTLD along with the address range. Check that # this path is present and, if so, extract the address range. diff --git a/gdb/testsuite/gdb.base/savedregs.exp b/gdb/testsuite/gdb.base/savedregs.exp index 35dc10acae19..985500bb62f4 100644 --- a/gdb/testsuite/gdb.base/savedregs.exp +++ b/gdb/testsuite/gdb.base/savedregs.exp @@ -33,11 +33,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { return } # Advance to main if {![runto_main]} { - return 0 + return } proc process_saved_regs { current inner outer } { global gdb_prompt global expect_out diff --git a/gdb/testsuite/gdb.base/set-noassign.exp b/gdb/testsuite/gdb.base/set-noassign.exp index 0f3b843cd1fe..621769ea9c30 100644 --- a/gdb/testsuite/gdb.base/set-noassign.exp +++ b/gdb/testsuite/gdb.base/set-noassign.exp @@ -17,11 +17,11 @@ if { [prepare_for_testing "failed to prepare" "set-noassign" start.c {debug nowarnings}] } { return } if {![runto_main]} { - return 0 + return } # Verify that set command without assignment emits a warning. # gdb_test "set language ada" ".*" diff --git a/gdb/testsuite/gdb.base/shreloc.exp b/gdb/testsuite/gdb.base/shreloc.exp index 5e3b60b27ee6..e0efd61bcdf9 100644 --- a/gdb/testsuite/gdb.base/shreloc.exp +++ b/gdb/testsuite/gdb.base/shreloc.exp @@ -67,11 +67,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile $exec_opts] != 0} { gdb_load_shlib $lib1_sl gdb_load_shlib $lib2_sl # Load up the shared objects if {![runto_main]} { - return 0 + return } # # Check debugging symbol relocations # diff --git a/gdb/testsuite/gdb.base/sigaltstack.exp b/gdb/testsuite/gdb.base/sigaltstack.exp index 354643f237a8..c9105342fa29 100644 --- a/gdb/testsuite/gdb.base/sigaltstack.exp +++ b/gdb/testsuite/gdb.base/sigaltstack.exp @@ -36,11 +36,11 @@ gdb_test "handle SIGALRM print pass nostop" gdb_test "handle SIGVTALRM print pass nostop" gdb_test "handle SIGPROF print pass nostop" # Advance to main if {![runto_main]} { - return 0 + return } # Stop in handle, when at the inner most level gdb_test "break catcher if level == INNER" gdb_test "continue" ".* catcher .*" "continue to catch" diff --git a/gdb/testsuite/gdb.base/sigbpt.exp b/gdb/testsuite/gdb.base/sigbpt.exp index c3f17e0e9707..8237b555d46e 100644 --- a/gdb/testsuite/gdb.base/sigbpt.exp +++ b/gdb/testsuite/gdb.base/sigbpt.exp @@ -40,11 +40,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # If we can examine what's at memory address 0, it is possible that we # could also execute it. This could probably make us run away, # executing random code, which could have all sorts of ill effects, diff --git a/gdb/testsuite/gdb.base/siginfo-addr.exp b/gdb/testsuite/gdb.base/siginfo-addr.exp index 93ce7a227909..a33d9bbe4999 100644 --- a/gdb/testsuite/gdb.base/siginfo-addr.exp +++ b/gdb/testsuite/gdb.base/siginfo-addr.exp @@ -30,11 +30,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { gdb_test "display/i \$pc" # Advance to main if {![runto_main]} { - return 0 + return } # Run to the signal. gdb_test "continue" ".*Program received signal SIGSEGV.*" "continue to signal" diff --git a/gdb/testsuite/gdb.base/siginfo-obj.exp b/gdb/testsuite/gdb.base/siginfo-obj.exp index daf160bc162b..a94bf0e33bae 100644 --- a/gdb/testsuite/gdb.base/siginfo-obj.exp +++ b/gdb/testsuite/gdb.base/siginfo-obj.exp @@ -32,11 +32,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } # Advance to main if {![runto_main]} { - return 0 + return } # Run to the signal. gdb_test "continue" ".*Program received signal SIGSEGV.*" \ "continue to signal, 1st" @@ -92,11 +92,11 @@ with_test_prefix "validate siginfo fields" { # Again, but this time, patch si_addr and check that the inferior sees # the changed value. # Advance to main if {![runto_main]} { - return 0 + return } # Run to the signal. gdb_test "continue" ".*Program received signal SIGSEGV.*" \ "continue to signal, 2nd" diff --git a/gdb/testsuite/gdb.base/siginfo-thread.exp b/gdb/testsuite/gdb.base/siginfo-thread.exp index 14f4ac06141b..40004234138e 100644 --- a/gdb/testsuite/gdb.base/siginfo-thread.exp +++ b/gdb/testsuite/gdb.base/siginfo-thread.exp @@ -26,11 +26,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile {debug pthreads}] != 0 } return } # Advance to main if {![runto_main]} { - return 0 + return } # Run to the signal. gdb_test "continue" "Thread .* received signal SIGSEGV.*" "continue to signal" diff --git a/gdb/testsuite/gdb.base/siginfo.exp b/gdb/testsuite/gdb.base/siginfo.exp index f5a00220f12a..21de03ed3f14 100644 --- a/gdb/testsuite/gdb.base/siginfo.exp +++ b/gdb/testsuite/gdb.base/siginfo.exp @@ -34,11 +34,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { gdb_test "display/i \$pc" # Advance to main if {![runto_main]} { - return 0 + return } # Pass all the alarms straight through (but verbosely) # gdb_test "handle SIGALRM print pass nostop" # gdb_test "handle SIGVTALRM print pass nostop" diff --git a/gdb/testsuite/gdb.base/signull.exp b/gdb/testsuite/gdb.base/signull.exp index 6927dac2fafc..93cc5a0301b3 100644 --- a/gdb/testsuite/gdb.base/signull.exp +++ b/gdb/testsuite/gdb.base/signull.exp @@ -39,11 +39,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # If we can examine what's at memory address 0, it is possible that we # could also execute it. This could probably make us run away, # executing random code, which could have all sorts of ill effects, diff --git a/gdb/testsuite/gdb.base/sigrepeat.exp b/gdb/testsuite/gdb.base/sigrepeat.exp index f14030b6f91d..d48aee2ff507 100644 --- a/gdb/testsuite/gdb.base/sigrepeat.exp +++ b/gdb/testsuite/gdb.base/sigrepeat.exp @@ -28,11 +28,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { return } # Advance to main if {![runto_main]} { - return 0 + return } # Run to the signal handler wait loop. set infinite_loop [gdb_get_line_number {infinite loop}] gdb_test "advance $infinite_loop" ".*" "advance to infinite loop" diff --git a/gdb/testsuite/gdb.base/solib-disc.exp b/gdb/testsuite/gdb.base/solib-disc.exp index a9b2bd471eea..6fc5bfee0083 100644 --- a/gdb/testsuite/gdb.base/solib-disc.exp +++ b/gdb/testsuite/gdb.base/solib-disc.exp @@ -18,11 +18,11 @@ require allow_shlib_tests set gdbserver_reconnect_p 1 if { [info proc gdb_reconnect] == "" } { unsupported "requires gdbserver reconnect" - return 0 + return } set testfile solib-disc set libfile so-disc-shr set srcfile ${testfile}.c @@ -48,11 +48,11 @@ if { [prepare_for_testing "prepare" $testfile $execsrc $exec_opts] != 0 } { } gdb_load_shlib $libobj if {![runto_main]} { - return 0 + return } gdb_test_no_output "set stop-on-solib-events 1" gdb_test "continue" "Stopped due to shared library event.*" "continue to load" @@ -69,11 +69,11 @@ gdb_test_multiple "print/x \$pc" $msg { gdb_test "disconnect" "Ending remote debugging\\." "disconnect after load" if { [gdb_reconnect] == 0 } { pass "reconnect after load" } else { fail "reconnect after load" - return 0 + return } gdb_test "print/x \$pc" "${::valnum_re} = $saved_pc" "check \$pc after load" @@ -91,9 +91,9 @@ gdb_test_multiple "print/x \$pc" $msg { gdb_test "disconnect" "Ending remote debugging\\." "disconnect after unload" if { [gdb_reconnect] == 0 } { pass "reconnect after unload" } else { fail "reconnect after unload" - return 0 + return } gdb_test "print/x \$pc" "${::valnum_re} = $saved_pc" "check \$pc after unload" diff --git a/gdb/testsuite/gdb.base/solib-weak.exp b/gdb/testsuite/gdb.base/solib-weak.exp index 449d468603fe..319100e4a552 100644 --- a/gdb/testsuite/gdb.base/solib-weak.exp +++ b/gdb/testsuite/gdb.base/solib-weak.exp @@ -21,16 +21,16 @@ require allow_shlib_tests # These targets have shared libraries, but weak symbols are not meaningful. if {([istarget *-*-mingw*] || [istarget *-*-cygwin*] || [istarget *-*-pe*])} { - return 0 + return } # This test uses GCC-specific syntax. if {![test_compiler_info "gcc-*"]} { - return 0 + return } proc do_test { lib1opts lib2opts lib1first } { global srcdir subdir diff --git a/gdb/testsuite/gdb.base/source-execution.exp b/gdb/testsuite/gdb.base/source-execution.exp index a16535e97e4c..9c5b4d611498 100644 --- a/gdb/testsuite/gdb.base/source-execution.exp +++ b/gdb/testsuite/gdb.base/source-execution.exp @@ -22,11 +22,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } gdb_test "source ${srcdir}/${subdir}/source-execution.gdb" \ "func2.*func3.*" \ "source source-execution.gdb" diff --git a/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp b/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp index 6b299b3bc05a..be2150450485 100644 --- a/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp +++ b/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp @@ -40,11 +40,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } delete_breakpoints # With the all-stop RSP, we can't talk to the target while it's diff --git a/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp b/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp index 042caf6c27bb..0bc6ff83fe87 100644 --- a/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp +++ b/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp @@ -23,11 +23,11 @@ set executable ${testfile} if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "set foo break here"] gdb_continue_to_breakpoint "first breakpoint" ".* set foo break here .*" diff --git a/gdb/testsuite/gdb.base/stack-checking.exp b/gdb/testsuite/gdb.base/stack-checking.exp index 72b3ad1cc0cc..7e6789b7c04f 100644 --- a/gdb/testsuite/gdb.base/stack-checking.exp +++ b/gdb/testsuite/gdb.base/stack-checking.exp @@ -20,11 +20,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile \ [list debug additional_flags=-fstack-check nowarnings]] != 0 } { return } if {![runto_main]} { - return 0 + return } # Test that the debugger is able to unwind to "main" at the next breakpoint # hit. The frame number of "main" should be passed into MAIN_FRAME_NUMBER." diff --git a/gdb/testsuite/gdb.base/stack-protector.exp b/gdb/testsuite/gdb.base/stack-protector.exp index 249baad8ac8e..b2d1e6000e8c 100644 --- a/gdb/testsuite/gdb.base/stack-protector.exp +++ b/gdb/testsuite/gdb.base/stack-protector.exp @@ -22,11 +22,11 @@ # protection. if { !([test_compiler_info "gcc-*"] || [test_compiler_info "clang-*"]) || [test_compiler_info {gcc-[0-3]-*}] || [test_compiler_info {gcc-4-0-*}] || [test_compiler_info {clang-[0-4]=*}] } { - return 0 + return } standard_testfile set protector_options { "-fno-stack-protector" "-fstack-protector" \ diff --git a/gdb/testsuite/gdb.base/structs2.exp b/gdb/testsuite/gdb.base/structs2.exp index 76deeae53839..ce8b0c00769f 100644 --- a/gdb/testsuite/gdb.base/structs2.exp +++ b/gdb/testsuite/gdb.base/structs2.exp @@ -18,11 +18,11 @@ standard_testfile .c if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug}] } { return } if {![runto_main]} { - return 0 + return } gdb_test "f" \ ".*bkpt = 0.*" \ "structs2 sanity check" diff --git a/gdb/testsuite/gdb.base/sym-file.exp b/gdb/testsuite/gdb.base/sym-file.exp index fe7b5ad13fa0..022c1eedbd9e 100644 --- a/gdb/testsuite/gdb.base/sym-file.exp +++ b/gdb/testsuite/gdb.base/sym-file.exp @@ -37,11 +37,11 @@ set target_size TARGET_UNKNOWN if {[is_lp64_target]} { set target_size TARGET_LP64 } elseif {[is_ilp32_target]} { set target_size TARGET_ILP32 } else { - return 0 + return } set main_basename sym-file-main set loader_basename sym-file-loader set lib_basename sym-file-lib diff --git a/gdb/testsuite/gdb.base/symlink-sourcefile.exp b/gdb/testsuite/gdb.base/symlink-sourcefile.exp index bc2249071eb5..fc6a0c08b2d5 100644 --- a/gdb/testsuite/gdb.base/symlink-sourcefile.exp +++ b/gdb/testsuite/gdb.base/symlink-sourcefile.exp @@ -26,11 +26,11 @@ set srcfilelink [standard_output_file $linksrc] remote_file host delete $srcfilelink set status [remote_exec host \ "ln -sf $srcdir/$subdir/$srcfile $srcfilelink"] if {[lindex $status 0] != 0} { unsupported "$test (host does not support symbolic links)" - return 0 + return } if {[prepare_for_testing $testfile $testfile $srcfilelink]} { return } diff --git a/gdb/testsuite/gdb.base/term.exp b/gdb/testsuite/gdb.base/term.exp index b615d9a410e9..8612a04e57b9 100644 --- a/gdb/testsuite/gdb.base/term.exp +++ b/gdb/testsuite/gdb.base/term.exp @@ -24,11 +24,11 @@ if { [prepare_for_testing "failed to prepare" term term.c] } { gdb_test "info terminal" \ "No saved terminal information.*" \ "test info terminal pre-execution" if {![runto break_here]} { - return 0 + return } # Read the inferior's terminal settings, saved in the T global variable. proc read_term_settings_from_inferior {} { diff --git a/gdb/testsuite/gdb.base/type-opaque.exp b/gdb/testsuite/gdb.base/type-opaque.exp index 7c4d24eccb9b..f173639a02ac 100644 --- a/gdb/testsuite/gdb.base/type-opaque.exp +++ b/gdb/testsuite/gdb.base/type-opaque.exp @@ -36,11 +36,11 @@ if { [prepare_for_testing "prepare" $testfile $execsrc \ } gdb_load_shlib ${libobj} if {![runto_main]} { - return 0 + return } # DWARF3: An incomplete structure, union or class type is represented by # a structure, union or class entry that does not have a byte size attribute diff --git a/gdb/testsuite/gdb.base/until-nodebug.exp b/gdb/testsuite/gdb.base/until-nodebug.exp index 5980bc435ced..01be462bb86f 100644 --- a/gdb/testsuite/gdb.base/until-nodebug.exp +++ b/gdb/testsuite/gdb.base/until-nodebug.exp @@ -21,11 +21,11 @@ standard_testfile advance.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile nodebug]} { return } if {![runto_main]} { - return 0 + return } # Without debug information, the program stops at the next # instruction, which is still in main. gdb_test "until" "in main .*" "until 1" diff --git a/gdb/testsuite/gdb.base/until.exp b/gdb/testsuite/gdb.base/until.exp index 58f9174af988..5aeb896e3118 100644 --- a/gdb/testsuite/gdb.base/until.exp +++ b/gdb/testsuite/gdb.base/until.exp @@ -24,11 +24,11 @@ set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location19 [gdb_get_line_number "set breakpoint 19 here"] set bp_location20 [gdb_get_line_number "set breakpoint 20 here"] set bp_location21 [gdb_get_line_number "set breakpoint 21 here"] if {![runto_main]} { - return 0 + return } # Verify that "until " works. (This is really just syntactic # sugar for "tbreak ; continue".) # diff --git a/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl b/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl index 471342684aec..ed7bf83752fd 100644 --- a/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl +++ b/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl @@ -28,11 +28,11 @@ if {[prepare_for_testing_full "failed to prepare" \ $srcfile $srcfile_flags $srcfile2 $srcfile2_flags]]} { return } if {![runto_main]} { - return 0 + return } # Return a two element list, the first element is the stack-pointer # value (from the $sp register), and the second element is the frame # base address (from the 'info frame' output). diff --git a/gdb/testsuite/gdb.base/unwindonsignal.exp b/gdb/testsuite/gdb.base/unwindonsignal.exp index cd98b9fdd02f..aed8ef6f4c75 100644 --- a/gdb/testsuite/gdb.base/unwindonsignal.exp +++ b/gdb/testsuite/gdb.base/unwindonsignal.exp @@ -25,11 +25,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if { ![runto_main] } { - return 0 + return } gdb_test "break stop_here" "Breakpoint \[0-9\]* at .*" gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_here.*" \ "continue to breakpoint at stop_here" @@ -66,11 +66,11 @@ if {[gdb_test "call gen_signal ()" \ "while in a function called from GDB\\. GDB has restored the context" \ "to what it was before the call\\. To change this behavior use" \ "\"set unwind-on-signal off\"\\. Evaluation of the expression containing" \ "the function \\(gen_signal\\) will be abandoned\\."] \ "unwindonsignal, inferior function call signaled"] != 0} { - return 0 + return } # Verify the stack got unwound. gdb_test "bt" \ "#0 *\[x0-9a-f in\]*stop_here \\(.*\\) at .*#1 *\[x0-9a-f in\]*main \\(.*\\) at .*" \ diff --git a/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp b/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp index 85494e5463ed..3f853b51527f 100644 --- a/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp +++ b/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp @@ -37,11 +37,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } # The line we'll be stepping. set srcline [gdb_get_line_number "stepi line"] From patchwork Wed Apr 29 23:04:06 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134224 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 5D5BE4BAE7C9 for ; Wed, 29 Apr 2026 23:11:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 5D5BE4BAE7C9 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=JeqvnckV X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x92d.google.com (mail-ua1-x92d.google.com [IPv6:2607:f8b0:4864:20::92d]) by sourceware.org (Postfix) with ESMTPS id 118AC4358A6B for ; Wed, 29 Apr 2026 23:05:31 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 118AC4358A6B Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 118AC4358A6B Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::92d ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503931; cv=none; b=P+YwUWh1ttWmt4QhS7Ajvnhg/hkVeTM92X/uA/XceGuvbSuIONdB5VzGsoYBvTMKe1IwJ07CKVGfJDNtWWPQyvO5b6q2G8aLL9fNELJHWuJAR5uIKex5ycd+C5cFXLlIKzd4S+DzWlJ0QpD3mUC6Y55Tv9tIeeShI7J5m+mUOnQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503931; c=relaxed/simple; bh=uiBlvLn1lt47Hue5pFHWm86c7WcslpcP2xxbGedG4tI=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=QXqOgVMDqAa7voanbHGNU9PDfKcPu8/7GYXz4rRycwDpwrwGzf6MowtGKAO3GHDDJ5aeSZAlqcXNI+Tm87NTPEKD2wpLKiCpmfYrso8V+dKpGcc0A5F2xp1am92IdnIJsZYuVthz/0iJ/+mL2Mz3UfvKK//wj15l4OGiVfNe/tU= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 118AC4358A6B Received: by mail-ua1-x92d.google.com with SMTP id a1e0cc1a2514c-95697b46831so218718241.0 for ; Wed, 29 Apr 2026 16:05:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503930; x=1778108730; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=OWWPBE/nzsR1TNmwL5P9qPsfStcO0UON/rDhjOuswVs=; b=JeqvnckVtyD7H8M6MKQziSgj6Atf7GvYZ9N4pEs+Q20fWVBJM13KbWS2GyYU5gJObC 0NsNceSZANkNFtp2/lthpUocLEbWrpYxHWkZd6SaNf0W7DamGkyivq6EVWMNUlwQz1d2 6TJcP3cZoGfGqRU9TDZ9MI2jmfJqssFVRlvwkZYI1aFyCyp6qRBnHB/DyK3hA8StNTmk 8fCx0NfQqA860Hktmtwf76I/KW7yeTP2k7mo7YbvSycbv0FPm8qIkZwx4gHsJTRtz3fs XJpmMdux9Uez6N73ia4NAuRRGnxK201CY2nNR09cJymI8Zhll6dD9mqqe6t3tzbAJ+c4 PaFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503930; x=1778108730; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=OWWPBE/nzsR1TNmwL5P9qPsfStcO0UON/rDhjOuswVs=; b=VqNsyj2N47NfMVKwgv3gDElg7w1Lx3mml+0eehIzuYzBSE/m/BoNhvRzWZ6zSF6vAE 6hRuTcdr5ezNFj5tZgSTDJQ9SkRNThkXyEoiQR+ebbORq1CYlpi9TRPcbe4Y2qIRcNLl Hij4FNSdJvcatHDYUXAjDhq6FV5pfP4qrz69CV9+9dqfxh6fm7r/hYjq55T2zgOF9eFp iLfXsXS54ejvFL3pu+QxNw9VCqnXECQWilbpq5o7XVqUeSB6tMcUATroP8xOfEUxBPpy yu9tXprBJ7sKvQ97S3caHjhM7TwZ9kEQywUAGp8eMVlfCqNy1S870Gp4J3zTkCaC0lnV muuw== X-Gm-Message-State: AOJu0YzQ5k1U/+g9IGoGWrJAqyA7/5CVN7q66oZ8tnsbDMrPzYF8XOJU /jXvBJU4plF94rFM2sD+w10rywT0Kx7XQXNV7FPyCpyla8334rZ//A1ZlmEkjwUpPnITVEVryL8 OztWN X-Gm-Gg: AeBDieuKKjGK2Jd8FyavZyTEtIk4ntMZ4jmc1Oma+x1B4ybJ5Z6FHq/bITNWmPwuB1n RPSwk4lC5sq+GoPHqWf7V+6dmhD5XpfUg2kTORF9RcdFNwXzCRjtKOokKemo7egDi6TykAOOVOc 8/CQtP9vkcDO0vs0MuK5lmdo0hXUzYu841+CaR4I0f14N8wAFvzdTI6dFpTWZQKMwqty+as/hiu oWy0MaKesyUbAqHwZrVAtaYtpMg587ppCF1M1Lj8hv0+ORC5D4Q5oUZQ/2IoKYA3yzdkOHMv+Kt iyYmEDSPm/8YI0vWQEdgpE4f/bIX/5T86hILAefOS7+6Urng+rgnN4CciRIZt0DjRAeDu+7tf6/ 2NT8XUoUQ7YPTsJ+eWB+k9w5ph9ZDsGzJPH/L6j82VkeZ71lFT4l1cblpZzdw5Gf0VNxze3j1Yr ruLDRKIjqepAoBVad6QDKRjY1bj/n6NdG5xBdK/vAO/56HumKlVGtxMAw= X-Received: by 2002:a05:6102:554c:b0:604:f029:224c with SMTP id ada2fe7eead31-62ad223bf06mr286891137.8.1777503929807; Wed, 29 Apr 2026 16:05:29 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb7584bb1sm1750694241.2.2026.04.29.16.05.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:29 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 15/37] GDB: testsuite: base: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:06 -0300 Message-ID: <20260429230432.60487-16-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" and "return 0" statements that weren't caught by the sed command. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside a block such as save_vars, with_test_prefix, foreach, gdb_test_multiple. Some weren't changed because they didn't meet the criteria above, or weren't trivial to check. There was also one return statement with an unnecessary semi-colon at the end, which was removed. --- gdb/testsuite/gdb.base/argv0-symlink.exp | 8 ++++---- gdb/testsuite/gdb.base/async-shell.exp | 2 +- gdb/testsuite/gdb.base/attach-pie-misread.exp | 2 +- gdb/testsuite/gdb.base/bigcore.exp | 4 ++-- gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp | 2 +- gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp | 2 +- gdb/testsuite/gdb.base/branch-to-self.exp | 4 ++-- gdb/testsuite/gdb.base/break-always.exp | 2 +- gdb/testsuite/gdb.base/bt-on-error-and-warning.exp | 2 +- gdb/testsuite/gdb.base/bt-on-fatal-signal.exp | 2 +- gdb/testsuite/gdb.base/catch-fork-kill.exp | 2 +- gdb/testsuite/gdb.base/catch-syscall.exp | 2 +- gdb/testsuite/gdb.base/checkpoint.exp | 2 +- gdb/testsuite/gdb.base/code_elim.exp | 4 ++-- gdb/testsuite/gdb.base/compare-sections.exp | 6 +++--- gdb/testsuite/gdb.base/cond-eval-mode.exp | 2 +- gdb/testsuite/gdb.base/condbreak-bad.exp | 6 +++--- .../gdb.base/continue-all-already-running.exp | 2 +- gdb/testsuite/gdb.base/coredump-filter.exp | 2 +- gdb/testsuite/gdb.base/corefile-buildid.exp | 4 ++-- gdb/testsuite/gdb.base/corefile-exec-context.exp | 2 +- gdb/testsuite/gdb.base/corefile-find-exec.exp | 12 ++++++------ gdb/testsuite/gdb.base/cvexpr.exp | 2 +- gdb/testsuite/gdb.base/detach.exp | 2 +- gdb/testsuite/gdb.base/disabled-location.exp | 2 +- gdb/testsuite/gdb.base/dmsym.exp | 4 ++-- gdb/testsuite/gdb.base/dso2dso.exp | 4 ++-- gdb/testsuite/gdb.base/endianity.exp | 4 ++-- gdb/testsuite/gdb.base/foll-exec-mode.exp | 8 ++++---- gdb/testsuite/gdb.base/fullname.exp | 2 +- gdb/testsuite/gdb.base/fullpath-expand.exp | 2 +- gdb/testsuite/gdb.base/gcore-relro.exp | 12 ++++++------ gdb/testsuite/gdb.base/gcore.exp | 2 +- gdb/testsuite/gdb.base/gcorebg.exp | 2 +- gdb/testsuite/gdb.base/global-var-nested-by-dso.exp | 2 +- gdb/testsuite/gdb.base/gnu-ifunc.exp | 2 +- gdb/testsuite/gdb.base/gnu_vector.exp | 4 ++-- gdb/testsuite/gdb.base/huge.exp | 2 +- gdb/testsuite/gdb.base/info-fun.exp | 4 ++-- gdb/testsuite/gdb.base/info-proc.exp | 4 ++-- gdb/testsuite/gdb.base/info-shared.exp | 2 +- gdb/testsuite/gdb.base/interp.exp | 2 +- gdb/testsuite/gdb.base/jit-reader-simple.exp | 2 +- gdb/testsuite/gdb.base/jump.exp | 2 +- gdb/testsuite/gdb.base/label.exp | 2 +- gdb/testsuite/gdb.base/longjmp.exp | 4 ++-- gdb/testsuite/gdb.base/moribund-step.exp | 2 +- gdb/testsuite/gdb.base/nostdlib.exp | 2 +- gdb/testsuite/gdb.base/overlays.exp | 4 ++-- gdb/testsuite/gdb.base/printcmds.exp | 4 ++-- gdb/testsuite/gdb.base/random-signal.exp | 2 +- gdb/testsuite/gdb.base/randomize.exp | 4 ++-- gdb/testsuite/gdb.base/readline-ask.exp | 2 +- gdb/testsuite/gdb.base/readline.exp | 2 +- gdb/testsuite/gdb.base/readnever.exp | 2 +- gdb/testsuite/gdb.base/relocate.exp | 4 ++-- gdb/testsuite/gdb.base/reread.exp | 4 ++-- gdb/testsuite/gdb.base/return2.exp | 4 ++-- gdb/testsuite/gdb.base/setshow.exp | 4 ++-- gdb/testsuite/gdb.base/solib-abort.exp | 2 +- gdb/testsuite/gdb.base/solib-bad-entry-addr.exp | 2 +- gdb/testsuite/gdb.base/solib-display.exp | 4 ++-- gdb/testsuite/gdb.base/solib-overlap.exp | 6 +++--- gdb/testsuite/gdb.base/solib-search.exp | 2 +- gdb/testsuite/gdb.base/solib-symbol.exp | 2 +- gdb/testsuite/gdb.base/stale-infcall.exp | 2 +- gdb/testsuite/gdb.base/step-break.exp | 4 ++-- gdb/testsuite/gdb.base/step-line.exp | 2 +- gdb/testsuite/gdb.base/step-test.exp | 6 +++--- gdb/testsuite/gdb.base/style-logging.exp | 2 +- gdb/testsuite/gdb.base/testenv.exp | 2 +- gdb/testsuite/gdb.base/traced-thread.exp | 2 +- gdb/testsuite/gdb.base/valgrind-bt.exp | 4 ++-- gdb/testsuite/gdb.base/valgrind-infcall.exp | 4 ++-- gdb/testsuite/gdb.base/vdso-warning.exp | 2 +- gdb/testsuite/gdb.base/watchpoint.exp | 4 ++-- gdb/testsuite/gdb.base/wchar.exp | 2 +- gdb/testsuite/gdb.base/wrong_frame_bt_full.exp | 4 ++-- 78 files changed, 126 insertions(+), 126 deletions(-) diff --git a/gdb/testsuite/gdb.base/argv0-symlink.exp b/gdb/testsuite/gdb.base/argv0-symlink.exp index 6b05bba205d6..58d5ef98fc44 100644 --- a/gdb/testsuite/gdb.base/argv0-symlink.exp +++ b/gdb/testsuite/gdb.base/argv0-symlink.exp @@ -40,17 +40,17 @@ with_test_prefix "file symlink" { remote_file host delete [standard_output_file $filelink] set status [remote_exec host \ "ln -sf ${testfile} [standard_output_file $filelink]"] if {[lindex $status 0] != 0} { unsupported "$test (host does not support symbolic links)" - return 0 + return } clean_restart "$filelink" if {![runto_main]} { - return -1 + return } gdb_test_no_output "set print repeats 10000" gdb_test_no_output "set print elements 10000" @@ -80,17 +80,17 @@ with_test_prefix "dir symlink" { # delete a directory. remote_exec host "rm -f [standard_output_file $dirlink]" set status [remote_exec host "ln -sf . [standard_output_file $dirlink]"] if {[lindex $status 0] != 0} { unsupported "$test (host does not support symbolic links)" - return 0 + return } clean_restart "$dirlink/$filelink" if {![runto_main]} { - return -1 + return } gdb_test_no_output "set print repeats 10000" gdb_test_no_output "set print elements 10000" diff --git a/gdb/testsuite/gdb.base/async-shell.exp b/gdb/testsuite/gdb.base/async-shell.exp index 72f3645a757e..28003fa92d3d 100644 --- a/gdb/testsuite/gdb.base/async-shell.exp +++ b/gdb/testsuite/gdb.base/async-shell.exp @@ -21,11 +21,11 @@ require support_displaced_stepping require !use_gdb_stub save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS -ex \"set non-stop on\"" if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } } set gdbindex_warning_re "warning: Skipping \[^\r\n\]+ \\.gdb_index section \[^\r\n\]*\r\nDo \"set use-deprecated-index-sections on\" before the file is read\r\nto use the section anyway\\." diff --git a/gdb/testsuite/gdb.base/attach-pie-misread.exp b/gdb/testsuite/gdb.base/attach-pie-misread.exp index a8002119d962..d2decd801fc3 100644 --- a/gdb/testsuite/gdb.base/attach-pie-misread.exp +++ b/gdb/testsuite/gdb.base/attach-pie-misread.exp @@ -97,11 +97,11 @@ if {$result == 0} { with_test_prefix "rebuild with DGEN defined" { set prelink_args [build_executable_own_libs ${testfile}.exp $executable $srcfile \ [list pie "additional_flags=-DGEN=\"$genfile\""]] if {$prelink_args == ""} { - return -1 + return } } # x86_64 file has 25MB, no need to keep it. file delete -- $genfile diff --git a/gdb/testsuite/gdb.base/bigcore.exp b/gdb/testsuite/gdb.base/bigcore.exp index 7dd881082354..b1ced340fc11 100644 --- a/gdb/testsuite/gdb.base/bigcore.exp +++ b/gdb/testsuite/gdb.base/bigcore.exp @@ -37,12 +37,12 @@ if { [istarget "*-*-*bsd*"] standard_testfile .c set corefile [standard_output_file ${binfile}.corefile] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # Traverse part of bigcore's linked list of memory chunks (forward or # backward), saving each chunk's address. diff --git a/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp b/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp index 368507b2409c..9fac9b551b32 100644 --- a/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp +++ b/gdb/testsuite/gdb.base/bp-cmds-continue-ctrl-c.exp @@ -119,11 +119,11 @@ proc do_test {} { with_test_prefix "run" { clean_restart $testfile if {![runto_main]} { - return -1 + return } do_test } diff --git a/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp b/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp index 95c2811a3e03..1bdb75f44fd0 100644 --- a/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp +++ b/gdb/testsuite/gdb.base/bp-cmds-run-with-ex.exp @@ -33,11 +33,11 @@ save_vars { GDBFLAGS } { append GDBFLAGS " --args ${binfile}" gdb_exit if {[gdb_spawn] != 0} { fail "spawn gdb" - return -1 + return } } gdb_test_multiple "" "execute bp commands" { -re " = 123\r\n$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.base/branch-to-self.exp b/gdb/testsuite/gdb.base/branch-to-self.exp index ffd15780d724..2cb388219e01 100644 --- a/gdb/testsuite/gdb.base/branch-to-self.exp +++ b/gdb/testsuite/gdb.base/branch-to-self.exp @@ -26,11 +26,11 @@ if { [build_executable ${testfile}.exp ${testfile} $srcfile {debug}] == -1 } { with_test_prefix "single-step" { global testfile clean_restart ${testfile} if {![runto_main]} { - return -1 + return } set line_num [gdb_get_line_number "loop-line" ${testfile}.c] gdb_test "break ${testfile}.c:${line_num}" "Breakpoint .*" \ "set breakpoint" @@ -59,11 +59,11 @@ with_test_prefix "break-cond" { foreach_with_prefix side {"host" "target"} { clean_restart ${testfile} if {![runto_main]} { - return -1 + return } set test "set breakpoint condition-evaluation $side" gdb_test_multiple $test $test { -re "warning: Target does not support breakpoint condition evaluation.\r\nUsing host evaluation mode instead.\r\n$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.base/break-always.exp b/gdb/testsuite/gdb.base/break-always.exp index f2eb1a3ba8b9..8fe3fb3f863d 100644 --- a/gdb/testsuite/gdb.base/break-always.exp +++ b/gdb/testsuite/gdb.base/break-always.exp @@ -76,11 +76,11 @@ foreach test_value {0 1} { -re "Cannot access memory at address $hex.*$gdb_prompt $" { # Some targets do not allow manually writing a breakpoint to a # certain memory address, like QEMU. In that case, just bail out. unsupported "cannot write to address $bp_address" - return -1 + return } -re " = .*$gdb_prompt $" { pass $write_test } } diff --git a/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp b/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp index a9a1db344d21..0873ce5728c4 100644 --- a/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp +++ b/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp @@ -35,11 +35,11 @@ if {![runto_main]} { # skip this test. gdb_test_multiple "maint set internal-error backtrace on" \ "check backtrace is supported" { -re "support for this feature is not compiled into GDB" { untested "feature not supported" - return -1 + return } -re "$gdb_prompt $" { pass $gdb_test_name } } diff --git a/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp b/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp index 9bf5f09c566f..67511741d395 100644 --- a/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp +++ b/gdb/testsuite/gdb.base/bt-on-fatal-signal.exp @@ -40,11 +40,11 @@ if {![runto_main]} { # trying to turn this on will give an error, in which case we just # skip this test. gdb_test_multiple "maint set backtrace-on-fatal-signal on" "" { -re "support for this feature is not compiled into GDB" { untested $testfile - return -1 + return } -re "$gdb_prompt $" { pass $gdb_test_name } } diff --git a/gdb/testsuite/gdb.base/catch-fork-kill.exp b/gdb/testsuite/gdb.base/catch-fork-kill.exp index 498e34a49bec..cd541e66247c 100644 --- a/gdb/testsuite/gdb.base/catch-fork-kill.exp +++ b/gdb/testsuite/gdb.base/catch-fork-kill.exp @@ -42,11 +42,11 @@ foreach kind {"fork" "vfork"} { set compile_options "debug additional_flags=-DFORK=$kind" set testfile [set testfile_$kind] if {[build_executable $testfile.exp $testfile ${srcfile} \ ${compile_options}] == -1} { untested "failed to compile" - return -1 + return } } # The test proper. FORK_KIND is either "fork" or "vfork". EXIT_KIND # is either "exit" (run the parent to exit) or "kill" (kill parent). diff --git a/gdb/testsuite/gdb.base/catch-syscall.exp b/gdb/testsuite/gdb.base/catch-syscall.exp index 673fca4a9984..63abc1aec809 100644 --- a/gdb/testsuite/gdb.base/catch-syscall.exp +++ b/gdb/testsuite/gdb.base/catch-syscall.exp @@ -22,11 +22,11 @@ require supports_catch_syscall standard_testfile if { [prepare_for_testing "failed to prepare" $testfile ${testfile}.c] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/checkpoint.exp b/gdb/testsuite/gdb.base/checkpoint.exp index b6ea9f63f170..828a633d4a46 100644 --- a/gdb/testsuite/gdb.base/checkpoint.exp +++ b/gdb/testsuite/gdb.base/checkpoint.exp @@ -36,11 +36,11 @@ if {[is_remote host]} { set copy1_txt [standard_output_file copy1.txt] } if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug "additional_flags=-DPI_TXT=\"$pi_txt\" -DCOPY1_TXT=\"$copy1_txt\""]]} { - return -1 + return } global gdb_prompt # diff --git a/gdb/testsuite/gdb.base/code_elim.exp b/gdb/testsuite/gdb.base/code_elim.exp index 15e59b9095bb..7c79ff54f196 100644 --- a/gdb/testsuite/gdb.base/code_elim.exp +++ b/gdb/testsuite/gdb.base/code_elim.exp @@ -36,16 +36,16 @@ if {[istarget "riscv*-*-*"]} { remote_exec build "rm -f ${binfile1}" remote_exec build "rm -f ${binfile2}" if { [gdb_compile "${srcdir}/${subdir}/${srcfile1}" "${binfile1}" executable $opts] != "" } { untested "failed to compile" - return -1 + return } if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable $opts] != "" } { untested "failed to compile" - return -1 + return } proc not_null_var_address { var } { # Same as get_var_address, expect that it reports a failure if a null diff --git a/gdb/testsuite/gdb.base/compare-sections.exp b/gdb/testsuite/gdb.base/compare-sections.exp index bf6207061778..ba2687dbcb84 100644 --- a/gdb/testsuite/gdb.base/compare-sections.exp +++ b/gdb/testsuite/gdb.base/compare-sections.exp @@ -115,11 +115,11 @@ with_test_prefix "read-only" { } } if {!$has_ro_sections} { unsupported "no read-only sections" - return -1; + return } set orig -1 set test "get value of read-only section" @@ -130,11 +130,11 @@ with_test_prefix "read-only" { } } if {$orig == -1} { untested "couldn't read address of read-only section" - return -1 + return } # Come up with different value. set patch [expr {255 - $orig}] @@ -151,11 +151,11 @@ with_test_prefix "read-only" { } } if { $written != $patch } { unsupported "can't patch read-only section" - return -1 + return } gdb_test "compare-sections -r" \ "MIS-MATCHED.*warning.*One or more sections.*does not match.*loaded file.*" } diff --git a/gdb/testsuite/gdb.base/cond-eval-mode.exp b/gdb/testsuite/gdb.base/cond-eval-mode.exp index e9463950eb54..c2aefc4a93b6 100644 --- a/gdb/testsuite/gdb.base/cond-eval-mode.exp +++ b/gdb/testsuite/gdb.base/cond-eval-mode.exp @@ -45,11 +45,11 @@ gdb_test_no_output $test_auto set warning "warning: Target does not support breakpoint condition evaluation.\r\nUsing host evaluation mode instead." gdb_test_multiple $test_target $test_target { -re "$warning\r\n$gdb_prompt $" { unsupported $test_target - return -1 + return } -re "^$test_target\r\n$gdb_prompt $" { pass $test_target } diff --git a/gdb/testsuite/gdb.base/condbreak-bad.exp b/gdb/testsuite/gdb.base/condbreak-bad.exp index 216b485b6356..7ee32bdb40bb 100644 --- a/gdb/testsuite/gdb.base/condbreak-bad.exp +++ b/gdb/testsuite/gdb.base/condbreak-bad.exp @@ -65,11 +65,11 @@ with_test_prefix "with run" { # This is needed to check a scenario where the breakpoints are no # longer re-inserted due to solib events. Note that runto_main # deletes the breakpoints. with_test_prefix "with continue 1" { if {![runto_main]} { - return -1 + return } gdb_breakpoint "$bp_location" set bpnum [get_integer_valueof "\$bpnum" 0 "get bpnum"] @@ -85,11 +85,11 @@ with_test_prefix "with continue 1" { } # Repeat with a condition that evaluates to false. with_test_prefix "with continue 2" { if {![runto_main]} { - return -1 + return } gdb_breakpoint "$bp_location" set bpnum [get_integer_valueof "\$bpnum" 0 "get bpnum"] @@ -105,11 +105,11 @@ with_test_prefix "with continue 2" { } # Repeat with a condition that contains junk at the end. with_test_prefix "with junk" { if {![runto_main]} { - return -1 + return } gdb_breakpoint "$bp_location" set bpnum [get_integer_valueof "\$bpnum" 0 "get bpnum"] diff --git a/gdb/testsuite/gdb.base/continue-all-already-running.exp b/gdb/testsuite/gdb.base/continue-all-already-running.exp index 734b5e9681bb..65d9073e74e1 100644 --- a/gdb/testsuite/gdb.base/continue-all-already-running.exp +++ b/gdb/testsuite/gdb.base/continue-all-already-running.exp @@ -19,11 +19,11 @@ standard_testfile save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS -ex \"set non-stop on\"" if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } } if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.base/coredump-filter.exp b/gdb/testsuite/gdb.base/coredump-filter.exp index 6bf26f1643ab..26bf2ebed50e 100644 --- a/gdb/testsuite/gdb.base/coredump-filter.exp +++ b/gdb/testsuite/gdb.base/coredump-filter.exp @@ -192,11 +192,11 @@ gdb_test_multiple "info inferiors" "getting inferior pid" { } -re "Remote target.*$gdb_prompt $" { # If the target does not provide PID information (like usermode QEMU), # just bail out as the rest of the test may rely on it, giving spurious # failures. - return -1 + return } } # Get the main function's address. set main_addr "" diff --git a/gdb/testsuite/gdb.base/corefile-buildid.exp b/gdb/testsuite/gdb.base/corefile-buildid.exp index 45c613b528ff..2f5ea644081f 100644 --- a/gdb/testsuite/gdb.base/corefile-buildid.exp +++ b/gdb/testsuite/gdb.base/corefile-buildid.exp @@ -215,17 +215,17 @@ proc locate_exec_from_core_build_id {corefile buildid \ foreach_with_prefix mode { exec shared } { # Build the executable. set progname ${binfile}-$mode set build_proc build_corefile_buildid_${mode} if { ![$build_proc $progname] } { - return -1 + return } # Generate a corefile. set corefile [create_core_file $progname] if { $corefile eq "" } { - return -1 + return } # Get the build-id filename without ".debug" on the end. This # will have the format: '.build-id/xx/xxxxx' set buildid [build_id_debug_filename_get $progname ""] diff --git a/gdb/testsuite/gdb.base/corefile-exec-context.exp b/gdb/testsuite/gdb.base/corefile-exec-context.exp index 8c342171cecf..9b018533b68e 100644 --- a/gdb/testsuite/gdb.base/corefile-exec-context.exp +++ b/gdb/testsuite/gdb.base/corefile-exec-context.exp @@ -145,11 +145,11 @@ save_vars { ::env($env_var_name) } { setenv $env_var_name $env_var_value set corefile [core_find $binfile {} $args] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } } set corefile_3 "$binfile.2.core" remote_exec build "mv $corefile $corefile_3" diff --git a/gdb/testsuite/gdb.base/corefile-find-exec.exp b/gdb/testsuite/gdb.base/corefile-find-exec.exp index 7d79b70c41b7..7219d32e4cb3 100644 --- a/gdb/testsuite/gdb.base/corefile-find-exec.exp +++ b/gdb/testsuite/gdb.base/corefile-find-exec.exp @@ -63,11 +63,11 @@ with_test_prefix "absolute path" { # executable. with_test_prefix "to file" { set corefile [core_find $binfile] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_1 "$binfile.1.core" remote_exec build "mv $corefile $corefile_1" test_load $corefile_1 $binfile $binfile @@ -84,11 +84,11 @@ with_test_prefix "absolute path" { } set corefile [core_find $symlink] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_2 "$binfile.2.core" remote_exec build "mv $corefile $corefile_2" test_load $corefile_2 $symlink $symlink @@ -106,11 +106,11 @@ with_test_prefix "absolute path" { } set corefile [core_find $symlink] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_3 "$binfile.3.core" remote_exec build "mv $corefile $corefile_3" remote_exec build "rm -f $symlink" @@ -140,11 +140,11 @@ with_test_prefix "absolute path" { remote_exec build "cp $binfile $binfile_2" set corefile [core_find $binfile_2] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_4 "$binfile.4.core" remote_exec build "mv $corefile $corefile_4" set side_dir [standard_output_file side_dir] @@ -214,11 +214,11 @@ with_test_prefix "relative path" { with_cwd $work_dir { with_test_prefix "to file" { set corefile [core_find $rel_path_to_file] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_5 "${work_dir}/${testfile}.5.core" remote_exec build "mv $corefile $corefile_5" test_load $corefile_5 \ @@ -228,11 +228,11 @@ with_test_prefix "relative path" { with_test_prefix "to symlink" { set corefile [core_find $rel_path_to_symlink_2] if {$corefile == ""} { untested "unable to create corefile" - return 0 + return } set corefile_6 "${work_dir}/${testfile}.6.core" remote_exec build "mv $corefile $corefile_6" test_load $corefile_6 \ diff --git a/gdb/testsuite/gdb.base/cvexpr.exp b/gdb/testsuite/gdb.base/cvexpr.exp index a726b1a71bf4..f556d38803b5 100644 --- a/gdb/testsuite/gdb.base/cvexpr.exp +++ b/gdb/testsuite/gdb.base/cvexpr.exp @@ -516,11 +516,11 @@ foreach testspec $specs { } # These tests don't rely on the debug format. with_test_prefix nodebug { if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}] } { - return 0 + return } gdb_test "ptype _Atomic int" "type = _Atomic int" gdb_test "ptype int * restrict" "type = int \\* restrict" diff --git a/gdb/testsuite/gdb.base/detach.exp b/gdb/testsuite/gdb.base/detach.exp index be5afddc1f8f..b8b1ce91dde6 100644 --- a/gdb/testsuite/gdb.base/detach.exp +++ b/gdb/testsuite/gdb.base/detach.exp @@ -17,11 +17,11 @@ # NOTE: This test could be much more thorough. # Only GNU/Linux is known to support this. if { ! [istarget "*-*-linux*"] } { - return 0 + return } standard_testfile attach.c set escapedbinfile [string_to_regexp ${binfile}] diff --git a/gdb/testsuite/gdb.base/disabled-location.exp b/gdb/testsuite/gdb.base/disabled-location.exp index 17e8987ded18..3a5c2f344779 100644 --- a/gdb/testsuite/gdb.base/disabled-location.exp +++ b/gdb/testsuite/gdb.base/disabled-location.exp @@ -18,11 +18,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile}] } { return } if {![runto_main]} { - return 0 + return } gdb_test "break function" \ "Breakpoint.*at.* file .*$srcfile, line.*" \ "setting breakpoint on function" diff --git a/gdb/testsuite/gdb.base/dmsym.exp b/gdb/testsuite/gdb.base/dmsym.exp index 3820b13bfdc7..6b02b97014de 100644 --- a/gdb/testsuite/gdb.base/dmsym.exp +++ b/gdb/testsuite/gdb.base/dmsym.exp @@ -24,12 +24,12 @@ set testfile dmsym_main set dmsym_o [standard_output_file dmsym.o] if {[gdb_compile "${srcdir}/${subdir}/dmsym.c" \ $dmsym_o \ object {}] != ""} { - untested "failed to compile object file" - return -1 + untested "failed to compile object file" + return } if {[gdb_compile \ [list ${srcdir}/${subdir}/dmsym_main.c $dmsym_o] \ [standard_output_file ${testfile}] \ diff --git a/gdb/testsuite/gdb.base/dso2dso.exp b/gdb/testsuite/gdb.base/dso2dso.exp index 1e7e633d1827..6f8962b0309a 100644 --- a/gdb/testsuite/gdb.base/dso2dso.exp +++ b/gdb/testsuite/gdb.base/dso2dso.exp @@ -47,18 +47,18 @@ if { [build_executable "build shlib 2" $binfile_libdso2 \ return } if { [prepare_for_testing "prepare" $testfile $srcfile \ [list debug shlib=$binfile_libdso2 shlib=$binfile_libdso1]] != 0 } { - return + return } gdb_load_shlib $binfile_libdso2 gdb_load_shlib $binfile_libdso1 if { ![runto_main] } { - return -1 + return } set bp_location [gdb_get_line_number "STOP HERE" [file tail $srcfile_libdso1]] gdb_breakpoint ${libdso1}.c:${bp_location} diff --git a/gdb/testsuite/gdb.base/endianity.exp b/gdb/testsuite/gdb.base/endianity.exp index 0da319a824cd..e82f31f29854 100644 --- a/gdb/testsuite/gdb.base/endianity.exp +++ b/gdb/testsuite/gdb.base/endianity.exp @@ -19,16 +19,16 @@ set test_sso [expr \ {[supports_scalar_storage_order_attribute] \ && [supports_gnuc]}] if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug additional_flags=-DTEST_SSO=$test_sso]] } { - return -1 + return } set bp_location [gdb_get_line_number "START"] if {![runto "endianity.c:$bp_location"]} { - return -1 + return } gdb_test "print o" "= {v = 3, w = 2, x = 7, f = 23.5, cplx = 1.25 \\+ 7.25i, d = 75}" \ "print o before assignment" diff --git a/gdb/testsuite/gdb.base/foll-exec-mode.exp b/gdb/testsuite/gdb.base/foll-exec-mode.exp index c3f5390ca5c2..6fa076ada2a7 100644 --- a/gdb/testsuite/gdb.base/foll-exec-mode.exp +++ b/gdb/testsuite/gdb.base/foll-exec-mode.exp @@ -45,17 +45,17 @@ set binfile2 [standard_output_file ${testfile2}] set compile_options debug # build the first test case if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable $compile_options] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $compile_options] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # Test exec catchpoints to ensure exec events are supported. # proc do_catch_exec_test { } { diff --git a/gdb/testsuite/gdb.base/fullname.exp b/gdb/testsuite/gdb.base/fullname.exp index 7f46cb56d858..30969248d56c 100644 --- a/gdb/testsuite/gdb.base/fullname.exp +++ b/gdb/testsuite/gdb.base/fullname.exp @@ -93,11 +93,11 @@ if { [gdb_breakpoint [standard_output_file tmp-${srcfile}]:${line} {no-message}] # we'll run GDB from. with_cwd [standard_output_file {}] { if { [gdb_compile [standard_output_file tmp-${srcfile}] "${testfile}" \ executable {debug}] != "" } { - return -1 + return } } clean_restart $testfile diff --git a/gdb/testsuite/gdb.base/fullpath-expand.exp b/gdb/testsuite/gdb.base/fullpath-expand.exp index 053eb9b59f0a..e7f96c1e7a5b 100644 --- a/gdb/testsuite/gdb.base/fullpath-expand.exp +++ b/gdb/testsuite/gdb.base/fullpath-expand.exp @@ -27,11 +27,11 @@ if { [file pathtype $objdir] != "absolute" } { with_cwd $srcdir { set err [gdb_compile "${subdir}/${srcfile} ${subdir}/${srcfile2}" $binfile executable {debug}] if { $err != "" } { untested "${srcfile} or ${srcfile2} compilation failed" - return -1 + return } } set result [catch {exec realpath ${srcdir}/${subdir}/${srcfile2}} realsrcfile2] if { $result != 0 || $realsrcfile2 == "" } { diff --git a/gdb/testsuite/gdb.base/gcore-relro.exp b/gdb/testsuite/gdb.base/gcore-relro.exp index 59bd37f93acc..70b6daff2936 100644 --- a/gdb/testsuite/gdb.base/gcore-relro.exp +++ b/gdb/testsuite/gdb.base/gcore-relro.exp @@ -22,29 +22,29 @@ set binfile_lib [standard_output_file ${libfile}.so] set gcorefile ${binfile}.gcore set objfile [standard_output_file ${testfile}.o] if { [gdb_compile_shlib ${srcdir}/${subdir}/${srcfile_lib} ${binfile_lib} {debug}] != "" || [gdb_compile ${srcdir}/${subdir}/${srcfile} ${objfile} object {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } set opts [list debug shlib=${binfile_lib} ldflags=-Wl,-z,relro] if { [gdb_compile ${objfile} ${binfile} executable $opts] != "" } { - unsupported "-Wl,-z,relro compilation failed" - return -1 + unsupported "-Wl,-z,relro compilation failed" + return } with_test_prefix "first session" { clean_restart $testfile gdb_load_shlib ${binfile_lib} if {![runto lib]} { - return -1 + return } if {![gdb_gcore_cmd $gcorefile "save a corefile"]} { - return -1 + return } } # Now restart gdb and load the corefile. diff --git a/gdb/testsuite/gdb.base/gcore.exp b/gdb/testsuite/gdb.base/gcore.exp index aa887b0da14d..243e0b39082b 100644 --- a/gdb/testsuite/gdb.base/gcore.exp +++ b/gdb/testsuite/gdb.base/gcore.exp @@ -52,11 +52,11 @@ set pre_corefile_extern_array \ [capture_command_output "print extern_array" "$print_prefix"] set corefile [standard_output_file gcore.test] set core_supported [gdb_gcore_cmd "$corefile" "save a corefile"] if {!$core_supported} { - return -1 + return } # Now restart gdb and load the corefile. clean_restart $testfile diff --git a/gdb/testsuite/gdb.base/gcorebg.exp b/gdb/testsuite/gdb.base/gcorebg.exp index 8724794b607a..67436dedb43a 100644 --- a/gdb/testsuite/gdb.base/gcorebg.exp +++ b/gdb/testsuite/gdb.base/gcorebg.exp @@ -24,11 +24,11 @@ require has_gcore_script require can_spawn_for_attach set corefile [standard_output_file ${testfile}.core] if {[build_executable "failed to build" $testfile ${srcfile}] == -1 } { - return -1 + return } # Cleanup. proc core_clean {} { diff --git a/gdb/testsuite/gdb.base/global-var-nested-by-dso.exp b/gdb/testsuite/gdb.base/global-var-nested-by-dso.exp index 5fca2345f6af..164f60b25793 100644 --- a/gdb/testsuite/gdb.base/global-var-nested-by-dso.exp +++ b/gdb/testsuite/gdb.base/global-var-nested-by-dso.exp @@ -43,11 +43,11 @@ if { [prepare_for_testing "prepare" $testfile $srcfile \ gdb_load_shlib $binfile_lib1 gdb_load_shlib $binfile_lib2 if { ![runto_main] } { - return -1 + return } gdb_test "next" "$decimal.*b_main \\(\\);" "step over c_main" gdb_test "next" "$decimal.*return 0;" "step over b_main" gdb_test "print test" " = 42" diff --git a/gdb/testsuite/gdb.base/gnu-ifunc.exp b/gdb/testsuite/gdb.base/gnu-ifunc.exp index 2c1dffeeece1..d6a50a9b6862 100644 --- a/gdb/testsuite/gdb.base/gnu-ifunc.exp +++ b/gdb/testsuite/gdb.base/gnu-ifunc.exp @@ -391,11 +391,11 @@ with_test_prefix "static" { if { [gdb_compile ${srcdir}/${subdir}/$libsrc $lib_o object {}] != "" || [gdb_compile ${srcdir}/${subdir}/$final_src $final_o object {}] != "" || [gdb_compile "${srcdir}/${subdir}/$srcfile $lib_o $final_o" \ $staticbinfile executable {debug}] != "" } { untested "failed to compile second testcase" - return -1 + return } clean_restart $staticexecutable gdb_breakpoint "gnu_ifunc" diff --git a/gdb/testsuite/gdb.base/gnu_vector.exp b/gdb/testsuite/gdb.base/gnu_vector.exp index b92d82c3428c..36724d1e9786 100644 --- a/gdb/testsuite/gdb.base/gnu_vector.exp +++ b/gdb/testsuite/gdb.base/gnu_vector.exp @@ -34,12 +34,12 @@ proc do_compile { {opts {}} } { if { [do_compile {-mcpu=native}] != "" && [do_compile {-mcpu=native -Wno-psabi}] != "" && [do_compile {-march=native}] != "" && [do_compile] != ""} { - untested "compiler can't handle vector_size attribute?" - return -1 + untested "compiler can't handle vector_size attribute?" + return } clean_restart $testfile if { ![runto_main] } { diff --git a/gdb/testsuite/gdb.base/huge.exp b/gdb/testsuite/gdb.base/huge.exp index 4ddfceebd9e5..98c081b557ab 100644 --- a/gdb/testsuite/gdb.base/huge.exp +++ b/gdb/testsuite/gdb.base/huge.exp @@ -44,11 +44,11 @@ require {expr {$compilation_succeeded}} # Start with a fresh gdb. clean_restart $testfile with_timeout_factor 3 { if {![runto_main]} { - return -1 + return } gdb_test_no_output "set max-value-size unlimited" gdb_test_no_output "maint set per-command space on" diff --git a/gdb/testsuite/gdb.base/info-fun.exp b/gdb/testsuite/gdb.base/info-fun.exp index c2f9ae03152a..1465220d3db4 100644 --- a/gdb/testsuite/gdb.base/info-fun.exp +++ b/gdb/testsuite/gdb.base/info-fun.exp @@ -36,11 +36,11 @@ foreach_with_prefix n_flag { 0 1 } { } if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib} $sep_lib_flags] != "" || [gdb_compile $srcdir/$subdir/${srcfile} ${binfile} \ executable $bin_flags] != "" } { untested "failed to compile" - return -1 + return } if {$libsepdebug == "SEP"} { if {[gdb_gnu_strip_debug $binfile_lib] != 0} { unsupported "could not split debug of $binfile_lib." @@ -51,11 +51,11 @@ foreach_with_prefix n_flag { 0 1 } { } clean_restart $executable if {![runto_main]} { - return 0 + return } set match_str {All functions matching regular expression "foo":[\r\n]*} if { "$libsepdebug" != "NO" } { append match_str {File .*/info-fun-solib[.]c:[\r\n]*} diff --git a/gdb/testsuite/gdb.base/info-proc.exp b/gdb/testsuite/gdb.base/info-proc.exp index f1b435e249f3..89eed2ac815a 100644 --- a/gdb/testsuite/gdb.base/info-proc.exp +++ b/gdb/testsuite/gdb.base/info-proc.exp @@ -25,11 +25,11 @@ standard_testfile break.c break1.c save_vars { env(GDB_INFO_PROC_ENVIRON_1) } { set env(GDB_INFO_PROC_ENVIRON_1) "ONE" if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug nowarnings}]} { - return -1 + return } } gdb_test "help info proc" "Show additional information about a process.*" @@ -38,11 +38,11 @@ gdb_test_multiple "info proc" "info proc without a process" { pass "info proc without a process" } -re "Not supported on this target.*$gdb_prompt $" { # info proc command not supported -- nothing to test here. unsupported "gdb does not support info proc on this target" - return -1 + return } } # Set command line arguments to be verified later with "info proc # cmdline". However, if we're using a stub, then "set args" would not diff --git a/gdb/testsuite/gdb.base/info-shared.exp b/gdb/testsuite/gdb.base/info-shared.exp index 993e64f64a27..5e740f2a3ee5 100644 --- a/gdb/testsuite/gdb.base/info-shared.exp +++ b/gdb/testsuite/gdb.base/info-shared.exp @@ -158,11 +158,11 @@ with_test_prefix styled { clean_restart $testfile gdb_test_no_output "set style enabled off" if {![runto_main]} { - return 0 + return } gdb_breakpoint "stop" gdb_continue_to_breakpoint "library load #1" "\\.?stop .*" # Simple test for "info sharedlibrary" styling. Look for styled diff --git a/gdb/testsuite/gdb.base/interp.exp b/gdb/testsuite/gdb.base/interp.exp index d19d0e3ceca6..516c1507657e 100644 --- a/gdb/testsuite/gdb.base/interp.exp +++ b/gdb/testsuite/gdb.base/interp.exp @@ -80,10 +80,10 @@ gdb_test_multiple "define hello" "$test" { gdb_test "$commands\nend" "" "finish defining hello command" gdb_test "hello" [string_to_regexp "^done,value=\"23\""] if {![runto_main]} { - return -1 + return } gdb_test "list" ".*\[0-9\].*main \\(int argc.*" "can list sources" gdb_exit diff --git a/gdb/testsuite/gdb.base/jit-reader-simple.exp b/gdb/testsuite/gdb.base/jit-reader-simple.exp index 445e2b053fd2..a50a92b6c504 100644 --- a/gdb/testsuite/gdb.base/jit-reader-simple.exp +++ b/gdb/testsuite/gdb.base/jit-reader-simple.exp @@ -179,11 +179,11 @@ foreach standalone {1 0} { with_test_prefix "two JITers" { clean_restart gdb_load $binfile_dl2 if {![runto_main]} { - return -1 + return } set num_bps 0 set ws "\[ \t\]+" gdb_test_multiple "maint info breakpoints" "have two jit breakpoints" { diff --git a/gdb/testsuite/gdb.base/jump.exp b/gdb/testsuite/gdb.base/jump.exp index 3139b081aa25..63b145dbf5e4 100644 --- a/gdb/testsuite/gdb.base/jump.exp +++ b/gdb/testsuite/gdb.base/jump.exp @@ -108,11 +108,11 @@ for {set inf 2} {$inf <= $num_inferiors} {incr inf} { "add inferior ${inf} with -exec " gdb_test "inferior ${inf}" \ "Switching to inferior ${inf} .*" \ "switch to inferior ${inf}" if {![runto_main]} { - return -1 + return } } # Run tests on all inferiors. for {set inf 1} {$inf <= $num_inferiors} {incr inf} { diff --git a/gdb/testsuite/gdb.base/label.exp b/gdb/testsuite/gdb.base/label.exp index 418841961c8d..647f1551d511 100644 --- a/gdb/testsuite/gdb.base/label.exp +++ b/gdb/testsuite/gdb.base/label.exp @@ -23,11 +23,11 @@ if { [prepare_for_testing "failed to prepare" $testfile ${srcfile} debug] } { return } if {![runto_main]} { - return -1 + return } gdb_test "break -q here" \ "Breakpoint.*at.*" \ "breakpoint here" diff --git a/gdb/testsuite/gdb.base/longjmp.exp b/gdb/testsuite/gdb.base/longjmp.exp index 92b9544021fa..c895799938a3 100644 --- a/gdb/testsuite/gdb.base/longjmp.exp +++ b/gdb/testsuite/gdb.base/longjmp.exp @@ -19,12 +19,12 @@ standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug nowarnings}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc do_test { with_probes } { clean_restart $::testfile diff --git a/gdb/testsuite/gdb.base/moribund-step.exp b/gdb/testsuite/gdb.base/moribund-step.exp index 79acb0a543cc..134a9032192a 100644 --- a/gdb/testsuite/gdb.base/moribund-step.exp +++ b/gdb/testsuite/gdb.base/moribund-step.exp @@ -18,11 +18,11 @@ standard_testfile start.c require support_displaced_stepping save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS -ex \"set non-stop on\"" if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile] } { - return -1 + return } } if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.base/nostdlib.exp b/gdb/testsuite/gdb.base/nostdlib.exp index 91a3de3fa235..920f145d6288 100644 --- a/gdb/testsuite/gdb.base/nostdlib.exp +++ b/gdb/testsuite/gdb.base/nostdlib.exp @@ -47,11 +47,11 @@ foreach_with_prefix pie { "nopie" "pie" } { set err [eval $compile] unset_board_info mathlib } if {$err != ""} { untested "failed to compile" - return -1 + return } clean_restart $filename gdb_breakpoint "*marker" diff --git a/gdb/testsuite/gdb.base/overlays.exp b/gdb/testsuite/gdb.base/overlays.exp index 1cb452b77142..0d11726d4df5 100644 --- a/gdb/testsuite/gdb.base/overlays.exp +++ b/gdb/testsuite/gdb.base/overlays.exp @@ -27,12 +27,12 @@ require {istarget "m32r-*-*"} {!istarget "*-*-linux*"} standard_testfile overlays.c ovlymgr.c foo.c bar.c baz.c grbx.c if {[build_executable $testfile.exp $testfile \ [list $srcfile $srcfile2 $srcfile3 $srcfile4 $srcfile5 $srcfile6] \ "debug ldscript=-Wl,-T$linker_script"] == -1} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } remote_exec build "mv ${testfile}.o foo.o bar.o baz.o grbx.o ovlymgr.o ${objdir}/${subdir}" diff --git a/gdb/testsuite/gdb.base/printcmds.exp b/gdb/testsuite/gdb.base/printcmds.exp index 0be8f170d19f..12933d898ed6 100644 --- a/gdb/testsuite/gdb.base/printcmds.exp +++ b/gdb/testsuite/gdb.base/printcmds.exp @@ -21,12 +21,12 @@ # This file was written by Fred Fish. (fnf@cygnus.com) standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc test_integer_literals_accepted {} { global gdb_prompt diff --git a/gdb/testsuite/gdb.base/random-signal.exp b/gdb/testsuite/gdb.base/random-signal.exp index e0c5e669c2f2..9482b0aee8ed 100644 --- a/gdb/testsuite/gdb.base/random-signal.exp +++ b/gdb/testsuite/gdb.base/random-signal.exp @@ -50,11 +50,11 @@ proc do_test {} { # single-step. With remote debugging, the ctrl-c reaches GDB first. with_test_prefix "run" { clean_restart $testfile if {![runto_main]} { - return -1 + return } do_test } diff --git a/gdb/testsuite/gdb.base/randomize.exp b/gdb/testsuite/gdb.base/randomize.exp index 58c2c78ee26a..ef358bef88e2 100644 --- a/gdb/testsuite/gdb.base/randomize.exp +++ b/gdb/testsuite/gdb.base/randomize.exp @@ -41,15 +41,15 @@ proc address_get { testname } { set test "set disable-randomization off" gdb_test_multiple "${test}" "${test}" { -re "Disabling randomization .* unsupported .*$gdb_prompt $" { untested "disabling randomization is not supported on this Linux GDB" - return -1 + return } -re "No symbol .* in current context.*$gdb_prompt $" { untested "disabling randomization is not supported on this GDB platform" - return -1 + return } -re "$gdb_prompt $" { pass $test } } diff --git a/gdb/testsuite/gdb.base/readline-ask.exp b/gdb/testsuite/gdb.base/readline-ask.exp index bee3fbba4e78..3857d90436f1 100644 --- a/gdb/testsuite/gdb.base/readline-ask.exp +++ b/gdb/testsuite/gdb.base/readline-ask.exp @@ -96,11 +96,11 @@ gdb_test_multiple "" $test { -re "^\r\nDisplay all 5 possibilities\\? \\(y or n\\)$" { pass $test } -re "$gdb_prompt " { fail $test - return 0 + return } } send_gdb "y" set test "ask message for 01 and 02" diff --git a/gdb/testsuite/gdb.base/readline.exp b/gdb/testsuite/gdb.base/readline.exp index f8f9adecf8f7..c9e5830a3220 100644 --- a/gdb/testsuite/gdb.base/readline.exp +++ b/gdb/testsuite/gdb.base/readline.exp @@ -152,11 +152,11 @@ save_vars { env(TERM) } { gdb_start gdb_reinitialize_dir $srcdir/$subdir if { ![readline_is_used] } { unsupported "readline isn't used." - return -1 + return } save_vars { timeout env(GDBHISTSIZE) env(GDBHISTFILE) } { set timeout 30 diff --git a/gdb/testsuite/gdb.base/readnever.exp b/gdb/testsuite/gdb.base/readnever.exp index 9f74b8b005d5..bba1186a3441 100644 --- a/gdb/testsuite/gdb.base/readnever.exp +++ b/gdb/testsuite/gdb.base/readnever.exp @@ -25,11 +25,11 @@ if { [build_executable "failed to build" $testfile $srcfile { debug }] == -1 } { } save_vars { GDBFLAGS } { append GDBFLAGS " --readnever" if { [clean_restart $testfile] == -1 } { - return -1 + return } } if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.base/relocate.exp b/gdb/testsuite/gdb.base/relocate.exp index 8c1ffc52e509..5b5d7cffd726 100644 --- a/gdb/testsuite/gdb.base/relocate.exp +++ b/gdb/testsuite/gdb.base/relocate.exp @@ -19,12 +19,12 @@ standard_testfile .c append binfile .o remote_exec build "rm -f ${binfile}" if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } clean_restart #Check that invalid options are rejected. diff --git a/gdb/testsuite/gdb.base/reread.exp b/gdb/testsuite/gdb.base/reread.exp index d5373ce3348b..15d1186a40a1 100644 --- a/gdb/testsuite/gdb.base/reread.exp +++ b/gdb/testsuite/gdb.base/reread.exp @@ -25,11 +25,11 @@ foreach_with_prefix opts { "" "pie" } { set testfile1_opt [list debug nowarnings $opts] if { [gdb_compile "${srcdir}/${subdir}/${srcfile1}" "${binfile1}" \ executable ${testfile1_opt}] != "" } { untested "failed to compile first testcase" - return -1 + return } # build the second test case set testfile2 "reread2" @@ -42,11 +42,11 @@ foreach_with_prefix opts { "" "pie" } { if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" \ executable ${testfile2_opt1}] != "" && [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" \ executable ${testfile2_opt2}] != ""} { untested "failed to compile second testcase" - return -1 + return } # Start with a fresh gdb. set testfile "reread" diff --git a/gdb/testsuite/gdb.base/return2.exp b/gdb/testsuite/gdb.base/return2.exp index e0aa63b8d5b0..7168aef49fce 100644 --- a/gdb/testsuite/gdb.base/return2.exp +++ b/gdb/testsuite/gdb.base/return2.exp @@ -17,12 +17,12 @@ standard_testfile .c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } set allow_float_test [allow_float_test] proc return_1 { type } { diff --git a/gdb/testsuite/gdb.base/setshow.exp b/gdb/testsuite/gdb.base/setshow.exp index feac4e993ac1..b8923492e4b8 100644 --- a/gdb/testsuite/gdb.base/setshow.exp +++ b/gdb/testsuite/gdb.base/setshow.exp @@ -21,12 +21,12 @@ standard_testfile .c if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc_with_prefix test_setshow_annotate {} { # Start with a fresh gdb clean_restart $::testfile diff --git a/gdb/testsuite/gdb.base/solib-abort.exp b/gdb/testsuite/gdb.base/solib-abort.exp index cdf7af6b26f0..f731eecbef77 100644 --- a/gdb/testsuite/gdb.base/solib-abort.exp +++ b/gdb/testsuite/gdb.base/solib-abort.exp @@ -40,11 +40,11 @@ if { [build_executable "build solib" $binfile_lib $srcfile_lib \ if { [prepare_for_testing "prepare" $testfile $srcfile $bin_flags] != 0 } { return } if {![runto_main]} { - return 0 + return } # Run until the program dies. gdb_test "cont" "Program received signal SIGABRT,.*" diff --git a/gdb/testsuite/gdb.base/solib-bad-entry-addr.exp b/gdb/testsuite/gdb.base/solib-bad-entry-addr.exp index 39694bffe637..eff7ffe16cbf 100644 --- a/gdb/testsuite/gdb.base/solib-bad-entry-addr.exp +++ b/gdb/testsuite/gdb.base/solib-bad-entry-addr.exp @@ -93,7 +93,7 @@ if { $load_segment_count <= 2 } { # Start GDB and run to main. If the shared library is causing issues # then we will see an internal error once the inferior starts running. clean_restart $testfile if {![runto_main message]} { - return 0 + return } diff --git a/gdb/testsuite/gdb.base/solib-display.exp b/gdb/testsuite/gdb.base/solib-display.exp index cda9605b0db0..83afcaba1494 100644 --- a/gdb/testsuite/gdb.base/solib-display.exp +++ b/gdb/testsuite/gdb.base/solib-display.exp @@ -65,11 +65,11 @@ foreach libsepdebug {NO IN SEP} { with_test_prefix "$libsepdebug" { lappend sep_lib_flags {debug} } if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib} $sep_lib_flags] != "" || [gdb_compile ${srcfile} ${binfile} executable $bin_flags] != "" } { untested "failed to compile" - return -1 + return } if {$libsepdebug == "SEP"} { if {[gdb_gnu_strip_debug $binfile_lib] != 0} { unsupported "could not split debug of $binfile_lib." @@ -80,11 +80,11 @@ foreach libsepdebug {NO IN SEP} { with_test_prefix "$libsepdebug" { } clean_restart $executable if {![runto_main]} { - return 0 + return } gdb_test "display (int) a_global" "1: \\(int\\) a_global = 41" gdb_test "display (int) b_global" "2: \\(int\\) b_global = 42" gdb_test "display (int) c_global" "3: \\(int\\) c_global = 43" diff --git a/gdb/testsuite/gdb.base/solib-overlap.exp b/gdb/testsuite/gdb.base/solib-overlap.exp index feb080708b70..3fc92d37e90b 100644 --- a/gdb/testsuite/gdb.base/solib-overlap.exp +++ b/gdb/testsuite/gdb.base/solib-overlap.exp @@ -59,19 +59,19 @@ foreach prelink_lib1 {0x40000000 0x50000000} { with_test_prefix "$prelink_lib1" if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib1} $lib_flags] != "" || [gdb_compile_shlib ${srcfile_lib} ${binfile_lib2} $lib_flags] != "" || [gdb_compile ${srcfile} ${binfile} executable $bin_flags] != "" } { untested "failed to compile" - return -1 + return } if {[catch {exec prelink -N -r ${prelink_lib1} ${binfile_lib1}} output] != 0 || [catch {exec prelink -N -r ${prelink_lib2} ${binfile_lib2}} output] != 0} { # Maybe we don't have prelink. verbose -log "prelink failed: $output" untested "could not prelink ${binfile_lib1_test_msg} or ${binfile_lib2_test_msg}." - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] @@ -83,11 +83,11 @@ foreach prelink_lib1 {0x40000000 0x50000000} { with_test_prefix "$prelink_lib1" if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib1} $lib_flags] != "" || [gdb_compile_shlib ${srcfile_lib} ${binfile_lib2} $lib_flags] != ""} { untested "failed to compile shared library" kill_wait_spawned_process $test_spawn_id - return -1 + return } clean_restart ${binfile_base} # This testcase currently does not support remote targets. # gdb_load_shlib ${binfile_lib1} diff --git a/gdb/testsuite/gdb.base/solib-search.exp b/gdb/testsuite/gdb.base/solib-search.exp index 43f54b41df0e..3ae9bc442b2a 100644 --- a/gdb/testsuite/gdb.base/solib-search.exp +++ b/gdb/testsuite/gdb.base/solib-search.exp @@ -88,11 +88,11 @@ gdb_continue "break_here" set corefile [standard_output_file solib-search.core] set core_supported [gdb_gcore_cmd "$corefile" "save a corefile"] if {!$core_supported} { - return -1 + return } # Before we restart gdb, replace the libs with the "wrong" ones. remote_exec build "ln -sf ${wrong_lib_subdir}/${libname1}.so ${binfile1_lib}" remote_exec build "ln -sf ${wrong_lib_subdir}/${libname2}.so ${binfile2_lib}" diff --git a/gdb/testsuite/gdb.base/solib-symbol.exp b/gdb/testsuite/gdb.base/solib-symbol.exp index efddd52eef9d..7a7941b9f4f4 100644 --- a/gdb/testsuite/gdb.base/solib-symbol.exp +++ b/gdb/testsuite/gdb.base/solib-symbol.exp @@ -45,11 +45,11 @@ gdb_test "br foo2" \ "foo2 in main" delete_breakpoints if {![runto_main]} { - return 0 + return } # Break in the library. gdb_test "br foo" \ "Breakpoint.*file.*${libname}\\.c.*" \ diff --git a/gdb/testsuite/gdb.base/stale-infcall.exp b/gdb/testsuite/gdb.base/stale-infcall.exp index cb7c09972032..ea3db89d2e92 100644 --- a/gdb/testsuite/gdb.base/stale-infcall.exp +++ b/gdb/testsuite/gdb.base/stale-infcall.exp @@ -34,11 +34,11 @@ gdb_test_multiple "next" $test { pass $test } -re "( test-fail .*|\r\nCannot insert breakpoint 0\\.\r\n.*)\r\n$gdb_prompt $" { xfail $test untested "system lacks support for tracking longjmps" - return -1 + return } } gdb_test_no_output {delete $test_fail_bpnum} gdb_breakpoint [gdb_get_line_number "break-run1"] diff --git a/gdb/testsuite/gdb.base/step-break.exp b/gdb/testsuite/gdb.base/step-break.exp index a580d7f201b3..e5fe59933bd1 100644 --- a/gdb/testsuite/gdb.base/step-break.exp +++ b/gdb/testsuite/gdb.base/step-break.exp @@ -16,15 +16,15 @@ # along with this program. If not, see . standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return 0 + return } set bp_location [gdb_get_line_number "set breakpoint here"] gdb_test "break $bp_location" \ diff --git a/gdb/testsuite/gdb.base/step-line.exp b/gdb/testsuite/gdb.base/step-line.exp index e0a758357384..b85ea7800c48 100644 --- a/gdb/testsuite/gdb.base/step-line.exp +++ b/gdb/testsuite/gdb.base/step-line.exp @@ -26,11 +26,11 @@ set linefile ${testfile}.inp if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set remote_linefile [gdb_remote_download host ${srcdir}/${subdir}/${linefile}] gdb_test "break f1" ".*Breakpoint 2 at .* file .*step-line.c.*" diff --git a/gdb/testsuite/gdb.base/step-test.exp b/gdb/testsuite/gdb.base/step-test.exp index b10a732f93bc..ccd636ab71d0 100644 --- a/gdb/testsuite/gdb.base/step-test.exp +++ b/gdb/testsuite/gdb.base/step-test.exp @@ -23,11 +23,11 @@ remote_exec build "rm -f ${binfile}" if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } { return } if {![runto_main]} { - return 0 + return } # Set a breakpoint at line 45, if stepi then finish fails, we would # run to the end of the program, which would mess up the rest of the tests. @@ -140,14 +140,14 @@ gdb_test_multiple "finish" "$test" { pass "$test" } -re ".*(Program received|$inferior_exited_re).*$gdb_prompt $" { # Oops... We ran to the end of the program... Better reset if {![runto_main]} { - return 0 + return } if {![runto step-test.c:45]} { - return 0 + return } fail "$test" } -re ".*${decimal}.*callee.*STEPI.*$gdb_prompt $" { # On PA64, we end up at a different instruction than PA32. diff --git a/gdb/testsuite/gdb.base/style-logging.exp b/gdb/testsuite/gdb.base/style-logging.exp index 8895e88d4b59..7f56b2d49f2a 100644 --- a/gdb/testsuite/gdb.base/style-logging.exp +++ b/gdb/testsuite/gdb.base/style-logging.exp @@ -22,11 +22,11 @@ require {!is_remote host} standard_testfile style.c with_ansi_styling_terminal { if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.base/testenv.exp b/gdb/testsuite/gdb.base/testenv.exp index 83de52c510b0..62887ebe7170 100644 --- a/gdb/testsuite/gdb.base/testenv.exp +++ b/gdb/testsuite/gdb.base/testenv.exp @@ -26,11 +26,11 @@ standard_testfile .c # Compile binary # and start with a fresh gdb if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Test that the inferior sees EXPECTED env vars starting with # "TEST_GDB". proc test_num_test_vars {expected message} { diff --git a/gdb/testsuite/gdb.base/traced-thread.exp b/gdb/testsuite/gdb.base/traced-thread.exp index b6d354907225..219e3f900ac5 100644 --- a/gdb/testsuite/gdb.base/traced-thread.exp +++ b/gdb/testsuite/gdb.base/traced-thread.exp @@ -24,11 +24,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug pthreads}]} { return } if {![runto "parent_stop"]} { - return -1 + return } # We don't want to be bothered. gdb_test_no_output "set confirm off" diff --git a/gdb/testsuite/gdb.base/valgrind-bt.exp b/gdb/testsuite/gdb.base/valgrind-bt.exp index 36614427cf9b..2fd29e72508d 100644 --- a/gdb/testsuite/gdb.base/valgrind-bt.exp +++ b/gdb/testsuite/gdb.base/valgrind-bt.exp @@ -40,17 +40,17 @@ gdb_test_multiple "continue" $test { } -re "Remote connection closed.*\r\n$gdb_prompt $" { fail "$test (remote connection closed)" # Only if valgrind got stuck. kill_wait_spawned_process $valgrind_spawn_id - return -1 + return } -re "The program is not being run\\.\r\n$gdb_prompt $" { fail "$test (valgrind vgdb has terminated)" # Only if valgrind got stuck. kill_wait_spawned_process $valgrind_spawn_id - return -1 + return } -re "\r\n$gdb_prompt $" { pass "$test (false warning)" } } diff --git a/gdb/testsuite/gdb.base/valgrind-infcall.exp b/gdb/testsuite/gdb.base/valgrind-infcall.exp index c39d31819837..ca13f42f076b 100644 --- a/gdb/testsuite/gdb.base/valgrind-infcall.exp +++ b/gdb/testsuite/gdb.base/valgrind-infcall.exp @@ -40,17 +40,17 @@ while {$loop && $continue_count < 100} { } -re "Remote connection closed.*\r\n$gdb_prompt $" { fail "$test (remote connection closed)" # Only if valgrind got stuck. kill_wait_spawned_process $valgrind_spawn_id - return -1 + return } -re "The program is not being run\\.\r\n$gdb_prompt $" { fail "$test (valgrind vgdb has terminated)" # Only if valgrind got stuck. kill_wait_spawned_process $valgrind_spawn_id - return -1 + return } -re "\r\n$gdb_prompt $" { pass "$test (false warning)" } } diff --git a/gdb/testsuite/gdb.base/vdso-warning.exp b/gdb/testsuite/gdb.base/vdso-warning.exp index 4f61554dc68a..358a1dd42d8d 100644 --- a/gdb/testsuite/gdb.base/vdso-warning.exp +++ b/gdb/testsuite/gdb.base/vdso-warning.exp @@ -71,11 +71,11 @@ with_test_prefix "run" { # Now, dump a core, and reload it. with_test_prefix "core" { set corefile [standard_output_file $testfile.core] set core_supported [gdb_gcore_cmd "$corefile" "save a corefile"] if {!$core_supported} { - return -1 + return } clean_restart ${testfile} test_no_vdso "core-file $corefile" diff --git a/gdb/testsuite/gdb.base/watchpoint.exp b/gdb/testsuite/gdb.base/watchpoint.exp index 29b9c3fd07dd..46eec592402d 100644 --- a/gdb/testsuite/gdb.base/watchpoint.exp +++ b/gdb/testsuite/gdb.base/watchpoint.exp @@ -24,12 +24,12 @@ set allow_hw_watchpoint_tests_p [allow_hw_watchpoint_tests] standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # True if we're forcing no hardware watchpoints. set no_hw 0 diff --git a/gdb/testsuite/gdb.base/wchar.exp b/gdb/testsuite/gdb.base/wchar.exp index d3cfd09d5de4..d4c1a5fd87c6 100644 --- a/gdb/testsuite/gdb.base/wchar.exp +++ b/gdb/testsuite/gdb.base/wchar.exp @@ -19,11 +19,11 @@ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } set bp_location [gdb_get_line_number "START"] if {![runto "wchar.c:$bp_location"]} { - return -1 + return } gdb_test "print narrow" "= 97 L'a'" gdb_test "print single" "= 48879 L'\\\\xbeef'" diff --git a/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp b/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp index 98680e5c5a32..8a381843cffb 100644 --- a/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp +++ b/gdb/testsuite/gdb.base/wrong_frame_bt_full.exp @@ -26,12 +26,12 @@ set opaque_testfile wrong_frame_bt_full-opaque set opaque_objfile [standard_output_file "$opaque_testfile.o"] if {[gdb_compile "${srcdir}/${subdir}/$opaque_testfile.c" \ $opaque_objfile \ object {}] != ""} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[gdb_compile \ [list ${srcdir}/${subdir}/$main_testfile.c $opaque_objfile] \ [standard_output_file ${main_testfile}] \ From patchwork Wed Apr 29 23:04:07 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134205 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 37AF34358A4E for ; Wed, 29 Apr 2026 23:07:15 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 37AF34358A4E Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=V2z9a1s3 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa36.google.com (mail-vk1-xa36.google.com [IPv6:2607:f8b0:4864:20::a36]) by sourceware.org (Postfix) with ESMTPS id 6DEDF4B920E5 for ; Wed, 29 Apr 2026 23:05:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6DEDF4B920E5 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 6DEDF4B920E5 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a36 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503935; cv=none; b=MmsiXVGnXIijJi+pr4OGNx/+ohr8ZPOxNCADtP8+fzC7sbkCYSlhzjQtZwXry2hq5XLq2/TLvpXgFF+/o10yAxwxeDue1vhLFYdMHmMuHKMNRMfFuMbg7ViL9Ra9Nr5mPT73DJWhUUeVmyo5uVGuYhVs+r745xNutn4Gemni6YE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503935; c=relaxed/simple; bh=eNi9z8l6rStZ/hYeCgiYKcTusoiYOWqAdhFVmWC7f2I=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=aGirHFlrNw//Np1dUxZHo4rZKnI018vNPSYvR9sFd5rML5zR1Fv6S4Fh6AvWiOKqJ66jiHHOT3ZKTLdk3TbDYRs1QvhfAW13PpA0GRbzntTBsSABWgm4QtusGoxLhpccrqr0bNTnVuTJroLiZ5GJduV1rvjz8VLW5HgKcV+q6Vs= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6DEDF4B920E5 Received: by mail-vk1-xa36.google.com with SMTP id 71dfb90a1353d-56d9ed609d2so100819e0c.1 for ; Wed, 29 Apr 2026 16:05:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503935; x=1778108735; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=O4UUph4V+Aj2MW9iLr4f1wA60PIeqz3xYgd6q2+AQHs=; b=V2z9a1s3YJRp8735EuoMwG39qngIYD8vrzcmpH0gWt2bmq02MkJpr91Cf5TYQgPe3o EPedsSFp+T6MPxaLhR0JTxECusGvk8pM+krDvuxyXIDAnyT7MK96JARYH6gdKND9ZNOb gvFOxPNN18SbDvV2WcN/Q8tHHyzgYrAl10k6f3/mnolpZskv6W0FJ/MmzvDZTrfk1LgV ldoguRvwO7aj4PuTigllCV+2wk6SsKnZhC0LNiMyZGx4MSxhme4z0ptF0DsnJB1WYQYA W4PiwGEc+UZN+KFVA7tl1hNLuZc9RXpOpf906gUqTMZUIf7bpOt/IihN1i8uNP3eCLEO f7TQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503935; x=1778108735; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=O4UUph4V+Aj2MW9iLr4f1wA60PIeqz3xYgd6q2+AQHs=; b=of7e+jO7ehaQ5wzOZivfVJk7gV6CMDdyXqe97V54+Ygtfij3Z5ESurY5wiydiDBrv3 1lt556gi2zvIr/4tnQvkrMNo4SVE3ErdlzSx8x3kqrHBIXFn9o+qDWStfG1Kzuh8ys1K DsSKuneLWDX52JWGP604Q7/iw6nnPoFJPmHUIOmLG8IRRlLWGZAHc138TZOA49OCPLE7 pmtBIwqNACkDM+766YDw24miQpNBr5kqgnulUNlWEdbNblAukfebzzg63S8d2rB7PXV7 C9auYowf1CHuYy55SdlTnGETkP8js3WuzgZMg6NDIEP3O+/oFNe2FGkEmvGkkNlp0898 ToUw== X-Gm-Message-State: AOJu0Yz9EDhCOISKj1opoE9Tj7ixuQGpRHk6/uK0TQLDB2MrpS9XWNRa QKaG2PTEcGqAAevP24YnhAi1fXE4bKQkNhMkxdhON/8tPtUxJmKnSr+S0/jp968D1laqTUwC01z kg6dF X-Gm-Gg: AeBDievjggehPa4Z/PdWRFiWWTIKhFuHMWy0h6jRacRPKwTnc7umn1fWORoseI3PT0v g9waKy0q+T4YcssVVPsRb9026Vo1aqyPMhNUdn9nkeBiPDSs7HOgA3ighfsXs/Ycg4HE/O35m3R dGsWYSXfpassDXdzO8/kfchg1FS8zU++GKgjQ1MDERSCCbMMORiGS+idZyrVA3K1cXx6EGJcooi Fz+yoZML19me+N2ZBH4DPaAwwJGB8XBiE4+twZ0X5N6wO68Kqwws8w5l+z+jY3gt228ZWvLJjGM CWXKXBPh9Sff4XFhKb85kfJi5y6TW2Wfn0WkqR+KEVglbazyVndzi/u+CQcDprxMHRJ2PZ2wdKT eZTyCgvRTgBiCIrsgNPKBeLD69VzlELsg33JaMldIg1owB6ULgol67tuBdqVlJapf0o4Q5YW0dj jvnnowlvQQN9IQ653zXAcIFbno1Ip+cW7DYQYhSumDRhUW X-Received: by 2002:a05:6122:829c:b0:56e:eafe:3bdb with SMTP id 71dfb90a1353d-573c968f21fmr90303e0c.10.1777503933906; Wed, 29 Apr 2026 16:05:33 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6bfd75fsm2063962e0c.8.2026.04.29.16.05.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:32 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 16/37] GDB: testsuite: C++: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:04:07 -0300 Message-ID: <20260429230432.60487-17-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* and $ sed -i 's/^ return 0/ return/' *.exp* inside gdb/testsuite/gdb.cp. I didn't include changes made to return statements inside procedures. --- gdb/testsuite/gdb.cp/abstract-origin.exp | 4 ++-- gdb/testsuite/gdb.cp/align.exp | 2 +- gdb/testsuite/gdb.cp/ambiguous.exp | 2 +- gdb/testsuite/gdb.cp/annota2.exp | 2 +- gdb/testsuite/gdb.cp/annota3.exp | 2 +- gdb/testsuite/gdb.cp/anon-ns.exp | 2 +- gdb/testsuite/gdb.cp/anon-union.exp | 2 +- gdb/testsuite/gdb.cp/arg-reference.exp | 2 +- gdb/testsuite/gdb.cp/baseenum.exp | 4 ++-- gdb/testsuite/gdb.cp/bool.exp | 2 +- gdb/testsuite/gdb.cp/break-template-cast.exp | 2 +- gdb/testsuite/gdb.cp/breakpoint-locs.exp | 2 +- gdb/testsuite/gdb.cp/breakpoint-shlib-func.exp | 6 +++--- gdb/testsuite/gdb.cp/breakpoint.exp | 2 +- gdb/testsuite/gdb.cp/bs15503.exp | 2 +- gdb/testsuite/gdb.cp/call-c.exp | 2 +- gdb/testsuite/gdb.cp/call-method-register.exp | 6 +++--- gdb/testsuite/gdb.cp/casts.exp | 4 ++-- gdb/testsuite/gdb.cp/chained-calls.exp | 4 ++-- gdb/testsuite/gdb.cp/class2.exp | 2 +- gdb/testsuite/gdb.cp/classes.exp | 2 +- gdb/testsuite/gdb.cp/cmpd-minsyms.exp | 2 +- gdb/testsuite/gdb.cp/cold-clone.exp | 2 +- gdb/testsuite/gdb.cp/constexpr-field.exp | 2 +- gdb/testsuite/gdb.cp/cp-relocate.exp | 2 +- gdb/testsuite/gdb.cp/cpcompletion.exp | 4 ++-- gdb/testsuite/gdb.cp/cpexprs.exp.tcl | 2 +- gdb/testsuite/gdb.cp/cplabel.exp | 4 ++-- gdb/testsuite/gdb.cp/cplusfuncs.exp | 2 +- gdb/testsuite/gdb.cp/ctti.exp | 2 +- gdb/testsuite/gdb.cp/derivation.exp | 2 +- gdb/testsuite/gdb.cp/destrprint.exp | 4 ++-- gdb/testsuite/gdb.cp/disasm-func-name.exp | 2 +- gdb/testsuite/gdb.cp/dispcxx.exp | 2 +- gdb/testsuite/gdb.cp/empty-enum.exp | 4 ++-- gdb/testsuite/gdb.cp/ena-dis-br-range.exp | 4 ++-- gdb/testsuite/gdb.cp/enum-class.exp | 4 ++-- gdb/testsuite/gdb.cp/exception.exp | 2 +- gdb/testsuite/gdb.cp/exceptprint.exp | 8 ++++---- gdb/testsuite/gdb.cp/expand-sals.exp | 4 ++-- gdb/testsuite/gdb.cp/extern-c.exp | 2 +- gdb/testsuite/gdb.cp/filename.exp | 2 +- gdb/testsuite/gdb.cp/formatted-ref.exp | 2 +- gdb/testsuite/gdb.cp/gdb1355.exp | 2 +- gdb/testsuite/gdb.cp/gdb2384.exp | 4 ++-- gdb/testsuite/gdb.cp/gdb2495.exp | 2 +- gdb/testsuite/gdb.cp/hang.exp | 2 +- gdb/testsuite/gdb.cp/impl-this.exp | 2 +- gdb/testsuite/gdb.cp/infcall-dlopen.exp | 4 ++-- gdb/testsuite/gdb.cp/inherit.exp | 2 +- gdb/testsuite/gdb.cp/iostream.exp | 2 +- gdb/testsuite/gdb.cp/local.exp | 2 +- gdb/testsuite/gdb.cp/m-data.exp | 2 +- gdb/testsuite/gdb.cp/m-static.exp | 2 +- gdb/testsuite/gdb.cp/main-cp.exp | 2 +- gdb/testsuite/gdb.cp/many-args.exp | 2 +- gdb/testsuite/gdb.cp/mb-ctor.exp | 2 +- gdb/testsuite/gdb.cp/mb-inline.exp | 4 ++-- gdb/testsuite/gdb.cp/mb-templates.exp | 4 ++-- gdb/testsuite/gdb.cp/member-name.exp | 2 +- gdb/testsuite/gdb.cp/member-ptr.exp | 2 +- gdb/testsuite/gdb.cp/meth-typedefs.exp | 2 +- gdb/testsuite/gdb.cp/method-call-in-c.exp | 4 ++-- gdb/testsuite/gdb.cp/method-ref-return.exp | 4 ++-- gdb/testsuite/gdb.cp/method.exp | 2 +- gdb/testsuite/gdb.cp/minsym-fallback.exp | 2 +- gdb/testsuite/gdb.cp/misc.exp | 2 +- gdb/testsuite/gdb.cp/namelessclass.exp | 4 ++-- gdb/testsuite/gdb.cp/namespace-enum.exp | 2 +- gdb/testsuite/gdb.cp/namespace-nested-import.exp | 2 +- gdb/testsuite/gdb.cp/namespace.exp | 2 +- gdb/testsuite/gdb.cp/nested-class-func-class.exp | 4 ++-- gdb/testsuite/gdb.cp/nested-types.exp | 2 +- gdb/testsuite/gdb.cp/nextoverthrow.exp | 4 ++-- gdb/testsuite/gdb.cp/no-libstdcxx-probe.exp | 4 ++-- gdb/testsuite/gdb.cp/non-trivial-retval.exp | 4 ++-- gdb/testsuite/gdb.cp/noparam.exp | 2 +- gdb/testsuite/gdb.cp/nsalias.exp | 10 +++++----- gdb/testsuite/gdb.cp/nsdecl.exp | 2 +- gdb/testsuite/gdb.cp/nsimport.exp | 2 +- gdb/testsuite/gdb.cp/nsrecurs.exp | 2 +- gdb/testsuite/gdb.cp/nsstress.exp | 2 +- gdb/testsuite/gdb.cp/nsusing.exp | 2 +- gdb/testsuite/gdb.cp/operator.exp | 2 +- gdb/testsuite/gdb.cp/overload-const.exp | 2 +- gdb/testsuite/gdb.cp/overload.exp | 2 +- gdb/testsuite/gdb.cp/ovldbreak.exp | 2 +- gdb/testsuite/gdb.cp/ovsrch.exp | 2 +- gdb/testsuite/gdb.cp/paramless.exp | 2 +- gdb/testsuite/gdb.cp/paren-type.exp | 2 +- gdb/testsuite/gdb.cp/parse-lang.exp | 2 +- gdb/testsuite/gdb.cp/pass-by-ref-2.exp | 4 ++-- gdb/testsuite/gdb.cp/pass-by-ref.exp | 4 ++-- gdb/testsuite/gdb.cp/pointer-to-member.exp | 2 +- gdb/testsuite/gdb.cp/pr-1023.exp | 2 +- gdb/testsuite/gdb.cp/pr-1210.exp | 2 +- gdb/testsuite/gdb.cp/pr-574.exp | 2 +- gdb/testsuite/gdb.cp/pr10687.exp | 2 +- gdb/testsuite/gdb.cp/pr12028.exp | 2 +- gdb/testsuite/gdb.cp/pr17132.exp | 4 ++-- gdb/testsuite/gdb.cp/pr17494.exp | 4 ++-- gdb/testsuite/gdb.cp/pr9067.exp | 2 +- gdb/testsuite/gdb.cp/pr9167.exp | 2 +- gdb/testsuite/gdb.cp/pr9631.exp | 2 +- gdb/testsuite/gdb.cp/print-demangle.exp | 2 +- gdb/testsuite/gdb.cp/print-global-stub.exp | 2 +- gdb/testsuite/gdb.cp/print-method-args.exp | 2 +- gdb/testsuite/gdb.cp/printmethod.exp | 2 +- gdb/testsuite/gdb.cp/psmang.exp | 2 +- gdb/testsuite/gdb.cp/psymtab-parameter.exp | 2 +- gdb/testsuite/gdb.cp/ptype-cv-cp.exp | 2 +- gdb/testsuite/gdb.cp/ptype-flags.exp | 2 +- gdb/testsuite/gdb.cp/re-set-overloaded.exp | 2 +- gdb/testsuite/gdb.cp/readnow-language.exp | 2 +- gdb/testsuite/gdb.cp/ref-params.exp | 2 +- gdb/testsuite/gdb.cp/ref-types.exp | 2 +- gdb/testsuite/gdb.cp/rtti.exp | 2 +- gdb/testsuite/gdb.cp/rvalue-ref-casts.exp | 4 ++-- gdb/testsuite/gdb.cp/rvalue-ref-overload.exp | 4 ++-- gdb/testsuite/gdb.cp/rvalue-ref-params.exp | 2 +- gdb/testsuite/gdb.cp/rvalue-ref-types.exp | 6 +++--- gdb/testsuite/gdb.cp/save-bp-qualified.exp | 2 +- gdb/testsuite/gdb.cp/scope-err.exp | 4 ++-- gdb/testsuite/gdb.cp/shadow.exp | 2 +- gdb/testsuite/gdb.cp/static-method.exp | 2 +- gdb/testsuite/gdb.cp/static-print-quit.exp | 2 +- gdb/testsuite/gdb.cp/static-typedef-print.exp | 4 ++-- gdb/testsuite/gdb.cp/step-and-next-inline.exp | 2 +- gdb/testsuite/gdb.cp/stub-array-size.exp | 2 +- gdb/testsuite/gdb.cp/subtypes.exp | 2 +- gdb/testsuite/gdb.cp/temargs.exp | 4 ++-- gdb/testsuite/gdb.cp/templates.exp | 2 +- gdb/testsuite/gdb.cp/try_catch.exp | 2 +- gdb/testsuite/gdb.cp/typed-enum.exp | 2 +- gdb/testsuite/gdb.cp/typedef-base.exp | 4 ++-- gdb/testsuite/gdb.cp/typedef-operator.exp | 4 ++-- gdb/testsuite/gdb.cp/typeid.exp | 4 ++-- gdb/testsuite/gdb.cp/userdef.exp | 2 +- gdb/testsuite/gdb.cp/using-crash.exp | 2 +- gdb/testsuite/gdb.cp/var-tag.exp | 2 +- gdb/testsuite/gdb.cp/virtbase.exp | 2 +- gdb/testsuite/gdb.cp/virtbase2.exp | 2 +- gdb/testsuite/gdb.cp/virtfunc.exp | 2 +- gdb/testsuite/gdb.cp/virtfunc2.exp | 2 +- gdb/testsuite/gdb.cp/vla-cxx.exp | 4 ++-- gdb/testsuite/gdb.cp/watch-cp.exp | 2 +- 146 files changed, 194 insertions(+), 194 deletions(-) diff --git a/gdb/testsuite/gdb.cp/abstract-origin.exp b/gdb/testsuite/gdb.cp/abstract-origin.exp index f9df73d5fe85..5b7139527a08 100644 --- a/gdb/testsuite/gdb.cp/abstract-origin.exp +++ b/gdb/testsuite/gdb.cp/abstract-origin.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" diff --git a/gdb/testsuite/gdb.cp/align.exp b/gdb/testsuite/gdb.cp/align.exp index 6cf046b0cb72..03b981175194 100644 --- a/gdb/testsuite/gdb.cp/align.exp +++ b/gdb/testsuite/gdb.cp/align.exp @@ -137,11 +137,11 @@ close $outfile standard_testfile $filename if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug nowarnings c++ additional_flags=-std=c++11}]} { - return -1 + return } if {![runto_main]} { perror "test suppressed" return diff --git a/gdb/testsuite/gdb.cp/ambiguous.exp b/gdb/testsuite/gdb.cp/ambiguous.exp index 838fa95cbb1c..94ba6a6b7cac 100644 --- a/gdb/testsuite/gdb.cp/ambiguous.exp +++ b/gdb/testsuite/gdb.cp/ambiguous.exp @@ -31,11 +31,11 @@ if {[test_compiler_info {gcc-[0-9]-*}]} { set additional_flags "additional_flags=-Wno-inaccessible-base" } if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug c++ $additional_flags]]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/annota2.exp b/gdb/testsuite/gdb.cp/annota2.exp index b3190fb3e252..466cab05b8ab 100644 --- a/gdb/testsuite/gdb.cp/annota2.exp +++ b/gdb/testsuite/gdb.cp/annota2.exp @@ -24,11 +24,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug c++ nowarnings}]} { - return -1 + return } # This testcase cannot use runto_main because of the different prompt # we get when using annotation level 2. # diff --git a/gdb/testsuite/gdb.cp/annota3.exp b/gdb/testsuite/gdb.cp/annota3.exp index a7016ee76bda..39a1399f95da 100644 --- a/gdb/testsuite/gdb.cp/annota3.exp +++ b/gdb/testsuite/gdb.cp/annota3.exp @@ -24,11 +24,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug c++ nowarnings}]} { - return -1 + return } # This testcase cannot use runto_main because of the different prompt # we get when using annotation level 2. # diff --git a/gdb/testsuite/gdb.cp/anon-ns.exp b/gdb/testsuite/gdb.cp/anon-ns.exp index 99f949cfc96c..50f77952bb3b 100644 --- a/gdb/testsuite/gdb.cp/anon-ns.exp +++ b/gdb/testsuite/gdb.cp/anon-ns.exp @@ -20,11 +20,11 @@ require allow_cplus_tests standard_testfile .cc anon-ns2.cc if {[prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" {c++ debug}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/anon-union.exp b/gdb/testsuite/gdb.cp/anon-union.exp index 5b26f7a848da..def3c3df1095 100644 --- a/gdb/testsuite/gdb.cp/anon-union.exp +++ b/gdb/testsuite/gdb.cp/anon-union.exp @@ -26,11 +26,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { continue } diff --git a/gdb/testsuite/gdb.cp/arg-reference.exp b/gdb/testsuite/gdb.cp/arg-reference.exp index b690c1376e60..1433ec3b3e49 100644 --- a/gdb/testsuite/gdb.cp/arg-reference.exp +++ b/gdb/testsuite/gdb.cp/arg-reference.exp @@ -25,9 +25,9 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } gdb_test "ptype foo" "type = int \\\(Obj\\\)" "no false reference" diff --git a/gdb/testsuite/gdb.cp/baseenum.exp b/gdb/testsuite/gdb.cp/baseenum.exp index da7a436026d2..5bf9963645d4 100644 --- a/gdb/testsuite/gdb.cp/baseenum.exp +++ b/gdb/testsuite/gdb.cp/baseenum.exp @@ -16,15 +16,15 @@ # Test searching enum constant symbols derived from base classes. standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "breakpoint 1" $srcfile] gdb_continue_to_breakpoint "breakpoint 1" gdb_test "print X" "= A::X" "print enum constant X of class A" diff --git a/gdb/testsuite/gdb.cp/bool.exp b/gdb/testsuite/gdb.cp/bool.exp index 1cab03b73d0d..eb2946d8c725 100644 --- a/gdb/testsuite/gdb.cp/bool.exp +++ b/gdb/testsuite/gdb.cp/bool.exp @@ -24,11 +24,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } runto_main # Testcases for tdep/2075. diff --git a/gdb/testsuite/gdb.cp/break-template-cast.exp b/gdb/testsuite/gdb.cp/break-template-cast.exp index 04ebff92489d..26cf9d387f3d 100644 --- a/gdb/testsuite/gdb.cp/break-template-cast.exp +++ b/gdb/testsuite/gdb.cp/break-template-cast.exp @@ -20,10 +20,10 @@ require allow_cplus_tests standard_testfile .cc if { [prepare_for_testing "failed to prepare" $testfile "$srcfile"\ {debug c++}] } { - return -1 + return } gdb_test "break foo" \ "Breakpoint $decimal at $hex: foo\\. \\(2 locations\\)" diff --git a/gdb/testsuite/gdb.cp/breakpoint-locs.exp b/gdb/testsuite/gdb.cp/breakpoint-locs.exp index 2ab046d3be89..6a77ef26bdee 100644 --- a/gdb/testsuite/gdb.cp/breakpoint-locs.exp +++ b/gdb/testsuite/gdb.cp/breakpoint-locs.exp @@ -21,11 +21,11 @@ standard_testfile .cc breakpoint-locs-2.cc include_file breakpoint-locs.h if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2"\ {debug c++}] } { - return -1 + return } gdb_test "break N1::C1::baz" "\\(2 locations\\)" if {[have_index $binfile] == ""} { diff --git a/gdb/testsuite/gdb.cp/breakpoint-shlib-func.exp b/gdb/testsuite/gdb.cp/breakpoint-shlib-func.exp index aaa2a531c819..5f99ab9a437d 100644 --- a/gdb/testsuite/gdb.cp/breakpoint-shlib-func.exp +++ b/gdb/testsuite/gdb.cp/breakpoint-shlib-func.exp @@ -30,16 +30,16 @@ require allow_shlib_tests standard_testfile .cc -lib.cc set libobj [standard_output_file libfoo.so] if {[build_executable "build shared library" $libobj $srcfile2 \ {debug c++ shlib}] != 0} { - return -1 + return } if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug c++ shlib=$libobj]]} { - return -1 + return } gdb_load_shlib $libobj # Place the breakpoint before the shared library has been loaded, the @@ -47,11 +47,11 @@ gdb_load_shlib $libobj gdb_test "break foo" "Breakpoint $decimal at $hex" gdb_test "info breakpoints" "" # Runto main, but don't delete all the breakpoints. if {![runto_main no-delete-breakpoints]} { - return -1 + return } # The breakpoint should now be showing in `foo` for real. gdb_test "info breakpoints" \ "\r\n$decimal\\s+\[^\r\n\]+ in foo\\(\\) at \[^\r\n\]+\r\n.*" \ diff --git a/gdb/testsuite/gdb.cp/breakpoint.exp b/gdb/testsuite/gdb.cp/breakpoint.exp index bb7b8bf5a510..936015e67095 100644 --- a/gdb/testsuite/gdb.cp/breakpoint.exp +++ b/gdb/testsuite/gdb.cp/breakpoint.exp @@ -24,11 +24,11 @@ require allow_cplus_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } proc test_breakpoint {name} { # Restart the program every time, so that a single failure doesn't # lead to a cascade. diff --git a/gdb/testsuite/gdb.cp/bs15503.exp b/gdb/testsuite/gdb.cp/bs15503.exp index 3a1ec22b5a43..603cc0f1debb 100644 --- a/gdb/testsuite/gdb.cp/bs15503.exp +++ b/gdb/testsuite/gdb.cp/bs15503.exp @@ -20,11 +20,11 @@ require allow_stl_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/call-c.exp b/gdb/testsuite/gdb.cp/call-c.exp index bdbe42772397..b5f7fdb24bb1 100644 --- a/gdb/testsuite/gdb.cp/call-c.exp +++ b/gdb/testsuite/gdb.cp/call-c.exp @@ -22,11 +22,11 @@ set objfilecpp [standard_output_file ${testfile}.o] if {[gdb_compile "$srcdir/$subdir/${srcfile2}" "${objfilec}" object {debug}] != "" || [gdb_compile "$srcdir/$subdir/${srcfile}" "${objfilecpp}" object {c++ debug}] != "" || [gdb_compile "${objfilecpp} ${objfilec}" "${binfile}" executable {c++ debug}] != ""} { untested "failed to compile" - return -1 + return } clean_restart ${::testfile} runto_main diff --git a/gdb/testsuite/gdb.cp/call-method-register.exp b/gdb/testsuite/gdb.cp/call-method-register.exp index d711cc9bd532..815c0e6a485f 100644 --- a/gdb/testsuite/gdb.cp/call-method-register.exp +++ b/gdb/testsuite/gdb.cp/call-method-register.exp @@ -30,11 +30,11 @@ lappend flags_debug c++ set flags_nodebug {} lappend flags_nodebug nodebug lappend flags_nodebug c++ if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags_debug]} { - return -1 + return } set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { @@ -103,15 +103,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] $::flags_nodebug] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print global_var.yyy ()" \ "Address requested for identifier \"global_var\" which is in register .*" \ "call method on register local" diff --git a/gdb/testsuite/gdb.cp/casts.exp b/gdb/testsuite/gdb.cp/casts.exp index fd37368e1a88..67246ac7b5ca 100644 --- a/gdb/testsuite/gdb.cp/casts.exp +++ b/gdb/testsuite/gdb.cp/casts.exp @@ -33,11 +33,11 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } if {![runto_main]} { return } @@ -213,11 +213,11 @@ gdb_test "print &dynamic_cast (*vlr) == vr" " = true" gdb_test "print &dynamic_cast (*vl) == vr" " = true" gdb_test "print &dynamic_cast (*vr) == vr" " = true" if {[prepare_for_testing "failed to prepare" ${testfile}03 $srcfile2 \ {debug c++ additional_flags=-std=c++03}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/chained-calls.exp b/gdb/testsuite/gdb.cp/chained-calls.exp index 4d7522a0bd1a..5c7b84d50b6e 100644 --- a/gdb/testsuite/gdb.cp/chained-calls.exp +++ b/gdb/testsuite/gdb.cp/chained-calls.exp @@ -18,15 +18,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break here" diff --git a/gdb/testsuite/gdb.cp/class2.exp b/gdb/testsuite/gdb.cp/class2.exp index d8f1e7972250..705f51ac3e07 100644 --- a/gdb/testsuite/gdb.cp/class2.exp +++ b/gdb/testsuite/gdb.cp/class2.exp @@ -24,11 +24,11 @@ set flags [list debug c++] if { [gcc_major_version "clang-*" "c++"] > 10 } { lappend flags additional_flags=-Wno-non-c-typedef-for-linkage } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } # Start with "set print object off" and "set print symbol off". gdb_test_no_output "set print object off" diff --git a/gdb/testsuite/gdb.cp/classes.exp b/gdb/testsuite/gdb.cp/classes.exp index ea4b2033b830..71ce810adadf 100644 --- a/gdb/testsuite/gdb.cp/classes.exp +++ b/gdb/testsuite/gdb.cp/classes.exp @@ -32,11 +32,11 @@ if { [test_compiler_info "clang-*" "c++"] } { lappend flags additional_flags=-Wno-non-c-typedef-for-linkage } } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } # Test ptype of class objects. proc test_ptype_class_objects {} { diff --git a/gdb/testsuite/gdb.cp/cmpd-minsyms.exp b/gdb/testsuite/gdb.cp/cmpd-minsyms.exp index 7afda5fbe827..19653a4ccc9e 100644 --- a/gdb/testsuite/gdb.cp/cmpd-minsyms.exp +++ b/gdb/testsuite/gdb.cp/cmpd-minsyms.exp @@ -22,11 +22,11 @@ require allow_cplus_tests # Tests for c++/12273, breakpoint/12803 standard_testfile .cc # Do NOT compile with debug flag. if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++}]} { - return -1 + return } # Before setting the language, try to set a few simple breakpoints set min_syms [list \ "GDB::a() const" \ diff --git a/gdb/testsuite/gdb.cp/cold-clone.exp b/gdb/testsuite/gdb.cp/cold-clone.exp index 1fb7c2449af4..d2c69c504faa 100644 --- a/gdb/testsuite/gdb.cp/cold-clone.exp +++ b/gdb/testsuite/gdb.cp/cold-clone.exp @@ -20,11 +20,11 @@ lappend flags debug lappend flags c++ lappend flags optimize=-O2 lappend_include_file flags $srcdir/lib/attributes.h if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } gdb_test_multiple "break foo" "" { -re -wrap "\\($decimal locations\\)" { fail $gdb_test_name diff --git a/gdb/testsuite/gdb.cp/constexpr-field.exp b/gdb/testsuite/gdb.cp/constexpr-field.exp index 3e8a7b985137..c50ea3ef5d94 100644 --- a/gdb/testsuite/gdb.cp/constexpr-field.exp +++ b/gdb/testsuite/gdb.cp/constexpr-field.exp @@ -20,11 +20,11 @@ require {have_compile_flag -std=c++17} standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {c++ debug additional_flags=-std=c++17}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/cp-relocate.exp b/gdb/testsuite/gdb.cp/cp-relocate.exp index fb45313466b1..c42c67a95e75 100644 --- a/gdb/testsuite/gdb.cp/cp-relocate.exp +++ b/gdb/testsuite/gdb.cp/cp-relocate.exp @@ -110,11 +110,11 @@ gdb_test_multiple "info file" "info file" { } } if { $func1_sec == $func2_sec } { untested "cp-relocate.exp - template functions in same sections" - return -1 + return } # Now start a clean GDB, for add-symbol-file tests. clean_restart diff --git a/gdb/testsuite/gdb.cp/cpcompletion.exp b/gdb/testsuite/gdb.cp/cpcompletion.exp index 555392b470ab..f767a8b7bc64 100644 --- a/gdb/testsuite/gdb.cp/cpcompletion.exp +++ b/gdb/testsuite/gdb.cp/cpcompletion.exp @@ -54,19 +54,19 @@ proc test_class_complete {class expr name matches} { require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } # Test that completion is restricted by class name (all methods) test_class_complete Foo "" "complete class methods" \ [list Foo Foofoo get_foo set_foo ~Foo] diff --git a/gdb/testsuite/gdb.cp/cpexprs.exp.tcl b/gdb/testsuite/gdb.cp/cpexprs.exp.tcl index 085dfdd0678a..c9646755f0ac 100644 --- a/gdb/testsuite/gdb.cp/cpexprs.exp.tcl +++ b/gdb/testsuite/gdb.cp/cpexprs.exp.tcl @@ -704,11 +704,11 @@ standard_testfile cpexprs.cc # Include required flags. set flags "$flags debug c++" if {[prepare_for_testing "failed to prepare" $testfile $srcfile "$flags"]} { - return -1 + return } if {![runto_main]} { perror "couldn't run to breakpoint" continue diff --git a/gdb/testsuite/gdb.cp/cplabel.exp b/gdb/testsuite/gdb.cp/cplabel.exp index 0bb22cd96ad0..e0301eb3628c 100644 --- a/gdb/testsuite/gdb.cp/cplabel.exp +++ b/gdb/testsuite/gdb.cp/cplabel.exp @@ -18,15 +18,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } set methods {"bar" "baz"} set labels {"to_the_top" "get_out_of_here"} diff --git a/gdb/testsuite/gdb.cp/cplusfuncs.exp b/gdb/testsuite/gdb.cp/cplusfuncs.exp index b8ce5d7bdd02..62b149c9f357 100644 --- a/gdb/testsuite/gdb.cp/cplusfuncs.exp +++ b/gdb/testsuite/gdb.cp/cplusfuncs.exp @@ -19,11 +19,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # # g++ changed its ABI between 2.95 and 3.0. gdb has two demanglers # for the two different styles. The two demanglers have some subtle diff --git a/gdb/testsuite/gdb.cp/ctti.exp b/gdb/testsuite/gdb.cp/ctti.exp index e328b7c59c41..5c2be5de57b8 100644 --- a/gdb/testsuite/gdb.cp/ctti.exp +++ b/gdb/testsuite/gdb.cp/ctti.exp @@ -25,11 +25,11 @@ require allow_cplus_tests standard_testfile cttiadd.cc cttiadd1.cc cttiadd2.cc cttiadd3.cc if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2 $srcfile3 $srcfile4] {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/derivation.exp b/gdb/testsuite/gdb.cp/derivation.exp index 34fbf3c250e1..3b42c85a6272 100644 --- a/gdb/testsuite/gdb.cp/derivation.exp +++ b/gdb/testsuite/gdb.cp/derivation.exp @@ -34,11 +34,11 @@ load_lib "cp-support.exp" standard_testfile derivation.cc derivation2.cc if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}]} { - return -1 + return } # Check inheritance of typedefs. with_test_prefix "before run" { foreach klass {"A" "D" "E" "F" "A2" "D2"} { diff --git a/gdb/testsuite/gdb.cp/destrprint.exp b/gdb/testsuite/gdb.cp/destrprint.exp index b0f1087a38df..f20255a4c4f7 100644 --- a/gdb/testsuite/gdb.cp/destrprint.exp +++ b/gdb/testsuite/gdb.cp/destrprint.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break here" diff --git a/gdb/testsuite/gdb.cp/disasm-func-name.exp b/gdb/testsuite/gdb.cp/disasm-func-name.exp index 77b872fe1ade..d4b6586dbded 100644 --- a/gdb/testsuite/gdb.cp/disasm-func-name.exp +++ b/gdb/testsuite/gdb.cp/disasm-func-name.exp @@ -22,11 +22,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile \ $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/dispcxx.exp b/gdb/testsuite/gdb.cp/dispcxx.exp index 0af655ad0a50..c20dbadd65ce 100644 --- a/gdb/testsuite/gdb.cp/dispcxx.exp +++ b/gdb/testsuite/gdb.cp/dispcxx.exp @@ -16,11 +16,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/empty-enum.exp b/gdb/testsuite/gdb.cp/empty-enum.exp index 437dd0ad0868..e2b82d386f34 100644 --- a/gdb/testsuite/gdb.cp/empty-enum.exp +++ b/gdb/testsuite/gdb.cp/empty-enum.exp @@ -33,15 +33,15 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "breakpt" gdb_continue_to_breakpoint "stop in breakpt" diff --git a/gdb/testsuite/gdb.cp/ena-dis-br-range.exp b/gdb/testsuite/gdb.cp/ena-dis-br-range.exp index f6d3f0cb9717..36ab2f659697 100644 --- a/gdb/testsuite/gdb.cp/ena-dis-br-range.exp +++ b/gdb/testsuite/gdb.cp/ena-dis-br-range.exp @@ -24,15 +24,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto 'marker']} { - return -1 + return } # Returns a buffer corresponding to what GDB replies when asking for # 'info breakpoint'. The parameters are all the existing breakpoints # enabled/disable value: 'n' or 'y'. diff --git a/gdb/testsuite/gdb.cp/enum-class.exp b/gdb/testsuite/gdb.cp/enum-class.exp index b7858719f1e5..26a496972fa6 100644 --- a/gdb/testsuite/gdb.cp/enum-class.exp +++ b/gdb/testsuite/gdb.cp/enum-class.exp @@ -19,15 +19,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug c++ additional_flags=-std=c++11}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "ptype E1" \ [multi_line \ "type = enum class E1 (: int )?{" \ diff --git a/gdb/testsuite/gdb.cp/exception.exp b/gdb/testsuite/gdb.cp/exception.exp index 987fa799c56f..b7bba4c71d42 100644 --- a/gdb/testsuite/gdb.cp/exception.exp +++ b/gdb/testsuite/gdb.cp/exception.exp @@ -33,11 +33,11 @@ set nl "\[\r\n\]+" require allow_stl_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # Set a catch catchpoint gdb_test "catch catch" "Catchpoint ${::decimal} \\(catch\\)" \ diff --git a/gdb/testsuite/gdb.cp/exceptprint.exp b/gdb/testsuite/gdb.cp/exceptprint.exp index b940f66f9a89..d0e0a07bfb90 100644 --- a/gdb/testsuite/gdb.cp/exceptprint.exp +++ b/gdb/testsuite/gdb.cp/exceptprint.exp @@ -16,20 +16,20 @@ standard_testfile .cc require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } if {[skip_libstdcxx_probe_tests]} { untested "could not find libstdc++ stap probe" - return -1 + return } proc do_continue_to_catchpoint {name} { global gdb_prompt @@ -69,11 +69,11 @@ do_exceptprint_tests "reference to struct" "{mv = 77}" delete_breakpoints if {![runto_main]} { - return -1 + return } with_test_prefix "2nd run" { gdb_test "catch catch int if \$_exception == 23" \ "Catchpoint ${::decimal} \\(catch\\)" \ diff --git a/gdb/testsuite/gdb.cp/expand-sals.exp b/gdb/testsuite/gdb.cp/expand-sals.exp index dad11bbd9b0e..187073ec86eb 100644 --- a/gdb/testsuite/gdb.cp/expand-sals.exp +++ b/gdb/testsuite/gdb.cp/expand-sals.exp @@ -15,14 +15,14 @@ require allow_cplus_tests set srcfile expand-sals.cc if { [prepare_for_testing "failed to prepare" expand-sals $srcfile {debug c++}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "func-line"] gdb_continue_to_breakpoint "func" ".*func-line.*" diff --git a/gdb/testsuite/gdb.cp/extern-c.exp b/gdb/testsuite/gdb.cp/extern-c.exp index 67a2ced08072..ce77afae1e47 100644 --- a/gdb/testsuite/gdb.cp/extern-c.exp +++ b/gdb/testsuite/gdb.cp/extern-c.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } runto_main if { [gdb_breakpoint "c_func"] == 1 } { diff --git a/gdb/testsuite/gdb.cp/filename.exp b/gdb/testsuite/gdb.cp/filename.exp index f9f6007ccc79..72fbbcfcebee 100644 --- a/gdb/testsuite/gdb.cp/filename.exp +++ b/gdb/testsuite/gdb.cp/filename.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc include_file includefile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/formatted-ref.exp b/gdb/testsuite/gdb.cp/formatted-ref.exp index 354c716a6c07..bc2ac9d36b24 100644 --- a/gdb/testsuite/gdb.cp/formatted-ref.exp +++ b/gdb/testsuite/gdb.cp/formatted-ref.exp @@ -31,11 +31,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } proc get_address { var } { global expect_out global gdb_prompt diff --git a/gdb/testsuite/gdb.cp/gdb1355.exp b/gdb/testsuite/gdb.cp/gdb1355.exp index 900f9029c259..77e845b468d6 100644 --- a/gdb/testsuite/gdb.cp/gdb1355.exp +++ b/gdb/testsuite/gdb.cp/gdb1355.exp @@ -28,11 +28,11 @@ require allow_cplus_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/gdb2384.exp b/gdb/testsuite/gdb.cp/gdb2384.exp index 0a5b3088fa0f..d0c96aeaab32 100644 --- a/gdb/testsuite/gdb.cp/gdb2384.exp +++ b/gdb/testsuite/gdb.cp/gdb2384.exp @@ -30,19 +30,19 @@ include_file gdb2384-base.h set sofile [standard_output_file gdb2384-base.so] if { [gdb_compile_shlib $srcdir/$subdir/$srcfile2 $sofile {debug c++}] != "" || [gdb_compile $srcdir/$subdir/$srcfile $binfile executable [list debug "c++" shlib=${sofile}]] != ""} { untested "failed to compile" - return -1 + return } clean_restart ${::testfile} gdb_load_shlib ${sofile} if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "First breakpoint"] gdb_continue_to_breakpoint "run to 'First breakpoint', first time" diff --git a/gdb/testsuite/gdb.cp/gdb2495.exp b/gdb/testsuite/gdb.cp/gdb2495.exp index c3bac7a9ce46..aa5a2a16e437 100644 --- a/gdb/testsuite/gdb.cp/gdb2495.exp +++ b/gdb/testsuite/gdb.cp/gdb2495.exp @@ -40,11 +40,11 @@ standard_testfile .cc # Some targets can't do function calls, so don't even bother with this # test. require {!target_info exists gdb,cannot_call_functions} if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/hang.exp b/gdb/testsuite/gdb.cp/hang.exp index f547f1bb1590..bd6fbd24ae7c 100644 --- a/gdb/testsuite/gdb.cp/hang.exp +++ b/gdb/testsuite/gdb.cp/hang.exp @@ -20,11 +20,11 @@ standard_testfile hang1.cc hang2.cc hang3.cc include_file hang.H if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2 $srcfile3] {debug c++}]} { - return -1 + return } # As of May 1, 2002, GDB hangs trying to read the debug info for the # `hang2.o' compilation unit from the executable `hang', when compiled # by g++ 2.96 with STABS debugging info. Here's what's going on, as diff --git a/gdb/testsuite/gdb.cp/impl-this.exp b/gdb/testsuite/gdb.cp/impl-this.exp index 213d41e664f7..a8979f383c79 100644 --- a/gdb/testsuite/gdb.cp/impl-this.exp +++ b/gdb/testsuite/gdb.cp/impl-this.exp @@ -21,11 +21,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } set gcc_used [test_compiler_info gcc-*-*] # First test expressions when there is no context. diff --git a/gdb/testsuite/gdb.cp/infcall-dlopen.exp b/gdb/testsuite/gdb.cp/infcall-dlopen.exp index 50ccf608ef66..b69c9f58cce0 100644 --- a/gdb/testsuite/gdb.cp/infcall-dlopen.exp +++ b/gdb/testsuite/gdb.cp/infcall-dlopen.exp @@ -20,17 +20,17 @@ set libfile [standard_output_file ${testfile}.so] set lib_dlopen [shlib_target_file ${testfile}.so] # Use completely arbitrary file for $libfile source. if { [gdb_compile_shlib ${srcdir}/${subdir}/${srcfile2} ${libfile} {debug c++}] != "" || [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++ shlib_load}] } { - return -1 + return } gdb_load_shlib $libfile if { ![runto_main] } { - return -1 + return } for {set i 0} {$i < 10} {incr i} { gdb_test "p openlib (\"${lib_dlopen}\")" " = 1" "test $i" # Try to exploit the GDB trashed memory. diff --git a/gdb/testsuite/gdb.cp/inherit.exp b/gdb/testsuite/gdb.cp/inherit.exp index 5d7d12c40e9c..dd2ea1a7afcf 100644 --- a/gdb/testsuite/gdb.cp/inherit.exp +++ b/gdb/testsuite/gdb.cp/inherit.exp @@ -25,11 +25,11 @@ require allow_cplus_tests load_lib "cp-support.exp" standard_testfile misc.cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # Single inheritance, print type definitions. proc test_ptype_si { } { diff --git a/gdb/testsuite/gdb.cp/iostream.exp b/gdb/testsuite/gdb.cp/iostream.exp index 39ccdb4087dc..b23e81115322 100644 --- a/gdb/testsuite/gdb.cp/iostream.exp +++ b/gdb/testsuite/gdb.cp/iostream.exp @@ -19,11 +19,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/local.exp b/gdb/testsuite/gdb.cp/local.exp index 73527687ff85..cf072ba6c722 100644 --- a/gdb/testsuite/gdb.cp/local.exp +++ b/gdb/testsuite/gdb.cp/local.exp @@ -30,11 +30,11 @@ set nl "\[\r\n\]+" require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.cp/m-data.exp b/gdb/testsuite/gdb.cp/m-data.exp index 1d1c94e107da..125c7e0483ad 100644 --- a/gdb/testsuite/gdb.cp/m-data.exp +++ b/gdb/testsuite/gdb.cp/m-data.exp @@ -25,11 +25,11 @@ require allow_cplus_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/m-static.exp b/gdb/testsuite/gdb.cp/m-static.exp index 939e1880d64f..a898bc934e54 100644 --- a/gdb/testsuite/gdb.cp/m-static.exp +++ b/gdb/testsuite/gdb.cp/m-static.exp @@ -35,11 +35,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } { lappend flags additional_flags=-fno-eliminate-unused-debug-types } if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] $flags]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/main-cp.exp b/gdb/testsuite/gdb.cp/main-cp.exp index bdca417e0b50..42175cd5ec31 100644 --- a/gdb/testsuite/gdb.cp/main-cp.exp +++ b/gdb/testsuite/gdb.cp/main-cp.exp @@ -23,11 +23,11 @@ require !readnow set opts {} lappend opts debug lappend opts c++ if { [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] } { - return -1 + return } require {string eq [have_index $binfile] ""} gdb_test_no_output "maint info symtabs" diff --git a/gdb/testsuite/gdb.cp/many-args.exp b/gdb/testsuite/gdb.cp/many-args.exp index 49b5e28e976f..a2b19b0edf58 100644 --- a/gdb/testsuite/gdb.cp/many-args.exp +++ b/gdb/testsuite/gdb.cp/many-args.exp @@ -22,11 +22,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/mb-ctor.exp b/gdb/testsuite/gdb.cp/mb-ctor.exp index 925c215f9d82..67fb8f1afe40 100644 --- a/gdb/testsuite/gdb.cp/mb-ctor.exp +++ b/gdb/testsuite/gdb.cp/mb-ctor.exp @@ -20,11 +20,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {[test_compiler_info {clang-*-*} c++]} { set using_clang true } else { diff --git a/gdb/testsuite/gdb.cp/mb-inline.exp b/gdb/testsuite/gdb.cp/mb-inline.exp index 4bb95547ccf2..3a7d15ad2185 100644 --- a/gdb/testsuite/gdb.cp/mb-inline.exp +++ b/gdb/testsuite/gdb.cp/mb-inline.exp @@ -24,11 +24,11 @@ standard_testfile mb-inline1.cc mb-inline2.cc set hdrfile "${testfile}.h" include_file $hdrfile if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}]} { - return -1 + return } set bp_location [gdb_get_line_number "set breakpoint here" $hdrfile] # Set a breakpoint with multiple locations. @@ -78,11 +78,11 @@ gdb_test_multiple "info break" "disabled breakpoint 1.2" { delete_breakpoints set bp_location [gdb_get_line_number "set multi-line breakpoint here" $hdrfile] if { ![runto_main] } { - return 0 + return } gdb_test "break $hdrfile:$bp_location" \ "Breakpoint.*at.*: $hdrfile:$bp_location. \\(2 locations\\).*" \ "set multi_line_foo breakpoint" diff --git a/gdb/testsuite/gdb.cp/mb-templates.exp b/gdb/testsuite/gdb.cp/mb-templates.exp index c9b78e8a16c4..a1d55d3246f2 100644 --- a/gdb/testsuite/gdb.cp/mb-templates.exp +++ b/gdb/testsuite/gdb.cp/mb-templates.exp @@ -20,11 +20,11 @@ require allow_stl_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } set bp_location [gdb_get_line_number "set breakpoint here"] # Set a breakpoint with multiple locations @@ -106,11 +106,11 @@ gdb_test "continue" \ delete_breakpoints set bp_location [gdb_get_line_number "set multi-line breakpoint here"] if { ![runto_main] } { - return 0 + return } gdb_test "break $srcfile:$bp_location" \ "Breakpoint.*at.*: $srcfile:$bp_location. \\(2 locations\\).*" \ "set multi_line_foo breakpoint" diff --git a/gdb/testsuite/gdb.cp/member-name.exp b/gdb/testsuite/gdb.cp/member-name.exp index ca414c9915f2..95f628076b7b 100644 --- a/gdb/testsuite/gdb.cp/member-name.exp +++ b/gdb/testsuite/gdb.cp/member-name.exp @@ -16,11 +16,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/member-ptr.exp b/gdb/testsuite/gdb.cp/member-ptr.exp index f7aa475d4f81..055b1d4e7095 100644 --- a/gdb/testsuite/gdb.cp/member-ptr.exp +++ b/gdb/testsuite/gdb.cp/member-ptr.exp @@ -25,11 +25,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/meth-typedefs.exp b/gdb/testsuite/gdb.cp/meth-typedefs.exp index 898bdd499e76..ba0fc6d9cbb7 100644 --- a/gdb/testsuite/gdb.cp/meth-typedefs.exp +++ b/gdb/testsuite/gdb.cp/meth-typedefs.exp @@ -35,11 +35,11 @@ require allow_cplus_tests # Tests for c++/12266 et al standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {c++ debug additional_flags=-std=c++11}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/method-call-in-c.exp b/gdb/testsuite/gdb.cp/method-call-in-c.exp index a8e62f816a3b..5d4600b2ec23 100644 --- a/gdb/testsuite/gdb.cp/method-call-in-c.exp +++ b/gdb/testsuite/gdb.cp/method-call-in-c.exp @@ -24,15 +24,15 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if { [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] } { - return -1 + return } if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break here" diff --git a/gdb/testsuite/gdb.cp/method-ref-return.exp b/gdb/testsuite/gdb.cp/method-ref-return.exp index 8e082f36aa2c..1e5e0619b015 100644 --- a/gdb/testsuite/gdb.cp/method-ref-return.exp +++ b/gdb/testsuite/gdb.cp/method-ref-return.exp @@ -18,15 +18,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Set a breakpoint after the bar object is created and the reference is obtained. gdb_breakpoint [gdb_get_line_number "breakpoint here"] gdb_continue_to_breakpoint "after reference assignment" diff --git a/gdb/testsuite/gdb.cp/method.exp b/gdb/testsuite/gdb.cp/method.exp index d890be1df9e6..e0946651a6e4 100644 --- a/gdb/testsuite/gdb.cp/method.exp +++ b/gdb/testsuite/gdb.cp/method.exp @@ -35,11 +35,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.cp/minsym-fallback.exp b/gdb/testsuite/gdb.cp/minsym-fallback.exp index 46427d6905c8..b42710278144 100644 --- a/gdb/testsuite/gdb.cp/minsym-fallback.exp +++ b/gdb/testsuite/gdb.cp/minsym-fallback.exp @@ -35,11 +35,11 @@ set objmainfile [standard_output_file ${testfile}-main.o] if {[gdb_compile $srcdir/$subdir/$srcfile $objfile object $nodebug_flags] != "" || [gdb_compile $srcdir/$subdir/$srcfile2 $objmainfile object $debug_flags] != "" || [gdb_compile "$objfile $objmainfile" $binfile executable $debug_flags] != ""} { untested "failed to compile" - return -1 + return } clean_restart ${executable} gdb_test_no_output "set breakpoint pending off" diff --git a/gdb/testsuite/gdb.cp/misc.exp b/gdb/testsuite/gdb.cp/misc.exp index 974ad1a550c1..e844ab9244e3 100644 --- a/gdb/testsuite/gdb.cp/misc.exp +++ b/gdb/testsuite/gdb.cp/misc.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # # Deduce language of main() # diff --git a/gdb/testsuite/gdb.cp/namelessclass.exp b/gdb/testsuite/gdb.cp/namelessclass.exp index a247fcebb7bc..e3be4cf666c8 100644 --- a/gdb/testsuite/gdb.cp/namelessclass.exp +++ b/gdb/testsuite/gdb.cp/namelessclass.exp @@ -26,15 +26,15 @@ require is_x86_64_m64_target standard_testfile .S set csrcfile "${testfile}.cc" if {[prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Set a breakpoint in the lambda in A::doit (). */ set line [gdb_get_line_number "set breakpoint here" $csrcfile] gdb_breakpoint $line diff --git a/gdb/testsuite/gdb.cp/namespace-enum.exp b/gdb/testsuite/gdb.cp/namespace-enum.exp index cc9c274ad497..8ccdd320c738 100644 --- a/gdb/testsuite/gdb.cp/namespace-enum.exp +++ b/gdb/testsuite/gdb.cp/namespace-enum.exp @@ -15,11 +15,11 @@ standard_testfile .cc namespace-enum-main.cc if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}]} { - return -1 + return } gdb_test "print foo::B::B_B" "`foo::B' is not defined as an aggregate type." gdb_test "print foo::B_B" "foo::B_B" gdb_test "print A_A" "A_A" diff --git a/gdb/testsuite/gdb.cp/namespace-nested-import.exp b/gdb/testsuite/gdb.cp/namespace-nested-import.exp index 1ec31c1903e3..b2fb2d914cbb 100644 --- a/gdb/testsuite/gdb.cp/namespace-nested-import.exp +++ b/gdb/testsuite/gdb.cp/namespace-nested-import.exp @@ -15,11 +15,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } ############################################ # Test printing of a variable from a nested # in a namespace inner to the one which has diff --git a/gdb/testsuite/gdb.cp/namespace.exp b/gdb/testsuite/gdb.cp/namespace.exp index 6c5dd667060c..b39b2a164fc3 100644 --- a/gdb/testsuite/gdb.cp/namespace.exp +++ b/gdb/testsuite/gdb.cp/namespace.exp @@ -36,11 +36,11 @@ if {[test_compiler_info {gcc-[0-3]-*}] set xfail_class_types 1 } if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}]} { - return -1 + return } gdb_test "show lang" "auto; currently c\\+\\+.*" # diff --git a/gdb/testsuite/gdb.cp/nested-class-func-class.exp b/gdb/testsuite/gdb.cp/nested-class-func-class.exp index f2d6f317b144..64b2ae8343c0 100644 --- a/gdb/testsuite/gdb.cp/nested-class-func-class.exp +++ b/gdb/testsuite/gdb.cp/nested-class-func-class.exp @@ -20,15 +20,15 @@ require allow_cplus_tests load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "BP 1"] gdb_breakpoint [gdb_get_line_number "BP 2"] gdb_continue_to_breakpoint "BP 1" diff --git a/gdb/testsuite/gdb.cp/nested-types.exp b/gdb/testsuite/gdb.cp/nested-types.exp index e0a9d1635824..9806bb6d5c89 100644 --- a/gdb/testsuite/gdb.cp/nested-types.exp +++ b/gdb/testsuite/gdb.cp/nested-types.exp @@ -25,11 +25,11 @@ load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug c++}]} { - return -1 + return } # Build the node given by ID (a number representing the struct S[ID] in # the source file). # diff --git a/gdb/testsuite/gdb.cp/nextoverthrow.exp b/gdb/testsuite/gdb.cp/nextoverthrow.exp index 2f34795d201b..2dbaae128694 100644 --- a/gdb/testsuite/gdb.cp/nextoverthrow.exp +++ b/gdb/testsuite/gdb.cp/nextoverthrow.exp @@ -17,20 +17,20 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } if {![skip_unwinder_tests]} { unsupported "nextoverthrow.exp could not find _Unwind_DebugHook" - return -1 + return } # Set a temporary breakpoint and then continue to it. # The breakpoint is set according to a marker in the file. proc tbreak_and_cont {text} { diff --git a/gdb/testsuite/gdb.cp/no-libstdcxx-probe.exp b/gdb/testsuite/gdb.cp/no-libstdcxx-probe.exp index 202e1f0d0f1b..14e42a2e361a 100644 --- a/gdb/testsuite/gdb.cp/no-libstdcxx-probe.exp +++ b/gdb/testsuite/gdb.cp/no-libstdcxx-probe.exp @@ -16,19 +16,19 @@ standard_testfile exceptprint.cc require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # This tests that $_exception gives an error when the systemtap probes # are not available, so simulate this by disabling them. gdb_test "maint ignore-probes libstdcxx .*" ".*OBJNAME: ''" if {![runto_main]} { - return -1 + return } gdb_test "catch throw" "Catchpoint $decimal \\(throw\\)" \ "catch throw" diff --git a/gdb/testsuite/gdb.cp/non-trivial-retval.exp b/gdb/testsuite/gdb.cp/non-trivial-retval.exp index 0b70d3546e97..f5c32dca079d 100644 --- a/gdb/testsuite/gdb.cp/non-trivial-retval.exp +++ b/gdb/testsuite/gdb.cp/non-trivial-retval.exp @@ -35,15 +35,15 @@ if {[have_fvar_tracking]} { } } if {[prepare_for_testing "failed to prepare" $testfile $srcfile [list debug c++ $additional_flags]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break here" diff --git a/gdb/testsuite/gdb.cp/noparam.exp b/gdb/testsuite/gdb.cp/noparam.exp index 1607d64f8eee..8ce8becd91b9 100644 --- a/gdb/testsuite/gdb.cp/noparam.exp +++ b/gdb/testsuite/gdb.cp/noparam.exp @@ -12,10 +12,10 @@ # # You should have received a copy of the GNU General Public License # along with this program. If not, see . if { [prepare_for_testing "failed to prepare" "noparam" "noparam.cc" {debug c++}] } { - return -1 + return } # Check if GDB does not crash. gdb_test "p C::m (int)" "no member function matches that type instantiation" diff --git a/gdb/testsuite/gdb.cp/nsalias.exp b/gdb/testsuite/gdb.cp/nsalias.exp index e384d8d77eb2..459efbf12d08 100644 --- a/gdb/testsuite/gdb.cp/nsalias.exp +++ b/gdb/testsuite/gdb.cp/nsalias.exp @@ -168,20 +168,20 @@ Dwarf::assemble $asm_file { } } if {[gdb_compile $srcdir/$subdir/$srcfile ${binfile}1.o \ object {c++ debug}] != ""} { - return -1 + return } if {[gdb_compile $asm_file ${binfile}2.o object {nodebug}] != ""} { - return -1 + return } if {[gdb_compile [list ${binfile}1.o ${binfile}2.o] \ $binfile executable {c++}] != ""} { - return -1 + return } clean_restart $testfile # A procedure to run various tests on aliased namespaces. @@ -302,16 +302,16 @@ set the_dwarf [format { } $imports] Dwarf::assemble $asm_file $the_dwarf if {[gdb_compile $asm_file ${binfile}3.o object {nodebug}] != ""} { - return -1 + return } if {[gdb_compile [list ${binfile}1.o ${binfile}3.o] \ ${binfile}-r executable {c++}] != ""} { - return -1 + return } clean_restart # Set complaints before loading the file. Otherwise the complaint won't diff --git a/gdb/testsuite/gdb.cp/nsdecl.exp b/gdb/testsuite/gdb.cp/nsdecl.exp index 72d20b618dc6..e068f419db89 100644 --- a/gdb/testsuite/gdb.cp/nsdecl.exp +++ b/gdb/testsuite/gdb.cp/nsdecl.exp @@ -17,11 +17,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/nsimport.exp b/gdb/testsuite/gdb.cp/nsimport.exp index bab4701f16fa..2ac4c0b4d5bd 100644 --- a/gdb/testsuite/gdb.cp/nsimport.exp +++ b/gdb/testsuite/gdb.cp/nsimport.exp @@ -18,11 +18,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } ############################################ # test printing of namespace imported within # the function. diff --git a/gdb/testsuite/gdb.cp/nsrecurs.exp b/gdb/testsuite/gdb.cp/nsrecurs.exp index 220fe897387f..58d90420c820 100644 --- a/gdb/testsuite/gdb.cp/nsrecurs.exp +++ b/gdb/testsuite/gdb.cp/nsrecurs.exp @@ -15,11 +15,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/nsstress.exp b/gdb/testsuite/gdb.cp/nsstress.exp index 872bf62fd6e3..eebfaf30fef6 100644 --- a/gdb/testsuite/gdb.cp/nsstress.exp +++ b/gdb/testsuite/gdb.cp/nsstress.exp @@ -17,11 +17,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { continue } diff --git a/gdb/testsuite/gdb.cp/nsusing.exp b/gdb/testsuite/gdb.cp/nsusing.exp index d76676fda9e1..7b1d3e5283a9 100644 --- a/gdb/testsuite/gdb.cp/nsusing.exp +++ b/gdb/testsuite/gdb.cp/nsusing.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } ############################################ # Test printing of namespace imported within the function. diff --git a/gdb/testsuite/gdb.cp/operator.exp b/gdb/testsuite/gdb.cp/operator.exp index 15dfee5a9fe1..1e22f8f74bff 100644 --- a/gdb/testsuite/gdb.cp/operator.exp +++ b/gdb/testsuite/gdb.cp/operator.exp @@ -15,11 +15,11 @@ standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug c++ additional_flags=-Wno-unused-comparison}] } { - return -1 + return } ############################################ if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/overload-const.exp b/gdb/testsuite/gdb.cp/overload-const.exp index a036aee6a6c8..442617848587 100644 --- a/gdb/testsuite/gdb.cp/overload-const.exp +++ b/gdb/testsuite/gdb.cp/overload-const.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $testfile.cc {c++ debug}]} { - return -1 + return } gdb_test_no_output "set language c++" if {[gdb_breakpoint "myclass::func"]} { diff --git a/gdb/testsuite/gdb.cp/overload.exp b/gdb/testsuite/gdb.cp/overload.exp index 5d586b19e244..9c0149bdfe05 100644 --- a/gdb/testsuite/gdb.cp/overload.exp +++ b/gdb/testsuite/gdb.cp/overload.exp @@ -27,11 +27,11 @@ set nl "\[\r\n\]+" require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # Set it up at a breakpoint so we can play with the variable values. if {![runto 'marker1']} { diff --git a/gdb/testsuite/gdb.cp/ovldbreak.exp b/gdb/testsuite/gdb.cp/ovldbreak.exp index a4e853e2986e..dce7d3b414b3 100644 --- a/gdb/testsuite/gdb.cp/ovldbreak.exp +++ b/gdb/testsuite/gdb.cp/ovldbreak.exp @@ -31,11 +31,11 @@ set timeout 15 require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # set it up at a breakpoint so we can play with the variable values # if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/ovsrch.exp b/gdb/testsuite/gdb.cp/ovsrch.exp index 4b8392395513..5fccdb43d4db 100644 --- a/gdb/testsuite/gdb.cp/ovsrch.exp +++ b/gdb/testsuite/gdb.cp/ovsrch.exp @@ -59,11 +59,11 @@ standard_testfile ovsrch1.cc ovsrch2.cc ovsrch3.cc ovsrch4.cc include_file ovsrch.h if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2 $srcfile3 $srcfile4] {c++ debug}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/paramless.exp b/gdb/testsuite/gdb.cp/paramless.exp index 65f4a461f6b7..4c9b6a8b8bdc 100644 --- a/gdb/testsuite/gdb.cp/paramless.exp +++ b/gdb/testsuite/gdb.cp/paramless.exp @@ -25,11 +25,11 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } foreach ordinary {"outer::fn" "outer::fn" "toplev"} { gdb_breakpoint $ordinary message clean_restart $testfile diff --git a/gdb/testsuite/gdb.cp/paren-type.exp b/gdb/testsuite/gdb.cp/paren-type.exp index fef63979cff7..16df250c61bb 100644 --- a/gdb/testsuite/gdb.cp/paren-type.exp +++ b/gdb/testsuite/gdb.cp/paren-type.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${testfile}.cc {c++ debug}] } { - return -1 + return } gdb_test_no_output "set breakpoint pending off" gdb_test "break C::f(long)" {Function "C::f\(long\)" not defined\.} diff --git a/gdb/testsuite/gdb.cp/parse-lang.exp b/gdb/testsuite/gdb.cp/parse-lang.exp index 04504a091b0b..0b1d2b6bcf1a 100644 --- a/gdb/testsuite/gdb.cp/parse-lang.exp +++ b/gdb/testsuite/gdb.cp/parse-lang.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # Place the breakpoint before inferior gets started. Then the breakpoint # condition will be re-evaluated in non-C++ startup code. gdb_breakpoint "C::m if v == 42" diff --git a/gdb/testsuite/gdb.cp/pass-by-ref-2.exp b/gdb/testsuite/gdb.cp/pass-by-ref-2.exp index e4c56ee2b7ec..3d7046359010 100644 --- a/gdb/testsuite/gdb.cp/pass-by-ref-2.exp +++ b/gdb/testsuite/gdb.cp/pass-by-ref-2.exp @@ -29,15 +29,15 @@ require allow_cplus_tests standard_testfile .cc set options {debug c++ additional_flags=-std=c++11} if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # GCC version <= 6 and Clang do not emit DW_AT_defaulted and DW_AT_deleted. set is_gcc_6_or_older [test_compiler_info {gcc-[0-6]-*}] set is_clang [test_compiler_info {clang-*}] diff --git a/gdb/testsuite/gdb.cp/pass-by-ref.exp b/gdb/testsuite/gdb.cp/pass-by-ref.exp index fde95d4d0a4e..66bc4b356582 100644 --- a/gdb/testsuite/gdb.cp/pass-by-ref.exp +++ b/gdb/testsuite/gdb.cp/pass-by-ref.exp @@ -334,15 +334,15 @@ set program [generate_program $classes $stmts] set srcfile [standard_output_file ${srcfile}] gdb_produce_source $srcfile $program set options {debug c++ additional_flags=-std=c++11} if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options]} { - return -1 + return } if {![runto_main]} { - return -1 + return } set bp_location [gdb_get_line_number "stop here"] gdb_breakpoint $bp_location gdb_continue_to_breakpoint "end of main" ".*return .*;" diff --git a/gdb/testsuite/gdb.cp/pointer-to-member.exp b/gdb/testsuite/gdb.cp/pointer-to-member.exp index 5370cdbed18c..d2d04b27ae27 100644 --- a/gdb/testsuite/gdb.cp/pointer-to-member.exp +++ b/gdb/testsuite/gdb.cp/pointer-to-member.exp @@ -20,9 +20,9 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } gdb_test "print ptm" " = &A::i" diff --git a/gdb/testsuite/gdb.cp/pr-1023.exp b/gdb/testsuite/gdb.cp/pr-1023.exp index 5e15b649c777..e524e88bb39c 100644 --- a/gdb/testsuite/gdb.cp/pr-1023.exp +++ b/gdb/testsuite/gdb.cp/pr-1023.exp @@ -25,11 +25,11 @@ require allow_cplus_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/pr-1210.exp b/gdb/testsuite/gdb.cp/pr-1210.exp index cf42f58b228e..c215d0f1a918 100644 --- a/gdb/testsuite/gdb.cp/pr-1210.exp +++ b/gdb/testsuite/gdb.cp/pr-1210.exp @@ -24,11 +24,11 @@ require allow_cplus_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/pr-574.exp b/gdb/testsuite/gdb.cp/pr-574.exp index 1952463063fe..4312eebb0677 100644 --- a/gdb/testsuite/gdb.cp/pr-574.exp +++ b/gdb/testsuite/gdb.cp/pr-574.exp @@ -33,11 +33,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } { # Work around PR gcc/101452. lappend flags additional_flags=-fno-eliminate-unused-debug-types } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/pr10687.exp b/gdb/testsuite/gdb.cp/pr10687.exp index b27de9720887..c2063f975ae3 100644 --- a/gdb/testsuite/gdb.cp/pr10687.exp +++ b/gdb/testsuite/gdb.cp/pr10687.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/pr12028.exp b/gdb/testsuite/gdb.cp/pr12028.exp index b656a88975d5..f4e0aefb0d46 100644 --- a/gdb/testsuite/gdb.cp/pr12028.exp +++ b/gdb/testsuite/gdb.cp/pr12028.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } ############################################ if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/pr17132.exp b/gdb/testsuite/gdb.cp/pr17132.exp index 3492425534a4..06d329c81fd7 100644 --- a/gdb/testsuite/gdb.cp/pr17132.exp +++ b/gdb/testsuite/gdb.cp/pr17132.exp @@ -18,15 +18,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break here" diff --git a/gdb/testsuite/gdb.cp/pr17494.exp b/gdb/testsuite/gdb.cp/pr17494.exp index 33bc4831239f..ab23e1133823 100644 --- a/gdb/testsuite/gdb.cp/pr17494.exp +++ b/gdb/testsuite/gdb.cp/pr17494.exp @@ -18,15 +18,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "Break here" diff --git a/gdb/testsuite/gdb.cp/pr9067.exp b/gdb/testsuite/gdb.cp/pr9067.exp index 43f4aa75796f..043690123f88 100644 --- a/gdb/testsuite/gdb.cp/pr9067.exp +++ b/gdb/testsuite/gdb.cp/pr9067.exp @@ -20,11 +20,11 @@ require allow_cplus_tests load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/pr9167.exp b/gdb/testsuite/gdb.cp/pr9167.exp index d1ceb6a4b9a1..8ae4356a6dad 100644 --- a/gdb/testsuite/gdb.cp/pr9167.exp +++ b/gdb/testsuite/gdb.cp/pr9167.exp @@ -20,11 +20,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } { # Work around PR gcc/101452. lappend flags additional_flags=-fno-eliminate-unused-debug-types } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/pr9631.exp b/gdb/testsuite/gdb.cp/pr9631.exp index f0b4fb5dc220..71cdda50d985 100644 --- a/gdb/testsuite/gdb.cp/pr9631.exp +++ b/gdb/testsuite/gdb.cp/pr9631.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/print-demangle.exp b/gdb/testsuite/gdb.cp/print-demangle.exp index 98c0167d42dd..9065adc3eac4 100644 --- a/gdb/testsuite/gdb.cp/print-demangle.exp +++ b/gdb/testsuite/gdb.cp/print-demangle.exp @@ -16,11 +16,11 @@ require allow_cplus_tests standard_testfile bool.cc if {[prepare_for_testing $testfile.exp $testfile $srcfile {debug c++}]} { - return -1 + return } runto_main gdb_breakpoint "return_true" diff --git a/gdb/testsuite/gdb.cp/print-global-stub.exp b/gdb/testsuite/gdb.cp/print-global-stub.exp index df29bb61ee93..f82df5931da3 100644 --- a/gdb/testsuite/gdb.cp/print-global-stub.exp +++ b/gdb/testsuite/gdb.cp/print-global-stub.exp @@ -23,11 +23,11 @@ set testfile $testfile.o set binfile [standard_output_file $testfile] if { [gdb_compile $srcdir/$subdir/$srcfile $binfile object \ {c++ debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile gdb_test "print s" " = " diff --git a/gdb/testsuite/gdb.cp/print-method-args.exp b/gdb/testsuite/gdb.cp/print-method-args.exp index dd9cb8be748b..17f4204c44a8 100644 --- a/gdb/testsuite/gdb.cp/print-method-args.exp +++ b/gdb/testsuite/gdb.cp/print-method-args.exp @@ -20,11 +20,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } set re \ [multi_line \ "type = class A {" \ diff --git a/gdb/testsuite/gdb.cp/printmethod.exp b/gdb/testsuite/gdb.cp/printmethod.exp index bad147b874d6..fdc1c91bf232 100644 --- a/gdb/testsuite/gdb.cp/printmethod.exp +++ b/gdb/testsuite/gdb.cp/printmethod.exp @@ -26,11 +26,11 @@ require allow_cplus_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/psmang.exp b/gdb/testsuite/gdb.cp/psmang.exp index bd51b8b03a34..d29b51f867eb 100644 --- a/gdb/testsuite/gdb.cp/psmang.exp +++ b/gdb/testsuite/gdb.cp/psmang.exp @@ -180,11 +180,11 @@ require allow_cplus_tests standard_testfile psmang1.cc psmang2.cc if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}]} { - return -1 + return } gdb_test "break s::method1" "Breakpoint .* at .*: file .*psmang1.cc.*" # We have to exit and restart GDB here, to make sure that all the diff --git a/gdb/testsuite/gdb.cp/psymtab-parameter.exp b/gdb/testsuite/gdb.cp/psymtab-parameter.exp index 9412945fb099..aac95195922e 100644 --- a/gdb/testsuite/gdb.cp/psymtab-parameter.exp +++ b/gdb/testsuite/gdb.cp/psymtab-parameter.exp @@ -17,11 +17,11 @@ require allow_cplus_tests standard_testfile .cc if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}.x" object {debug c++}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $testfile.x # As `main' is not present GDB fails to find the proper inferior language. diff --git a/gdb/testsuite/gdb.cp/ptype-cv-cp.exp b/gdb/testsuite/gdb.cp/ptype-cv-cp.exp index c0129a71f55b..bfc6e176cc17 100644 --- a/gdb/testsuite/gdb.cp/ptype-cv-cp.exp +++ b/gdb/testsuite/gdb.cp/ptype-cv-cp.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } gdb_test "whatis v_my_int" "type = my_int" gdb_test "ptype v_my_int" "type = int" diff --git a/gdb/testsuite/gdb.cp/ptype-flags.exp b/gdb/testsuite/gdb.cp/ptype-flags.exp index c97c8b436de1..4530f99a50cf 100644 --- a/gdb/testsuite/gdb.cp/ptype-flags.exp +++ b/gdb/testsuite/gdb.cp/ptype-flags.exp @@ -20,11 +20,11 @@ require allow_cplus_tests load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/re-set-overloaded.exp b/gdb/testsuite/gdb.cp/re-set-overloaded.exp index d63be344252d..e5492c67c6ed 100644 --- a/gdb/testsuite/gdb.cp/re-set-overloaded.exp +++ b/gdb/testsuite/gdb.cp/re-set-overloaded.exp @@ -20,11 +20,11 @@ standard_testfile bool.cc .cc set sofile [standard_output_file ${testfile}.so] if { [gdb_compile_shlib $srcdir/$subdir/$srcfile2 $sofile {debug c++}] != "" || [gdb_compile $srcdir/$subdir/$srcfile $binfile executable [list debug "c++" shlib=${sofile}]] != ""} { untested "failed to compile" - return -1 + return } clean_restart $testfile gdb_load_shlib ${sofile} diff --git a/gdb/testsuite/gdb.cp/readnow-language.exp b/gdb/testsuite/gdb.cp/readnow-language.exp index 73199bf15a15..fb4e62805397 100644 --- a/gdb/testsuite/gdb.cp/readnow-language.exp +++ b/gdb/testsuite/gdb.cp/readnow-language.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if {[build_executable ${testfile}.exp $testfile ${testfile}.cc {c++ debug}] == -1} { - return -1 + return } save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS -readnow" clean_restart $testfile diff --git a/gdb/testsuite/gdb.cp/ref-params.exp b/gdb/testsuite/gdb.cp/ref-params.exp index 31144fcba213..0238d938dc14 100644 --- a/gdb/testsuite/gdb.cp/ref-params.exp +++ b/gdb/testsuite/gdb.cp/ref-params.exp @@ -23,11 +23,11 @@ require allow_cplus_tests standard_testfile .cc if {[build_executable $testfile.exp $testfile $srcfile {debug c++}] == -1} { - return -1 + return } proc gdb_start_again { text } { global binfile global srcfile diff --git a/gdb/testsuite/gdb.cp/ref-types.exp b/gdb/testsuite/gdb.cp/ref-types.exp index d56d10ea4bb4..b55b6ffe7f6f 100644 --- a/gdb/testsuite/gdb.cp/ref-types.exp +++ b/gdb/testsuite/gdb.cp/ref-types.exp @@ -23,11 +23,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # # set it up at a breakpoint so we can play with the variable values # diff --git a/gdb/testsuite/gdb.cp/rtti.exp b/gdb/testsuite/gdb.cp/rtti.exp index b694ab935e34..7fe140c5c58e 100644 --- a/gdb/testsuite/gdb.cp/rtti.exp +++ b/gdb/testsuite/gdb.cp/rtti.exp @@ -36,11 +36,11 @@ standard_testfile rtti1.cc rtti2.cc include_file rtti.h if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/rvalue-ref-casts.exp b/gdb/testsuite/gdb.cp/rvalue-ref-casts.exp index a73708d92112..360037912186 100644 --- a/gdb/testsuite/gdb.cp/rvalue-ref-casts.exp +++ b/gdb/testsuite/gdb.cp/rvalue-ref-casts.exp @@ -21,15 +21,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing $testfile.exp $testfile $srcfile \ {debug c++ additional_flags="-std=gnu++11"}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Prevent symbol on address 0x0 being printed. gdb_test_no_output "set print symbol off" diff --git a/gdb/testsuite/gdb.cp/rvalue-ref-overload.exp b/gdb/testsuite/gdb.cp/rvalue-ref-overload.exp index b9da32c244e4..6083606567a0 100644 --- a/gdb/testsuite/gdb.cp/rvalue-ref-overload.exp +++ b/gdb/testsuite/gdb.cp/rvalue-ref-overload.exp @@ -24,18 +24,18 @@ load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing $testfile.exp $testfile $srcfile \ {debug c++ additional_flags="-std=gnu++11"}]} { - return -1 + return } # Set it up at a breakpoint so we can play with the variable values. if {![runto 'marker1']} { untested "couldn't run to marker1" - return -1 + return } # Prevent symbol on address 0x0 being printed. gdb_test_no_output "set print symbol off" gdb_test "up" ".*main.*" "up from marker1" diff --git a/gdb/testsuite/gdb.cp/rvalue-ref-params.exp b/gdb/testsuite/gdb.cp/rvalue-ref-params.exp index 6b4c891cef3d..a4c7156bda7b 100644 --- a/gdb/testsuite/gdb.cp/rvalue-ref-params.exp +++ b/gdb/testsuite/gdb.cp/rvalue-ref-params.exp @@ -20,11 +20,11 @@ require allow_cplus_tests standard_testfile .cc if {[build_executable $testfile.exp $testfile $srcfile \ {debug c++ additional_flags="-std=gnu++11"}] == -1} { - return -1 + return } proc gdb_start_again {text prefix} { global binfile global srcfile diff --git a/gdb/testsuite/gdb.cp/rvalue-ref-types.exp b/gdb/testsuite/gdb.cp/rvalue-ref-types.exp index e251efebf35f..af10ce37b7f1 100644 --- a/gdb/testsuite/gdb.cp/rvalue-ref-types.exp +++ b/gdb/testsuite/gdb.cp/rvalue-ref-types.exp @@ -20,22 +20,22 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing $testfile.exp $testfile $srcfile \ {debug c++ additional_flags="-std=gnu++11"}]} { - return -1 + return } # # Set it up at a breakpoint so we can play with the variable values. # if {![runto_main]} { - return -1 + return } if {![runto 'marker1']} { - return -1 + return } gdb_test "up" ".*main.*" "up from marker1 1" gdb_test "print rrt" " = \\(short( int)? &&\\) @$hex: -1" "print value of rrt" diff --git a/gdb/testsuite/gdb.cp/save-bp-qualified.exp b/gdb/testsuite/gdb.cp/save-bp-qualified.exp index a6ee09c6cdcb..a6851ba96623 100644 --- a/gdb/testsuite/gdb.cp/save-bp-qualified.exp +++ b/gdb/testsuite/gdb.cp/save-bp-qualified.exp @@ -16,11 +16,11 @@ # Test "save breakpoints" + "break -qualified". standard_testfile .cc if { [build_executable "failed to prepare" ${testfile} $srcfile {debug c++}] } { - return -1 + return } proc restart {} { global testfile diff --git a/gdb/testsuite/gdb.cp/scope-err.exp b/gdb/testsuite/gdb.cp/scope-err.exp index 3e2591402119..236928d84903 100644 --- a/gdb/testsuite/gdb.cp/scope-err.exp +++ b/gdb/testsuite/gdb.cp/scope-err.exp @@ -20,15 +20,15 @@ require allow_cplus_tests standard_testfile .cc set exefile $testfile if {[prepare_for_testing "failed to prepare" $exefile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return 0 + return } # Run to a location in the file. set bp_location [gdb_get_line_number "set breakpoint here"] diff --git a/gdb/testsuite/gdb.cp/shadow.exp b/gdb/testsuite/gdb.cp/shadow.exp index 1fed09a366c9..d095f85324ad 100644 --- a/gdb/testsuite/gdb.cp/shadow.exp +++ b/gdb/testsuite/gdb.cp/shadow.exp @@ -18,11 +18,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/static-method.exp b/gdb/testsuite/gdb.cp/static-method.exp index 527352f4ac4a..7ab795d0115d 100644 --- a/gdb/testsuite/gdb.cp/static-method.exp +++ b/gdb/testsuite/gdb.cp/static-method.exp @@ -41,11 +41,11 @@ require allow_cplus_tests # Tests for c++/12750 standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}]} { - return -1 + return } # The GDB workaround for GCC PR debug/45682 does not apply as it requires # DW_AT_linkage_name of methods. The whole class A is in anonymous namespace, # therefore not accessible outside of the CU (compilation unit) and therefore diff --git a/gdb/testsuite/gdb.cp/static-print-quit.exp b/gdb/testsuite/gdb.cp/static-print-quit.exp index 088abb9b9f8e..19756f64732e 100644 --- a/gdb/testsuite/gdb.cp/static-print-quit.exp +++ b/gdb/testsuite/gdb.cp/static-print-quit.exp @@ -17,11 +17,11 @@ require allow_cplus_tests standard_testfile .cc if { [gdb_compile $srcdir/$subdir/$srcfile $binfile.o object {debug c++}] != ""} { untested "failed to compile" - return -1 + return } clean_restart $testfile.o gdb_test_no_output "set width 80" diff --git a/gdb/testsuite/gdb.cp/static-typedef-print.exp b/gdb/testsuite/gdb.cp/static-typedef-print.exp index 2d0b9869725a..579ddf671688 100644 --- a/gdb/testsuite/gdb.cp/static-typedef-print.exp +++ b/gdb/testsuite/gdb.cp/static-typedef-print.exp @@ -16,15 +16,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print a" \ "static INSTANCE = }}.*" \ "print static member" diff --git a/gdb/testsuite/gdb.cp/step-and-next-inline.exp b/gdb/testsuite/gdb.cp/step-and-next-inline.exp index 08694a67afbf..e8bb998231b4 100644 --- a/gdb/testsuite/gdb.cp/step-and-next-inline.exp +++ b/gdb/testsuite/gdb.cp/step-and-next-inline.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if {[test_compiler_info gcc*] && ![supports_statement_frontiers] } { - return -1 + return } # Compile the test source with USE_NEXT_INLINE_H defined (when # use_header is true), or not defined. proc do_test { use_header } { diff --git a/gdb/testsuite/gdb.cp/stub-array-size.exp b/gdb/testsuite/gdb.cp/stub-array-size.exp index 527f74fe8e26..fab9754dcc9c 100644 --- a/gdb/testsuite/gdb.cp/stub-array-size.exp +++ b/gdb/testsuite/gdb.cp/stub-array-size.exp @@ -24,9 +24,9 @@ standard_testfile .cc stub-array-size2.cc include_file stub-array-size.h if {[prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" \ {c++ debug}]} { - return -1 + return } gdb_test "print sizeof(a)/sizeof(a\[0\])" "10" diff --git a/gdb/testsuite/gdb.cp/subtypes.exp b/gdb/testsuite/gdb.cp/subtypes.exp index 31c8c2264928..187bd494902a 100644 --- a/gdb/testsuite/gdb.cp/subtypes.exp +++ b/gdb/testsuite/gdb.cp/subtypes.exp @@ -25,11 +25,11 @@ standard_testfile .cc subtypes-2.cc include_file subtypes.h if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] \ {debug c++ additional_flags=-std=c++11}]} { - return -1 + return } # Xfail for superfluous DW_TAG_lexical_block, gcc PR debug/55541. set have_xfail [expr {[test_compiler_info gcc-*] && [gcc_major_version] < 5}] diff --git a/gdb/testsuite/gdb.cp/temargs.exp b/gdb/testsuite/gdb.cp/temargs.exp index eb1d987c6747..ff4ae3bf5747 100644 --- a/gdb/testsuite/gdb.cp/temargs.exp +++ b/gdb/testsuite/gdb.cp/temargs.exp @@ -21,15 +21,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug c++ additional_flags=-std=c++11}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # gcc 4.4 and earlier don't emit enough info for some of our template tests. set have_older_template_gcc 0 set have_pr_41736_fixed 1 diff --git a/gdb/testsuite/gdb.cp/templates.exp b/gdb/testsuite/gdb.cp/templates.exp index 3531b231e5df..044190f1fac0 100644 --- a/gdb/testsuite/gdb.cp/templates.exp +++ b/gdb/testsuite/gdb.cp/templates.exp @@ -28,11 +28,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } { # Work around PR gcc/101452. lappend flags additional_flags=-DGCC_BUG } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} { - return -1 + return } # # Test printing of the types of templates. # diff --git a/gdb/testsuite/gdb.cp/try_catch.exp b/gdb/testsuite/gdb.cp/try_catch.exp index 6a8e68834773..663f42a9c0e3 100644 --- a/gdb/testsuite/gdb.cp/try_catch.exp +++ b/gdb/testsuite/gdb.cp/try_catch.exp @@ -25,11 +25,11 @@ require allow_stl_tests # standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/typed-enum.exp b/gdb/testsuite/gdb.cp/typed-enum.exp index 7fc3759ef02e..a2021abd64cb 100644 --- a/gdb/testsuite/gdb.cp/typed-enum.exp +++ b/gdb/testsuite/gdb.cp/typed-enum.exp @@ -23,10 +23,10 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } gdb_test "print (int)byte_val" "= 128" gdb_test "print (int)uchar_val" "= 128" diff --git a/gdb/testsuite/gdb.cp/typedef-base.exp b/gdb/testsuite/gdb.cp/typedef-base.exp index 97ce29f2a9c8..358b510e7f13 100644 --- a/gdb/testsuite/gdb.cp/typedef-base.exp +++ b/gdb/testsuite/gdb.cp/typedef-base.exp @@ -18,15 +18,15 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "ptype C::x" \ "type = int" \ "ptype typedef base struct member" diff --git a/gdb/testsuite/gdb.cp/typedef-operator.exp b/gdb/testsuite/gdb.cp/typedef-operator.exp index 4e45dd8a4fb4..9513b3725dc7 100644 --- a/gdb/testsuite/gdb.cp/typedef-operator.exp +++ b/gdb/testsuite/gdb.cp/typedef-operator.exp @@ -18,17 +18,17 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}]} { - return -1 + return } gdb_test_no_output "set language c++" gdb_test "p *u" {You can't do that without a process to debug.} "test crash" if {![runto_main]} { - return -1 + return } gdb_test "p *v" " = 42" "test typedef" diff --git a/gdb/testsuite/gdb.cp/typeid.exp b/gdb/testsuite/gdb.cp/typeid.exp index 06ba7468c758..4587ec0199ec 100644 --- a/gdb/testsuite/gdb.cp/typeid.exp +++ b/gdb/testsuite/gdb.cp/typeid.exp @@ -16,11 +16,11 @@ standard_testfile .cc require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } proc do_typeid_tests {started} { global hex @@ -81,11 +81,11 @@ proc do_typeid_tests {started} { with_test_prefix "before starting" { do_typeid_tests 0 } if {![runto_main]} { - return -1 + return } with_test_prefix "after starting" { do_typeid_tests 1 } diff --git a/gdb/testsuite/gdb.cp/userdef.exp b/gdb/testsuite/gdb.cp/userdef.exp index 68362fed2b0a..01182c4a9f15 100644 --- a/gdb/testsuite/gdb.cp/userdef.exp +++ b/gdb/testsuite/gdb.cp/userdef.exp @@ -22,11 +22,11 @@ require allow_stl_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/using-crash.exp b/gdb/testsuite/gdb.cp/using-crash.exp index 8334006f7c31..1f5e4ce7eb43 100644 --- a/gdb/testsuite/gdb.cp/using-crash.exp +++ b/gdb/testsuite/gdb.cp/using-crash.exp @@ -13,11 +13,11 @@ # along with this program. If not, see . standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } runto "foo" # This would cause reading debug info with using_directives pointing to diff --git a/gdb/testsuite/gdb.cp/var-tag.exp b/gdb/testsuite/gdb.cp/var-tag.exp index 676b36943d2f..c1b1158a4b57 100644 --- a/gdb/testsuite/gdb.cp/var-tag.exp +++ b/gdb/testsuite/gdb.cp/var-tag.exp @@ -21,11 +21,11 @@ require allow_cplus_tests standard_testfile var-tag.cc var-tag-2.cc var-tag-3.cc var-tag-4.cc if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2 $srcfile3 $srcfile4] {debug c++}]} { - return -1 + return } proc do_global_tests {lang} { set invalid_print "Attempt to use a type name as an expression" diff --git a/gdb/testsuite/gdb.cp/virtbase.exp b/gdb/testsuite/gdb.cp/virtbase.exp index b0c43fa87eaf..530587ac775d 100644 --- a/gdb/testsuite/gdb.cp/virtbase.exp +++ b/gdb/testsuite/gdb.cp/virtbase.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/virtbase2.exp b/gdb/testsuite/gdb.cp/virtbase2.exp index ae0424142f78..635635a0d282 100644 --- a/gdb/testsuite/gdb.cp/virtbase2.exp +++ b/gdb/testsuite/gdb.cp/virtbase2.exp @@ -18,11 +18,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/virtfunc.exp b/gdb/testsuite/gdb.cp/virtfunc.exp index 21e300e4ffc9..eecf4611e233 100644 --- a/gdb/testsuite/gdb.cp/virtfunc.exp +++ b/gdb/testsuite/gdb.cp/virtfunc.exp @@ -23,11 +23,11 @@ require allow_cplus_tests load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } proc test_ptype_of_classes {} { # class VA diff --git a/gdb/testsuite/gdb.cp/virtfunc2.exp b/gdb/testsuite/gdb.cp/virtfunc2.exp index 761453f6227e..6d4b83e7ba42 100644 --- a/gdb/testsuite/gdb.cp/virtfunc2.exp +++ b/gdb/testsuite/gdb.cp/virtfunc2.exp @@ -23,11 +23,11 @@ require allow_cplus_tests load_lib "cp-support.exp" standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/vla-cxx.exp b/gdb/testsuite/gdb.cp/vla-cxx.exp index 6fe42422c9fd..3e32cb96538e 100644 --- a/gdb/testsuite/gdb.cp/vla-cxx.exp +++ b/gdb/testsuite/gdb.cp/vla-cxx.exp @@ -18,15 +18,15 @@ standard_testfile .cc set flags {} lappend flags debug lappend flags c++ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $flags] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Before pointer assignment"] gdb_continue_to_breakpoint "Before pointer assignment" diff --git a/gdb/testsuite/gdb.cp/watch-cp.exp b/gdb/testsuite/gdb.cp/watch-cp.exp index 31a66864fe3a..906002b754f6 100644 --- a/gdb/testsuite/gdb.cp/watch-cp.exp +++ b/gdb/testsuite/gdb.cp/watch-cp.exp @@ -16,11 +16,11 @@ require allow_cplus_tests allow_hw_watchpoint_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } From patchwork Wed Apr 29 23:04:08 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134207 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 47F8D4B920D5 for ; Wed, 29 Apr 2026 23:07:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 47F8D4B920D5 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=JTjXemSC X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x936.google.com (mail-ua1-x936.google.com [IPv6:2607:f8b0:4864:20::936]) by sourceware.org (Postfix) with ESMTPS id 1A4604BB58A9 for ; Wed, 29 Apr 2026 23:05:38 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1A4604BB58A9 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1A4604BB58A9 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::936 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503938; cv=none; b=ReY0IRx3AmUMRVbhe5AwdltPxip1mKH1i2IBViS4lhaQ/3dDW1CVBlzz74dBr2nMKOG8NUi3cyFOY3Qssesy8K/sG+ODrXA1VH8v3tOXCUKZVEuxvzRFSRRamPt4LK9F8NLH4d2b2CMzmqw6fBhM3f4cuYTRWJd+glWqlLob7oM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503938; c=relaxed/simple; bh=sniron1aT3HrECpDMGArjbCUoORWoEifLejXUHmq14g=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=BnqMo+OUhYo3ynR7xLZB0wGbKkp3GTfnG+iAnFPff8E47Ivsw/WC5RYrJDrQ//2/k+EpFg04AZ55N6Y9z9bBxCCOlI6M39liYAKh9+QwaKW7I65wk/A0S0zOwXxyuuLH88uoM95St+lvcQdqvfPZdLDeJv2Vpy4nnu8vh9fJTMA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1A4604BB58A9 Received: by mail-ua1-x936.google.com with SMTP id a1e0cc1a2514c-9568bae58f7so191372241.3 for ; Wed, 29 Apr 2026 16:05:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503937; x=1778108737; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=JMIeKPOfnmuWM/xSSG0I6UyNGzZT1rARoB545Xhyt+Y=; b=JTjXemSCTZO0swm5P7oMMnqRgMRyYrwyCoLoRJTYGaUjnSiRXPrxeL2jKzuyPCBTOv 79ORF0OPSPYJjUtMhXtgO4oIfAWB3mN+7DjPqEefV78jr5cc6bWuzk2cT/dCD6+ef8zh obMvkGPZ/5GnyjtYuHazgClMiX4W6dHx9u34buwLRGNppieLHIL58IV1NpC0rpIdnd4G 0O4JvqvDOm4lhB3Z2bL0R8BVZNZfCUndgCWdcKHDQ4JeY7EzXBDz6wgUaU8wPdI9lE/0 6hI8Rs03QT5pWBIubUtdNPiRBy5JsbK/Mydb6QJFbzv33WhCDsq9dQbHe53Yhnj+oRuU 9Fgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503937; x=1778108737; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=JMIeKPOfnmuWM/xSSG0I6UyNGzZT1rARoB545Xhyt+Y=; b=Jd6ayhUrsXMqSDigFpEpT5k2r1KNWl7sHG+VikPmx5PHae9u6txn+5EQKhPdiiXUf8 nXUqoBcn6EKuyrp0UdltL9Zni96yj/TNk732QMNWuQJyJjTC8kSDHiITb7kXws3UtjY+ IERP1E6iTCVrsMpNzN3YostlRK7fIoVsef09w+FD3DeJ4GG3l0ZgJ4D06zVbP+oHyFQP a6v67tkMDuuamulXKjdwskRRZqHdxJbllhNLvJJ1KvM4JuDQCWIDUSWaW7weOu0Ro+vY lXR4cjKZIs9q9WO/HvDQWWSs1lqV48Snhv2484vwdMNh5gJj3H5sUPQaaUgK+o/umYL4 gbTg== X-Gm-Message-State: AOJu0YwI7/zUW/w6DhMNfKnqpWtDkWKVFMdyDRfbEMST74uLLmw05PQ2 Ds1K6LJD6SuLSD82VjDXPUpzrQONr+nxDQZb94nTPraRigwEeRDfunX7XXjbYcwOLNYG6Ukt60U 7kR+q X-Gm-Gg: AeBDiev8/CeORn5gPA1lnoiHI7dv10B8X9f7gC3pxPNeDxIgXriGSJ6aR+4idZv2r96 1WEagURhLJiQElEx7E05P8GSAsJ/JrQOPyzJNTQM40EpwS0FaF4MMwTp5L8Gny1DQ1iMkEUNVZt P8pvsxzpdT/SYmfSv3fbCU1dTAv5jds+p+t6kd6BZmCxeobJj6V/SE6jh4Nzb5Uoq68TIdCjpmH FC9oz/XpGcCAJMoAqXo680D1NxSnOk5swliD4sAN8dO8To6ayLrUxLGA0SpkKesuXBgz8stRAX2 VPMFYiRuQV0/QgOFKGBiv0/NwopzHzAhXXeTSUjnkNM+WfUzbCsr0Y6m2qi7ha8QW748PAGeplF rjIyR87Ufa06DOBWkqWUmxtgmmXkYf/G+RsdpLXoCW7EkJhhGJG89/ElEspN1emKYMnP0fR4UpJ qQz3AKdQ2hUxTGFUbt7MQrRTlS7xo+cfLTpnWvTGQZKGR/ X-Received: by 2002:a05:6102:2acd:b0:612:164e:ab02 with SMTP id ada2fe7eead31-62ad1d38cb4mr324270137.5.1777503937393; Wed, 29 Apr 2026 16:05:37 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb75c4030sm1925092241.4.2026.04.29.16.05.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:36 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 17/37] GDB: testsuite: C++: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:08 -0300 Message-ID: <20260429230432.60487-18-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" and "return 0" statements that weren't caught by the sed command. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside block such as save_vars, with_test_prefix, foreach, gdb_test_multiple. Some weren't changed because they didn't meet the criteria above, or weren't trivial to check. --- gdb/testsuite/gdb.cp/anon-struct.exp | 2 +- gdb/testsuite/gdb.cp/converts.exp | 2 +- gdb/testsuite/gdb.cp/cp-relocate.exp | 8 ++++---- gdb/testsuite/gdb.cp/cpsizeof.exp | 2 +- gdb/testsuite/gdb.cp/expand-psymtabs-cxx.exp | 4 ++-- gdb/testsuite/gdb.cp/fpointer.exp | 2 +- gdb/testsuite/gdb.cp/koenig.exp | 2 +- gdb/testsuite/gdb.cp/method2.exp | 2 +- gdb/testsuite/gdb.cp/nsnested.exp | 2 +- gdb/testsuite/gdb.cp/nsnoimports.exp | 2 +- gdb/testsuite/gdb.cp/oranking.exp | 2 +- gdb/testsuite/gdb.cp/pr10728.exp | 12 ++++++------ gdb/testsuite/gdb.cp/rvalue-ref-sizeof.exp | 2 +- gdb/testsuite/gdb.cp/save-bp-qualified.exp | 4 ++-- gdb/testsuite/gdb.cp/smartp.exp | 2 +- gdb/testsuite/gdb.cp/static-print-quit.exp | 2 +- 16 files changed, 26 insertions(+), 26 deletions(-) diff --git a/gdb/testsuite/gdb.cp/anon-struct.exp b/gdb/testsuite/gdb.cp/anon-struct.exp index e420d75207fd..10b7ce6c7766 100644 --- a/gdb/testsuite/gdb.cp/anon-struct.exp +++ b/gdb/testsuite/gdb.cp/anon-struct.exp @@ -18,11 +18,11 @@ # for types and functions within anonymous structures. standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } # Clang doesn't add any names for functions within anonymous structures, # so there is no way to try and refer to them inside GDB. if {[test_compiler_info clang-*-* c++]} { diff --git a/gdb/testsuite/gdb.cp/converts.exp b/gdb/testsuite/gdb.cp/converts.exp index 7d26db9f3022..60a732f87ee0 100644 --- a/gdb/testsuite/gdb.cp/converts.exp +++ b/gdb/testsuite/gdb.cp/converts.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } ############################################ if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/cp-relocate.exp b/gdb/testsuite/gdb.cp/cp-relocate.exp index c42c67a95e75..67a9f21b9646 100644 --- a/gdb/testsuite/gdb.cp/cp-relocate.exp +++ b/gdb/testsuite/gdb.cp/cp-relocate.exp @@ -19,12 +19,12 @@ standard_testfile .cc append binfile .o require allow_cplus_tests if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {c++ debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc get_func_address { func } { global gdb_prompt hex @@ -65,11 +65,11 @@ gdb_test_multiple "info functions func<.>" "info functions" { -re "$gdb_prompt $" { if { ${func1_name} != "" && ${func2_name} != "" } { pass "info functions" } else { fail "info functions" - return -1 + return } } } # Check that all the functions have different addresses. @@ -103,11 +103,11 @@ gdb_test_multiple "info file" "info file" { -re "$gdb_prompt $" { if { ${func1_sec} != "" && ${func2_sec} != "" } { pass "info file" } else { fail "info file" - return -1 + return } } } if { $func1_sec == $func2_sec } { diff --git a/gdb/testsuite/gdb.cp/cpsizeof.exp b/gdb/testsuite/gdb.cp/cpsizeof.exp index a43ae6431acf..239811855791 100644 --- a/gdb/testsuite/gdb.cp/cpsizeof.exp +++ b/gdb/testsuite/gdb.cp/cpsizeof.exp @@ -17,11 +17,11 @@ standard_testfile .cc require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}] } { - return -1 + return } if {![runto_main]} { perror "could not run to main" return diff --git a/gdb/testsuite/gdb.cp/expand-psymtabs-cxx.exp b/gdb/testsuite/gdb.cp/expand-psymtabs-cxx.exp index 110970c89b8b..e0d34c86a11d 100644 --- a/gdb/testsuite/gdb.cp/expand-psymtabs-cxx.exp +++ b/gdb/testsuite/gdb.cp/expand-psymtabs-cxx.exp @@ -17,12 +17,12 @@ standard_testfile .cc set executable ${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {debug c++} ] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } clean_restart ${executable} gdb_test_no_output "set language c++" diff --git a/gdb/testsuite/gdb.cp/fpointer.exp b/gdb/testsuite/gdb.cp/fpointer.exp index a97eef7e55b6..f4f69a0532d6 100644 --- a/gdb/testsuite/gdb.cp/fpointer.exp +++ b/gdb/testsuite/gdb.cp/fpointer.exp @@ -17,11 +17,11 @@ # complex expressions. standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/koenig.exp b/gdb/testsuite/gdb.cp/koenig.exp index 474c4a95b41e..4fd755ad7b7c 100644 --- a/gdb/testsuite/gdb.cp/koenig.exp +++ b/gdb/testsuite/gdb.cp/koenig.exp @@ -20,11 +20,11 @@ lappend opts debug lappend opts c++ lappend opts additional_flags=-Wno-unused-comparison lappend opts additional_flags=-std=c++11 if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } ############################################ if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/method2.exp b/gdb/testsuite/gdb.cp/method2.exp index 4eed2197c36c..e64853ab7ae8 100644 --- a/gdb/testsuite/gdb.cp/method2.exp +++ b/gdb/testsuite/gdb.cp/method2.exp @@ -21,11 +21,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.cp/nsnested.exp b/gdb/testsuite/gdb.cp/nsnested.exp index 8c1cef585a8d..11b326fa9b9c 100644 --- a/gdb/testsuite/gdb.cp/nsnested.exp +++ b/gdb/testsuite/gdb.cp/nsnested.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } ############################################ if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.cp/nsnoimports.exp b/gdb/testsuite/gdb.cp/nsnoimports.exp index 3077e447c285..7c9e70ac3bf1 100644 --- a/gdb/testsuite/gdb.cp/nsnoimports.exp +++ b/gdb/testsuite/gdb.cp/nsnoimports.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } ############################################ if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.cp/oranking.exp b/gdb/testsuite/gdb.cp/oranking.exp index f7a2f4636227..1f418a96a7db 100644 --- a/gdb/testsuite/gdb.cp/oranking.exp +++ b/gdb/testsuite/gdb.cp/oranking.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } ############################################ if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/pr10728.exp b/gdb/testsuite/gdb.cp/pr10728.exp index 0625d243bd8f..2560325ae727 100644 --- a/gdb/testsuite/gdb.cp/pr10728.exp +++ b/gdb/testsuite/gdb.cp/pr10728.exp @@ -26,22 +26,22 @@ include_file pr10728-x.h set tfx [standard_output_file pr10728-x.o] set tfy [standard_output_file pr10728-y.o] if { [gdb_compile "${srcdir}/${subdir}/$srcfile2" "${tfy}.o" object {c++}] != "" } { - untested "failed to compile second object file" - return -1 + untested "failed to compile second object file" + return } if { [gdb_compile "${srcdir}/${subdir}/$srcfile" "${tfx}.o" object {debug c++}] != "" } { - untested "failed to compile first object file" - return -1 + untested "failed to compile first object file" + return } if { [gdb_compile "${tfx}.o ${tfy}.o" ${binfile} executable {debug c++}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } clean_restart $::testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/rvalue-ref-sizeof.exp b/gdb/testsuite/gdb.cp/rvalue-ref-sizeof.exp index a21485e215cb..ed15018b37ff 100644 --- a/gdb/testsuite/gdb.cp/rvalue-ref-sizeof.exp +++ b/gdb/testsuite/gdb.cp/rvalue-ref-sizeof.exp @@ -20,11 +20,11 @@ standard_testfile .cc require allow_cplus_tests if {[prepare_for_testing ${testfile}.exp $testfile $srcfile \ {debug c++ additional_flags="-std=gnu++11"}] } { - return -1 + return } if {![runto_main]} { perror "could not run to main" return diff --git a/gdb/testsuite/gdb.cp/save-bp-qualified.exp b/gdb/testsuite/gdb.cp/save-bp-qualified.exp index a6851ba96623..345290276628 100644 --- a/gdb/testsuite/gdb.cp/save-bp-qualified.exp +++ b/gdb/testsuite/gdb.cp/save-bp-qualified.exp @@ -36,11 +36,11 @@ proc restart {} { return 1 } with_test_prefix "save" { if {![restart]} { - return -1 + return } gdb_breakpoint "function" qualified gdb_breakpoint "function" @@ -54,11 +54,11 @@ with_test_prefix "save" { gdb_test "save breakpoint $bps" "" "save breakpoint bps" } with_test_prefix "restore" { if {![restart]} { - return -1 + return } # Restore the breakpoints. gdb_test "source $bps" "" "source bps" diff --git a/gdb/testsuite/gdb.cp/smartp.exp b/gdb/testsuite/gdb.cp/smartp.exp index 8a79f4385a9c..4c04a465e475 100644 --- a/gdb/testsuite/gdb.cp/smartp.exp +++ b/gdb/testsuite/gdb.cp/smartp.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .cc if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } { - return -1 + return } ############################################ if {![runto_main]} { diff --git a/gdb/testsuite/gdb.cp/static-print-quit.exp b/gdb/testsuite/gdb.cp/static-print-quit.exp index 19756f64732e..58f4f5283b30 100644 --- a/gdb/testsuite/gdb.cp/static-print-quit.exp +++ b/gdb/testsuite/gdb.cp/static-print-quit.exp @@ -32,11 +32,11 @@ gdb_test_multiple "print c" "" { pass $gdb_test_name } -re "\r\n$pagination_prompt$" { # gdb-7.1 did not crash with this testcase but it had the same bug. untested "bug does not reproduce" - return 0 + return } } gdb_test "q" ".*" From patchwork Wed Apr 29 23:04:09 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134225 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id DAFA24BA7995 for ; Wed, 29 Apr 2026 23:12:36 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DAFA24BA7995 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=GCsq4Olk X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x930.google.com (mail-ua1-x930.google.com [IPv6:2607:f8b0:4864:20::930]) by sourceware.org (Postfix) with ESMTPS id 18E714358A4F for ; Wed, 29 Apr 2026 23:05:44 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 18E714358A4F Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 18E714358A4F Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::930 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503944; cv=none; b=qf9PcWNglFnoeJXrIePUwzQJaKVpEo4gt4oDZe7xUwoLK8+yplMo79XUhJi2YHXW4sFgqh99JxMd1nNbJ9VDFiouul+IL7PK1o0QBjemtWb3ssXqPply8xnCNz8Fr1eDZDlqhBlLAhgTVOKYlOwJoJS5wTye3zcQU8OKcm++kJc= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503944; c=relaxed/simple; bh=re689DJnW5l8pN44lLSLYXU8pPTt83UFTVp4jBY/hCY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=SgCuYzHCOCWm8uI9fZUVrs5V3m5QnOf9L5BEx25xoEUZ53qCo3kp3YfEDfEY+t/EpyZ19yA2l0CSuzObtcnMTd+GcDau6PP73IVyXcbxReZiedxxawhRjksdAKaYD7W4VEkU1I3nATCZJgV2jo5BLyz5gMariFj3xNgcAXyBaMQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 18E714358A4F Received: by mail-ua1-x930.google.com with SMTP id a1e0cc1a2514c-94e578a0fa5so184762241.0 for ; Wed, 29 Apr 2026 16:05:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503943; x=1778108743; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=MNoREBayFiIn8UydG1RXJsvnoeb8FcEkiRK36kPM1U4=; b=GCsq4OlkpEZqi/53dH1P4PURJ1s36C6Lh1LwicfO1CC3ZfG1OSrmVJJUdobVkkjjQu uf42DeUx3xqLVq2BiJr5+qLPOryOTk90yjuE7r6Hl50mf2WL4dB7D38jMKD1/WjK9xgT h3niylN+xj2qZUMpZlMcUD2A+ctLHDKL+1Y/gENhTHyHM6ijI24loRfDNvkrzSos2dQU GcGFZuNaTzminbkaHKxLxPQiqeowvefrgqA9vuUPSFu7epWC46jddyTBbzsXWOGdTKEs Xpol/yfx4xoSJHqANXetRFJkACGHRpI0CwUWXXVP0MkeiQwOHLgKLi/UnogK8QlwN4T9 ySfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503943; x=1778108743; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=MNoREBayFiIn8UydG1RXJsvnoeb8FcEkiRK36kPM1U4=; b=Dv237/YIxjtnl1aXLb6/732wKHa86Wbjflz4JvMiRqsmhLXGGxpakR9TaJrIGBYZ7r nVzlJs5iSw+cbNDfDajUAL21OhqNqh6ug66BtTfzObNkUP4qeQ/D946q8Wd4o5LKzcHX w1wGheaU/k68/pSTC56GcQdy7twCcdmHVWkC4v9E29/w0HaCgZYITMlpbXhe1Z3xCAxY 5TPmTdV50Ig0PRnzn7uOTMSDhubpaUly3XbQp5s7TbarzORVMu2wjwQPID+AWk+6KP9e XNKO2JNpHDTxXx/3Tby51cUcnP5b+d3UxfXQgKUNVeIkn5eoX3EtNrQuvydvqIkan96J tmnQ== X-Gm-Message-State: AOJu0YzrqEgOR4yYqmzpzogBG79YS7+oddEneco8SYoV1sEW2usvyAOQ ugokD/3pfhty2keygtVK35qnc465nEgTq0BbpKpaFL5GE8CwuZ3B4rnpLfep00pxs31DDl9xtPU VX7LU X-Gm-Gg: AeBDietyXTZhaHbt/7eGN/RGvdZLMVoSocMz+hxvx7i00nEMjPts61UdFyoe5Qi53se ei6x+0wlu+Mq3hV7q4ONZ29qoRQasSJUJriiV6gvGapGKbnCp/4UFK5l6uo1OGFVyII1854K8Zj DZSKdGD10bAdaq3sPPJzFpPyXrJKF+m+rOkFRQn4tJsXL1UOhfb66ZgW4JcAZkCDXA9XsYE1aKv HvAkLxfMYvMFVMTrWNEU5m2z7R4Sl3DgMDcJKXNVe1lK41wtJ3Q6/BNjJf2Y5fW/azFVCPpkOMG LXeWJ/bS5zMBWXkmnIM3k6RppfcnutVn+C60uDc0/Q5eqb2RZlqFjiLpun+X4nRQBGp3Zo3B8Yv bI+drRNPC5LzwXPeMeBrUcufms8+iIlE76F922OW6dIO+Q1w+kkpmk2BvkEQoNeoUGs/WEusDw0 kzc9g/e3Rr0u2OzpwuZg+XEXk6MKQjdvhY6BJx2ShWTszl X-Received: by 2002:a05:6102:4415:b0:5ff:b8d8:b40b with SMTP id ada2fe7eead31-62ad2833d04mr308298137.11.1777503942434; Wed, 29 Apr 2026 16:05:42 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb7584bb1sm1750939241.2.2026.04.29.16.05.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:41 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 18/37] GDB: testsuite: DWARF: Don't return value from top-level (sed) Date: Wed, 29 Apr 2026 20:04:09 -0300 Message-ID: <20260429230432.60487-19-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* and $ sed -i 's/^ return 0/ return/' *.exp* inside gdb/testsuite/gdb.dwarf2. --- .../DW_OP_piece_with_DW_OP_GNU_uninit.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/ada-array-bound.exp | 2 +- gdb/testsuite/gdb.dwarf2/ada-cold-name.exp | 2 +- gdb/testsuite/gdb.dwarf2/ada-linkage-name.exp | 2 +- gdb/testsuite/gdb.dwarf2/ada-thick-pointer.exp | 2 +- gdb/testsuite/gdb.dwarf2/ada-valprint-error.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/anon-ns-fn.exp | 2 +- gdb/testsuite/gdb.dwarf2/arr-opt-out.exp | 2 +- gdb/testsuite/gdb.dwarf2/arr-stride.exp | 2 +- gdb/testsuite/gdb.dwarf2/arr-subrange.exp | 2 +- gdb/testsuite/gdb.dwarf2/atomic-type.exp | 2 +- .../gdb.dwarf2/backward-spec-inter-cu.exp | 2 +- gdb/testsuite/gdb.dwarf2/bad-regnum.exp | 4 ++-- .../gdb.dwarf2/bitfield-parent-optimized-out.exp | 4 ++-- .../gdb.dwarf2/break-inline-psymtab.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/callframecfa.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/calling-convention.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/clztest.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/corrupt.exp | 2 +- gdb/testsuite/gdb.dwarf2/count.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/cpp-linkage-name.exp | 2 +- gdb/testsuite/gdb.dwarf2/cu-empty-name.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/cu-no-addrs.exp | 2 +- gdb/testsuite/gdb.dwarf2/data-loc.exp | 6 +++--- .../gdb.dwarf2/debug-names-bad-cu-index.exp | 2 +- .../gdb.dwarf2/debug-names-duplicate-cu.exp | 2 +- .../gdb.dwarf2/debug-names-missing-cu.exp | 2 +- gdb/testsuite/gdb.dwarf2/debug-names-tu.exp.tcl | 2 +- gdb/testsuite/gdb.dwarf2/debug-names.exp | 2 +- gdb/testsuite/gdb.dwarf2/dup-psym.exp | 2 +- .../dw-form-ref-addr-with-type-units.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-abs-hi-pc.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-ada-ffffffff.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-align.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-anon-mptr.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-anonymous-func.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-aranges.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-bad-elf.exp | 4 ++-- .../gdb.dwarf2/dw2-bad-mips-linkage-name.exp | 2 +- .../gdb.dwarf2/dw2-bad-parameter-type.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-bad-unresolved.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-basic.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-bfloat16.exp | 4 ++-- .../gdb.dwarf2/dw2-canonicalize-type.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-common-block.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-compdir-oldgcc.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-complex-parts.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/dw2-compressed.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-const.exp | 2 +- .../gdb.dwarf2/dw2-cp-infcall-ref-static.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-cu-size.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-dir-file-name.exp | 6 +++--- .../gdb.dwarf2/dw2-disasm-over-non-stmt.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-dos-drive.exp | 2 +- .../gdb.dwarf2/dw2-double-set-die-type.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-dummy-cu.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-dup-frame.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-empty-file-name.exp | 2 +- .../gdb.dwarf2/dw2-empty-inline-ranges.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-empty-namespace.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-empty-pc-range.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-entry-pc.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/dw2-entry-value-2.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-entry-value.exp | 4 ++-- .../gdb.dwarf2/dw2-epilogue-begin.exp.tcl | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-error.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-filename.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-fixed-point.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-gas-workaround.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-icycle.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-inheritance.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-inline-break.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-inline-header-2.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-inline-header-3.exp | 4 ++-- .../gdb.dwarf2/dw2-inline-many-frames.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp | 4 ++-- .../gdb.dwarf2/dw2-inline-small-func.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-inline-stepping.exp | 4 ++-- .../gdb.dwarf2/dw2-inline-with-lexical-scope.exp | 2 +- .../gdb.dwarf2/dw2-inter-cu-error-2.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error.exp | 2 +- .../gdb.dwarf2/dw2-inter-cu-forth-and-back.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-inter-cu-symbol.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-intercu.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-intermix.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-is-stmt-2.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-is-stmt.exp | 4 ++-- .../gdb.dwarf2/dw2-lexical-block-bare.exp | 2 +- .../gdb.dwarf2/dw2-line-number-zero.exp | 6 +++--- .../gdb.dwarf2/dw2-linkage-name-trust.exp | 4 ++-- .../gdb.dwarf2/dw2-main-no-line-number.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-minsym-in-cu.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-missing-cu-tag.exp | 2 +- .../gdb.dwarf2/dw2-modula2-self-type.exp | 2 +- .../gdb.dwarf2/dw2-multiple-debug-info.exp | 2 +- .../gdb.dwarf2/dw2-namespaceless-anonymous.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-no-code-cu.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-noloc.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-objfile-overlap.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-op-call.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-op-out-param.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-op-stack-value.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-opt-structptr.exp | 2 +- .../gdb.dwarf2/dw2-out-of-range-end-of-seq.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-param-error.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-producer.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-prologue-end-2.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-ranges-overlap.exp | 4 ++-- .../gdb.dwarf2/dw2-ranges-psym-warning.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/dw2-ranges-psym.exp | 6 +++--- .../gdb.dwarf2/dw2-ref-missing-frame.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-reg-undefined.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-restore.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-restrict.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-simple-locdesc.exp | 2 +- .../dw2-single-line-discriminators.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.exp | 4 ++-- .../gdb.dwarf2/dw2-skipped-line-entries.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-stack-boundary.exp | 2 +- ...2-step-between-different-inline-functions.exp | 4 ++-- .../dw2-step-between-inline-func-blocks.exp | 4 ++-- .../dw2-step-out-of-function-no-stmt.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-strp.exp | 2 +- .../gdb.dwarf2/dw2-symtab-includes-lookup.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-symtab-includes.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-tu-dwarf-4-5.exp | 2 +- .../gdb.dwarf2/dw2-undefined-ret-addr.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-unresolved.exp | 4 ++-- .../gdb.dwarf2/dw2-unspecified-type.exp | 4 ++-- .../gdb.dwarf2/dw2-unusual-field-names.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-using-debug-str.exp | 10 +++++----- gdb/testsuite/gdb.dwarf2/dw2-var-zero-addr.exp | 2 +- .../gdb.dwarf2/dw2-vendor-extended-opcode.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw2-weird-type-len.exp | 4 ++-- .../gdb.dwarf2/dw2-wrong-mangled-name.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw4-sig-type-unused.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw4-sig-types.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw4-toplevel-types.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dw5-rnglist-test.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dwp-sepdebug.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/dwp-symlink.exp | 16 ++++++++-------- gdb/testsuite/gdb.dwarf2/dwz-many.exp | 2 +- gdb/testsuite/gdb.dwarf2/dwz-unused-pu.exp | 2 +- gdb/testsuite/gdb.dwarf2/dwz.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/dwznolink.exp | 2 +- .../gdb.dwarf2/dyn-type-unallocated.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/dynamic-bit-offset.exp | 2 +- gdb/testsuite/gdb.dwarf2/dynarr-ptr.exp | 6 +++--- .../gdb.dwarf2/enqueued-cu-base-addr.exp | 2 +- gdb/testsuite/gdb.dwarf2/enum-type-c++.exp | 2 +- gdb/testsuite/gdb.dwarf2/enum-type.exp | 2 +- .../gdb.dwarf2/fission-absolute-dwo.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/fission-base.exp | 4 ++-- .../gdb.dwarf2/fission-loclists-pie.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/fission-loclists.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/fission-mix.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/fission-multi-cu.exp | 4 ++-- .../gdb.dwarf2/fission-relative-dwo.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/fission-reread.exp | 2 +- .../gdb.dwarf2/fission-type-unit-locexpr.exp | 2 +- gdb/testsuite/gdb.dwarf2/formdata16.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/fortran-var-string.exp | 6 +++--- .../gdb.dwarf2/forward-spec-inter-cu.exp | 2 +- gdb/testsuite/gdb.dwarf2/forward-spec.exp | 2 +- .../gdb.dwarf2/gdb-add-index-symlink.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/gdb-add-index.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/gdb-index-cxx.exp | 2 +- gdb/testsuite/gdb.dwarf2/gdb-index-nodebug.exp | 2 +- gdb/testsuite/gdb.dwarf2/gdb-index-tilde.exp | 8 ++++---- .../gdb.dwarf2/gdb-index-types-dwarf5.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/gdb-index.exp | 6 +++--- .../gdb.dwarf2/implptr-optimized-out.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/implptr.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/implptrconst.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/implptrpiece.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/implref-array.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/implref-const.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/implref-global.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/implref-struct.exp | 6 +++--- .../imported-unit-abstract-const-value.exp | 4 ++-- .../gdb.dwarf2/imported-unit-bp.exp.tcl | 2 +- gdb/testsuite/gdb.dwarf2/imported-unit-c.exp | 6 +++--- .../gdb.dwarf2/imported-unit-runto-main.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/imported-unit.exp | 4 ++-- .../gdb.dwarf2/info-locals-optimized-out.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/inline.exp | 2 +- .../inlined_subroutine-inheritance.exp | 2 +- gdb/testsuite/gdb.dwarf2/intbits.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/local-var.exp | 2 +- .../gdb.dwarf2/locexpr-data-member-location.exp | 2 +- gdb/testsuite/gdb.dwarf2/mac-fileno.exp | 2 +- gdb/testsuite/gdb.dwarf2/main-subprogram.exp | 4 ++-- .../gdb.dwarf2/malformed-line-header.exp | 2 +- gdb/testsuite/gdb.dwarf2/mega-enum.exp | 2 +- .../gdb.dwarf2/member-ptr-forwardref.exp | 2 +- gdb/testsuite/gdb.dwarf2/method-ptr.exp | 2 +- gdb/testsuite/gdb.dwarf2/missing-line-table.exp | 2 +- gdb/testsuite/gdb.dwarf2/missing-sig-type.exp | 2 +- .../missing-type-name-for-templates.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/missing-type-name.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/multidictionary.exp | 2 +- gdb/testsuite/gdb.dwarf2/nameless-enum.exp | 2 +- gdb/testsuite/gdb.dwarf2/no-gnu-debuglink.exp | 2 +- gdb/testsuite/gdb.dwarf2/nonvar-access.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/nostaticblock.exp | 2 +- gdb/testsuite/gdb.dwarf2/nullptr_t.exp | 2 +- gdb/testsuite/gdb.dwarf2/opaque-type-lookup.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/opt-out-not-implptr.exp | 4 ++-- .../gdb.dwarf2/pieces-optimized-out.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/pieces.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/pr10770.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/pr11465.exp | 2 +- gdb/testsuite/gdb.dwarf2/pr13961.exp | 2 +- gdb/testsuite/gdb.dwarf2/rust-enum.exp | 2 +- gdb/testsuite/gdb.dwarf2/self-spec.exp | 2 +- gdb/testsuite/gdb.dwarf2/shortpiece.exp | 2 +- .../gdb.dwarf2/static-optimized-out.exp | 2 +- gdb/testsuite/gdb.dwarf2/staticvirtual.exp | 2 +- gdb/testsuite/gdb.dwarf2/struct-decl.exp | 2 +- gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp | 2 +- gdb/testsuite/gdb.dwarf2/struct-with-sig.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/subrange-enum.exp | 2 +- gdb/testsuite/gdb.dwarf2/subrange.exp | 2 +- .../gdb.dwarf2/symbol_needs_eval_fail.exp | 4 ++-- .../gdb.dwarf2/symbol_needs_eval_timeout.exp | 4 ++-- .../template-specification-full-name.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/trace-crash.exp | 2 +- gdb/testsuite/gdb.dwarf2/typeddwarf.exp | 6 +++--- gdb/testsuite/gdb.dwarf2/typedef-void-finish.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/utf-rust.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/valop.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/var-access.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/variant.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/varval.exp | 10 +++++----- gdb/testsuite/gdb.dwarf2/void-type.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/watch-notconst.exp | 2 +- 241 files changed, 398 insertions(+), 398 deletions(-) diff --git a/gdb/testsuite/gdb.dwarf2/DW_OP_piece_with_DW_OP_GNU_uninit.exp b/gdb/testsuite/gdb.dwarf2/DW_OP_piece_with_DW_OP_GNU_uninit.exp index eb5899661a6f..52599ca3ced9 100644 --- a/gdb/testsuite/gdb.dwarf2/DW_OP_piece_with_DW_OP_GNU_uninit.exp +++ b/gdb/testsuite/gdb.dwarf2/DW_OP_piece_with_DW_OP_GNU_uninit.exp @@ -71,17 +71,17 @@ Dwarf::assemble $asm_file { } } if {[build_executable ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } clean_restart ${testfile} if {![runto_main]} { - return -1 + return } set cmd "print i64_var" if { [is_64_target] } { gdb_test $cmd \ diff --git a/gdb/testsuite/gdb.dwarf2/ada-array-bound.exp b/gdb/testsuite/gdb.dwarf2/ada-array-bound.exp index 90858e26e654..4a5e14e2c2ed 100644 --- a/gdb/testsuite/gdb.dwarf2/ada-array-bound.exp +++ b/gdb/testsuite/gdb.dwarf2/ada-array-bound.exp @@ -80,11 +80,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language ada" gdb_test "print value" \ [string_to_regexp " = (disc => 3, nums => (7, 11, 13))"] diff --git a/gdb/testsuite/gdb.dwarf2/ada-cold-name.exp b/gdb/testsuite/gdb.dwarf2/ada-cold-name.exp index f4dc9acf4b1f..144bec7e5325 100644 --- a/gdb/testsuite/gdb.dwarf2/ada-cold-name.exp +++ b/gdb/testsuite/gdb.dwarf2/ada-cold-name.exp @@ -57,11 +57,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language ada" gdb_breakpoint "pck.xtra.function" message gdb_breakpoint "pck.xtra.function\[cold\]" message diff --git a/gdb/testsuite/gdb.dwarf2/ada-linkage-name.exp b/gdb/testsuite/gdb.dwarf2/ada-linkage-name.exp index e50763109c48..01c0fbe5e4e2 100644 --- a/gdb/testsuite/gdb.dwarf2/ada-linkage-name.exp +++ b/gdb/testsuite/gdb.dwarf2/ada-linkage-name.exp @@ -61,11 +61,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } with_test_prefix "first first" { gdb_test_no_output "set language ada" gdb_breakpoint "<__gnat_namefirst>" message diff --git a/gdb/testsuite/gdb.dwarf2/ada-thick-pointer.exp b/gdb/testsuite/gdb.dwarf2/ada-thick-pointer.exp index 526ebaffe682..b53d8a359355 100644 --- a/gdb/testsuite/gdb.dwarf2/ada-thick-pointer.exp +++ b/gdb/testsuite/gdb.dwarf2/ada-thick-pointer.exp @@ -84,10 +84,10 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language ada" gdb_test "ptype array_type" "type = array \\(1 \\.\\. 7\\) of integer" diff --git a/gdb/testsuite/gdb.dwarf2/ada-valprint-error.exp b/gdb/testsuite/gdb.dwarf2/ada-valprint-error.exp index 00e737bcef2b..171e0cbf3aab 100644 --- a/gdb/testsuite/gdb.dwarf2/ada-valprint-error.exp +++ b/gdb/testsuite/gdb.dwarf2/ada-valprint-error.exp @@ -26,11 +26,11 @@ standard_testfile .c -dw.S # Any program would do, but since we already have ada-valprint-error.c # specifically for this testcase, might as well use that. if { [prepare_for_testing ${testfile}.exp ${testfile} ${srcfile}] } { untested "failed to compile" - return -1 + return } # Make some DWARF for the test. set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { @@ -102,11 +102,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Note: This test may fail with certain clang + linker combinations # Specifically, clang + ld.lld can fail to apply relocations when linking # nodebug .o with separate DWARF .o, leaving fd__global as NULL instead diff --git a/gdb/testsuite/gdb.dwarf2/anon-ns-fn.exp b/gdb/testsuite/gdb.dwarf2/anon-ns-fn.exp index 0f47b7783ed6..1d04ea176d0a 100644 --- a/gdb/testsuite/gdb.dwarf2/anon-ns-fn.exp +++ b/gdb/testsuite/gdb.dwarf2/anon-ns-fn.exp @@ -16,11 +16,11 @@ require allow_cplus_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } set cmd "ptype main" set re \ diff --git a/gdb/testsuite/gdb.dwarf2/arr-opt-out.exp b/gdb/testsuite/gdb.dwarf2/arr-opt-out.exp index bef0d63528e0..8587897ccef1 100644 --- a/gdb/testsuite/gdb.dwarf2/arr-opt-out.exp +++ b/gdb/testsuite/gdb.dwarf2/arr-opt-out.exp @@ -79,11 +79,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } gdb_test_no_output "set language ada" gdb_test "print the_table" " = " diff --git a/gdb/testsuite/gdb.dwarf2/arr-stride.exp b/gdb/testsuite/gdb.dwarf2/arr-stride.exp index f1ef47efd51e..cdec17eed07c 100644 --- a/gdb/testsuite/gdb.dwarf2/arr-stride.exp +++ b/gdb/testsuite/gdb.dwarf2/arr-stride.exp @@ -109,11 +109,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language ada" gdb_test "ptype pck.table" \ diff --git a/gdb/testsuite/gdb.dwarf2/arr-subrange.exp b/gdb/testsuite/gdb.dwarf2/arr-subrange.exp index c466d1b8257a..ec2640cdb7ac 100644 --- a/gdb/testsuite/gdb.dwarf2/arr-subrange.exp +++ b/gdb/testsuite/gdb.dwarf2/arr-subrange.exp @@ -74,11 +74,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language ada" gdb_test "ptype pck.table" \ diff --git a/gdb/testsuite/gdb.dwarf2/atomic-type.exp b/gdb/testsuite/gdb.dwarf2/atomic-type.exp index c2f9bfcece41..92865016ea3a 100644 --- a/gdb/testsuite/gdb.dwarf2/atomic-type.exp +++ b/gdb/testsuite/gdb.dwarf2/atomic-type.exp @@ -79,9 +79,9 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "ptype f" "int \\(const _Atomic char \\\* volatile _Atomic\\)" diff --git a/gdb/testsuite/gdb.dwarf2/backward-spec-inter-cu.exp b/gdb/testsuite/gdb.dwarf2/backward-spec-inter-cu.exp index c59e0463e290..de76cc8aca22 100644 --- a/gdb/testsuite/gdb.dwarf2/backward-spec-inter-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/backward-spec-inter-cu.exp @@ -73,11 +73,11 @@ Dwarf::assemble $asm_file { } } if {[build_executable "failed to build executable" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } set eol "\r\n" set ws "\[ \t\]" diff --git a/gdb/testsuite/gdb.dwarf2/bad-regnum.exp b/gdb/testsuite/gdb.dwarf2/bad-regnum.exp index 84c1895e5d2f..6c9d80b1e048 100644 --- a/gdb/testsuite/gdb.dwarf2/bad-regnum.exp +++ b/gdb/testsuite/gdb.dwarf2/bad-regnum.exp @@ -60,15 +60,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "info addr foo1" \ "Symbol \"foo1\" is a variable in \\\$bad_register_number." diff --git a/gdb/testsuite/gdb.dwarf2/bitfield-parent-optimized-out.exp b/gdb/testsuite/gdb.dwarf2/bitfield-parent-optimized-out.exp index 45e66a42f0fd..0e7318bfd644 100644 --- a/gdb/testsuite/gdb.dwarf2/bitfield-parent-optimized-out.exp +++ b/gdb/testsuite/gdb.dwarf2/bitfield-parent-optimized-out.exp @@ -68,15 +68,15 @@ Dwarf::assemble $asm_file { } } } if {[prepare_for_testing "failed to prepare" $executable "${asm_file} ${srcfile}" {}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "p var" " = " gdb_test "p var.bitfield" " = " gdb_test "p var.intfield" " = " diff --git a/gdb/testsuite/gdb.dwarf2/break-inline-psymtab.exp b/gdb/testsuite/gdb.dwarf2/break-inline-psymtab.exp index 45213468abb2..3f03bf78df97 100644 --- a/gdb/testsuite/gdb.dwarf2/break-inline-psymtab.exp +++ b/gdb/testsuite/gdb.dwarf2/break-inline-psymtab.exp @@ -15,20 +15,20 @@ standard_testfile .c -2.c set sources [list $srcfile $srcfile2] if { [prepare_for_testing "failed to prepare" ${testfile} $sources] } { - return -1 + return } if {![runto_main]} { - return -1 + return } get_debug_format if { [skip_inline_frame_tests] } { - return -1 + return } # Set a break-point in inline function bar, in a CU for which the partial # symtab has not been expanded. gdb_breakpoint "bar" message diff --git a/gdb/testsuite/gdb.dwarf2/callframecfa.exp b/gdb/testsuite/gdb.dwarf2/callframecfa.exp index 315ce0a12f6d..91a1be56506d 100644 --- a/gdb/testsuite/gdb.dwarf2/callframecfa.exp +++ b/gdb/testsuite/gdb.dwarf2/callframecfa.exp @@ -22,15 +22,15 @@ require dwarf2_support is_x86_like_target standard_testfile .S if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list {additional_flags=-nostdlib}]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break *func" "Breakpoint 2.*" "set breakpoint for call-frame-cfa" gdb_continue_to_breakpoint "continue to breakpoint for call-frame-cfa" gdb_test "display arg" "arg = 77" "set display for call-frame-cfa" diff --git a/gdb/testsuite/gdb.dwarf2/calling-convention.exp b/gdb/testsuite/gdb.dwarf2/calling-convention.exp index 294a250408c3..202371400ea7 100644 --- a/gdb/testsuite/gdb.dwarf2/calling-convention.exp +++ b/gdb/testsuite/gdb.dwarf2/calling-convention.exp @@ -32,11 +32,11 @@ require dwarf2_support standard_testfile .c .S # First compile the .c file so we can ask GDB what is sizeof(int). if { [prepare_for_testing ${testfile}.exp ${testfile} ${srcfile}] } { untested "failed to compile" - return -1 + return } # Make some DWARF for the test. set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { @@ -67,15 +67,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "call foo ()" \ "Cannot call the function 'foo' which does not follow the target calling convention." gdb_breakpoint "foo" diff --git a/gdb/testsuite/gdb.dwarf2/clztest.exp b/gdb/testsuite/gdb.dwarf2/clztest.exp index 43f17889f5a6..c827ae6175c8 100644 --- a/gdb/testsuite/gdb.dwarf2/clztest.exp +++ b/gdb/testsuite/gdb.dwarf2/clztest.exp @@ -24,15 +24,15 @@ require dwarf2_support # This test can only be run on x86-64 targets. require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" "${test}" ${test}.S \ {nodebug nopie additional_flags=-nostdlib}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Initialize tests to be an empty array. unset -nocomplain tests array set tests {} diff --git a/gdb/testsuite/gdb.dwarf2/corrupt.exp b/gdb/testsuite/gdb.dwarf2/corrupt.exp index aff411132142..b46f0cb1b434 100644 --- a/gdb/testsuite/gdb.dwarf2/corrupt.exp +++ b/gdb/testsuite/gdb.dwarf2/corrupt.exp @@ -67,9 +67,9 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } gdb_test "print 1" "= 1" "recover from corrupt DWARF" diff --git a/gdb/testsuite/gdb.dwarf2/count.exp b/gdb/testsuite/gdb.dwarf2/count.exp index a238c352d97f..8ed443fe7343 100644 --- a/gdb/testsuite/gdb.dwarf2/count.exp +++ b/gdb/testsuite/gdb.dwarf2/count.exp @@ -125,15 +125,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "ptype array" "type = char \\\[5\\\]" gdb_test "whatis array" "type = char \\\[5\\\]" gdb_test "print array" " = \"hello\"" diff --git a/gdb/testsuite/gdb.dwarf2/cpp-linkage-name.exp b/gdb/testsuite/gdb.dwarf2/cpp-linkage-name.exp index bbb3a3765ab4..6a3abaf83a4d 100644 --- a/gdb/testsuite/gdb.dwarf2/cpp-linkage-name.exp +++ b/gdb/testsuite/gdb.dwarf2/cpp-linkage-name.exp @@ -80,10 +80,10 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_assert [runto_main] "run to main" gdb_test "p global_var" " = {x = 0, y = 0}" diff --git a/gdb/testsuite/gdb.dwarf2/cu-empty-name.exp b/gdb/testsuite/gdb.dwarf2/cu-empty-name.exp index 32f4a4c007fd..d4aa02038071 100644 --- a/gdb/testsuite/gdb.dwarf2/cu-empty-name.exp +++ b/gdb/testsuite/gdb.dwarf2/cu-empty-name.exp @@ -36,13 +36,13 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_continue_to_end diff --git a/gdb/testsuite/gdb.dwarf2/cu-no-addrs.exp b/gdb/testsuite/gdb.dwarf2/cu-no-addrs.exp index 8ff6765d170c..844b01d1b4a5 100644 --- a/gdb/testsuite/gdb.dwarf2/cu-no-addrs.exp +++ b/gdb/testsuite/gdb.dwarf2/cu-no-addrs.exp @@ -51,10 +51,10 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } gdb_test "break *$main_start" ".*Breakpoint $decimal at $hex" \ "set breakpoint at main address" diff --git a/gdb/testsuite/gdb.dwarf2/data-loc.exp b/gdb/testsuite/gdb.dwarf2/data-loc.exp index 3a2787e9f268..b78afe257164 100644 --- a/gdb/testsuite/gdb.dwarf2/data-loc.exp +++ b/gdb/testsuite/gdb.dwarf2/data-loc.exp @@ -25,11 +25,11 @@ standard_testfile .c -dw.S # For that, we ask GDB by debugging our data-loc.c program. # Any program would do, but since we already have data-loc.c # specifically for this testcase, might as well use that. if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Make some DWARF for the test. set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { @@ -119,15 +119,15 @@ Dwarf::assemble $asm_file { # program using our debug info instead of the info generated by # the compiler. if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set language ada" # foo.three diff --git a/gdb/testsuite/gdb.dwarf2/debug-names-bad-cu-index.exp b/gdb/testsuite/gdb.dwarf2/debug-names-bad-cu-index.exp index 00dacb78b817..10e649f06afe 100644 --- a/gdb/testsuite/gdb.dwarf2/debug-names-bad-cu-index.exp +++ b/gdb/testsuite/gdb.dwarf2/debug-names-bad-cu-index.exp @@ -80,11 +80,11 @@ Dwarf::assemble { } } if {[build_executable ${testfile}.exp $testfile "${asm_file} ${srcfile}" \ [list ldflags=-nostartfiles]] == -1} { - return -1 + return } clean_restart with_complaints 1 { diff --git a/gdb/testsuite/gdb.dwarf2/debug-names-duplicate-cu.exp b/gdb/testsuite/gdb.dwarf2/debug-names-duplicate-cu.exp index b9ad865a79d1..11294ae5a131 100644 --- a/gdb/testsuite/gdb.dwarf2/debug-names-duplicate-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/debug-names-duplicate-cu.exp @@ -60,11 +60,11 @@ Dwarf::assemble { } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile}" \ [list ldflags=-nostartfiles]]} { - return -1 + return } # Check for warning. set re \ [list \ diff --git a/gdb/testsuite/gdb.dwarf2/debug-names-missing-cu.exp b/gdb/testsuite/gdb.dwarf2/debug-names-missing-cu.exp index 532482318dd1..c5eca54b55cf 100644 --- a/gdb/testsuite/gdb.dwarf2/debug-names-missing-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/debug-names-missing-cu.exp @@ -67,11 +67,11 @@ Dwarf::assemble { } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile}" \ [list ldflags=-nostartfiles]]} { - return -1 + return } # Verify that .debug_names section is not ignored. set index [have_index $binfile] gdb_assert { [string equal $index ""] } ".debug_names not used" diff --git a/gdb/testsuite/gdb.dwarf2/debug-names-tu.exp.tcl b/gdb/testsuite/gdb.dwarf2/debug-names-tu.exp.tcl index 4d588ab6cec6..af3f263a2733 100644 --- a/gdb/testsuite/gdb.dwarf2/debug-names-tu.exp.tcl +++ b/gdb/testsuite/gdb.dwarf2/debug-names-tu.exp.tcl @@ -88,11 +88,11 @@ Dwarf::assemble { } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile}" \ [list ldflags=-nostartfiles]]} { - return -1 + return } # Verify that .debug_names section is not ignored. set index [have_index $binfile] gdb_assert { [string equal $index "debug_names"] } ".debug_names used" diff --git a/gdb/testsuite/gdb.dwarf2/debug-names.exp b/gdb/testsuite/gdb.dwarf2/debug-names.exp index 23e8dad4577a..39bdd3d59e82 100644 --- a/gdb/testsuite/gdb.dwarf2/debug-names.exp +++ b/gdb/testsuite/gdb.dwarf2/debug-names.exp @@ -63,11 +63,11 @@ Dwarf::assemble { } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile}" \ [list ldflags=-nostartfiles]]} { - return -1 + return } # Verify that .debug_names section is not ignored. set index [have_index $binfile] gdb_assert { [string equal $index "debug_names"] } ".debug_names used" diff --git a/gdb/testsuite/gdb.dwarf2/dup-psym.exp b/gdb/testsuite/gdb.dwarf2/dup-psym.exp index da3a8947c2fb..b020146e285b 100644 --- a/gdb/testsuite/gdb.dwarf2/dup-psym.exp +++ b/gdb/testsuite/gdb.dwarf2/dup-psym.exp @@ -21,11 +21,11 @@ require dwarf2_support standard_testfile .S if {[prepare_for_testing_full "failed to prepare" \ [list $testfile {debug} main.c debug $srcfile nodebug]]} { - return -1 + return } set test "info sources should contain only one reference to file1.txt" gdb_test_multiple "info sources" "$test" { -re "file1\\.txt.*file1\\.txt.*$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.dwarf2/dw-form-ref-addr-with-type-units.exp b/gdb/testsuite/gdb.dwarf2/dw-form-ref-addr-with-type-units.exp index 9a8a396375b1..6c3304352988 100644 --- a/gdb/testsuite/gdb.dwarf2/dw-form-ref-addr-with-type-units.exp +++ b/gdb/testsuite/gdb.dwarf2/dw-form-ref-addr-with-type-units.exp @@ -98,11 +98,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Without the corresponding fix, we get an internal error: # # gdb/dwarf2/read.c:3940: internal-error: load_full_comp_unit: Assertion `! this_cu->is_debug_types' failed. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-abs-hi-pc.exp b/gdb/testsuite/gdb.dwarf2/dw2-abs-hi-pc.exp index 04d8f91be5b8..367871e3094e 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-abs-hi-pc.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-abs-hi-pc.exp @@ -48,11 +48,11 @@ lappend flags additional_flags=[quote_for_host -DWORLD_START=$world_start] lappend flags additional_flags=[quote_for_host -DWORLD_END=$world_start \ + $world_len] set executable ${testfile} if {[build_executable ${testfile}.exp ${executable} $sources $flags] == -1} { - return -1 + return } clean_restart $executable gdb_test "break hello" \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ada-ffffffff.exp b/gdb/testsuite/gdb.dwarf2/dw2-ada-ffffffff.exp index 06d4f6930240..1716741c0c14 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ada-ffffffff.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ada-ffffffff.exp @@ -19,11 +19,11 @@ require dwarf2_support standard_testfile .S set executable ${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $executable # -1 was produced, it is now caught with the complaint: diff --git a/gdb/testsuite/gdb.dwarf2/dw2-align.exp b/gdb/testsuite/gdb.dwarf2/dw2-align.exp index f4e6947f755e..6671dd5a3fd3 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-align.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-align.exp @@ -66,15 +66,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set lang c++" gdb_test "print alignof(int_4096)" " = 4096" gdb_test "print alignof(ptr_4096)" " = 4096" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-anon-mptr.exp b/gdb/testsuite/gdb.dwarf2/dw2-anon-mptr.exp index 50b949345fcc..bbfdf23168b8 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-anon-mptr.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-anon-mptr.exp @@ -23,11 +23,11 @@ require allow_cplus_tests standard_testfile .S if {[gdb_compile [file join $srcdir $subdir $srcfile] $binfile \ object {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart # Be sure to set cp-abi before $binfile gets loaded diff --git a/gdb/testsuite/gdb.dwarf2/dw2-anonymous-func.exp b/gdb/testsuite/gdb.dwarf2/dw2-anonymous-func.exp index 949464bd3c18..a02d580bfd26 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-anonymous-func.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-anonymous-func.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_remote_download host ${srcdir}/${subdir}/${dwarf_srcfile} # Force the debugger to create the file1.txt symtab, to make sure that diff --git a/gdb/testsuite/gdb.dwarf2/dw2-aranges.exp b/gdb/testsuite/gdb.dwarf2/dw2-aranges.exp index d1d2a09c8830..beda49270c74 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-aranges.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-aranges.exp @@ -34,10 +34,10 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" $testfile \ [list $asm_file $srcfile ]] } { - return -1 + return } # Failed gdb_load would abort the testcase execution earlier. pass "file loaded" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-bad-elf.exp b/gdb/testsuite/gdb.dwarf2/dw2-bad-elf.exp index 134397cdfcbe..b148ae0e005c 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-bad-elf.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-bad-elf.exp @@ -34,11 +34,11 @@ require dwarf2_support standard_testfile main.c -other.S -dwarf.S if { [prepare_for_testing ${testfile}.exp ${testfile} ${srcfile}] } { untested "failed to compile" - return -1 + return } set int_size [get_sizeof "int" 4] # Make some DWARF for the test. @@ -158,11 +158,11 @@ Dwarf::assemble $asm_file { } } if { [build_executable ${testfile}.exp ${testfile} \ [list $srcfile $srcfile2 $asm_file] {nodebug}] } { - return -1 + return } # Attempt to place a breakpoint on 'some_func', then check GDB is # still alive. This test can optionally set a breakpoint on 'main' # first (based on GOTO_MAIN), the original bug behaved differently diff --git a/gdb/testsuite/gdb.dwarf2/dw2-bad-mips-linkage-name.exp b/gdb/testsuite/gdb.dwarf2/dw2-bad-mips-linkage-name.exp index 5a8e902b0181..aa7c12c12fab 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-bad-mips-linkage-name.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-bad-mips-linkage-name.exp @@ -53,11 +53,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # A successful run will have two PASSes. A GDB that's lacking # attribute type checking will segfault at some point. It doesn't # much matter what we test here, so long as we do something to make diff --git a/gdb/testsuite/gdb.dwarf2/dw2-bad-parameter-type.exp b/gdb/testsuite/gdb.dwarf2/dw2-bad-parameter-type.exp index 9bba38c81025..79cd67af65d9 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-bad-parameter-type.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-bad-parameter-type.exp @@ -20,11 +20,11 @@ require dwarf2_support standard_testfile .S set executable ${testfile} # First try referencing DW_AT_frame_base which is not defined. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $executable # The first access (as we do not use -readnow) prints some: diff --git a/gdb/testsuite/gdb.dwarf2/dw2-bad-unresolved.exp b/gdb/testsuite/gdb.dwarf2/dw2-bad-unresolved.exp index 307fcc1546d2..6f6eb153c3a5 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-bad-unresolved.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-bad-unresolved.exp @@ -50,10 +50,10 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "ptype var" "type = bool" gdb_test "print var" "Missing .* symbol \"var\"." diff --git a/gdb/testsuite/gdb.dwarf2/dw2-basic.exp b/gdb/testsuite/gdb.dwarf2/dw2-basic.exp index 305fc7173ab0..f94bb8633ce3 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-basic.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-basic.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_remote_download host ${srcdir}/${subdir}/${dwarf_srcfile} gdb_test_no_output "set listsize 1" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-bfloat16.exp b/gdb/testsuite/gdb.dwarf2/dw2-bfloat16.exp index d7b76eaf6e72..6b71e1e05581 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-bfloat16.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-bfloat16.exp @@ -66,15 +66,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Make sure we can print both types correctly. gdb_test "print bf16_1" " = 3.141" gdb_test "print fp16_1" " = 3.1406" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-canonicalize-type.exp b/gdb/testsuite/gdb.dwarf2/dw2-canonicalize-type.exp index 4928bcb3e4c2..48206cdc2376 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-canonicalize-type.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-canonicalize-type.exp @@ -23,10 +23,10 @@ set additional_flags [gdb_target_symbol_prefix_flags_asm] standard_testfile .S set executable ${testfile} if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list nodebug $additional_flags]]} { - return -1 + return } # The correct new[] and delete[] syntax is probably unsupported by GDB. gdb_test "ptype f" {type = void \(typename, C::operator new\(int\), C::operator delete\(void\*\), C::operator new\[\]\(int\), C::operator delete\[\]\(void\*\)\)} diff --git a/gdb/testsuite/gdb.dwarf2/dw2-common-block.exp b/gdb/testsuite/gdb.dwarf2/dw2-common-block.exp index 7c470ff25a0d..38d2652cd3bf 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-common-block.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-common-block.exp @@ -26,11 +26,11 @@ require allow_fortran_tests standard_testfile .S if { [prepare_for_testing "failed to prepare" "${testfile}" $srcfile \ {nodebug nopie f90}] } { - return -1 + return } if {![runto MAIN__]} { return } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-compdir-oldgcc.exp b/gdb/testsuite/gdb.dwarf2/dw2-compdir-oldgcc.exp index b067f3b7f28b..6e729f8c6ec0 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-compdir-oldgcc.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-compdir-oldgcc.exp @@ -21,11 +21,11 @@ require dwarf2_support set additional_flags [gdb_target_symbol_prefix_flags_asm] standard_testfile .S if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ $additional_flags]} { - return -1 + return } # Here should be GDB-computed "Compilation directory is". gdb_test "list gcc42" ".*" gdb_test "info source" "\r\nCurrent source file is dw2-compdir-oldgcc42.S\r\nCompilation directory is /dir/d\r\n.*" \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-complex-parts.exp b/gdb/testsuite/gdb.dwarf2/dw2-complex-parts.exp index f0a159e4aa4e..f8da14c0a5aa 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-complex-parts.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-complex-parts.exp @@ -31,11 +31,11 @@ require dwarf2_support standard_testfile main.c -debug.S if {[prepare_for_testing "failed to prepare" $testfile \ "${srcfile}" {}]} { - return -1 + return } set float_size [get_sizeof float 0] set double_size [get_sizeof double 0] set long_double_size [get_sizeof "long double" 0] @@ -157,15 +157,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" $testfile \ "${asm_file} ${srcfile}" {}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } proc do_test { type {clang 0}} { with_test_prefix $type { with_test_prefix clang=$clang { diff --git a/gdb/testsuite/gdb.dwarf2/dw2-compressed.exp b/gdb/testsuite/gdb.dwarf2/dw2-compressed.exp index 5ac342506c95..ff197a4d74fe 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-compressed.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-compressed.exp @@ -24,11 +24,11 @@ set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile \ {debug additional_flags=-static additional_flags=-nostdlib} \ main.c -g0 $srcfile nodebug]]} { - return -1 + return } gdb_remote_download host ${srcdir}/${subdir}/${dwarf_srcfile} gdb_test_no_output "set listsize 1" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-const.exp b/gdb/testsuite/gdb.dwarf2/dw2-const.exp index 41eea8063b1f..93ddfaa0f2ff 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-const.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-const.exp @@ -19,11 +19,11 @@ require dwarf2_support standard_testfile .S if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_test "print twelve" "= 12" gdb_test "print/x val8" " = 0xffffffff00000000" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-cp-infcall-ref-static.exp b/gdb/testsuite/gdb.dwarf2/dw2-cp-infcall-ref-static.exp index 1ddf32aab571..a659ae7171a9 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-cp-infcall-ref-static.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-cp-infcall-ref-static.exp @@ -25,15 +25,15 @@ require dwarf2_support standard_testfile .S -main.c if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile2 $srcfile] {}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # main is not provided by DWARF. gdb_test_no_output "set language c++" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-cu-size.exp b/gdb/testsuite/gdb.dwarf2/dw2-cu-size.exp index db6ad49e9968..ea3842fe7c0a 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-cu-size.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-cu-size.exp @@ -24,9 +24,9 @@ require dwarf2_support standard_testfile .S if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_test "ptype noloc" "type = const int" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-dir-file-name.exp b/gdb/testsuite/gdb.dwarf2/dw2-dir-file-name.exp index a21cc40284b7..6b01e1d28800 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-dir-file-name.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-dir-file-name.exp @@ -80,11 +80,11 @@ set srcabsdir [standard_output_file ${testfile}.d] set srctmpfile tmp-${testfile}.c # $srcdir may be relative. if {[file pathtype $srcabsdir] != "absolute"} { untested "objdir pathtype is not absolute" - return -1 + return } set f [open $asmsrcfile "w"] puts $f "/* DO NOT EDIT! GENERATED AUTOMATICALLY! */" @@ -412,11 +412,11 @@ if { [test_compiler_info clang*] } { lappend opts "additional_flags=-fno-integrated-as" } if { [gdb_compile "${asmsrcfile} ${srcdir}/${subdir}/$srcfile" "${binfile}" executable $opts] != "" } { untested "failed to compile" - return -1 + return } set dirs {} foreach r {"" /rdir} { foreach x {"" /xdir} { @@ -448,11 +448,11 @@ remote_exec host "sh -c \"mkdir $dircreatelist\"" remote_exec host "sh -c \"for d in $dircreatelist; do cp ${srcdir}/${subdir}/${srcfile} \\\$d/${srctmpfile}; done\"" clean_restart ${testfile} if {![runto_main]} { - return -1 + return } gdb_test "cd ${srcabsdir}/rdir" "Working directory [string_to_regexp ${srcabsdir}]/rdir\\." "cd .../rdir" proc test { func compdir filename } { diff --git a/gdb/testsuite/gdb.dwarf2/dw2-disasm-over-non-stmt.exp b/gdb/testsuite/gdb.dwarf2/dw2-disasm-over-non-stmt.exp index 1c0d3979ee93..76de1bc46499 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-disasm-over-non-stmt.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-disasm-over-non-stmt.exp @@ -92,15 +92,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug} ] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Global lines array, maps lines numbers to the list of addresses # associated with that line in the debug output. array set lines {} diff --git a/gdb/testsuite/gdb.dwarf2/dw2-dos-drive.exp b/gdb/testsuite/gdb.dwarf2/dw2-dos-drive.exp index f7ddd2280b93..9ae132fae2f5 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-dos-drive.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-dos-drive.exp @@ -18,11 +18,11 @@ require dwarf2_support standard_testfile .S set executable ${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $executable gdb_test_no_output "set breakpoint pending off" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-double-set-die-type.exp b/gdb/testsuite/gdb.dwarf2/dw2-double-set-die-type.exp index dc76285c1acc..bd36d62a5d32 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-double-set-die-type.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-double-set-die-type.exp @@ -22,10 +22,10 @@ require dwarf2_support standard_testfile .S if { [gdb_compile [file join $srcdir $subdir $srcfile] $binfile \ object {nodebug}] != "" } { - return -1 + return } clean_restart $testfile gdb_test "ptype a" "type = class .*" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-dummy-cu.exp b/gdb/testsuite/gdb.dwarf2/dw2-dummy-cu.exp index 6bbc25319b9f..2933de412320 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-dummy-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-dummy-cu.exp @@ -20,11 +20,11 @@ require dwarf2_support standard_testfile .S set executable ${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $executable gdb_test_no_output "maint expand-symtab" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-dup-frame.exp b/gdb/testsuite/gdb.dwarf2/dw2-dup-frame.exp index df925a653746..6f3c6a0092e4 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-dup-frame.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-dup-frame.exp @@ -21,16 +21,16 @@ require dwarf2_support require is_x86_64_m64_target standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug nopie}] } { - return -1 + return } if {![runto stop_frame]} { perror "Failed to stop in stop_frame" - return -1 + return } gdb_test "bt" \ "#0 stop_frame \[^\r\n\]*\r\nBacktrace stopped: previous frame identical to this frame \\(corrupt stack\\?\\)" \ "backtrace from stop_frame" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-empty-file-name.exp b/gdb/testsuite/gdb.dwarf2/dw2-empty-file-name.exp index 91ba571de6ff..15539bad8564 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-empty-file-name.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-empty-file-name.exp @@ -50,11 +50,11 @@ Dwarf::assemble $asm_file { } } if { [build_executable "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } clean_restart # If there's an ERROR during gdb_load, the assert will produce an UNRESOLVED diff --git a/gdb/testsuite/gdb.dwarf2/dw2-empty-inline-ranges.exp b/gdb/testsuite/gdb.dwarf2/dw2-empty-inline-ranges.exp index 914b9d6f8130..5c6ec7a2d4ec 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-empty-inline-ranges.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-empty-inline-ranges.exp @@ -58,11 +58,11 @@ get_func_info main # # Use `nopie` to ensure that addresses are the same across runs, in case ASLR # can't be disabled. if { [prepare_for_testing "failed to prepare" ${testfile} \ [list ${srcfile}] {debug nopie}] } { - return -1 + return } # Some addresses that we need when generating the DWARF. for { set i 0 } { $i < 9 } { incr i } { set main_$i [get_hexadecimal_valueof "&main_$i" "UNKNOWN" \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-empty-namespace.exp b/gdb/testsuite/gdb.dwarf2/dw2-empty-namespace.exp index a00eea2a28ec..7b7dd946c009 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-empty-namespace.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-empty-namespace.exp @@ -21,11 +21,11 @@ require dwarf2_support standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" $binfile \ object {nodebug}] != "" } { - return -1 + return } clean_restart $testfile # `p var' below can work without identified DWARF DIE just based on its ELF symbol. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-empty-pc-range.exp b/gdb/testsuite/gdb.dwarf2/dw2-empty-pc-range.exp index 9a8a88a74735..f365866c0960 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-empty-pc-range.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-empty-pc-range.exp @@ -19,11 +19,11 @@ require dwarf2_support standard_testfile .S set executable ${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $executable gdb_test "ptype emptyrange" {No symbol "emptyrange" in current context\.} \ "empty range before CU load" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-entry-pc.exp b/gdb/testsuite/gdb.dwarf2/dw2-entry-pc.exp index f7cc7f7c0674..9a1f5e101e7a 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-entry-pc.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-entry-pc.exp @@ -27,11 +27,11 @@ standard_testfile # before calling prepare_for_testing otherwise GDB will have exited. get_func_info foo if { [prepare_for_testing "failed to prepare" ${testfile} \ [list ${srcfile}] {debug nopie}]} { - return -1 + return } # Address for the middle of foo. This is used as our entry point when # the entry_pc is defined as an address. set foo_middle_addr [get_hexadecimal_valueof "&foo_middle" "UNKNOWN" \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp b/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp index 33feb375b9d0..fa3bf5f4b3e0 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp @@ -189,15 +189,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Try whether we can set and hit breakpoints at the entry_points. gdb_breakpoint "*foo" gdb_breakpoint "*foobar" @@ -218,11 +218,11 @@ gdb_test "bt" [multi_line \ # Now try whether we can also set breakpoints on entry_points from other CUs. clean_restart ${testfile} if {![runto_main]} { - return -1 + return } gdb_breakpoint "*fooso" gdb_continue_to_breakpoint "foo_so" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-entry-value-2.exp b/gdb/testsuite/gdb.dwarf2/dw2-entry-value-2.exp index 710b9285cecb..3b48846fb718 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-entry-value-2.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-entry-value-2.exp @@ -92,11 +92,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto *main] } { return } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-entry-value.exp b/gdb/testsuite/gdb.dwarf2/dw2-entry-value.exp index 3739dff18cf4..fecb2e9296de 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-entry-value.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-entry-value.exp @@ -16,15 +16,15 @@ load_lib dwarf.exp # This test can only be run on targets which support DWARF-2 and use gas. require dwarf2_support if { [prepare_for_testing "failed to prepare" "dw2-entry-value" {dw2-entry-value-main.c dw2-entry-value.S} {nodebug}] } { - return -1 + return } if {![runto f]} { - return -1 + return } # FAIL was printing: # param=Unhandled dwarf expression opcode 0xf3 gdb_test "frame" "param=.*" " is printed" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-epilogue-begin.exp.tcl b/gdb/testsuite/gdb.dwarf2/dw2-epilogue-begin.exp.tcl index 89519f577846..d74a8db0a7bf 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-epilogue-begin.exp.tcl +++ b/gdb/testsuite/gdb.dwarf2/dw2-epilogue-begin.exp.tcl @@ -164,15 +164,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Moving to the scope with a local variable. gdb_breakpoint $srcfile:$watch_start_line diff --git a/gdb/testsuite/gdb.dwarf2/dw2-error.exp b/gdb/testsuite/gdb.dwarf2/dw2-error.exp index 6da0949b3829..01d07a4e6ec0 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-error.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-error.exp @@ -23,11 +23,11 @@ standard_testfile .S require is_x86_64_m64_target # We can't use prepare_for_testing here because we need to check the # 'file' command's output. if {[build_executable $testfile.exp $testfile $srcfile {nodebug quiet}]} { - return -1 + return } clean_restart gdb_test_no_output "set breakpoint pending off" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-filename.exp b/gdb/testsuite/gdb.dwarf2/dw2-filename.exp index f5e9a4c5bd40..953ad7d8eb5d 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-filename.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-filename.exp @@ -21,11 +21,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {nodebug}] != "" } { - return -1 + return } gdb_remote_download host ${srcdir}/${subdir}/${dwarf_srcfile} clean_restart ${testfile} diff --git a/gdb/testsuite/gdb.dwarf2/dw2-fixed-point.exp b/gdb/testsuite/gdb.dwarf2/dw2-fixed-point.exp index b3009fa3f83e..c52f7302ea60 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-fixed-point.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-fixed-point.exp @@ -112,15 +112,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Do the testing in Ada mode, since this is the language for which # this feature has been implemented, and where we know the language # has the concept of fixed-point types. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-gas-workaround.exp b/gdb/testsuite/gdb.dwarf2/dw2-gas-workaround.exp index 81048e4c2e2a..a6e81e2407d3 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-gas-workaround.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-gas-workaround.exp @@ -88,11 +88,11 @@ proc create_dwarf_assembly {source_file one_diridx} { } set asm_file [create_dwarf_assembly $srcfile2 false] if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set debug symtab-create 1" gdb_test_multiple "ptype bar" "" { -re -wrap "name_for_id = $objdir/$srcfile\r\n.*" { @@ -106,9 +106,9 @@ gdb_test_multiple "ptype bar" "" { # Test whether gdb crashes in the case where the number of # directory indexes is only one. set asm_file [create_dwarf_assembly $srcfile3 true] if {[prepare_for_testing "failed to prepare" ${testfile}-one-diridx \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "ptype bar" ".*" "do not crash with only one directory table entry" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-icycle.exp b/gdb/testsuite/gdb.dwarf2/dw2-icycle.exp index 79030d01f95a..59a5ff6aaf92 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-icycle.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-icycle.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S main.c if { [build_executable "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {nodebug}] } { - return -1 + return } # We are trying to verify that the partial symtab to symtab expansion # for the debugging info hand-coded in our assembly file does not cause # the debugger to crash (infinite recursion). To facilitate the test, diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.exp b/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.exp index 048ab99f2056..7efeec9b4891 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.exp @@ -57,13 +57,13 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto func]} { - return -1 + return } gdb_test "p/x param" " = 0xdeadf00d" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inheritance.exp b/gdb/testsuite/gdb.dwarf2/dw2-inheritance.exp index a0325cfb71d3..a65a0e702bb9 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inheritance.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inheritance.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" $binfile \ object {nodebug}] != "" } { - return -1 + return } clean_restart $testfile gdb_test "ptype inherited" "type = class inherited .*" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-break.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-break.exp index 7e7223cfcaf3..114252335dea 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-break.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-break.exp @@ -27,11 +27,11 @@ require is_x86_64_m64_target set basename "inline-break" standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}] } { - return -1 + return } # # func1 is a static inlined function that is called once. # The result should be a single-location breakpoint. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-header-2.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-header-2.exp index 3b712fb1ab3a..d8e8c0591476 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-header-2.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-header-2.exp @@ -140,15 +140,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] $build_options] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Delete all breakpoints, watchpoints, tracepoints, and catchpoints so that # the output of "info breakpoints" below will only contain a single breakpoint. delete_breakpoints diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-header-3.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-header-3.exp index 831ed521fd53..c1faccb883aa 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-header-3.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-header-3.exp @@ -129,15 +129,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] $build_options] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Delete all breakpoints, watchpoints, tracepoints, and catchpoints so that # the output of "info breakpoints" below will only contain a single breakpoint. delete_breakpoints diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-many-frames.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-many-frames.exp index 2854e8666184..7709fec14fc6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-many-frames.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-many-frames.exp @@ -284,15 +284,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # First we step through all of the functions until we get the 'kkk'. set patterns [list "main call aaa" \ "aaa return" \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp index 8e218a9f8d09..7f9f9464aaf5 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp @@ -21,11 +21,11 @@ standard_testfile .S -main.c set binfile_stripped ${binfile}-stripped if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list $srcfile2 $srcfile] {nodebug nopie}] } { - return -1 + return } set break_at "" set test "info addr break_at" gdb_test_multiple $test $test { @@ -50,11 +50,11 @@ if {$result != 0} { } gdb_load ${binfile_stripped} if {![runto "*${break_at}"]} { - return -1 + return } set index [have_index $binfile_stripped] if {$index == "debug_names"} { # This test doesn't include .debug_aranges, so it doesn't cause CU diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-small-func.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-small-func.exp index c6086e39d001..bf372fcd5637 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-small-func.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-small-func.exp @@ -118,15 +118,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug optimize=-O1}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Delete all breakpoints, watchpoints, tracepoints, and catchpoints so that # the output of "info breakpoints" below will only contain a single breakpoint. delete_breakpoints diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-stepping.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-stepping.exp index 320d7188fe2e..07e9ef45be0d 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-stepping.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-stepping.exp @@ -121,15 +121,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set patterns [list "main call foo" \ "foo call bar" \ "bar return global_var"] diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-with-lexical-scope.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-with-lexical-scope.exp index 8bdd6128eed4..1454b1e14c46 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-with-lexical-scope.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-with-lexical-scope.exp @@ -130,11 +130,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } runto breakpoint_label # When using cc-with-debug-names, nothing will force the CU to be diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error-2.exp b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error-2.exp index 14bcda616e91..b783bf7434e6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error-2.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error-2.exp @@ -43,11 +43,11 @@ Dwarf::assemble $asm_file { } } if {[build_executable "failed to prepare" $testfile \ [list $asm_file $srcfile] {nodebug}]} { - return -1 + return } clean_restart gdb_test_no_output "maint set dwarf synchronous on" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error.exp b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error.exp index 0919177f313b..2e892350db57 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-error.exp @@ -45,11 +45,11 @@ Dwarf::assemble $asm_file { } } if {[build_executable "failed to prepare" $testfile \ [list $asm_file $srcfile] {nodebug}]} { - return -1 + return } clean_restart gdb_test_no_output "maint set dwarf synchronous on" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-forth-and-back.exp b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-forth-and-back.exp index 577b387d1269..a1aee9b2f473 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-forth-and-back.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-forth-and-back.exp @@ -55,10 +55,10 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" $testfile \ [list $asm_file $srcfile] {nodebug}]} { - return -1 + return } # Regression test for PR32081. gdb_assert { ![regexp -nocase "error:" $gdb_file_cmd_msg] } "No Error message" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-symbol.exp b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-symbol.exp index 8f70def01a76..964868f8d3e1 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-symbol.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inter-cu-symbol.exp @@ -72,15 +72,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto main]} { - return -1 + return } gdb_test "p var1" " = 1" set re \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-intercu.exp b/gdb/testsuite/gdb.dwarf2/dw2-intercu.exp index 7f927f11f6e0..99c7cf8c1113 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-intercu.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-intercu.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } set remote_dwarf_srcfile [gdb_remote_download host \ ${srcdir}/${subdir}/${dwarf_srcfile}] diff --git a/gdb/testsuite/gdb.dwarf2/dw2-intermix.exp b/gdb/testsuite/gdb.dwarf2/dw2-intermix.exp index 66dcdb8f9f91..c94a49f466bf 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-intermix.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-intermix.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_remote_download host \ ${srcdir}/${subdir}/${dwarf_srcfile} diff --git a/gdb/testsuite/gdb.dwarf2/dw2-is-stmt-2.exp b/gdb/testsuite/gdb.dwarf2/dw2-is-stmt-2.exp index 6791a46386cd..df29523bcaae 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-is-stmt-2.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-is-stmt-2.exp @@ -143,15 +143,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Check stepping through the out of order lines gives the experience # we expect; lines in the correct order, and stop at the correct # labels.Q diff --git a/gdb/testsuite/gdb.dwarf2/dw2-is-stmt.exp b/gdb/testsuite/gdb.dwarf2/dw2-is-stmt.exp index e20949ffee37..6d0c3795ea34 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-is-stmt.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-is-stmt.exp @@ -94,15 +94,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # First, break by address at a location we know is marked as not a # statement. GDB should still correctly report the file and line # number. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-lexical-block-bare.exp b/gdb/testsuite/gdb.dwarf2/dw2-lexical-block-bare.exp index feb6245c8c17..eb119d062c0c 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-lexical-block-bare.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-lexical-block-bare.exp @@ -54,11 +54,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } runto_main # FAILing GDB did print: No symbol "testvar" in current context. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp b/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp index 804bc07d640c..edc479134b1e 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp @@ -108,15 +108,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "$srcfile:27" gdb_continue_to_breakpoint "bar1" "\[^\r\n\]*:27\r\n.*" @@ -128,11 +128,11 @@ gdb_continue_to_breakpoint "bar2" "\[^\r\n\]*:41\r\n.*" gdb_test "n" "foo \\(2\\);" "bar2, 1st next" gdb_test "n" "foo \\(4\\);" "bar2, 2nd next" if {![runto_main]} { - return -1 + return } gdb_breakpoint "bar1_label_3" setup_kfail "gdb/nnnnn" *-*-* gdb_continue_to_breakpoint "bar1_label_3" "bar1 \\(\\)" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-linkage-name-trust.exp b/gdb/testsuite/gdb.dwarf2/dw2-linkage-name-trust.exp index a243b6ad01a9..e45ca986c159 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-linkage-name-trust.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-linkage-name-trust.exp @@ -27,15 +27,15 @@ standard_testfile .S set executable ${testfile} if {[prepare_for_testing_full "failed to prepare" \ [list $testfile c++ $testfile-main.cc {c++ nodebug} \ $srcfile {}]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # main is not provided by DWARF. gdb_test_no_output "set language c++" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp b/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp index aaef7478f412..b2f7a42c7302 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp @@ -44,14 +44,14 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set breakpoint_at_missing_lineno_set [gdb_breakpoint "1" no-message] gdb_assert { !$breakpoint_at_missing_lineno_set } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-minsym-in-cu.exp b/gdb/testsuite/gdb.dwarf2/dw2-minsym-in-cu.exp index fe700ccee8d5..8f582f6e752f 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-minsym-in-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-minsym-in-cu.exp @@ -24,11 +24,11 @@ set additional_flags [gdb_target_symbol_prefix_flags_asm] standard_testfile .S if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ ${additional_flags}]} { - return -1 + return } # The "info func" code tries to expand the corresponding symtab when a # minsym is found; and if this works, it omits the minsym from the # results. However, this test also does not include .debug_aranges, diff --git a/gdb/testsuite/gdb.dwarf2/dw2-missing-cu-tag.exp b/gdb/testsuite/gdb.dwarf2/dw2-missing-cu-tag.exp index 2819895b55ad..74a5ea90b130 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-missing-cu-tag.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-missing-cu-tag.exp @@ -39,11 +39,11 @@ Dwarf::assemble $asm_file { # Don't use prepare_for_testing here as we want to manually run the # file command (so we can check its output). if {[build_executable "failed to build executable" $testfile \ [list $srcfile $asm_file] {nodebug quiet}]} { - return -1 + return } set host_binfile [gdb_remote_download host $binfile] # Restart with no executable. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-modula2-self-type.exp b/gdb/testsuite/gdb.dwarf2/dw2-modula2-self-type.exp index 6624ce4cdfa7..28d16d535a96 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-modula2-self-type.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-modula2-self-type.exp @@ -19,11 +19,11 @@ require dwarf2_support standard_testfile .S # First try referencing DW_AT_frame_base which is not defined. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $testfile # C language would just naively print: diff --git a/gdb/testsuite/gdb.dwarf2/dw2-multiple-debug-info.exp b/gdb/testsuite/gdb.dwarf2/dw2-multiple-debug-info.exp index ada547a0440c..d8892be95d0e 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-multiple-debug-info.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-multiple-debug-info.exp @@ -26,11 +26,11 @@ lappend opts dwarf5 lappend opts c++ lappend opts additional_flags=-fdebug-types-section if { [gdb_compile "$srcdir/$subdir/$srcfile" "$binfile" object \ $opts] != "" } { - return -1 + return } clean_restart $::testfile gdb_test "ptype a" "type = class sp1::A .*" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-namespaceless-anonymous.exp b/gdb/testsuite/gdb.dwarf2/dw2-namespaceless-anonymous.exp index 8722be6bf09d..34f911eca126 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-namespaceless-anonymous.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-namespaceless-anonymous.exp @@ -53,10 +53,10 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "ptype '(anonymous namespace)::v'" "type = myint" gdb_test "p/d '(anonymous namespace)::v'" " = 1" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-no-code-cu.exp b/gdb/testsuite/gdb.dwarf2/dw2-no-code-cu.exp index 53ef496ea4ab..b3b9ea034fe8 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-no-code-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-no-code-cu.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile .c main.c if {[prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2"]} { - return -1 + return } set cmd "p var" set re \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-noloc.exp b/gdb/testsuite/gdb.dwarf2/dw2-noloc.exp index 230d39a7ed51..962e6ba2a512 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-noloc.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-noloc.exp @@ -209,11 +209,11 @@ Dwarf::assemble $asm_file { } } } if { [prepare_for_testing "failed to prepare" ${testfile} [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Symbols have the form: {file,main}_loc{addr,empty,no}_{,un}resolvable # file: Symbol DIE is placed in DW_TAG_compile_unit. # main: Symbol DIE is placed in DW_TAG_subprogram. @@ -271,11 +271,11 @@ proc file_symbols {type} { } file_symbols no-run if {![runto_main]} { - return -1 + return } file_symbols in-main diff --git a/gdb/testsuite/gdb.dwarf2/dw2-objfile-overlap.exp b/gdb/testsuite/gdb.dwarf2/dw2-objfile-overlap.exp index 3cb4cb4107f9..a7d32a63d8b9 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-objfile-overlap.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-objfile-overlap.exp @@ -27,11 +27,11 @@ set binfile_inner ${binfile}-inner.x if { [gdb_compile "${srcdir}/${subdir}/${srcfile_outer}" "${binfile_outer}" \ object {}] != "" || [gdb_compile "${srcdir}/${subdir}/${srcfile_inner}" "${binfile_inner}" \ object {}] != "" } { - return -1 + return } clean_restart $executable_outer set host_binfile_inner [gdb_remote_download host $binfile_inner] diff --git a/gdb/testsuite/gdb.dwarf2/dw2-op-call.exp b/gdb/testsuite/gdb.dwarf2/dw2-op-call.exp index eb5b67222bb5..852eb5b5e04c 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-op-call.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-op-call.exp @@ -21,11 +21,11 @@ require dwarf2_support standard_testfile .S main.c if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {nodebug}] } { - return -1 + return } # Additional test to verify the referenced CU is not aged out. gdb_test_no_output "maintenance set dwarf max-cache-age 0" @@ -33,9 +33,9 @@ gdb_test "p array1" " = 1" gdb_test "p array2" " = 2" "array2 using DW_OP_call2" gdb_test "p array3" " = 3" "array3 using DW_OP_call4" # Location lists need PC. if {![runto_main]} { - return -1 + return } gdb_test "p arraynoloc" " = " gdb_test "p arraycallnoloc" {Asked for position 0 of stack, stack only has 0 elements on it\.} diff --git a/gdb/testsuite/gdb.dwarf2/dw2-op-out-param.exp b/gdb/testsuite/gdb.dwarf2/dw2-op-out-param.exp index fa10f6b6c3cc..92fd7f71fb99 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-op-out-param.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-op-out-param.exp @@ -22,15 +22,15 @@ require dwarf2_support # This test can only be run on x86-64 targets. require is_x86_64_m64_target if { [prepare_for_testing "failed to prepare" "${test}" ${test}.S {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "breakpt" # Change the radix, making it easier to spot 0xdeadbeef in output. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-op-stack-value.exp b/gdb/testsuite/gdb.dwarf2/dw2-op-stack-value.exp index 196dd822cc81..0aa06852ac33 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-op-stack-value.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-op-stack-value.exp @@ -22,11 +22,11 @@ set additional_flags [gdb_target_symbol_prefix_flags_asm] standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" $binfile \ object {nodebug}] != "" } { - return -1 + return } clean_restart $testfile gdb_test "p/x stack2" " = 0x1" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-opt-structptr.exp b/gdb/testsuite/gdb.dwarf2/dw2-opt-structptr.exp index ef5e79dd68fd..7951d2514445 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-opt-structptr.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-opt-structptr.exp @@ -241,10 +241,10 @@ proc do_mi_test {} { "throw error, dereference ptr to access pointer member " } } if { [build_test_program] == -1 } { - return -1 + return } do_console_test do_mi_test diff --git a/gdb/testsuite/gdb.dwarf2/dw2-out-of-range-end-of-seq.exp b/gdb/testsuite/gdb.dwarf2/dw2-out-of-range-end-of-seq.exp index 63fe8bfaba72..3d790f1d4af8 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-out-of-range-end-of-seq.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-out-of-range-end-of-seq.exp @@ -74,15 +74,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set test "END with address 1 eliminated" gdb_test_multiple "maint info line-table \\b$srcfile$" $test { -re -wrap "END *0x0*1 *$hex *Y *\r\n.*" { diff --git a/gdb/testsuite/gdb.dwarf2/dw2-param-error.exp b/gdb/testsuite/gdb.dwarf2/dw2-param-error.exp index 9e4ea48c2470..cdd3923cb2c1 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-param-error.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-param-error.exp @@ -19,15 +19,15 @@ require dwarf2_support standard_testfile .S -main.c if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list $srcfile2 $srcfile] {nodebug}] } { - return -1 + return } if {![runto f]} { - return -1 + return } # FAIL was printing: # [...] in f (bad=) gdb_test "frame" { f \(bad=, good=23\)} diff --git a/gdb/testsuite/gdb.dwarf2/dw2-producer.exp b/gdb/testsuite/gdb.dwarf2/dw2-producer.exp index 23d233331bfa..8f50ab7b9c2e 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-producer.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-producer.exp @@ -20,11 +20,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_remote_download host ${srcdir}/${subdir}/${dwarf_srcfile} gdb_test_no_output "set listsize 1" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-prologue-end-2.exp b/gdb/testsuite/gdb.dwarf2/dw2-prologue-end-2.exp index 0bd6c0398638..acb9f3bb6006 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-prologue-end-2.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-prologue-end-2.exp @@ -71,11 +71,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Don't runto main here, otherwise the following doesn't # function as regression test for PR30369. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp b/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp index 76cf6f3309f9..294e7c8bf45f 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp @@ -78,15 +78,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set prologue_end_line [gdb_get_line_number "main assign o"] gdb_test "frame" ".*main \\\(\\\) at \[^\r\n\]*:$prologue_end_line\r\n.*" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp b/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp index f2271b54b494..0b792f8e4cf6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp @@ -116,15 +116,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Make use of the line numbers we faked in the .debug_line table above. gdb_test "info line main" \ "Line 11 of .* starts at address .* and ends at .*" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ranges-overlap.exp b/gdb/testsuite/gdb.dwarf2/dw2-ranges-overlap.exp index cbab1a8ede57..924752ccd65e 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ranges-overlap.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ranges-overlap.exp @@ -65,14 +65,14 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto foo]} { - return -1 + return } gdb_test "show language" \ "The current source language is \"auto; currently c\"\." diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym-warning.exp b/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym-warning.exp index b6486247620e..ea5ef93c014b 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym-warning.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym-warning.exp @@ -29,11 +29,11 @@ standard_testfile -main.c .c -dw.S # would do, but since we already have it specifically for this # testcase, might as well use that. if { [prepare_for_testing "failed to prepare" ${testfile} \ [list ${srcfile} ${srcfile2}]] } { - return -1 + return } set asm_file [standard_output_file $srcfile3] Dwarf::assemble $asm_file { global srcdir subdir srcfile srcfile2 @@ -100,19 +100,19 @@ Dwarf::assemble $asm_file { } } if { [build_executable "failed to prepare" ${testfile} \ [list $srcfile $srcfile2 $asm_file] {nodebug}] } { - return -1 + return } clean_restart gdb_load_no_complaints $binfile if {![runto_main]} { - return -1 + return } # Generate backtrace from baz, that visits the hole in the addrmap. If # the hole is there in the symbol table, but not the partial symbol table, # we run into: diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym.exp b/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym.exp index fa8a0e7d421c..eb4187f151cf 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ranges-psym.exp @@ -31,11 +31,11 @@ standard_testfile main.c .c -dw.S # would do, but since we already have it specifically for this # testcase, might as well use that. if { [prepare_for_testing "failed to prepare" ${testfile} \ [list ${srcfile} ${srcfile2}]] } { - return -1 + return } set asm_file [standard_output_file $srcfile3] Dwarf::assemble $asm_file { global srcdir subdir srcfile srcfile2 @@ -111,18 +111,18 @@ Dwarf::assemble $asm_file { } } if { [build_executable "failed to prepare" ${testfile} \ [list $srcfile $srcfile2 $asm_file] {nodebug}] } { - return -1 + return } clean_restart gdb_load_no_complaints $binfile if {![runto_main]} { - return -1 + return } # "someothername" should be put into the partial symbol table, but # there was a bug causing functions using DW_AT_ranges not to be. # Note we use a name that is very different from the linkage name, in diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ref-missing-frame.exp b/gdb/testsuite/gdb.dwarf2/dw2-ref-missing-frame.exp index 3ef8589f7bad..0ff1865da710 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ref-missing-frame.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ref-missing-frame.exp @@ -42,11 +42,11 @@ set executable ${testfile} if { [prepare_for_testing_full "failed to prepare" \ [list $testfile {} \ $srcfile [concat $flags {nodebug}] \ $srcfile2 {nodebug} \ $srcfile3 {debug}]] == -1 } { - return -1 + return } # First try referencing DW_AT_frame_base which is not defined. if {[runto func_nofb]} { gdb_test "p func_nofb_var" {Could not find the frame base for "func_nofb".} "func_nofb print" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-reg-undefined.exp b/gdb/testsuite/gdb.dwarf2/dw2-reg-undefined.exp index 10a801b2b631..b9a8cbbdb311 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-reg-undefined.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-reg-undefined.exp @@ -21,16 +21,16 @@ require dwarf2_support require is_x86_64_m64_target standard_testfile .S if { [prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug nopie}] } { - return -1 + return } if {![runto stop_frame]} { perror "Failed to stop in stop_frame" - return -1 + return } gdb_test "bt" "#0 (${::hex} in )?stop_frame \[^\r\n\]*\r\n#1 \[^\r\n\]*first_frame \[^\r\n\]*\r\n#2 \[^\r\n\]*main\[^\r\n\]*" \ "backtrace from stop_frame" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp b/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp index 29693c0c0376..c4aac0b4818b 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-regno-invalid.exp @@ -54,11 +54,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } runto_main # Variable 'bregx' needs to be inside main as for global symbols GDB does not diff --git a/gdb/testsuite/gdb.dwarf2/dw2-restore.exp b/gdb/testsuite/gdb.dwarf2/dw2-restore.exp index 98d80e7d6376..e0c334f80cc6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-restore.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-restore.exp @@ -26,13 +26,13 @@ if { [test_compiler_info clang*] } { lappend opts [list {additional_flags=-fno-integrated-as}] } if {[prepare_for_testing "failed to prepare" $testfile [list $srcfile] \ $opts]} { - return -1 + return } if {![runto foo]} { - return 0 + return } gdb_test "continue" "$hex in foo \\(\\)" gdb_test "where" "#0 +$hex in foo \\(\\)\r\n#1 +$hex in _start \\(\\)" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-restrict.exp b/gdb/testsuite/gdb.dwarf2/dw2-restrict.exp index 15b53dc1a1d1..be138b896938 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-restrict.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-restrict.exp @@ -23,9 +23,9 @@ require is_x86_64_m64_target standard_testfile .S if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {nodebug nopie}]} { - return -1 + return } gdb_test "ptype f" "int \\(char \\\* restrict\\)" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-simple-locdesc.exp b/gdb/testsuite/gdb.dwarf2/dw2-simple-locdesc.exp index a2864b1b0ce0..541e087c23f2 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-simple-locdesc.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-simple-locdesc.exp @@ -18,11 +18,11 @@ load_lib dwarf.exp require dwarf2_support standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart $testfile # Re: [patch 2/2] Fix decode_locdesc for gcc-4.7.x optimized DWARF diff --git a/gdb/testsuite/gdb.dwarf2/dw2-single-line-discriminators.exp b/gdb/testsuite/gdb.dwarf2/dw2-single-line-discriminators.exp index c7ffd9224e9d..6812d5b06b8f 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-single-line-discriminators.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-single-line-discriminators.exp @@ -26,11 +26,11 @@ require is_x86_64_m64_target standard_testfile .S set csrcfile ${testfile}.c if { [prepare_for_testing "failed to prepare" "${testfile}" $srcfile {nodebug nopie}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.exp b/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.exp index 582c343ad832..276793325d6d 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-skip-prologue.exp @@ -45,11 +45,11 @@ if {[is_ilp32_target]} { if { [build_executable ${testfile}.exp ${executable} \ "${testfile}.c ${testfile}.S" \ [list additional_flags=-DINLINED \ additional_flags=-DPTRBITS=$ptrbits]] == -1 } { - return -1 + return } # We need those symbols global to access them from the .S file. set test "strip stub symbols" set objcopy_program [gdb_find_objcopy] @@ -66,11 +66,11 @@ if {$result != 0} { pass $test clean_restart $executable if {![runto_main]} { - return -1 + return } gdb_breakpoint "func" gdb_continue_to_breakpoint "func" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-skipped-line-entries.exp b/gdb/testsuite/gdb.dwarf2/dw2-skipped-line-entries.exp index 2ab89b132f39..d3bafd4abf16 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-skipped-line-entries.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-skipped-line-entries.exp @@ -150,15 +150,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } # Check the END markers using 'maint info line-table'. # EXPECTED_SYMTAB is the basename of the source file being checked. # TEST_SPEC is a list of lists. Each inner list if a pair made of a diff --git a/gdb/testsuite/gdb.dwarf2/dw2-stack-boundary.exp b/gdb/testsuite/gdb.dwarf2/dw2-stack-boundary.exp index d76dea6f0805..a3bde43c62be 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-stack-boundary.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-stack-boundary.exp @@ -18,11 +18,11 @@ load_lib dwarf.exp require dwarf2_support standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } clean_restart gdb_test_no_output "maint set dwarf synchronous on" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-step-between-different-inline-functions.exp b/gdb/testsuite/gdb.dwarf2/dw2-step-between-different-inline-functions.exp index 76ca8ddc7f17..9ab8e1c953a9 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-step-between-different-inline-functions.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-step-between-different-inline-functions.exp @@ -178,15 +178,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" "${::testfile}" \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint bar gdb_continue_to_breakpoint "continue to bar line 1" \ ".*bar line 1\[^\r\n\]+" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-step-between-inline-func-blocks.exp b/gdb/testsuite/gdb.dwarf2/dw2-step-between-inline-func-blocks.exp index 506057df7322..33697ae9e4a3 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-step-between-inline-func-blocks.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-step-between-inline-func-blocks.exp @@ -161,15 +161,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" "${::testfile}" \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint bar gdb_continue_to_breakpoint "continue to bar line 1" \ ".*bar line 1\[^\r\n\]+" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-step-out-of-function-no-stmt.exp b/gdb/testsuite/gdb.dwarf2/dw2-step-out-of-function-no-stmt.exp index c381229397be..285cd00bfc53 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-step-out-of-function-no-stmt.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-step-out-of-function-no-stmt.exp @@ -97,15 +97,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Step into bar. gdb_breakpoint "bar" gdb_continue_to_breakpoint "bar" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-strp.exp b/gdb/testsuite/gdb.dwarf2/dw2-strp.exp index 6f3a867aaf60..7dbc94f57ca6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-strp.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-strp.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile .S if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_test "p a_string" " = \"hello world!\\\\n\"" gdb_test "ptype a_string" "type = const char \\\[14\\\]" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes-lookup.exp b/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes-lookup.exp index 9b1ccea00f66..0b2d7f64f754 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes-lookup.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes-lookup.exp @@ -89,11 +89,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" $testfile \ "${asm_file} ${srcfile}" {}] } { - return -1 + return } # Check that no symtabs are expanded. set test "no symtabs expanded" if { [readnow] } { diff --git a/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes.exp b/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes.exp index 7a1e4fb35b21..7c7c2a20432c 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-symtab-includes.exp @@ -61,18 +61,18 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" $testfile \ "${asm_file} ${srcfile}" {}] } { - return -1 + return } # Check that no symtabs are expanded. set test "no symtabs expanded" if { [readnow] } { unsupported $test - return -1 + return } gdb_test_no_output "maint info symtabs" $test # Expand dw2-symtab-includes.h symtab gdb_test "maint expand-symtab dw2-symtab-includes.h" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-tu-dwarf-4-5.exp b/gdb/testsuite/gdb.dwarf2/dw2-tu-dwarf-4-5.exp index 7493b2cbc554..359c8e128339 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-tu-dwarf-4-5.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-tu-dwarf-4-5.exp @@ -41,11 +41,11 @@ lappend lopts additional_flags=-nostdlib if { [prepare_for_testing_full "failed to prepare" \ [list $testfile $lopts \ $srcfile $opts \ $srcfile2 $opts2]] } { - return -1 + return } gdb_test_no_output \ [join \ [list \ diff --git a/gdb/testsuite/gdb.dwarf2/dw2-undefined-ret-addr.exp b/gdb/testsuite/gdb.dwarf2/dw2-undefined-ret-addr.exp index 88765d4f513a..8dac3949c5f6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-undefined-ret-addr.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-undefined-ret-addr.exp @@ -21,15 +21,15 @@ require dwarf2_support # This test can only be run on x86-64 targets. require is_x86_64_m64_target if {[prepare_for_testing "failed to prepare" "$testfile" $srcfile {nodebug nopie}]} { - return -1 + return } if {![runto "stop_frame"]} { - return -1 + return } # If test is compiled with clang, GDB would display absolute path. # This command keeps output consistent across toolchains. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-unresolved.exp b/gdb/testsuite/gdb.dwarf2/dw2-unresolved.exp index 06ce7a764785..1034ab5faf42 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-unresolved.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-unresolved.exp @@ -21,15 +21,15 @@ require dwarf2_support set additional_flags [gdb_target_symbol_prefix_flags_asm] if { [prepare_for_testing "failed to prepare" "dw2-unresolved" \ {dw2-unresolved-main.c dw2-unresolved.S} \ [list nodebug $additional_flags]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # This testcase tests LOC_UNRESOLVED works right. gdb_breakpoint "*extern_block_start" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-unspecified-type.exp b/gdb/testsuite/gdb.dwarf2/dw2-unspecified-type.exp index 7acfb714f3df..fe0974fd8f4f 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-unspecified-type.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-unspecified-type.exp @@ -91,15 +91,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" $testfile \ "${asm_file} ${srcfile} ${srcfile2}" {}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } foreach f {foo bar foo2} { # Print the function type. Return type should be stub type, which is printed # as void. diff --git a/gdb/testsuite/gdb.dwarf2/dw2-unusual-field-names.exp b/gdb/testsuite/gdb.dwarf2/dw2-unusual-field-names.exp index 43cdfccb1aef..b3bb1ed0f8c9 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-unusual-field-names.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-unusual-field-names.exp @@ -40,11 +40,11 @@ set asm_file [standard_output_file $srcfile2] # # For that, we ask GDB by debugging our test program. Any program # would do, but since we already have one specifically for this # testcase, might as well use that. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } set int_size [get_sizeof "int" -1] # Rebuild the test binary with the single field within the structure # renamed to FIELD_NAME, then test that we can access the field diff --git a/gdb/testsuite/gdb.dwarf2/dw2-using-debug-str.exp b/gdb/testsuite/gdb.dwarf2/dw2-using-debug-str.exp index 04ea209ddd7f..68d25f70375e 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-using-debug-str.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-using-debug-str.exp @@ -23,11 +23,11 @@ load_lib dwarf.exp require dwarf2_support standard_testfile .c -dw.S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { global srcfile @@ -84,15 +84,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Print the type of global_var. This type information is entirely # fictional, it only exists in the DWARF, but it contains lots of nice # field names, all of which are stored in the .debug_str section. @@ -120,22 +120,22 @@ set debug_str_section "${host_binfile}-debug-str" set args "--dump-section .debug_str=${debug_str_section} $host_binfile" set result [remote_exec host "[gdb_find_objcopy] $args"] set status [lindex $result 0] set output [lindex $result 1] if { $status == 0 && ![string equal $output ""] } { - return -1 + return } # Now copy the executable, and remove the .debug_str section. This # creates an executable with an invalid DWARF configuration. GDB # should give an error when trying to read the debug information from # this executable. set binfile_no_debug_str "${host_binfile}-no-debug-str" set args "--remove-section .debug_str $host_binfile ${binfile_no_debug_str}" if {[run_on_host "objcopy" [gdb_find_objcopy] "$args"]} { perror "failed to run objcopy" - return -1 + return } # Restart GDB, but don't load an executable. When we do load the # executable we're going to get an error, which we check for below. clean_restart diff --git a/gdb/testsuite/gdb.dwarf2/dw2-var-zero-addr.exp b/gdb/testsuite/gdb.dwarf2/dw2-var-zero-addr.exp index bbe74955e44b..04a2aa06ea93 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-var-zero-addr.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-var-zero-addr.exp @@ -19,11 +19,11 @@ require dwarf2_support standard_testfile .S main.c if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {nodebug}]} { - return -1 + return } proc test { } { # FAIL was: = (int *) 0x0 # Such DIE record can be produced using: gcc -fdata-sections -Wl,-gc-sections diff --git a/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp b/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp index d12b68311071..f02d82c3f220 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp @@ -62,13 +62,13 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "$srcfile:27" message diff --git a/gdb/testsuite/gdb.dwarf2/dw2-weird-type-len.exp b/gdb/testsuite/gdb.dwarf2/dw2-weird-type-len.exp index acc5c115d8e4..5d31a05b06be 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-weird-type-len.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-weird-type-len.exp @@ -86,15 +86,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # At one point this would trigger a divide by zero inside GDB. Now we # just get an error message. gdb_test "print get_bar ()" "could not determine alignment of type" diff --git a/gdb/testsuite/gdb.dwarf2/dw2-wrong-mangled-name.exp b/gdb/testsuite/gdb.dwarf2/dw2-wrong-mangled-name.exp index 26e8ffaba75e..bec85887e03d 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-wrong-mangled-name.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-wrong-mangled-name.exp @@ -52,15 +52,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "func_demangled_test" gdb_continue_to_breakpoint "func_demangled_test" diff --git a/gdb/testsuite/gdb.dwarf2/dw4-sig-type-unused.exp b/gdb/testsuite/gdb.dwarf2/dw4-sig-type-unused.exp index 15a01b616f32..b02f71422c0a 100644 --- a/gdb/testsuite/gdb.dwarf2/dw4-sig-type-unused.exp +++ b/gdb/testsuite/gdb.dwarf2/dw4-sig-type-unused.exp @@ -19,11 +19,11 @@ require dwarf2_support standard_testfile .S set executable ${testfile} if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" object {}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS --readnow" clean_restart $executable diff --git a/gdb/testsuite/gdb.dwarf2/dw4-sig-types.exp b/gdb/testsuite/gdb.dwarf2/dw4-sig-types.exp index cf731e3d1108..bb0769050bcd 100644 --- a/gdb/testsuite/gdb.dwarf2/dw4-sig-types.exp +++ b/gdb/testsuite/gdb.dwarf2/dw4-sig-types.exp @@ -24,18 +24,18 @@ include_file dw4-sig-types.h # we let that be the test of whether the target supports it. if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list $srcfile $srcfile2] \ {debug c++ additional_flags=-gdwarf-4 additional_flags=-fdebug-types-section}] } { - return -1 + return } # Stress test gdb's handling of cached comp units, disable the cache. gdb_test_no_output "maint set dwarf max-cache-age 0" if {![runto_main]} { - return -1 + return } # Bring symtab for myset into gdb. gdb_test "p myset" ".*" diff --git a/gdb/testsuite/gdb.dwarf2/dw4-toplevel-types.exp b/gdb/testsuite/gdb.dwarf2/dw4-toplevel-types.exp index 8429af8574d5..0f9b8385bed6 100644 --- a/gdb/testsuite/gdb.dwarf2/dw4-toplevel-types.exp +++ b/gdb/testsuite/gdb.dwarf2/dw4-toplevel-types.exp @@ -22,15 +22,15 @@ standard_testfile .cc # we let that be the test of whether the target supports it. if { [prepare_for_testing "failed to prepare" "${testfile}" \ $srcfile {debug c++ additional_flags=-gdwarf-4 \ additional_flags=-fdebug-types-section}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "ptype X" "type = struct X {.*" gdb_test "ptype Y" "type = struct Y {.*" gdb_test "ptype Z" "type = struct Z {.*" diff --git a/gdb/testsuite/gdb.dwarf2/dw5-rnglist-test.exp b/gdb/testsuite/gdb.dwarf2/dw5-rnglist-test.exp index 9e47cdac5fc1..02f1777bdd58 100644 --- a/gdb/testsuite/gdb.dwarf2/dw5-rnglist-test.exp +++ b/gdb/testsuite/gdb.dwarf2/dw5-rnglist-test.exp @@ -23,15 +23,15 @@ standard_testfile .cc # Since we pass an explicit -gdwarf-5 to the compiler, # we let that be the test of whether the target supports it. if { [prepare_for_testing "failed to prepare" "${testfile}" \ $srcfile {debug c++ dwarf5 additional_flags=-O0}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.dwarf2/dwp-sepdebug.exp b/gdb/testsuite/gdb.dwarf2/dwp-sepdebug.exp index 4ca793059ba3..9e203809e844 100644 --- a/gdb/testsuite/gdb.dwarf2/dwp-sepdebug.exp +++ b/gdb/testsuite/gdb.dwarf2/dwp-sepdebug.exp @@ -14,15 +14,15 @@ # along with this program. If not, see . standard_testfile if { [build_executable ${testfile}.exp ${testfile} ${srcfile}] == -1 } { - return -1 + return } if {![remote_file host exists [standard_output_file ${testfile}.dwp]]} { unsupported "testsuite run does not produce dwp files" - return 0 + return } # Note: the procedure gdb_gnu_strip_debug will produce an executable called # ${binfile}, which is just like the executable ($binfile) but without # the debuginfo. Instead $binfile has a .gnu_debuglink section which contains @@ -30,11 +30,11 @@ if {![remote_file host exists [standard_output_file ${testfile}.dwp]]} { # gdb.base/ subdirectory. if {[gdb_gnu_strip_debug $binfile$EXEEXT]} { # check that you have a recent version of strip and objcopy installed unsupported "cannot produce separate debug info files" - return -1 + return } clean_restart "$testfile" gdb_test "ptype main" {type = int \(int, char \*\*\)} diff --git a/gdb/testsuite/gdb.dwarf2/dwp-symlink.exp b/gdb/testsuite/gdb.dwarf2/dwp-symlink.exp index fa1ed877d7e7..fb1202afae9f 100644 --- a/gdb/testsuite/gdb.dwarf2/dwp-symlink.exp +++ b/gdb/testsuite/gdb.dwarf2/dwp-symlink.exp @@ -16,33 +16,33 @@ standard_testfile remote_file host delete [standard_output_file ${testfile}.dwp] if {[remote_file host exists [standard_output_file ${testfile}.dwp]]} { unsupported "dwp file cannot be deleted" - return 0 + return } if { [build_executable ${testfile}.exp ${testfile} ${srcfile}] == -1 } { - return -1 + return } if {![remote_file host exists [standard_output_file ${testfile}.dwp]]} { unsupported "testsuite run does not produce dwp files" - return 0 + return } set thelink "${testfile}-thelink" remote_file host delete [standard_output_file ${thelink}] remote_file host delete [standard_output_file ${thelink}.dwp] # file link is only Tcl 8.4+. remote_exec host "ln -sf ${testfile} [standard_output_file $thelink]" if {![remote_file host exists [standard_output_file $thelink]]} { unsupported "host does not support symbolic links (binary symlink is missing)" - return 0 + return } if {[remote_file host exists [standard_output_file $thelink.dwp]]} { unsupported "host does not support symbolic links (we tried to delete a file and it is still there)" - return 0 + return } clean_restart "$testfile" set main_type_re [string_to_regexp "type = int (int, char **)"] @@ -55,15 +55,15 @@ gdb_test "ptype main" $main_type_re "binary symlink, dwp default" gdb_exit remote_exec host "mv -f [standard_output_file ${testfile}.dwp] [standard_output_file ${thelink}.dwp]" if {[remote_file host exists [standard_output_file ${testfile}.dwp]]} { unsupported "host does not support symbolic links (binary symlink exists)" - return 0 + return } if {![remote_file host exists [standard_output_file ${thelink}.dwp]]} { unsupported "host does not support symbolic links (dwp symlink is missing)" - return 0 + return } clean_restart "$testfile" gdb_test "ptype main" \ @@ -124,10 +124,10 @@ remote_exec host "ln -sf ${dwp_bin_dir}/${dwp_real_binary} ${dwp_symlink_dir}/${ remote_exec host "ln -sf ${dwp_dwp_dir}/${dwp_real_dwp} ${dwp_symlink_dir}/${dwp_symlink_dwp}" clean_restart "${dwp_symlink_dir}/${dwp_symlink_binary}" if {![runto_main]} { - return -1 + return } gdb_test {print argv[0]} "/${dwp_symlink_binary}\"" \ "separate executable/dwp symlinks" diff --git a/gdb/testsuite/gdb.dwarf2/dwz-many.exp b/gdb/testsuite/gdb.dwarf2/dwz-many.exp index 551dd070958d..f11fd54c5909 100644 --- a/gdb/testsuite/gdb.dwarf2/dwz-many.exp +++ b/gdb/testsuite/gdb.dwarf2/dwz-many.exp @@ -40,11 +40,11 @@ if {[prepare_for_testing_full "failed to prepare" \ [list \ $testfile {debug} \ $srcfile {nodebug} \ $asm_file {nodebug} \ $srcfile3 {debug}]]} { - return -1 + return } set linenr [gdb_get_line_number "return 0" $srcfile3] for {set i 0} {$i < 100} {incr i} { diff --git a/gdb/testsuite/gdb.dwarf2/dwz-unused-pu.exp b/gdb/testsuite/gdb.dwarf2/dwz-unused-pu.exp index 4d074fb7464f..db497636d64a 100644 --- a/gdb/testsuite/gdb.dwarf2/dwz-unused-pu.exp +++ b/gdb/testsuite/gdb.dwarf2/dwz-unused-pu.exp @@ -54,11 +54,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" $testfile \ [list $asm_file $srcfile] {nodebug}] } { - return -1 + return } set cmd "p the_int" set re \ [string_to_regexp \ diff --git a/gdb/testsuite/gdb.dwarf2/dwz.exp b/gdb/testsuite/gdb.dwarf2/dwz.exp index c907a64f53f8..96dab6cf9309 100644 --- a/gdb/testsuite/gdb.dwarf2/dwz.exp +++ b/gdb/testsuite/gdb.dwarf2/dwz.exp @@ -79,14 +79,14 @@ Dwarf::assemble $asm_file { } } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile}" {}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "p other_int" " = 99" gdb_test "p the_int" " = 23" diff --git a/gdb/testsuite/gdb.dwarf2/dwznolink.exp b/gdb/testsuite/gdb.dwarf2/dwznolink.exp index e6c6ce6005d4..898ae1637f50 100644 --- a/gdb/testsuite/gdb.dwarf2/dwznolink.exp +++ b/gdb/testsuite/gdb.dwarf2/dwznolink.exp @@ -44,11 +44,11 @@ Dwarf::assemble $asm_file { # We can't use prepare_for_testing here because we need to check the # 'file' command's output. if {[build_executable $testfile.exp $testfile \ [list $srcfile $asm_file] {nodebug quiet}]} { - return -1 + return } clean_restart gdb_test "file -readnow $binfile" \ "could not find supplementary DWARF file" \ diff --git a/gdb/testsuite/gdb.dwarf2/dyn-type-unallocated.exp b/gdb/testsuite/gdb.dwarf2/dyn-type-unallocated.exp index b4ebd7002fc0..75eb35ec9a57 100644 --- a/gdb/testsuite/gdb.dwarf2/dyn-type-unallocated.exp +++ b/gdb/testsuite/gdb.dwarf2/dyn-type-unallocated.exp @@ -41,11 +41,11 @@ standard_testfile .c -dw.S set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/attributes.h if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $flags] } { - return -1 + return } with_shared_gdb { set func_info_vars [get_func_info main $flags] @@ -124,15 +124,15 @@ set flags {} lappend flags {nodebug} lappend_include_file flags $srcdir/lib/attributes.h if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list $srcfile $asm_file] $flags] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint "marker_label" gdb_continue_to_breakpoint "stop at marker_label" gdb_test "ptype dyn_object" "type = integer, allocatable \\(:\\)" diff --git a/gdb/testsuite/gdb.dwarf2/dynamic-bit-offset.exp b/gdb/testsuite/gdb.dwarf2/dynamic-bit-offset.exp index c87358ae947f..33ad0de8691f 100644 --- a/gdb/testsuite/gdb.dwarf2/dynamic-bit-offset.exp +++ b/gdb/testsuite/gdb.dwarf2/dynamic-bit-offset.exp @@ -86,11 +86,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } gdb_test_no_output "set language ada" gdb_test "print value" \ [string_to_regexp " = (disc => 3, nums => (7, 11, 13))"] diff --git a/gdb/testsuite/gdb.dwarf2/dynarr-ptr.exp b/gdb/testsuite/gdb.dwarf2/dynarr-ptr.exp index b7266db2affd..1f759c31dedb 100644 --- a/gdb/testsuite/gdb.dwarf2/dynarr-ptr.exp +++ b/gdb/testsuite/gdb.dwarf2/dynarr-ptr.exp @@ -25,11 +25,11 @@ standard_testfile .c -dw.S # For that, we ask GDB by debugging our dynarr-ptr.c program. # Any program would do, but since we already have dynarr-ptr.c # specifically for this testcase, might as well use that. if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Make some DWARF for the test. set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { @@ -119,15 +119,15 @@ Dwarf::assemble $asm_file { # program using our debug info instead of the info generated by # the compiler. if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set language ada" # foo.three_ptr.all diff --git a/gdb/testsuite/gdb.dwarf2/enqueued-cu-base-addr.exp b/gdb/testsuite/gdb.dwarf2/enqueued-cu-base-addr.exp index 6cffbd377933..31eb5f6a8396 100644 --- a/gdb/testsuite/gdb.dwarf2/enqueued-cu-base-addr.exp +++ b/gdb/testsuite/gdb.dwarf2/enqueued-cu-base-addr.exp @@ -70,11 +70,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Expand cu1. This will enqueue cu2. set cu1_expanded 0 gdb_test_multiple "ptype foo" "" { diff --git a/gdb/testsuite/gdb.dwarf2/enum-type-c++.exp b/gdb/testsuite/gdb.dwarf2/enum-type-c++.exp index 392632545621..827fe67bc08b 100644 --- a/gdb/testsuite/gdb.dwarf2/enum-type-c++.exp +++ b/gdb/testsuite/gdb.dwarf2/enum-type-c++.exp @@ -22,11 +22,11 @@ require dwarf2_support standard_testfile main.c .cc if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] {debug c++}] } { - return -1 + return } require {string equal [have_index $binfile] ""} set lines [gdb_get_lines "maint print objfiles"] diff --git a/gdb/testsuite/gdb.dwarf2/enum-type.exp b/gdb/testsuite/gdb.dwarf2/enum-type.exp index 7a37608670ec..5af889a35441 100644 --- a/gdb/testsuite/gdb.dwarf2/enum-type.exp +++ b/gdb/testsuite/gdb.dwarf2/enum-type.exp @@ -102,11 +102,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "print sizeof(enum E)" " = 4" gdb_test "ptype enum EU" \ diff --git a/gdb/testsuite/gdb.dwarf2/fission-absolute-dwo.exp b/gdb/testsuite/gdb.dwarf2/fission-absolute-dwo.exp index 4b87c48ad4a3..e173e728a109 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-absolute-dwo.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-absolute-dwo.exp @@ -108,18 +108,18 @@ Dwarf::assemble $asm_file { # ASM_FILE we split out the debug information into the dwo file. set object_file [standard_output_file ${testfile}.o] if { [build_executable_and_dwo_files "${testfile}.exp" ${binfile} {nodebug} \ [list $asm_file {nodebug split-dwo} ${object_file}] \ [list $srcfile {nodebug}]] } { - return -1 + return } # Now we can start GDB. clean_restart ${testfile} if {![runto_main]} { - return -1 + return } # Print the type of global_var. This type information is entirely # fictional, it only exists in the DWARF. If we don't have the DWARF # information then there's no way we can print this. diff --git a/gdb/testsuite/gdb.dwarf2/fission-base.exp b/gdb/testsuite/gdb.dwarf2/fission-base.exp index d1abf6c9eb7b..28507eac9ba1 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-base.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-base.exp @@ -30,17 +30,17 @@ set obj [standard_output_file "${testfile}.o"] set dwo [standard_output_file "${testfile}.dwo"] if {[build_executable_and_dwo_files "$testfile.exp" "${binfile}" {nodebug} \ [list $srcfile \ [list nodebug split-dwo additional_flags=-DDWO=\"$dwo\"] \ $obj]]} { - return -1 + return } clean_restart $::testfile if {![runto_main]} { - return -1 + return } # Do a few basic things to verify we're finding the DWO debug info. gdb_test "ptype main" "type = int \\(\\)" diff --git a/gdb/testsuite/gdb.dwarf2/fission-loclists-pie.exp b/gdb/testsuite/gdb.dwarf2/fission-loclists-pie.exp index 30e7d3913332..04072731754c 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-loclists-pie.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-loclists-pie.exp @@ -36,17 +36,17 @@ set dwo [standard_output_file "${testfile}.dwo"] if {[build_executable_and_dwo_files "$testfile.exp" "${binfile}" \ {nodebug pie} \ [list $srcfile \ [list nodebug split-dwo additional_flags=-DDWO=\"$dwo\"] \ $obj]]} { - return -1 + return } clean_restart $::testfile if {![runto_main]} { - return -1 + return } # Verify gdb can find argc. gdb_test "p argc" " = 1" diff --git a/gdb/testsuite/gdb.dwarf2/fission-loclists.exp b/gdb/testsuite/gdb.dwarf2/fission-loclists.exp index f081ea007734..6747192b1644 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-loclists.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-loclists.exp @@ -30,17 +30,17 @@ set obj [standard_output_file "${testfile}.o"] set dwo [standard_output_file "${testfile}.dwo"] if {[build_executable_and_dwo_files "$testfile.exp" "${binfile}" {nodebug} \ [list $srcfile \ [list nodebug split-dwo additional_flags=-DDWO=\"$dwo\"] \ $obj]]} { - return -1 + return } clean_restart $::testfile if {![runto_main]} { - return -1 + return } # Verify gdb can find argc. gdb_test "p argc" " = 1" diff --git a/gdb/testsuite/gdb.dwarf2/fission-mix.exp b/gdb/testsuite/gdb.dwarf2/fission-mix.exp index 7a4cfe5b22cc..be7916c558a9 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-mix.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-mix.exp @@ -24,17 +24,17 @@ include_file fission-mix.h set objfile [standard_output_file ${testfile}.o] set objfile2 [standard_output_file ${testfile}2.o] # Compile fission-mix.c without Fission and fission-mix-2.c with Fission. if { [gdb_compile ${srcdir}/${subdir}/${srcfile} $objfile object {debug}] != "" } { - return -1 + return } if { [gdb_compile ${srcdir}/${subdir}/${srcfile2} $objfile2 object {debug additional_flags=-gsplit-dwarf}] != "" } { - return -1 + return } if {[gdb_compile "$objfile $objfile2" $binfile executable {debug}] != "" } { - return -1 + return } clean_restart $::testfile gdb_test "break -q main" "Breakpoint .*" diff --git a/gdb/testsuite/gdb.dwarf2/fission-multi-cu.exp b/gdb/testsuite/gdb.dwarf2/fission-multi-cu.exp index f40e2f059465..0621069174bc 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-multi-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-multi-cu.exp @@ -198,17 +198,17 @@ set obj1 [standard_output_file "${testfile}-1-dw.o"] set obj2 [standard_output_file "${testfile}-2-dw.o"] if {[build_executable_and_dwo_files "$testfile.exp" "${binfile}" {nodebug} \ [list $asm_file_1 [list nodebug split-dwo] $obj1] \ [list $asm_file_2 [list nodebug split-dwo] $obj2] \ [list $srcfile [list nodebug]]]} { - return -1 + return } clean_restart $::testfile if {![runto_main]} { - return -1 + return } # Do a few basic things to verify we're finding the DWO debug info. gdb_test "ptype main" "type = int \\(\\)" diff --git a/gdb/testsuite/gdb.dwarf2/fission-relative-dwo.exp b/gdb/testsuite/gdb.dwarf2/fission-relative-dwo.exp index e246fac17b4c..6fe3e0b216b3 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-relative-dwo.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-relative-dwo.exp @@ -105,18 +105,18 @@ Dwarf::assemble $asm_file { # ASM_FILE we split out the debug information into the dwo file. set object_file [standard_output_file ${testfile}.o] if { [build_executable_and_dwo_files "${testfile}.exp" ${testfile} {nodebug} \ [list $asm_file {nodebug split-dwo} ${object_file}] \ [list $srcfile {nodebug}]] } { - return -1 + return } # Now we can start GDB. clean_restart ${testfile} if {![runto_main]} { - return -1 + return } # Print the type of global_var. This type information is entirely # fictional, it only exists in the DWARF. If we don't have the DWARF # information then there's no way we can print this. diff --git a/gdb/testsuite/gdb.dwarf2/fission-reread.exp b/gdb/testsuite/gdb.dwarf2/fission-reread.exp index b7e6cf2de65c..7fa70bcafe92 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-reread.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-reread.exp @@ -38,11 +38,11 @@ set dwo_options $options lappend dwo_options split-dwo lappend dwo_options additional_flags=-DDWO=\"$dwo\" if {[build_executable_and_dwo_files "$testfile.exp" "${binfile}" $options \ [list $srcfile $dwo_options $obj]]} { - return -1 + return } # Load FILENAME, perform some basic tests to confirm that the debug # information has been found, then unload FILENAME. proc run_test { filename } { diff --git a/gdb/testsuite/gdb.dwarf2/fission-type-unit-locexpr.exp b/gdb/testsuite/gdb.dwarf2/fission-type-unit-locexpr.exp index 5d94473c5ad6..47fc2fbd1dee 100644 --- a/gdb/testsuite/gdb.dwarf2/fission-type-unit-locexpr.exp +++ b/gdb/testsuite/gdb.dwarf2/fission-type-unit-locexpr.exp @@ -145,11 +145,11 @@ Dwarf::assemble $asm_file { set object_file [standard_output_file ${testfile}.o] if { [build_executable_and_dwo_files "${testfile}.exp" ${binfile} {nodebug} \ [list $asm_file {nodebug split-dwo} ${object_file}] \ [list $srcfile {nodebug}]] } { - return -1 + return } proc run_test { testfile } { clean_restart ${testfile} diff --git a/gdb/testsuite/gdb.dwarf2/formdata16.exp b/gdb/testsuite/gdb.dwarf2/formdata16.exp index 8169fa5e2c6b..ee35fdf0f058 100644 --- a/gdb/testsuite/gdb.dwarf2/formdata16.exp +++ b/gdb/testsuite/gdb.dwarf2/formdata16.exp @@ -21,11 +21,11 @@ require dwarf2_support standard_testfile main.c -dw.S # We need to know the endianess in order # to write some of the debugging info we'd like to generate. if {[prepare_for_testing "failed to prepare for endianness test" ${testfile} ${srcfile}]} { - return -1 + return } set endianness [get_endianness] set high "0x123456789abcdef0" @@ -82,11 +82,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "p/x xxx" " = 0x123456789abcdef00fedcba987654321" gdb_test "p xxx" "= 24197857203266734864629346612071973665" gdb_test "p/x yyy" " = 0xfedcba987654321" diff --git a/gdb/testsuite/gdb.dwarf2/fortran-var-string.exp b/gdb/testsuite/gdb.dwarf2/fortran-var-string.exp index b96740384fd9..925872bc2c89 100644 --- a/gdb/testsuite/gdb.dwarf2/fortran-var-string.exp +++ b/gdb/testsuite/gdb.dwarf2/fortran-var-string.exp @@ -25,11 +25,11 @@ standard_testfile .c -dw.S # For that, we ask GDB by debugging our dynarr-ptr.c program. # Any program would do, but since we already have dynarr-ptr.c # specifically for this testcase, might as well use that. if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Make some DWARF for the test. set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { @@ -136,15 +136,15 @@ Dwarf::assemble $asm_file { # program using our debug info instead of the info generated by # the compiler. if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set language fortran" gdb_test "info functions test_1_func" \ diff --git a/gdb/testsuite/gdb.dwarf2/forward-spec-inter-cu.exp b/gdb/testsuite/gdb.dwarf2/forward-spec-inter-cu.exp index ebcf375c5413..eb1d8a2df58f 100644 --- a/gdb/testsuite/gdb.dwarf2/forward-spec-inter-cu.exp +++ b/gdb/testsuite/gdb.dwarf2/forward-spec-inter-cu.exp @@ -73,11 +73,11 @@ Dwarf::assemble $asm_file { } } if {[build_executable "failed to build executable" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } set eol "\r\n" set ws "\[ \t\]" diff --git a/gdb/testsuite/gdb.dwarf2/forward-spec.exp b/gdb/testsuite/gdb.dwarf2/forward-spec.exp index af55d7e2eb77..fd7d008adb34 100644 --- a/gdb/testsuite/gdb.dwarf2/forward-spec.exp +++ b/gdb/testsuite/gdb.dwarf2/forward-spec.exp @@ -69,11 +69,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } require {string equal [have_index $binfile] ""} set re_ws "\[ \t\]" diff --git a/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp b/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp index 6245fbe66bd6..6d3bf29c1b10 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp @@ -37,22 +37,22 @@ with_test_prefix non-symlink { } # Regenerate exec without index. if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list ${srcfile}]] } { - return -1 + return } set symlink [file dirname $binfile]/symlink if { ![file exists $symlink] } { file link -symbolic $symlink $binfile } if { [ensure_gdb_index $symlink] == -1 } { fail "Unable to call gdb-add-index with a symlink to a symfile" - return -1 + return } # Ok, we have a copy of $binfile with an index. # Restart gdb and verify the index was used. diff --git a/gdb/testsuite/gdb.dwarf2/gdb-add-index.exp b/gdb/testsuite/gdb.dwarf2/gdb-add-index.exp index faf1aa7c5a02..4d91987bbb83 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-add-index.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-add-index.exp @@ -20,16 +20,16 @@ require dwarf2_support standard_testfile main.c if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list ${srcfile}]] } { - return -1 + return } if { [ensure_gdb_index $binfile] == -1 } { untested "error adding gdb index" - return -1 + return } # Ok, we have a copy of $binfile with an index. # Restart gdb and verify the index was used. diff --git a/gdb/testsuite/gdb.dwarf2/gdb-index-cxx.exp b/gdb/testsuite/gdb.dwarf2/gdb-index-cxx.exp index c964988bc88d..351abc225d75 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-index-cxx.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-index-cxx.exp @@ -22,11 +22,11 @@ lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[prepare_for_testing "failed to prepare" "${testfile}" \ [list ${srcfile}] $opts]} { - return -1 + return } # The bug was that gdb would crash when saving. set output_dir [host_standard_output_file ""] set cmd "save gdb-index" diff --git a/gdb/testsuite/gdb.dwarf2/gdb-index-nodebug.exp b/gdb/testsuite/gdb.dwarf2/gdb-index-nodebug.exp index f0d37362bacf..50f08b59e281 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-index-nodebug.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-index-nodebug.exp @@ -17,11 +17,11 @@ load_lib dwarf.exp standard_testfile main.c if {[prepare_for_testing "failed to prepare" "${testfile}" \ [list ${srcfile}] {nodebug}]} { - return -1 + return } set have_index [have_index $binfile] set have_index_re \ [list \ diff --git a/gdb/testsuite/gdb.dwarf2/gdb-index-tilde.exp b/gdb/testsuite/gdb.dwarf2/gdb-index-tilde.exp index e22fc606ca6f..0930e1010432 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-index-tilde.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-index-tilde.exp @@ -33,19 +33,19 @@ set home $::env(HOME) # Check that FULL_DIR is within the $HOME directory. If it's not, then # that's fine, but we can't test tilde expansion in this case. if { [string compare -length [string length $home] $full_dir $home] != 0 } { unsupported "test not run within home directory" - return -1 + return } # Convert the $HOME prefix in to ~. set dir "~[string range $full_dir [string length $home] end]" # Build the test executable. if { [prepare_for_testing "failed to prepare" "${testfile}" ${srcfile}] } { - return -1 + return } # Start GDB and load in the executable. clean_restart ${::testfile} @@ -71,16 +71,16 @@ gdb_test_multiple "maint print objfile $binfile" "check we can generate an index } } if { $has_index } { unsupported "already have an index" - return -1 + return } if { !$can_dump_index } { unsupported "lacks debug information needed to dump index" - return -1 + return } # Generate an index file. gdb_test_no_output "save gdb-index $dir" \ "save gdb-index to tilde based directory" diff --git a/gdb/testsuite/gdb.dwarf2/gdb-index-types-dwarf5.exp b/gdb/testsuite/gdb.dwarf2/gdb-index-types-dwarf5.exp index 94fc0ade3f18..cf1eff88bffe 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-index-types-dwarf5.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-index-types-dwarf5.exp @@ -23,16 +23,16 @@ set flags {} lappend flags {additional_flags=-fdebug-types-section} lappend flags {dwarf5} if { [prepare_for_testing "failed to prepare" ${testfile} \ $srcfile $flags] } { - return -1 + return } if { [ensure_gdb_index $binfile] != 1 } { untested "error adding gdb index" - return -1 + return } clean_restart ${::testfile} # Verify that .gdb_index section is not ignored. diff --git a/gdb/testsuite/gdb.dwarf2/gdb-index.exp b/gdb/testsuite/gdb.dwarf2/gdb-index.exp index 91e7ef5a5e14..456d7266c599 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-index.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-index.exp @@ -23,11 +23,11 @@ require !readnow standard_testfile main.c if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list ${srcfile}]] } { - return -1 + return } # Add a .gdb_index section to PROGRAM. # PROGRAM is assumed to be the output of standard_output_file. # Returns the path of the program or "" if there is a failure. @@ -139,14 +139,14 @@ gdb_test "mt print objfiles ${testfile}" \ # There is gdb_touch_execfile, but it doesn't handle remote hosts. # Is touch portable enough? # First make sure enough time has passed, file mtime resolution is seconds. gdb_test_no_output "shell sleep 1" if {[run_on_host "touch binary" touch $host_binfile_with_index]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "mt print objfiles ${testfile}" \ "(gdb_index|debug_names).*" \ "index used after symbol reloading" diff --git a/gdb/testsuite/gdb.dwarf2/implptr-optimized-out.exp b/gdb/testsuite/gdb.dwarf2/implptr-optimized-out.exp index 09fefaed496d..ac4f0491198d 100644 --- a/gdb/testsuite/gdb.dwarf2/implptr-optimized-out.exp +++ b/gdb/testsuite/gdb.dwarf2/implptr-optimized-out.exp @@ -75,14 +75,14 @@ Dwarf::assemble $asm_file { } } } if {[prepare_for_testing "failed to prepare" $executable "${asm_file} ${srcfile}" {}]} { - return -1 + return } # DW_OP_GNU_implicit_pointer implementation requires a valid frame. if {![runto_main]} { - return -1 + return } gdb_test "p p->f" " = " diff --git a/gdb/testsuite/gdb.dwarf2/implptr.exp b/gdb/testsuite/gdb.dwarf2/implptr.exp index 495c0de0297a..d30951c083de 100644 --- a/gdb/testsuite/gdb.dwarf2/implptr.exp +++ b/gdb/testsuite/gdb.dwarf2/implptr.exp @@ -33,18 +33,18 @@ if {[info exists COMPILE]} { set srcfile ${csrcfile} lappend opts debug optimize=-O2 } if {[prepare_for_testing "failed to prepare" ${testfile} $srcfile $opts]} { - return -1 + return } # Additional test to verify the referenced CU is not aged out. gdb_test_no_output "maintenance set dwarf max-cache-age 0" if {![runto_main]} { - return -1 + return } # Test various pointer depths in bar. proc implptr_test_bar {} { global csrcfile diff --git a/gdb/testsuite/gdb.dwarf2/implptrconst.exp b/gdb/testsuite/gdb.dwarf2/implptrconst.exp index 7e1daf02d73c..49684e3ec0cb 100644 --- a/gdb/testsuite/gdb.dwarf2/implptrconst.exp +++ b/gdb/testsuite/gdb.dwarf2/implptrconst.exp @@ -83,14 +83,14 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print *c" " = 114 'r'" gdb_test "print d\[-2\]" " = 114 'r'" diff --git a/gdb/testsuite/gdb.dwarf2/implptrpiece.exp b/gdb/testsuite/gdb.dwarf2/implptrpiece.exp index d262f78485f6..9211cf6d24a0 100644 --- a/gdb/testsuite/gdb.dwarf2/implptrpiece.exp +++ b/gdb/testsuite/gdb.dwarf2/implptrpiece.exp @@ -101,15 +101,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Determine byte order. set endian [get_endianness] diff --git a/gdb/testsuite/gdb.dwarf2/implref-array.exp b/gdb/testsuite/gdb.dwarf2/implref-array.exp index a3f5b98768dc..dfa676de6933 100644 --- a/gdb/testsuite/gdb.dwarf2/implref-array.exp +++ b/gdb/testsuite/gdb.dwarf2/implref-array.exp @@ -35,11 +35,11 @@ set asm_file [standard_output_file ${srcfile2}] # # For that, we ask GDB by debugging our implref-array program. # Any program would do, but since we already have implref-array # specifically for this testcase, might as well use that. if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set array_length [get_valueof "/u" "sizeof(array) / sizeof(array\[0\])" -1] # Create the DWARF. We need a regular variable which represents the array, and @@ -112,16 +112,16 @@ Dwarf::assemble ${asm_file} { } } } if {[prepare_for_testing "failed to prepare" ${executable} [list ${asm_file} ${srcfile}] {}]} { - return -1 + return } # DW_OP_GNU_implicit_pointer implementation requires a valid frame. if {![runto_main]} { - return -1 + return } # This matches e.g. '(int (&)[5])' set ref_type [format {\(int \(&\)\[%d\]\)} ${array_length}] diff --git a/gdb/testsuite/gdb.dwarf2/implref-const.exp b/gdb/testsuite/gdb.dwarf2/implref-const.exp index 9c30633af036..0d79e05f8ef0 100644 --- a/gdb/testsuite/gdb.dwarf2/implref-const.exp +++ b/gdb/testsuite/gdb.dwarf2/implref-const.exp @@ -35,11 +35,11 @@ set asm_file [standard_output_file ${srcfile2}] # # For that, we ask GDB by debugging our implref-const program. # Any program would do, but since we already have implref-const # specifically for this testcase, might as well use that. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Create the DWARF. We need a regular variable and a reference to it that'll # be marked with DW_OP_GNU_implicit_pointer. Dwarf::assemble ${asm_file} { @@ -91,16 +91,16 @@ Dwarf::assemble ${asm_file} { } } } if {[prepare_for_testing "failed to prepare" ${executable} [list ${asm_file} ${srcfile}] {}]} { - return -1 + return } # DW_OP_GNU_implicit_pointer implementation requires a valid frame. if {![runto_main]} { - return -1 + return } # Doing 'print ref' should show us e.g. '(int &) : 42'. gdb_test "print ref" " = \\(int &\\) : \\\d+" diff --git a/gdb/testsuite/gdb.dwarf2/implref-global.exp b/gdb/testsuite/gdb.dwarf2/implref-global.exp index d861c76ec3fc..4c2466756e3c 100644 --- a/gdb/testsuite/gdb.dwarf2/implref-global.exp +++ b/gdb/testsuite/gdb.dwarf2/implref-global.exp @@ -35,11 +35,11 @@ set asm_file [standard_output_file ${srcfile2}] # # For that, we ask GDB by debugging our implref-global program. # Any program would do, but since we already have implref-global # specifically for this testcase, might as well use that. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Create the DWARF. We need a regular variable and a reference to it that'll # be marked with DW_OP_GNU_implicit_pointer. The variable must be global so # that its name is an exported symbol that we can reference from the DWARF @@ -91,16 +91,16 @@ Dwarf::assemble ${asm_file} { } } } if {[prepare_for_testing "failed to prepare" ${executable} [list ${asm_file} ${srcfile}] {}]} { - return -1 + return } # DW_OP_GNU_implicit_pointer implementation requires a valid frame. if {![runto_main]} { - return -1 + return } # Address of the referenced value. set address [get_hexadecimal_valueof "&global_var" ""] diff --git a/gdb/testsuite/gdb.dwarf2/implref-struct.exp b/gdb/testsuite/gdb.dwarf2/implref-struct.exp index ce2dea7db3a4..d62f426ed736 100644 --- a/gdb/testsuite/gdb.dwarf2/implref-struct.exp +++ b/gdb/testsuite/gdb.dwarf2/implref-struct.exp @@ -35,11 +35,11 @@ set asm_file [standard_output_file ${srcfile2}] # # For that, we ask GDB by debugging our implref-struct program. # Any program would do, but since we already have implref-struct # specifically for this testcase, might as well use that. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}]} { - return -1 + return } # Create the DWARF. We need a regular variable for the struct and a reference # to it that'll be marked with DW_OP_GNU_implicit_pointer. The variable must be # global so that its name is an exported symbol that can we can reference from @@ -128,16 +128,16 @@ Dwarf::assemble ${asm_file} { } } } if {[prepare_for_testing "failed to prepare" ${executable} [list ${asm_file} ${srcfile}] {}]} { - return -1 + return } # DW_OP_GNU_implicit_pointer implementation requires a valid frame. if {![runto_main]} { - return -1 + return } # Returns the struct members, e.g. '{a = 0, b = 1, c = 2}'. proc get_members {var} { set members [get_valueof "" ${var} ""] diff --git a/gdb/testsuite/gdb.dwarf2/imported-unit-abstract-const-value.exp b/gdb/testsuite/gdb.dwarf2/imported-unit-abstract-const-value.exp index 115cb63db9ff..1bd00fc97139 100644 --- a/gdb/testsuite/gdb.dwarf2/imported-unit-abstract-const-value.exp +++ b/gdb/testsuite/gdb.dwarf2/imported-unit-abstract-const-value.exp @@ -27,11 +27,11 @@ set executable ${testfile} set asm_file [standard_output_file ${srcfile2}] # We need to know the size of integer type in order # to write some of the debugging info we'd like to generate. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Create the DWARF. Dwarf::assemble $asm_file { declare_labels cu_label main_label int_label @@ -79,9 +79,9 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "p aaa" "= 1" diff --git a/gdb/testsuite/gdb.dwarf2/imported-unit-bp.exp.tcl b/gdb/testsuite/gdb.dwarf2/imported-unit-bp.exp.tcl index 0bd1e0d2f91b..f9cc72c71725 100644 --- a/gdb/testsuite/gdb.dwarf2/imported-unit-bp.exp.tcl +++ b/gdb/testsuite/gdb.dwarf2/imported-unit-bp.exp.tcl @@ -112,11 +112,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file $srcfile3] $build_options] } { - return -1 + return } gdb_reinitialize_dir /tmp # Compilation on remote host downloads the source files to remote host, but diff --git a/gdb/testsuite/gdb.dwarf2/imported-unit-c.exp b/gdb/testsuite/gdb.dwarf2/imported-unit-c.exp index 1210fff84712..82f4baf5bdcb 100644 --- a/gdb/testsuite/gdb.dwarf2/imported-unit-c.exp +++ b/gdb/testsuite/gdb.dwarf2/imported-unit-c.exp @@ -10,11 +10,11 @@ set executable ${testfile} set asm_file [standard_output_file ${srcfile2}] # We need to know the size of integer and address types in order # to write some of the debugging info we'd like to generate. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug}]} { - return -1 + return } # Create the DWARF. Dwarf::assemble $asm_file { declare_labels cu_label cu2_label int_label int2_label @@ -132,11 +132,11 @@ Dwarf::assemble $asm_file { } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # If Python testing is enabled then try printing the global and static # blocks for the current frame, which is in function FUNC. proc test_python_block_printing { func } { @@ -151,11 +151,11 @@ proc test_python_block_printing { func } { [string_to_regexp " {$func}>"] \ "print global block in $func" } if {![runto_main]} { - return -1 + return } gdb_test "ptype inty" "type = int" "ptype in main" test_python_block_printing main diff --git a/gdb/testsuite/gdb.dwarf2/imported-unit-runto-main.exp b/gdb/testsuite/gdb.dwarf2/imported-unit-runto-main.exp index 26366d73e3bf..51f26dd6d41d 100644 --- a/gdb/testsuite/gdb.dwarf2/imported-unit-runto-main.exp +++ b/gdb/testsuite/gdb.dwarf2/imported-unit-runto-main.exp @@ -24,11 +24,11 @@ set executable ${testfile} set asm_file [standard_output_file ${srcfile2}] # We need to know the size of integer types in order to write some of the # debugging info we'd like to generate. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Create the DWARF. Dwarf::assemble $asm_file { declare_labels cu_label main_label int_label @@ -67,16 +67,16 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { [ensure_gdb_index $binfile] == -1 } { untested "error adding gdb index" - return -1 + return } clean_restart ${::testfile} runto main diff --git a/gdb/testsuite/gdb.dwarf2/imported-unit.exp b/gdb/testsuite/gdb.dwarf2/imported-unit.exp index 1be9f30a7d99..bd8694a872d6 100644 --- a/gdb/testsuite/gdb.dwarf2/imported-unit.exp +++ b/gdb/testsuite/gdb.dwarf2/imported-unit.exp @@ -36,11 +36,11 @@ set executable ${testfile} set asm_file [standard_output_file ${srcfile2}] # We need to know the size of integer and address types in order # to write some of the debugging info we'd like to generate. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}]} { - return -1 + return } # Create the DWARF. Dwarf::assemble $asm_file { declare_labels cu_label main_label doit_label int_label @@ -123,11 +123,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language c++" gdb_test "l imported_unit.c:1" \ diff --git a/gdb/testsuite/gdb.dwarf2/info-locals-optimized-out.exp b/gdb/testsuite/gdb.dwarf2/info-locals-optimized-out.exp index 4f783d9bca0d..8932cbf51099 100644 --- a/gdb/testsuite/gdb.dwarf2/info-locals-optimized-out.exp +++ b/gdb/testsuite/gdb.dwarf2/info-locals-optimized-out.exp @@ -63,15 +63,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set lines [gdb_get_lines "info locals"] # Make sure "info locals" shows optimized out variables. diff --git a/gdb/testsuite/gdb.dwarf2/inline.exp b/gdb/testsuite/gdb.dwarf2/inline.exp index 11109f297ccf..138d471acfb4 100644 --- a/gdb/testsuite/gdb.dwarf2/inline.exp +++ b/gdb/testsuite/gdb.dwarf2/inline.exp @@ -15,11 +15,11 @@ standard_testfile .c if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug nowarnings}]} { - return -1 + return } set cmd "ptype main" set re \ diff --git a/gdb/testsuite/gdb.dwarf2/inlined_subroutine-inheritance.exp b/gdb/testsuite/gdb.dwarf2/inlined_subroutine-inheritance.exp index 6a982acbdf6e..607e72bdf83a 100644 --- a/gdb/testsuite/gdb.dwarf2/inlined_subroutine-inheritance.exp +++ b/gdb/testsuite/gdb.dwarf2/inlined_subroutine-inheritance.exp @@ -200,11 +200,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" $testfile \ "${asm_file} ${srcfile}" {}]} { - return -1 + return } # All we need to do is set a breakpoint, which causes the DWARF # info to be read, to demonstrate the problem. diff --git a/gdb/testsuite/gdb.dwarf2/intbits.exp b/gdb/testsuite/gdb.dwarf2/intbits.exp index 2cf96e63eaa4..46e45aeb861e 100644 --- a/gdb/testsuite/gdb.dwarf2/intbits.exp +++ b/gdb/testsuite/gdb.dwarf2/intbits.exp @@ -24,11 +24,11 @@ standard_testfile .c .S set executable ${testfile} set asm_file [standard_output_file ${srcfile2}] if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Create the DWARF. Dwarf::assemble ${asm_file} { cu {} { @@ -194,15 +194,15 @@ Dwarf::assemble ${asm_file} { } } if {[prepare_for_testing "failed to prepare" ${executable} \ [list ${asm_file} ${srcfile}] {}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "print v_i16_m1" "= -1" gdb_test "print v_u16_1" "= true" gdb_test "print v_u32_m2" "= -2" diff --git a/gdb/testsuite/gdb.dwarf2/local-var.exp b/gdb/testsuite/gdb.dwarf2/local-var.exp index 77561a06d5a5..b3401a002531 100644 --- a/gdb/testsuite/gdb.dwarf2/local-var.exp +++ b/gdb/testsuite/gdb.dwarf2/local-var.exp @@ -16,11 +16,11 @@ # Check that local variables do not occur in the cooked index. standard_testfile .f90 if { [prepare_for_testing "failed to prepare" ${testfile} $srcfile {debug f90}] } { - return -1 + return } # Regression test for PR32276. gdb_test_lines "maint print objfiles" "local var not in index" "" -re-not "local_var" diff --git a/gdb/testsuite/gdb.dwarf2/locexpr-data-member-location.exp b/gdb/testsuite/gdb.dwarf2/locexpr-data-member-location.exp index 4305026089bf..9c0c5a700c2f 100644 --- a/gdb/testsuite/gdb.dwarf2/locexpr-data-member-location.exp +++ b/gdb/testsuite/gdb.dwarf2/locexpr-data-member-location.exp @@ -89,11 +89,11 @@ if {[gdb_compile_shlib $libsrc $lib_so \ # Value returned is $1 = (B *) $hex # Note that this compilation is used for all GDB sessions. set exec_options [list debug shlib=$lib_so] if {[prepare_for_testing "failed to prepare" ${testfile} \ ${::srcfile} $exec_options]} { - return -1 + return } ### First GDB session. with_test_prefix "first session" { diff --git a/gdb/testsuite/gdb.dwarf2/mac-fileno.exp b/gdb/testsuite/gdb.dwarf2/mac-fileno.exp index eae6600213ec..0e9a4988059d 100644 --- a/gdb/testsuite/gdb.dwarf2/mac-fileno.exp +++ b/gdb/testsuite/gdb.dwarf2/mac-fileno.exp @@ -23,11 +23,11 @@ require dwarf2_support standard_testfile .S set dwarf_srcfile "file1.txt" if {[prepare_for_testing_full "failed to prepare" \ [list $testfile debug main.c debug $srcfile nodebug]]} { - return -1 + return } gdb_remote_download host ${srcdir}/${subdir}/${dwarf_srcfile} gdb_test_no_output "set listsize 1" diff --git a/gdb/testsuite/gdb.dwarf2/main-subprogram.exp b/gdb/testsuite/gdb.dwarf2/main-subprogram.exp index cb01fca6bdf5..bb2219412d6c 100644 --- a/gdb/testsuite/gdb.dwarf2/main-subprogram.exp +++ b/gdb/testsuite/gdb.dwarf2/main-subprogram.exp @@ -53,22 +53,22 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } set have_index [exec_has_index_section $binfile] # Test that the "start" command stops in the "mymain" function. # This should happen because we used DW_AT_main_subprogram to tell gdb # that this was the real "main". if {[gdb_start_cmd] < 0} { fail "could not start ${testfile}" - return -1 + return } gdb_test_multiple "" "stopped at mymain" { -re -wrap "Temporary breakpoint .* mymain.*" { pass $gdb_test_name diff --git a/gdb/testsuite/gdb.dwarf2/malformed-line-header.exp b/gdb/testsuite/gdb.dwarf2/malformed-line-header.exp index 04494dc3889b..8b549b2d4471 100644 --- a/gdb/testsuite/gdb.dwarf2/malformed-line-header.exp +++ b/gdb/testsuite/gdb.dwarf2/malformed-line-header.exp @@ -46,11 +46,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "info line 1" \ [string cat \ "malformed line number program header," \ diff --git a/gdb/testsuite/gdb.dwarf2/mega-enum.exp b/gdb/testsuite/gdb.dwarf2/mega-enum.exp index 3d01db7b6907..d550a2b464a4 100644 --- a/gdb/testsuite/gdb.dwarf2/mega-enum.exp +++ b/gdb/testsuite/gdb.dwarf2/mega-enum.exp @@ -57,11 +57,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } # The largest known Fermat prime. gdb_test "print/d DEI_65537" " = 65537" gdb_test "print (enum mega_enum) 65537" " = DEI_65537" diff --git a/gdb/testsuite/gdb.dwarf2/member-ptr-forwardref.exp b/gdb/testsuite/gdb.dwarf2/member-ptr-forwardref.exp index eae8723563a2..b08e6c39825d 100644 --- a/gdb/testsuite/gdb.dwarf2/member-ptr-forwardref.exp +++ b/gdb/testsuite/gdb.dwarf2/member-ptr-forwardref.exp @@ -21,11 +21,11 @@ require allow_cplus_tests standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" ${binfile} object {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart # Be sure to set cp-abi before ${binfile} gets loaded diff --git a/gdb/testsuite/gdb.dwarf2/method-ptr.exp b/gdb/testsuite/gdb.dwarf2/method-ptr.exp index 459302a7994c..42cb93330a55 100644 --- a/gdb/testsuite/gdb.dwarf2/method-ptr.exp +++ b/gdb/testsuite/gdb.dwarf2/method-ptr.exp @@ -77,11 +77,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug c++}] } { - return -1 + return } gdb_test_no_output "set language c++" gdb_test "ptype the_typedef" \ "type = int \\(S::\\*\\)\\(S \\* const, float\\)" diff --git a/gdb/testsuite/gdb.dwarf2/missing-line-table.exp b/gdb/testsuite/gdb.dwarf2/missing-line-table.exp index 9f32a3663458..40e527b48448 100644 --- a/gdb/testsuite/gdb.dwarf2/missing-line-table.exp +++ b/gdb/testsuite/gdb.dwarf2/missing-line-table.exp @@ -78,11 +78,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Place a breakpoint on FUNC. Check that the address at which the # breakpoint is placed lies within FUNC which is starts at address # START, and address END is the first address after FUNC. diff --git a/gdb/testsuite/gdb.dwarf2/missing-sig-type.exp b/gdb/testsuite/gdb.dwarf2/missing-sig-type.exp index f69ecbb71da4..aa47a704cc32 100644 --- a/gdb/testsuite/gdb.dwarf2/missing-sig-type.exp +++ b/gdb/testsuite/gdb.dwarf2/missing-sig-type.exp @@ -47,9 +47,9 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "ptype foo" "type = " diff --git a/gdb/testsuite/gdb.dwarf2/missing-type-name-for-templates.exp b/gdb/testsuite/gdb.dwarf2/missing-type-name-for-templates.exp index 12852a4b33b8..bf9e9258c0a2 100644 --- a/gdb/testsuite/gdb.dwarf2/missing-type-name-for-templates.exp +++ b/gdb/testsuite/gdb.dwarf2/missing-type-name-for-templates.exp @@ -152,15 +152,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] $nodebug_flags] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "ptype var1" [multi_line \ "type = struct template_var1 \\\[with = int, second = float\\\] {" \ " me;" \ diff --git a/gdb/testsuite/gdb.dwarf2/missing-type-name.exp b/gdb/testsuite/gdb.dwarf2/missing-type-name.exp index 770dff4d7f2a..530e0c79b0f3 100644 --- a/gdb/testsuite/gdb.dwarf2/missing-type-name.exp +++ b/gdb/testsuite/gdb.dwarf2/missing-type-name.exp @@ -95,15 +95,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Use 'ptype' on two variables that are using DW_TAG_base_type types # with missing DW_AT_name attributes. gdb_test "ptype var_ptr" "type = \\*" \ diff --git a/gdb/testsuite/gdb.dwarf2/multidictionary.exp b/gdb/testsuite/gdb.dwarf2/multidictionary.exp index 52975d08a5ce..525967dbd897 100644 --- a/gdb/testsuite/gdb.dwarf2/multidictionary.exp +++ b/gdb/testsuite/gdb.dwarf2/multidictionary.exp @@ -139,11 +139,11 @@ Dwarf::assemble $asm_file { } # Build the test executable. if {[build_executable $testfile.exp $testfile [list $asm_file $srcfile] {}] \ == -1} { - return -1 + return } # We force the DIEs above to be read in via "-readnow". save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS -readnow" diff --git a/gdb/testsuite/gdb.dwarf2/nameless-enum.exp b/gdb/testsuite/gdb.dwarf2/nameless-enum.exp index 4dbe29b8e03b..b523ae6d6ae2 100644 --- a/gdb/testsuite/gdb.dwarf2/nameless-enum.exp +++ b/gdb/testsuite/gdb.dwarf2/nameless-enum.exp @@ -52,11 +52,11 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } # The bug was a crash, so just do anything here to verify gdb is still # alive. gdb_test "print 23" " = 23" diff --git a/gdb/testsuite/gdb.dwarf2/no-gnu-debuglink.exp b/gdb/testsuite/gdb.dwarf2/no-gnu-debuglink.exp index ae912aa4ace2..817d015a7d50 100644 --- a/gdb/testsuite/gdb.dwarf2/no-gnu-debuglink.exp +++ b/gdb/testsuite/gdb.dwarf2/no-gnu-debuglink.exp @@ -30,11 +30,11 @@ set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { gnu_debugaltlink "file-not-here" "0000000000000000000000000000000000000000" } if { [build_executable $testfile.exp $testfile [list $srcfile $asm_file]] } { - return -1 + return } clean_restart gdb_test_no_output "maint set dwarf synchronous on" diff --git a/gdb/testsuite/gdb.dwarf2/nonvar-access.exp b/gdb/testsuite/gdb.dwarf2/nonvar-access.exp index c0813ebf5eed..8e673bbade52 100644 --- a/gdb/testsuite/gdb.dwarf2/nonvar-access.exp +++ b/gdb/testsuite/gdb.dwarf2/nonvar-access.exp @@ -196,15 +196,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Determine byte order. set endian [get_endianness] diff --git a/gdb/testsuite/gdb.dwarf2/nostaticblock.exp b/gdb/testsuite/gdb.dwarf2/nostaticblock.exp index 88a2f69689dc..e9be5b8b5558 100644 --- a/gdb/testsuite/gdb.dwarf2/nostaticblock.exp +++ b/gdb/testsuite/gdb.dwarf2/nostaticblock.exp @@ -33,11 +33,11 @@ Dwarf::assemble $asm_file { } } if { [build_executable ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } save_vars { GDBFLAGS } { set GDBFLAGS "$GDBFLAGS --readnow" clean_restart $testfile diff --git a/gdb/testsuite/gdb.dwarf2/nullptr_t.exp b/gdb/testsuite/gdb.dwarf2/nullptr_t.exp index 4ce5751147a5..f25988fb3015 100644 --- a/gdb/testsuite/gdb.dwarf2/nullptr_t.exp +++ b/gdb/testsuite/gdb.dwarf2/nullptr_t.exp @@ -21,11 +21,11 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } set cmd "info types -q std::nullptr_t" set re \ diff --git a/gdb/testsuite/gdb.dwarf2/opaque-type-lookup.exp b/gdb/testsuite/gdb.dwarf2/opaque-type-lookup.exp index bcf833ca2130..119203308a75 100644 --- a/gdb/testsuite/gdb.dwarf2/opaque-type-lookup.exp +++ b/gdb/testsuite/gdb.dwarf2/opaque-type-lookup.exp @@ -182,14 +182,14 @@ Dwarf::assemble $asm_file { } } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile} ${srcfile3}" {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "p variable_a" " = {xyz = 97 'a'}" gdb_test "p variable_b" " = {xyz = 98 'b'}" diff --git a/gdb/testsuite/gdb.dwarf2/opt-out-not-implptr.exp b/gdb/testsuite/gdb.dwarf2/opt-out-not-implptr.exp index 5bfd0099b114..64a3a1e393ba 100644 --- a/gdb/testsuite/gdb.dwarf2/opt-out-not-implptr.exp +++ b/gdb/testsuite/gdb.dwarf2/opt-out-not-implptr.exp @@ -86,17 +86,17 @@ Dwarf::assemble $asm_file { } } if {[build_executable ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } clean_restart ${testfile} if {![runto_main]} { - return -1 + return } set cmd "print i64_noptr" if { [is_64_target] } { gdb_test $cmd \ diff --git a/gdb/testsuite/gdb.dwarf2/pieces-optimized-out.exp b/gdb/testsuite/gdb.dwarf2/pieces-optimized-out.exp index c9fb5764c28d..94ede63f31a5 100644 --- a/gdb/testsuite/gdb.dwarf2/pieces-optimized-out.exp +++ b/gdb/testsuite/gdb.dwarf2/pieces-optimized-out.exp @@ -25,15 +25,15 @@ set csrcfile ${testfile}.c set opts {} lappend opts debug lappend opts nopie if {[prepare_for_testing "failed to prepare" ${testfile} $srcfile $opts]} { - return -1 + return } if {![runto foo]} { - return -1 + return } # Move back up to main. gdb_test "up" "#1 $hex in main.*" "move up a frame" diff --git a/gdb/testsuite/gdb.dwarf2/pieces.exp b/gdb/testsuite/gdb.dwarf2/pieces.exp index 10d2f8b965ca..bcae3cfe859d 100644 --- a/gdb/testsuite/gdb.dwarf2/pieces.exp +++ b/gdb/testsuite/gdb.dwarf2/pieces.exp @@ -21,15 +21,15 @@ require dwarf2_support is_x86_like_target standard_testfile .S set csrcfile ${testfile}.c if {[prepare_for_testing "failed to prepare" ${testfile} $srcfile]} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Function f1 tests a particular gdb bug involving DW_OP_piece. proc pieces_test_f1 {} { global csrcfile diff --git a/gdb/testsuite/gdb.dwarf2/pr10770.exp b/gdb/testsuite/gdb.dwarf2/pr10770.exp index 6ff1639177eb..ec4e076cb8ff 100644 --- a/gdb/testsuite/gdb.dwarf2/pr10770.exp +++ b/gdb/testsuite/gdb.dwarf2/pr10770.exp @@ -16,21 +16,21 @@ # Test DW_OP_call_frame_cfa. standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return 0 + return } if {![runto_main]} { - return -1 + return } # This test also requires DWARF. get_debug_format if {![test_debug_format "DWARF \[0-9\]"]} { - return -1 + return } gdb_test "break force_unwind" "Breakpoint .*" "set breakpoint for pr10770" gdb_test "cont" "Breakpoint ., force_unwind .*" # If we have the bug, this will hang. diff --git a/gdb/testsuite/gdb.dwarf2/pr11465.exp b/gdb/testsuite/gdb.dwarf2/pr11465.exp index 2ca6985fd6f0..3cf6bdb70e18 100644 --- a/gdb/testsuite/gdb.dwarf2/pr11465.exp +++ b/gdb/testsuite/gdb.dwarf2/pr11465.exp @@ -25,11 +25,11 @@ if {[is_ilp32_target]} { set ptrbits 64 } if { [gdb_compile [file join $srcdir $subdir $srcfile] \ $binfile object [list additional_flags=-DPTRBITS=$ptrbits]] != "" } { - return -1 + return } clean_restart $testfile # Test delayed physname computations diff --git a/gdb/testsuite/gdb.dwarf2/pr13961.exp b/gdb/testsuite/gdb.dwarf2/pr13961.exp index 66441e862404..46bcdd70b0e1 100644 --- a/gdb/testsuite/gdb.dwarf2/pr13961.exp +++ b/gdb/testsuite/gdb.dwarf2/pr13961.exp @@ -25,11 +25,11 @@ set additional_flags [gdb_target_symbol_prefix_flags_asm] standard_testfile .S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ ${additional_flags}] == -1 } { - return -1 + return } gdb_test "break -q main" "Breakpoint.*at.*" # If we get this far gdb didn't crash. diff --git a/gdb/testsuite/gdb.dwarf2/rust-enum.exp b/gdb/testsuite/gdb.dwarf2/rust-enum.exp index 141ec90d927e..19c9bcacff5d 100644 --- a/gdb/testsuite/gdb.dwarf2/rust-enum.exp +++ b/gdb/testsuite/gdb.dwarf2/rust-enum.exp @@ -109,11 +109,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test_no_output "set language rust" gdb_test "print constant_variable" [string_to_regexp "One(65)"] diff --git a/gdb/testsuite/gdb.dwarf2/self-spec.exp b/gdb/testsuite/gdb.dwarf2/self-spec.exp index 398cdc1e8d2b..b51c7e41a8b0 100644 --- a/gdb/testsuite/gdb.dwarf2/self-spec.exp +++ b/gdb/testsuite/gdb.dwarf2/self-spec.exp @@ -51,11 +51,11 @@ Dwarf::assemble $asm_file { } } } if {[prepare_for_testing "failed to prepare" $testfile "${asm_file} ${srcfile}" {}]} { - return -1 + return } set index [have_index $binfile] require {string eq $index ""} diff --git a/gdb/testsuite/gdb.dwarf2/shortpiece.exp b/gdb/testsuite/gdb.dwarf2/shortpiece.exp index 118f7f1a97cb..bb37541ff072 100644 --- a/gdb/testsuite/gdb.dwarf2/shortpiece.exp +++ b/gdb/testsuite/gdb.dwarf2/shortpiece.exp @@ -119,11 +119,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "p s1" " = {a = 1, b = 0}" gdb_test "p s2" \ "access outside bounds of object referenced via synthetic pointer" diff --git a/gdb/testsuite/gdb.dwarf2/static-optimized-out.exp b/gdb/testsuite/gdb.dwarf2/static-optimized-out.exp index 29ec6b43fcc0..1ac48f5b31cd 100644 --- a/gdb/testsuite/gdb.dwarf2/static-optimized-out.exp +++ b/gdb/testsuite/gdb.dwarf2/static-optimized-out.exp @@ -46,11 +46,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "print var" " = " # Expand all symbol tables. diff --git a/gdb/testsuite/gdb.dwarf2/staticvirtual.exp b/gdb/testsuite/gdb.dwarf2/staticvirtual.exp index 91a61b7f8431..90ae120b79c3 100644 --- a/gdb/testsuite/gdb.dwarf2/staticvirtual.exp +++ b/gdb/testsuite/gdb.dwarf2/staticvirtual.exp @@ -47,11 +47,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # gdb/18021: The test below would cause GDB to crash. # Depending on whether the target maps memory at address 0x1000, # on success this may either print something like diff --git a/gdb/testsuite/gdb.dwarf2/struct-decl.exp b/gdb/testsuite/gdb.dwarf2/struct-decl.exp index 789ecb36f9be..aefa2609a8ac 100644 --- a/gdb/testsuite/gdb.dwarf2/struct-decl.exp +++ b/gdb/testsuite/gdb.dwarf2/struct-decl.exp @@ -64,9 +64,9 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } gdb_breakpoint "the_type::method" message diff --git a/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp b/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp index 1a2e696d5b69..4218dd119470 100644 --- a/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp +++ b/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp @@ -74,11 +74,11 @@ Dwarf::assemble $asm_file { # We're using an object instead of executable here to keep cc-with-tweaks.sh # from modifying it. It also means we can set the build-id, rather than # having to extract it. if { [gdb_compile $asm_file $binfile.dwz object {nodebug}] != "" } { - return -1 + return } set host_dwz_file [gdb_remote_download host $binfile.dwz] # Make some DWARF for the executable. diff --git a/gdb/testsuite/gdb.dwarf2/struct-with-sig.exp b/gdb/testsuite/gdb.dwarf2/struct-with-sig.exp index a85f615f37ee..5a3e5a77dcae 100644 --- a/gdb/testsuite/gdb.dwarf2/struct-with-sig.exp +++ b/gdb/testsuite/gdb.dwarf2/struct-with-sig.exp @@ -97,11 +97,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } set struct_s_i_re \ [multi_line \ "type = struct s {" \ @@ -112,11 +112,11 @@ set struct_s_j_re \ "type = struct s {" \ " int j;" \ "}"] if {![runto_main]} { - return -1 + return } gdb_test "ptype struct s" $struct_s_i_re \ "struct s with int i" diff --git a/gdb/testsuite/gdb.dwarf2/subrange-enum.exp b/gdb/testsuite/gdb.dwarf2/subrange-enum.exp index 172f4bd42fc4..a4cfab746db0 100644 --- a/gdb/testsuite/gdb.dwarf2/subrange-enum.exp +++ b/gdb/testsuite/gdb.dwarf2/subrange-enum.exp @@ -70,9 +70,9 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } gdb_test "print rangeval" " = TWO" diff --git a/gdb/testsuite/gdb.dwarf2/subrange.exp b/gdb/testsuite/gdb.dwarf2/subrange.exp index cd3a4b85b693..71e88f433538 100644 --- a/gdb/testsuite/gdb.dwarf2/subrange.exp +++ b/gdb/testsuite/gdb.dwarf2/subrange.exp @@ -103,11 +103,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug c++}] } { - return -1 + return } gdb_test_no_output "set language pascal" gdb_test "ptype TByteArray" \ diff --git a/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_fail.exp b/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_fail.exp index a05fa14b7cd7..27763beee3a8 100644 --- a/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_fail.exp +++ b/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_fail.exp @@ -98,19 +98,19 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # The variable's location expression requires a frame, # so an error should be reported. gdb_test "print/d a" "No frame selected." "variable a can't be printed" if {![runto_main]} { - return -1 + return } gdb_test_no_output "set var \$$regname = 2" "init reg to 2" gdb_test "print/d a" " = 2" "a == 2" diff --git a/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_timeout.exp b/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_timeout.exp index 8b98e73d421c..a72cdc8f55f6 100644 --- a/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_timeout.exp +++ b/gdb/testsuite/gdb.dwarf2/symbol_needs_eval_timeout.exp @@ -120,15 +120,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "set var \$$regname = 2" "init reg to 2" gdb_test_no_output "set var exec_mask = 0" "init exec_mask to 0" diff --git a/gdb/testsuite/gdb.dwarf2/template-specification-full-name.exp b/gdb/testsuite/gdb.dwarf2/template-specification-full-name.exp index eea7106d7011..f5a919cb747f 100644 --- a/gdb/testsuite/gdb.dwarf2/template-specification-full-name.exp +++ b/gdb/testsuite/gdb.dwarf2/template-specification-full-name.exp @@ -71,14 +71,14 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Just a sanity check to make sure GDB slurped the symbols correctly. gdb_test "print apply" " = {void \\(void\\)} $hex \\(\\)>" diff --git a/gdb/testsuite/gdb.dwarf2/trace-crash.exp b/gdb/testsuite/gdb.dwarf2/trace-crash.exp index aacb56a8d3e2..2df9bfa861bb 100644 --- a/gdb/testsuite/gdb.dwarf2/trace-crash.exp +++ b/gdb/testsuite/gdb.dwarf2/trace-crash.exp @@ -24,11 +24,11 @@ require is_x86_64_m64_target standard_testfile .S if {[prepare_for_testing "failed to prepare" "${testfile}" ${testfile}.S \ nodebug]} { - return -1 + return } gdb_test "trace ${testfile}.c:3" "Tracepoint $decimal .*" \ "set tracepoint" diff --git a/gdb/testsuite/gdb.dwarf2/typeddwarf.exp b/gdb/testsuite/gdb.dwarf2/typeddwarf.exp index afc600e2b725..00c8bd130096 100644 --- a/gdb/testsuite/gdb.dwarf2/typeddwarf.exp +++ b/gdb/testsuite/gdb.dwarf2/typeddwarf.exp @@ -24,23 +24,23 @@ require dwarf2_support if { [is_x86_like_target] } { set sfile ${test}.S } elseif { [is_x86_64_m64_target] } { set sfile ${test}-amd64.S } else { - return 0 + return } set opts {} lappend opts nodebug lappend opts nopie if { [prepare_for_testing "failed to prepare" "${test}" ${sfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Initialize tests to be an empty array. unset -nocomplain tests array set tests {} diff --git a/gdb/testsuite/gdb.dwarf2/typedef-void-finish.exp b/gdb/testsuite/gdb.dwarf2/typedef-void-finish.exp index 96b621ac6e09..507e698916af 100644 --- a/gdb/testsuite/gdb.dwarf2/typedef-void-finish.exp +++ b/gdb/testsuite/gdb.dwarf2/typedef-void-finish.exp @@ -59,15 +59,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break func" "Breakpoint .*" \ "set breakpoint in func" gdb_continue_to_breakpoint "continue to func" diff --git a/gdb/testsuite/gdb.dwarf2/utf-rust.exp b/gdb/testsuite/gdb.dwarf2/utf-rust.exp index 6eb8a7a171d6..0aedd6530aad 100644 --- a/gdb/testsuite/gdb.dwarf2/utf-rust.exp +++ b/gdb/testsuite/gdb.dwarf2/utf-rust.exp @@ -52,15 +52,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] debug]} { - return -1 + return } if {![runto main]} { - return -1 + return } gdb_test "set language rust" \ "Warning: the current language does not match this frame." # Get the values into history so we can use it from Rust. diff --git a/gdb/testsuite/gdb.dwarf2/valop.exp b/gdb/testsuite/gdb.dwarf2/valop.exp index dd5f01d4a324..18f51c117f8d 100644 --- a/gdb/testsuite/gdb.dwarf2/valop.exp +++ b/gdb/testsuite/gdb.dwarf2/valop.exp @@ -22,15 +22,15 @@ require dwarf2_support is_x86_like_target standard_testfile .S if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile] [list {additional_flags=-nostdlib}]]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break valop.c:19" "Breakpoint 2.*" "set breakpoint for valop" gdb_continue_to_breakpoint "continue to breakpoint for valop" diff --git a/gdb/testsuite/gdb.dwarf2/var-access.exp b/gdb/testsuite/gdb.dwarf2/var-access.exp index 5e240aeb7408..6719784f2302 100644 --- a/gdb/testsuite/gdb.dwarf2/var-access.exp +++ b/gdb/testsuite/gdb.dwarf2/var-access.exp @@ -248,15 +248,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing ${testfile}.exp ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Determine byte order. set endian [get_endianness] diff --git a/gdb/testsuite/gdb.dwarf2/variant.exp b/gdb/testsuite/gdb.dwarf2/variant.exp index 2dab87211acf..7f015e9e3ae1 100644 --- a/gdb/testsuite/gdb.dwarf2/variant.exp +++ b/gdb/testsuite/gdb.dwarf2/variant.exp @@ -200,15 +200,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] debug] } { - return -1 + return } if {![runto func]} { - return -1 + return } # Get the values into history so we can use it from Rust. gdb_test "print (void *) buffer" "\\\$1 = .void .. $hex .buffer." gdb_test "print (void *) buffer2" "\\\$2 = .void .. $hex .buffer2." diff --git a/gdb/testsuite/gdb.dwarf2/varval.exp b/gdb/testsuite/gdb.dwarf2/varval.exp index b0735bee94ae..032e3d11c0e7 100644 --- a/gdb/testsuite/gdb.dwarf2/varval.exp +++ b/gdb/testsuite/gdb.dwarf2/varval.exp @@ -32,11 +32,11 @@ set asm_file [standard_output_file ${srcfile2}] # # For that, we ask GDB by debugging our varval program. # Any program would do, but since we already have varval # specifically for this testcase, might as well use that. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } set int_size [get_sizeof "int" -1] # gdb always assumes references are implemented as pointers. set addr_size [get_sizeof "void *" -1] @@ -318,20 +318,20 @@ proc setup_exec { arg_bad } { return -1 } } if { [setup_exec 0] == -1 } { - return -1 + return } with_test_prefix "pre-main" { gdb_test "print varval3" "= \\{8\\}" "" } # DW_OP_GNU_variable_value implementation requires a valid frame. if {![runto_main]} { - return -1 + return } gdb_test "print varval" "= 8" gdb_test "print varval2" "= 8" gdb_test "print varval3" "= \\{8\\}" @@ -351,16 +351,16 @@ gdb_test "print structval" \ gdb_test "print untypedval" \ "Type of DW_OP_GNU_variable_value DIE must be an integer or pointer\\." if { [setup_exec 1] == -1 } { - return -1 + return } # DW_OP_GNU_variable_value implementation requires a valid frame. if {![runto_main]} { - return -1 + return } gdb_test "print badval" "value has been optimized out" gdb_test "print bad_die_val1" \ {DWARF Error: could not find unit containing offset 0xabcdef11 \[in module .*/varval\]} gdb_test "print bad_die_val2" \ diff --git a/gdb/testsuite/gdb.dwarf2/void-type.exp b/gdb/testsuite/gdb.dwarf2/void-type.exp index c3d37da56dc0..ee5d16e1ea07 100644 --- a/gdb/testsuite/gdb.dwarf2/void-type.exp +++ b/gdb/testsuite/gdb.dwarf2/void-type.exp @@ -91,15 +91,15 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } # Place a breakpoint in 'func' and continue to there. gdb_breakpoint func gdb_continue_to_breakpoint "func" diff --git a/gdb/testsuite/gdb.dwarf2/watch-notconst.exp b/gdb/testsuite/gdb.dwarf2/watch-notconst.exp index 7dd7afcb8a0d..c8fb0a955f81 100644 --- a/gdb/testsuite/gdb.dwarf2/watch-notconst.exp +++ b/gdb/testsuite/gdb.dwarf2/watch-notconst.exp @@ -20,11 +20,11 @@ set test "watch-notconst" # This test can only be run on x86 targets. require dwarf2_support is_x86_like_target if { [prepare_for_testing "failed to prepare" "${test}" \ {watch-notconst.c watch-notconst2.S} {nodebug}] } { - return -1 + return } if { ![runto f] } { perror "Could not run to breakpoint `f'." return From patchwork Wed Apr 29 23:04:10 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134203 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id A47E04BB3BE4 for ; Wed, 29 Apr 2026 23:06:57 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A47E04BB3BE4 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=j0c3k45C X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa36.google.com (mail-vk1-xa36.google.com [IPv6:2607:f8b0:4864:20::a36]) by sourceware.org (Postfix) with ESMTPS id 280894358A53 for ; Wed, 29 Apr 2026 23:05:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 280894358A53 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 280894358A53 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a36 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503947; cv=none; b=UTYXhDQm5z31ABeoNEkU8LhyCMHVNA2z4Ys5FL0C/wiDRtrJhqGvCs22u0gxAGkW/Ssm8kIyiRT85QM2QXNzAAAcczIH0PcRQ//8zB08e9b2kB2m3JWqgNmSDPd7GAZzfsEu3Azdu/hW0kVtEg/wmO5QURZ2Db88JKrlULdS7lw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503947; c=relaxed/simple; bh=BFnczcJVvynyEo9K+ZZTAhMKiwsUnEqB4BSEeFk1wAg=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=TuW6dfUbhdCwWVDbnLLdHY2yrOk250FNSCZOoT4fPs2ewgYyY8DCSBkXn0Z/N/pgO5R8XyeMsanLdNoQpbIZunJexlHiYs+S88crbZZq2QafC6pilkN1lm5zAAmFwAeAG6Zy3vxF0JkpGsot1SyMlAHJlEZRTX5Ome1eVIlKs7A= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 280894358A53 Received: by mail-vk1-xa36.google.com with SMTP id 71dfb90a1353d-56e91f17a99so191157e0c.3 for ; Wed, 29 Apr 2026 16:05:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503946; x=1778108746; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=QPKhlyNtYF20UvsXpxmalPiE965kFbn5215hkFZXu0A=; b=j0c3k45CgFh2P3hRJsDG8HZxOZ9c0idsuzptLp3kIqAT6VS/pLGY+lAOS2e30x5724 9gzp6sI7kJQcly8z3UUezjq43DPRRC6WhxNnCg2I05EVxl1y0sU6gjksr7Rcl5PpREEQ YOSTZ4thN6e/hrXLsuzkPL2PnkGgQCX2VdQWln2GV3ml8xEl+geiLYzJ/hF5moDCoj8/ WSB8OP7FckCHQRSpX3HwlOViZ8RJHg9TT234jwlWcawsa9c9v0HY0kuy6LD4pCIilXEq lFJkCCulBETiELexICxmRPiYg6PwGxbCDg+aIaMYtnw3t7HyfpHK9Zh4qvucPUS/t4pB jT1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503946; x=1778108746; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=QPKhlyNtYF20UvsXpxmalPiE965kFbn5215hkFZXu0A=; b=bigPBtZiRVDpxQJ2l+k3vlEsE7ezjXrDEoLHBD3P5oBJ7n6vBSkdYRUlG66vMMhbu3 CzACu7wjicCSxXcX7EPUsKx/pwf3C2samIpqQOVtSWa+mD2ExSpfAVQLCdDqzIfsLPxN 6HrJxa33j4PNaXtK4jPFAo32CcrSWx8fg0os0mO65sc0Z4wxsWY0YhE8lLN3dp5gOWc4 MLPNsoBDoqbFah49lFcxHV7sV3LbOz+fq3osygL2De7lwK0CpO3IWVrKn7uYRZ9Np8LY auF5Q8wjHhWW7fJihrtUQ282dwjSXDcYVnXEl5DbiivqcubGiMKERJJ1Tg6HqTQ7zDo6 IvqA== X-Gm-Message-State: AOJu0Yy4swLQ1qSays0KKv4L24VhTCtRVJ+vN9PlJCVSy2SVP+kQL6kN NFh55KdppMbQ7K1m/hEl7Ow6h+WPlv7BgygeZAqdokLN1DFDsQNE3bk+phzkovKcgkTL75yqNsf JKaJa X-Gm-Gg: AeBDiev+I0YZRHhdKYJgcZh0lUPaj4P/OY7Pn/kHLGmXGpZihWXAB8a7XItemMAUcbp OhwcTq61BrGraEFlqX8hCYmDB6+Kne29A3I0jJd8liRxpLZO8eSDeTKA0LA+fNM2QCUvRysi1g1 gKb5kNeXVGP14eV0lpXdqiJltXiSoIywlhC+Q3vTfADzfXgN9Nu57ZZTujKc/ZGzXEryGJYBR9d dT2SVtQzqVk05f2pTvHHv9SfvC4pp4YFcICKzuJmlwO6a9eyirEQHUnNNQVHV+M6xGrH4OCMIrH UVCHFwlP8iaCItv5wMqEIE9/ZniARsK2rUltqqN44UD/9tQoy1SRTB/oHPPYSu6h1aLRgc+uEzu yDapJW9Hcds+0Q351icFdHbeoLmH+rvge2i0xUSa+zP2VlguYYDK9vjEyaRIOYn9wTyfkDYB5R5 Zv52D8QvKmkAhlmWBL3UQel/olTEFIhsPhBqJRbaUfY8Wh X-Received: by 2002:a05:6122:e266:b0:56f:1bbb:83d6 with SMTP id 71dfb90a1353d-573c966b5a9mr87971e0c.10.1777503946419; Wed, 29 Apr 2026 16:05:46 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6b7d905sm2053822e0c.1.2026.04.29.16.05.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:45 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 19/37] GDB: testsuite: DWARF: Don't return -1 from top-level (manual) Date: Wed, 29 Apr 2026 20:04:10 -0300 Message-ID: <20260429230432.60487-20-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" statements that weren't caught by the sed command. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside block such as save_vars, with_test_prefix, foreach, gdb_test_multiple. Some weren't changed because they didn't meet the criteria above, or weren't trivial to check. --- .../gdb.dwarf2/debug-aranges-duplicate-offset-warning.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp | 2 +- gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp | 2 +- gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp | 4 ++-- gdb/testsuite/gdb.dwarf2/gdb-index.exp | 2 +- gdb/testsuite/gdb.dwarf2/loc-sec-offset.exp | 2 +- gdb/testsuite/gdb.dwarf2/loclists-multiple-cus.exp | 2 +- gdb/testsuite/gdb.dwarf2/loclists-sec-offset.exp | 2 +- gdb/testsuite/gdb.dwarf2/loclists-start-end.exp | 2 +- gdb/testsuite/gdb.dwarf2/rnglists-multiple-cus.exp | 2 +- gdb/testsuite/gdb.dwarf2/rnglists-sec-offset.exp | 2 +- gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp | 2 +- 13 files changed, 14 insertions(+), 14 deletions(-) diff --git a/gdb/testsuite/gdb.dwarf2/debug-aranges-duplicate-offset-warning.exp b/gdb/testsuite/gdb.dwarf2/debug-aranges-duplicate-offset-warning.exp index 250f479e0274..9432415fdd0d 100644 --- a/gdb/testsuite/gdb.dwarf2/debug-aranges-duplicate-offset-warning.exp +++ b/gdb/testsuite/gdb.dwarf2/debug-aranges-duplicate-offset-warning.exp @@ -59,11 +59,11 @@ Dwarf::assemble $asm_file { save_vars { GDBFLAGS } { append GDBFLAGS " -iex \"maint set dwarf synchronous on\"" if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } } set readnow_p [readnow] diff --git a/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp b/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp index fa3bf5f4b3e0..1be466f513c7 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp @@ -23,11 +23,11 @@ load_lib dwarf.exp require dwarf2_support standard_testfile .c -dw.S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Make some DWARF for the test. set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { diff --git a/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp b/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp index 7f9f9464aaf5..e6859159c291 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-inline-param.exp @@ -44,11 +44,11 @@ set command "$objcopy_program -N block_start -N block_end -N break_at ${binfile} verbose -log "Executing: $command" set result [catch {exec {*}$command} output] verbose "result is $result" verbose "output is $output" if {$result != 0} { - return -1 + return } gdb_load ${binfile_stripped} if {![runto "*${break_at}"]} { diff --git a/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp b/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp index 294e7c8bf45f..8032f71c7d9c 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-prologue-end.exp @@ -93,11 +93,11 @@ gdb_test "frame" ".*main \\\(\\\) at \[^\r\n\]*:$prologue_end_line\r\n.*" with_test_prefix "ignore-prologue-end" { clean_restart $::testfile gdb_test_no_output "maintenance set ignore-prologue-end-flag on" if {![runto_main]} { - return -1 + return } # If we ignore the prologue-end flag, we should stop at the first statement # of main which assigns m. set prologue_end_line [gdb_get_line_number "main assign m"] diff --git a/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp b/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp index 6d3bf29c1b10..94afa35f5588 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-add-index-symlink.exp @@ -25,16 +25,16 @@ standard_testfile main.c # First check whether we can actually handle the non-symlink case. with_test_prefix non-symlink { if { [prepare_for_testing "failed to prepare" "${testfile}" \ [list ${srcfile}]] } { - return -1 + return } if { [ensure_gdb_index $binfile] == -1 } { untested "error adding gdb index" - return -1 + return } } # Regenerate exec without index. if { [prepare_for_testing "failed to prepare" "${testfile}" \ diff --git a/gdb/testsuite/gdb.dwarf2/gdb-index.exp b/gdb/testsuite/gdb.dwarf2/gdb-index.exp index 456d7266c599..6ff1209ad1b6 100644 --- a/gdb/testsuite/gdb.dwarf2/gdb-index.exp +++ b/gdb/testsuite/gdb.dwarf2/gdb-index.exp @@ -115,11 +115,11 @@ gdb_test_multiple $cmd $test { } -re "(Psymtabs|Cooked).*${gdb_prompt} $" { lassign [local_add_gdb_index $binfile] binfile_with_index host_binfile_with_index set testfile_with_index [file tail $binfile_with_index] if { ${binfile_with_index} == "" } { - return -1 + return } } -re ".*${gdb_prompt} $" { fail "unrecognized symbol reader" } diff --git a/gdb/testsuite/gdb.dwarf2/loc-sec-offset.exp b/gdb/testsuite/gdb.dwarf2/loc-sec-offset.exp index f2a244791d16..edfcb8842d10 100644 --- a/gdb/testsuite/gdb.dwarf2/loc-sec-offset.exp +++ b/gdb/testsuite/gdb.dwarf2/loc-sec-offset.exp @@ -95,11 +95,11 @@ foreach_with_prefix is_64 {false true} { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto_main] } { return } diff --git a/gdb/testsuite/gdb.dwarf2/loclists-multiple-cus.exp b/gdb/testsuite/gdb.dwarf2/loclists-multiple-cus.exp index a822f0c2f2e9..e2bacbcb8dc0 100644 --- a/gdb/testsuite/gdb.dwarf2/loclists-multiple-cus.exp +++ b/gdb/testsuite/gdb.dwarf2/loclists-multiple-cus.exp @@ -122,11 +122,11 @@ foreach_with_prefix is_64 {false true} { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto_main] } { return } diff --git a/gdb/testsuite/gdb.dwarf2/loclists-sec-offset.exp b/gdb/testsuite/gdb.dwarf2/loclists-sec-offset.exp index b80639b32ddd..bc64b7adabd4 100644 --- a/gdb/testsuite/gdb.dwarf2/loclists-sec-offset.exp +++ b/gdb/testsuite/gdb.dwarf2/loclists-sec-offset.exp @@ -210,11 +210,11 @@ foreach_with_prefix is_64 {false true} { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto_main] } { return } diff --git a/gdb/testsuite/gdb.dwarf2/loclists-start-end.exp b/gdb/testsuite/gdb.dwarf2/loclists-start-end.exp index f40d6fd8ec5c..c8d9f123625f 100644 --- a/gdb/testsuite/gdb.dwarf2/loclists-start-end.exp +++ b/gdb/testsuite/gdb.dwarf2/loclists-start-end.exp @@ -113,11 +113,11 @@ foreach_with_prefix is_64 {false true} { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if { ![runto_main] } { return } diff --git a/gdb/testsuite/gdb.dwarf2/rnglists-multiple-cus.exp b/gdb/testsuite/gdb.dwarf2/rnglists-multiple-cus.exp index d005c8b907cc..e48eb39f3a59 100644 --- a/gdb/testsuite/gdb.dwarf2/rnglists-multiple-cus.exp +++ b/gdb/testsuite/gdb.dwarf2/rnglists-multiple-cus.exp @@ -90,11 +90,11 @@ foreach_with_prefix is_64 {false true} { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Sanity checks to make sure GDB slurped the symbols correctly. gdb_test "p/x &foo" " = 0x3000" } diff --git a/gdb/testsuite/gdb.dwarf2/rnglists-sec-offset.exp b/gdb/testsuite/gdb.dwarf2/rnglists-sec-offset.exp index bbfc9e35c646..6207e31b9d0f 100644 --- a/gdb/testsuite/gdb.dwarf2/rnglists-sec-offset.exp +++ b/gdb/testsuite/gdb.dwarf2/rnglists-sec-offset.exp @@ -129,11 +129,11 @@ foreach_with_prefix is_64 {false true} { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } # Sanity checks to make sure GDB slurped the symbols correctly. gdb_test "p/x &foo" " = 0x4000" gdb_test "p/x &bar" " = 0x5000" diff --git a/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp b/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp index 4218dd119470..28a2fd7ad58c 100644 --- a/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp +++ b/gdb/testsuite/gdb.dwarf2/struct-with-sig-2.exp @@ -122,11 +122,11 @@ Dwarf::assemble $asm_file { save_vars { GDBFLAGS } { append GDBFLAGS " -iex \"maint set dwarf synchronous on\"" if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } } set re "DWARF Error: .debug_types section not supported in dwz file" gdb_assert { [regexp $re $gdb_file_cmd_msg] } "Dwarf Error message" From patchwork Wed Apr 29 23:04:11 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134226 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 6D3634BB3BD0 for ; Wed, 29 Apr 2026 23:13:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6D3634BB3BD0 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=ddKf7qhG X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa32.google.com (mail-vk1-xa32.google.com [IPv6:2607:f8b0:4864:20::a32]) by sourceware.org (Postfix) with ESMTPS id 135414358A57 for ; Wed, 29 Apr 2026 23:05:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 135414358A57 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 135414358A57 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a32 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503950; cv=none; b=wjSVpUiHBojExg+YrX4m2VzZbnzWj89cY6mje8bDj+naTOzEdMw71NQvDNdGc4a5GqWBkJv6tmA2XJtgAshBnMrz1R80+NFJxYgbfHbTDCCHETxhS0gk3p/SIS+XJ4AAuAtUjsxatall6KluPlEnPu39gIbpY+0czJdZGU+wddQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503950; c=relaxed/simple; bh=M3IM7D8uMnO0jfAwPmn5vBEIKoXP0qIssQCx016fVkY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=EnG3+ciAc2rsYjIqnMdnGW+1K6hVr6rwhubUAmZZ5pfie5hsqwSiwof9w0TDKpIJ5IHOndCrD4rgBoutSaBc273Jfuvs3CDxQvn4M7EREKUwcPWeZcWQ+7FY2Nzec7DDpecPy8xwWRcQVsJfbxT3LwjQYfDe8Tj5YIeWMbw8wRQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 135414358A57 Received: by mail-vk1-xa32.google.com with SMTP id 71dfb90a1353d-56eec951db1so102914e0c.3 for ; Wed, 29 Apr 2026 16:05:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503949; x=1778108749; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=UxAQ12fWAwFjwK/WMFIDkEdzORNN63VBqdMwvHJqxBw=; b=ddKf7qhGt2YQKi24s+TF7RSPVnl1bFdNOHXpHBCuC1Bn8FaXlnXlu4eEtTOYov6qA4 kWb9iLrqTApDo23HaeEKMdEU1ZfjqYAQIyhrroCeRBkxu8kx7TyB+5QkC/qF14qBuJ+4 8bZo1ih809d9RviBFvCxqE8VR130Cwnxif2uiUDVxTujS5/9XHJFQ/sUHCf7CsCpaNz9 9aq8c6UidBNAGGLK7tQ1NExRg4kiW1b7QtN327CVbdkqVZ9KVL0TROjtLEigzlqrUJys zrIk/TkTW41AUYEflVW8s3ncpnbyA99eqRHthLDDKlTmgVRvkJWQcQ5srZxAo4RKS4t3 sp+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503949; x=1778108749; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=UxAQ12fWAwFjwK/WMFIDkEdzORNN63VBqdMwvHJqxBw=; b=IO9kYVHc+C87leDRWCayGru2lgWLdqk1iC/EMKVlEUCM++E9A0uLA55jBpEG0iwovK M2dN9VTol3ZP7qwCD2LIz3fgI18qwbhWGSTxzRn0wje88Cnh6wQOZqyiUI8ZcQqgD9uE AYOWVMIt5PN3mpQ1NQlceFiu3wfVg3mdaMmNunkUNMzlzKWbGmBDqbhsvpvDcNn9yreq Pb+LLmiNvPJCzAaTy9c9Pk09x9N90jcdfotJ3TWLCkLQRqR5+Nm+iqnZfrmORIsWO1O5 PqvBr9zKtB9wUaiEEVeV7YNwOYPmn/0o5mOaEdpQXDQ2SWpdZt18Uj7ckp1PQHd7d0WI PU/w== X-Gm-Message-State: AOJu0YxTI/HzBWlQmCwOEer8r1kBoIsSn8kf1oAGuRQJZwV/AXzqSgi+ eTosW+BLu0GcHtz1QtuXZpD2LDk55EpM1llyoGd+PLCCwJQwBmYXzpVYUJgkwWmITA9pz2XK1lb yK5PD X-Gm-Gg: AeBDievrz3mEKyZbo19if7tj8ZNXMKImm3/gpsZ258s7zF6CMVSDFCZdXz+ovzjp1zE 2b3KgaEFEtJNXksIFuecM0QGIF07DkzsPDz0JRs473lneyMBI8d0mFs4orBxOk9pS7e9lUnj6ml 7I2luphp1TRHAYymVlh7LinemnHvfYMowRuoSjDkUTGPT6xRMw5ZPPAP+DXUhgjiqBZCQGN465P XJbgTdYcKXPXnnAAWPZZxkfP1qnIYGudLhVVXFzYwjvJECj5kdoSb6aVwQ9TLaVm1P+ueVk1aZ5 Ktxm7y24HXE+GYc4SA3Vz4zGpKPKDxad1j6u152sJD3t2E2oxDnaRUDVZG4M/8JF3BQiQ/eZM+M N0qiNDchhy6IZILZVtg0eD3JaZSPTyCC21fS/QkvcBdCNnS/FhN+hG+upuonJtcVIl1emw9OGC0 xv4rub7+V6PT7+NAdpSsDMlCmKg5LJvQyssjPIThtJHojG X-Received: by 2002:a05:6122:790:b0:572:4f60:b8e6 with SMTP id 71dfb90a1353d-573c96f4495mr97178e0c.12.1777503949371; Wed, 29 Apr 2026 16:05:49 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6df59edsm2040631e0c.14.2026.04.29.16.05.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:49 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 20/37] GDB: testsuite: GDB: Don't return -1 from top-level Date: Wed, 29 Apr 2026 20:04:11 -0300 Message-ID: <20260429230432.60487-21-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org All changes except for one are the result of running: $ sed -i 's/^ return -1/ return/' *.exp inside gdb/testsuite/gdb.gdb. The exception is a return statement in index-file.exp, which is inside a with_timeout_factor block. --- gdb/testsuite/gdb.gdb/index-file.exp | 8 ++++---- gdb/testsuite/gdb.gdb/python-helper.exp | 2 +- gdb/testsuite/gdb.gdb/unittest.exp | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/gdb.gdb/index-file.exp b/gdb/testsuite/gdb.gdb/index-file.exp index 162ba28bfde1..d0c845302fc2 100644 --- a/gdb/testsuite/gdb.gdb/index-file.exp +++ b/gdb/testsuite/gdb.gdb/index-file.exp @@ -25,18 +25,18 @@ require !readnow set timeout_factor 20 set filename [selftest_prepare] if { $filename eq "" } { unsupported "${gdb_test_file_name}.exp" - return -1 + return } # If FILENAME is a libtool wrapper, then we need to get the path of the real # executable. set filename [selftest_libtool_get_real_gdb_executable $filename] if { $filename eq "" } { - return -1 + return } with_timeout_factor $timeout_factor { # Start GDB, load FILENAME. clean_restart @@ -46,11 +46,11 @@ with_timeout_factor $timeout_factor { # Record how many worker threads GDB is using. set worker_threads [gdb_get_worker_threads] if { $worker_threads eq "UNKNOWN" } { unresolved "unable to get worker thread count" - return -1 + return } # Generate an index file. set dir1 [standard_output_file "index_1"] remote_exec host "mkdir -p ${dir1}" @@ -64,11 +64,11 @@ with_timeout_factor $timeout_factor { pass $gdb_test_name set ok 1 } } if { ! $ok } { - return -1 + return } gdb_test_no_output "save gdb-index -dwarf-5 $dir1" \ "create dwarf-index files" } diff --git a/gdb/testsuite/gdb.gdb/python-helper.exp b/gdb/testsuite/gdb.gdb/python-helper.exp index b39f51de44fe..8f00ce920af3 100644 --- a/gdb/testsuite/gdb.gdb/python-helper.exp +++ b/gdb/testsuite/gdb.gdb/python-helper.exp @@ -24,11 +24,11 @@ require {!target_info exists gdb,noinferiorio} require allow_python_tests standard_testfile .cc if { [build_executable "failed to build" $testfile $srcfile {debug c++}] } { - return -1 + return } # Find the helper script in the GDB build directory. set py_helper_script [file dirname $GDB]/gdb-gdb.py if { ![file readable $py_helper_script] \ diff --git a/gdb/testsuite/gdb.gdb/unittest.exp b/gdb/testsuite/gdb.gdb/unittest.exp index 29e4206cb309..26870a7a0b7a 100644 --- a/gdb/testsuite/gdb.gdb/unittest.exp +++ b/gdb/testsuite/gdb.gdb/unittest.exp @@ -22,11 +22,11 @@ load_lib completion-support.exp set do_xml_test [allow_xml_test] standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc run_selftests_1 {} { global decimal gdb_prompt From patchwork Wed Apr 29 23:04:12 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134210 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id EDD6D4358A68 for ; Wed, 29 Apr 2026 23:07:59 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org EDD6D4358A68 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=RmQM99My X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2a.google.com (mail-vk1-xa2a.google.com [IPv6:2607:f8b0:4864:20::a2a]) by sourceware.org (Postfix) with ESMTPS id 8C1274358A44 for ; Wed, 29 Apr 2026 23:05:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8C1274358A44 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 8C1274358A44 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503953; cv=none; b=l0teus4y4cOy7m0HRiVtaB79hvKkpCd67nR2Qo3mrC2V4Cl+D6Fa1DN+HxoAfGYlpRMUxfJUy7sjwb+jt99eYSdB8IljwcuQvz/Emap1Luo3DpRBwNEo3wEsrjmEWa/1zMJ3G7SP+ObfEumrdFm+BjHqlsbNAiaxQBLAUwy8yUY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503953; c=relaxed/simple; bh=T0yetfKuv+5sOw9jxNVxIe3pNuJ2cBqLUxTzl/UwuqA=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=d809jQ1wlb8oiC+ud6A4b95DPkvhwfIoz2qGnme/+oVC7oAcnsnZI7GgRV+Uzu/Bq069GvDwiiJdQs3FpPWkfkz7HIcjfsZGC7T3WnKTXLiuv2DkFI4NwejwlWAe2ibCrVAE3UZWaSs4A7YHksnKpZ2iKlxtp5S+8Gpf8KGg3+k= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8C1274358A44 Received: by mail-vk1-xa2a.google.com with SMTP id 71dfb90a1353d-56efdc96b05so177317e0c.1 for ; Wed, 29 Apr 2026 16:05:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503953; x=1778108753; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=If5k3NMQaypmz2zRwxBmFMwKkMA+nzTdUYut0qsdqGI=; b=RmQM99MyZ2Uw2KTANbOHixLu5WLV8k5yjW//Jw08xDXfIJIWtKz6MrHsJXATia8Q5n qh+TVdIDKjnU3UvfOqk6ou0d1IOSZhrcoMtbW9fVxjDEyoMWESe+J5vHbvvKxWgTW6VT KFzJHOMgg5XYvi/osMyPXhsC4d2YxolXYox480TIhFyUJd007DLFpDvPlg+JzAmR8Ou9 whYdEg/Ga9le3IJkbzjC5Pjz8JBjteTKe8TJw86sFC2HRFqH/3aakFBx0X9Q9wDtItZn IdnZfOyTOlJVofflQmjjj3E3ovp1pekJwAFQD7vWZUlZfetAUMctp3VDfgNGrUGlLe4k sWTQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503953; x=1778108753; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=If5k3NMQaypmz2zRwxBmFMwKkMA+nzTdUYut0qsdqGI=; b=jGk2ligFKaxshpclLvX6m63ZG7mLcxg80yiED/jOtW9p78w3pbIAzNQkQLtlAXqJCR jfsQLJjkzSOFEkoeD1/WjKMIT7P5jDwRV/abC/Nop8yDoPAyoq8G2mfbKtI62buxzJP7 ASdY2ZKp1nE3lA7jpSCW0xWFKCdR5tKsK61nxLHJrPfIA0zKmpQrtGGbowUHnzhtcrUx huYpZ1j6sNuMs3bB7AtE88CXVZmu1Edgr5UoTfs9U8HGesWMNktDl5aV+nQK0//SvdQa sa4YxDpKI6MPOFS6rnaFeN0RWfIlpuYLZvrpnvdTJ7v0J5C4EEr+J6Dsokq6EE/fzUAY OHEA== X-Gm-Message-State: AOJu0Yy82Ez4bmmqY9R7YKwcmROZkQP8YopE9YFOAQ0dN4qKWhyqVp5z 2FoFgYGnh1xFdKLBt5N0cK0SQcKh8zmivLeZqPSit6vc3kVwxeW2+jIHi0FVTra/M3dLvRjq6aI YhCIP X-Gm-Gg: AeBDievu7iEDtr2YUwNxQPofkoEzC+fVn2kdnhIC7DqYeZ+Y3CxrXZpXnUlTAph4r1Z VgyMN9wt1rYSA7sia6ilPG9RWwhupt8nssrUL88+ty84nZ11Yr30HFd8VByMjYU0bCstOtY1R2N v/p2ESuePzAT3l0rMUlBlG5ygQPwDoooIP3cyzUn+hVRbgd5e1dkeKhF0/c+P8pP+7+5++I4Usw kEkAdbrSxHbJ8azEWGx8oE73h77rQpscG3Zld3s7z1x57nyBCoPrDylKKf9DpN0q6QDYIOUi44l gQqkiZBbl8u314ME8jR3NKOWSZ/elOHbFBfMZBmVtyPRf3mdVA31vBiChq1ZTZqHAlFzWd4aNPi H0hkuVPwXMgq0Kv60oMzzXGI+F93jE8jYEdeBhSdz7CWXtR82+C3kCm6Bg23o65izFXzhg9p+on FRtMAI2FnBjZM8zncDfqUFOLOPT02ebiSW+SWOXHT3H0n3 X-Received: by 2002:a05:6122:608c:b0:56d:9def:20c8 with SMTP id 71dfb90a1353d-573c95d5b6emr99790e0c.6.1777503952779; Wed, 29 Apr 2026 16:05:52 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6bc23e2sm2155220e0c.6.2026.04.29.16.05.51 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:51 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 21/37] GDB: testsuite: Guile: Don't return -1 from top-level Date: Wed, 29 Apr 2026 20:04:12 -0300 Message-ID: <20260429230432.60487-22-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org All changes are the result of running: $ sed -i 's/^ return -1/ return/' *.exp inside gdb/testsuite/gdb.guile. --- gdb/testsuite/gdb.guile/scm-block.exp | 2 +- gdb/testsuite/gdb.guile/scm-breakpoint.exp | 2 +- gdb/testsuite/gdb.guile/scm-frame.exp | 2 +- gdb/testsuite/gdb.guile/scm-iterator.exp | 2 +- gdb/testsuite/gdb.guile/scm-progspace.exp | 2 +- gdb/testsuite/gdb.guile/scm-symbol.exp | 4 ++-- gdb/testsuite/gdb.guile/types-module.exp | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) diff --git a/gdb/testsuite/gdb.guile/scm-block.exp b/gdb/testsuite/gdb.guile/scm-block.exp index 8027dc0ce193..c5e2fd4403bc 100644 --- a/gdb/testsuite/gdb.guile/scm-block.exp +++ b/gdb/testsuite/gdb.guile/scm-block.exp @@ -21,11 +21,11 @@ load_lib gdb-guile.exp require allow_guile_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![gdb_guile_runto_main]} { return } diff --git a/gdb/testsuite/gdb.guile/scm-breakpoint.exp b/gdb/testsuite/gdb.guile/scm-breakpoint.exp index 68744bb87f7f..60764a986c13 100644 --- a/gdb/testsuite/gdb.guile/scm-breakpoint.exp +++ b/gdb/testsuite/gdb.guile/scm-breakpoint.exp @@ -21,11 +21,11 @@ load_lib gdb-guile.exp require allow_guile_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } proc_with_prefix test_bkpt_basic { } { global srcfile testfile hex decimal diff --git a/gdb/testsuite/gdb.guile/scm-frame.exp b/gdb/testsuite/gdb.guile/scm-frame.exp index 8c86b7a8249b..7db24f6e4e9a 100644 --- a/gdb/testsuite/gdb.guile/scm-frame.exp +++ b/gdb/testsuite/gdb.guile/scm-frame.exp @@ -21,11 +21,11 @@ load_lib gdb-guile.exp require allow_guile_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # The following tests require execution. if {![gdb_guile_runto_main]} { diff --git a/gdb/testsuite/gdb.guile/scm-iterator.exp b/gdb/testsuite/gdb.guile/scm-iterator.exp index 6907ec2d8699..cdbaf20d6995 100644 --- a/gdb/testsuite/gdb.guile/scm-iterator.exp +++ b/gdb/testsuite/gdb.guile/scm-iterator.exp @@ -21,11 +21,11 @@ load_lib gdb-guile.exp require allow_guile_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![gdb_guile_runto_main]} { return } diff --git a/gdb/testsuite/gdb.guile/scm-progspace.exp b/gdb/testsuite/gdb.guile/scm-progspace.exp index 306d08769e8d..3b73ecb82330 100644 --- a/gdb/testsuite/gdb.guile/scm-progspace.exp +++ b/gdb/testsuite/gdb.guile/scm-progspace.exp @@ -21,11 +21,11 @@ load_lib gdb-guile.exp require allow_guile_tests standard_testfile if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } clean_restart gdb_install_guile_utils diff --git a/gdb/testsuite/gdb.guile/scm-symbol.exp b/gdb/testsuite/gdb.guile/scm-symbol.exp index bed817edcc02..6cd1199e9b28 100644 --- a/gdb/testsuite/gdb.guile/scm-symbol.exp +++ b/gdb/testsuite/gdb.guile/scm-symbol.exp @@ -21,11 +21,11 @@ load_lib gdb-guile.exp require allow_guile_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # These tests are done before we call gdb_guile_runto_main so we have to # import the gdb module ourselves. gdb_install_guile_utils @@ -136,11 +136,11 @@ gdb_test "guile (print (symbol-symtab t))" "= #" # C++ tests # Recompile binary. if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}-cxx" executable "debug c++"] != "" } { untested "failed to compile in C++ mode" - return -1 + return } clean_restart ${::testfile}-cxx if {![gdb_guile_runto_main]} { diff --git a/gdb/testsuite/gdb.guile/types-module.exp b/gdb/testsuite/gdb.guile/types-module.exp index 9693d4b36559..b48a24742ebf 100644 --- a/gdb/testsuite/gdb.guile/types-module.exp +++ b/gdb/testsuite/gdb.guile/types-module.exp @@ -25,11 +25,11 @@ standard_testfile .cc set flags {} lappend flags debug lappend flags c++ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $flags] } { - return -1 + return } if {![gdb_guile_runto_main]} { return } From patchwork Wed Apr 29 23:04:13 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134227 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 02ACA4BA798C for ; Wed, 29 Apr 2026 23:14:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 02ACA4BA798C Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=J+yxUiU4 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vs1-xe30.google.com (mail-vs1-xe30.google.com [IPv6:2607:f8b0:4864:20::e30]) by sourceware.org (Postfix) with ESMTPS id ACC864358A57 for ; Wed, 29 Apr 2026 23:05:57 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org ACC864358A57 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org ACC864358A57 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::e30 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503957; cv=none; b=cXHLJheWBpUMG0ss/YC2lfWy/l4Bi48C8b72JYShFCy8eL7y9hkQU9F/lLR/Wvi10zVs7HbSko7ZmHJ9qFMZB6bIJMLXjNGHtlJ4cOha1qfp2f1RGzo62AhuB2yDZ350aFakRaHjAE+Fg0+XJSkDrsiGnWIZTQboGRIo5islvEk= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503957; c=relaxed/simple; bh=TCnFb/psT0y8+NkTNXNDZciPTwCf85WT67zKA5bByCY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=jd99KVoV2abqL2SIaWyW3MUpqD/OmjzvFBZxJ+NrBEgP8D2qMnto99jB8jQ4EMGyCGJm9FaMNsOuRxg2ZmewCiyEeea82yrd5+6eimbjZ1ctY+Em1aAu72KBdxLwIXgWmbwBSfRV0jmhj+r3j4AfNcWBIonspr2PKQ5ICaH/psQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org ACC864358A57 Received: by mail-vs1-xe30.google.com with SMTP id ada2fe7eead31-60fce51aa55so108340137.3 for ; Wed, 29 Apr 2026 16:05:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503957; x=1778108757; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=n4BbJy427LLf07aM+ksn0AKlHt0oEnS9MN3Dcx63Oik=; b=J+yxUiU4Gx48V0lrZ9XG8xMWCgYiojel7KtQxCor9SkmhT3yBZov7kzM+1JiIy+iWo hsMgN1L1ZkCJ/SSlxgvp1XAO8UZ/Toj/yWfRWmeTDrokX1DdwdU/ZvwMX10ib84hPVD3 GudODkN/kegWxmKPhWia+nM8162nSN86ZR7lS57Xjp7IN6y0lk5EK97t7Q2XsWTXV/wZ BbsG2tn/RwKhOSCYKZfNTNFy1SO8NUeKy3YH0rk4ogLazGYm/FOVGI8waynVZWWkJ5N/ ajrBUaW53b23YkT+eAyNBa21s5qAL8MEjcdCDrhcxCvi934olBuG2+HdISMMC4EURuXD nnVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503957; x=1778108757; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=n4BbJy427LLf07aM+ksn0AKlHt0oEnS9MN3Dcx63Oik=; b=CICBWlgYGzCnF1J7ZXPmw9CxqZNKv4M2V/Y/U+o2ap7iohSAlpP5ofecHiz5n/+YoQ TJT5LbODzVBkAGfmXJCWJTKxjePUWx11U0Vu2b8sB7WC6XOaUlf1bjW14v9efgbm7hXz xt7kENzMkJZb5mcjgyHN1MMbRTUrQbbWBf9alGW659oXzjSU4a1/eA1UrihFCf87aq8R 5ZpFyJnNniwmm4w66+30I4SnxFtL2vEWmLHoQ/Y1EM0btMml1KRfI+fXGsWSh8eQ0XZb WLKd4+sggj5Ak5D239PGDIHOHahIbjR0F3If6eVVx+/Wk4VKIKAPYU1vqm2I5Y9EcY8n j7Yw== X-Gm-Message-State: AOJu0Ywm1Lc2VQYKQUqotnGXkXMuaMIKdgZoCdbQkHe7ibDyfCZiOKvJ K2vQr10DWEp10hIMnp6AMaj1q6sVuoFRdvvT8DyFwq63mXyPUlo/xerW1Ro1fv4iXa21g42cLxU bEHoc X-Gm-Gg: AeBDies1DhAinDgeIGwoJXCKW+Pihi2jzjNXYo8LbHT0idJwQsFlEIDyxdxHPXlcyP1 hBeZFoLoUW3nms3oYFvv2KmJzT48/4W8SXHFAg4k2cFSJuZBMk0U8WT7n9UZSPk0D+caW7NWKBU cfqFLsGRm96WFx3q/VsncsJgerHgkLnXPA/M72OZ4rAv4f2+sFCURz2onWtSVCE+71tKXE4lDmu TLdraNRhpuTpox17AMc6dczY6NYC5F/MZSLP/0aP+5d7khQDaE74id1l/jHtA2vu8VrpG2h9LR5 ocdDMxtBUUGsHQaRBgwiR8KBlVRnJhOs6nyQW2NBo+iDL2YDWCZ7OBUBAQ8+/EF2eoF3baKyY/W gDlp8QkXypN+AC4vdEOCykU5MV8RUikEE0vtqsTEChPkFEjmThpzVUb5m3UYi98Plqm0ixAiKh1 fMV2s0QwJoJ/67gPJ7oSJQ7IMhrrsuzFBCPwO2E5K7/oyIE+qecmXvGMM= X-Received: by 2002:a05:6102:4a8a:b0:605:889a:89a1 with SMTP id ada2fe7eead31-62ad405c8bamr285688137.23.1777503956535; Wed, 29 Apr 2026 16:05:56 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-6297f4e2345sm2049671137.0.2026.04.29.16.05.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:56 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 22/37] GDB: testsuite: Python: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:13 -0300 Message-ID: <20260429230432.60487-23-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.python. --- gdb/testsuite/gdb.python/lib-types.exp | 2 +- gdb/testsuite/gdb.python/pretty-print-call-by-hand.exp | 2 +- gdb/testsuite/gdb.python/py-arch-reg-groups.exp | 2 +- gdb/testsuite/gdb.python/py-arch-reg-names.exp | 2 +- gdb/testsuite/gdb.python/py-arch.exp | 2 +- gdb/testsuite/gdb.python/py-as-string.exp | 2 +- gdb/testsuite/gdb.python/py-auto-load-chaining.exp | 2 +- .../py-autoloaded-pretty-printers-in-newobjfile-event.exp | 4 ++-- gdb/testsuite/gdb.python/py-bad-printers.exp | 4 ++-- gdb/testsuite/gdb.python/py-block.exp | 2 +- gdb/testsuite/gdb.python/py-bp-locations.exp | 6 +++--- gdb/testsuite/gdb.python/py-breakpoint-create-fail.exp | 2 +- gdb/testsuite/gdb.python/py-breakpoint.exp | 2 +- gdb/testsuite/gdb.python/py-caller-is.exp | 2 +- gdb/testsuite/gdb.python/py-cmd-exception.exp | 2 +- gdb/testsuite/gdb.python/py-cmd-prompt.exp | 2 +- gdb/testsuite/gdb.python/py-cmd.exp | 2 +- gdb/testsuite/gdb.python/py-commands-breakpoint.exp | 2 +- gdb/testsuite/gdb.python/py-connection-removed.exp | 2 +- gdb/testsuite/gdb.python/py-connection.exp | 2 +- gdb/testsuite/gdb.python/py-event-load.exp | 4 ++-- gdb/testsuite/gdb.python/py-events.exp | 2 +- gdb/testsuite/gdb.python/py-evsignal.exp | 4 ++-- gdb/testsuite/gdb.python/py-evthreads.exp | 2 +- gdb/testsuite/gdb.python/py-exec-file.exp | 4 ++-- gdb/testsuite/gdb.python/py-explore-cc.exp | 2 +- gdb/testsuite/gdb.python/py-explore.exp | 2 +- .../gdb.python/py-finish-breakpoint-deletion.exp | 2 +- gdb/testsuite/gdb.python/py-finish-breakpoint.exp | 2 +- gdb/testsuite/gdb.python/py-finish-breakpoint2.exp | 2 +- gdb/testsuite/gdb.python/py-frame-args.exp | 4 ++-- gdb/testsuite/gdb.python/py-frame-inline.exp | 2 +- gdb/testsuite/gdb.python/py-frame.exp | 4 ++-- gdb/testsuite/gdb.python/py-framefilter-addr.exp | 2 +- gdb/testsuite/gdb.python/py-framefilter-invalidarg.exp | 2 +- gdb/testsuite/gdb.python/py-framefilter-mi.exp | 4 ++-- gdb/testsuite/gdb.python/py-framefilter.exp | 4 ++-- gdb/testsuite/gdb.python/py-inferior.exp | 2 +- gdb/testsuite/gdb.python/py-infthread.exp | 2 +- gdb/testsuite/gdb.python/py-label-symbol-value.exp | 2 +- gdb/testsuite/gdb.python/py-lazy-string.exp | 4 ++-- gdb/testsuite/gdb.python/py-linetable-empty.exp | 2 +- gdb/testsuite/gdb.python/py-linetable.exp | 4 ++-- gdb/testsuite/gdb.python/py-mi-cmd.exp | 2 +- gdb/testsuite/gdb.python/py-mi-events.exp | 2 +- gdb/testsuite/gdb.python/py-mi-notify.exp | 2 +- gdb/testsuite/gdb.python/py-mi-objfile.exp | 2 +- .../gdb.python/py-mi-var-info-path-expression.exp | 2 +- gdb/testsuite/gdb.python/py-mi.exp | 8 ++++---- gdb/testsuite/gdb.python/py-missing-debug.exp | 4 ++-- gdb/testsuite/gdb.python/py-nested-maps.exp | 4 ++-- gdb/testsuite/gdb.python/py-objfile-script.exp | 2 +- gdb/testsuite/gdb.python/py-objfile.exp | 4 ++-- gdb/testsuite/gdb.python/py-pending-frame-level.exp | 2 +- gdb/testsuite/gdb.python/py-pp-cast.exp | 4 ++-- gdb/testsuite/gdb.python/py-pp-integral.exp | 4 ++-- gdb/testsuite/gdb.python/py-pp-maint.exp | 4 ++-- gdb/testsuite/gdb.python/py-pp-re-notag.exp | 4 ++-- gdb/testsuite/gdb.python/py-pp-registration.exp | 4 ++-- gdb/testsuite/gdb.python/py-prettyprint-stub.exp | 2 +- gdb/testsuite/gdb.python/py-progspace-events.exp | 2 +- gdb/testsuite/gdb.python/py-progspace.exp | 2 +- gdb/testsuite/gdb.python/py-prompt.exp | 2 +- gdb/testsuite/gdb.python/py-read-memory-leak.exp | 2 +- gdb/testsuite/gdb.python/py-record-btrace-threads.exp | 4 ++-- gdb/testsuite/gdb.python/py-record-btrace.exp | 2 +- gdb/testsuite/gdb.python/py-record-full.exp | 2 +- gdb/testsuite/gdb.python/py-recurse-unwind.exp | 2 +- gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp | 2 +- gdb/testsuite/gdb.python/py-send-packet.exp | 2 +- gdb/testsuite/gdb.python/py-shared.exp | 4 ++-- gdb/testsuite/gdb.python/py-strfns.exp | 2 +- gdb/testsuite/gdb.python/py-sym-artificial.exp | 4 ++-- gdb/testsuite/gdb.python/py-symbol.exp | 4 ++-- gdb/testsuite/gdb.python/py-symtab.exp | 2 +- gdb/testsuite/gdb.python/py-sync-interp.exp | 2 +- gdb/testsuite/gdb.python/py-template.exp | 2 +- gdb/testsuite/gdb.python/py-thread-exited.exp | 4 ++-- gdb/testsuite/gdb.python/py-thrhandle.exp | 2 +- gdb/testsuite/gdb.python/py-typeprint.exp | 2 +- gdb/testsuite/gdb.python/py-unwind-inline.exp | 2 +- gdb/testsuite/gdb.python/py-unwind-maint.exp | 4 ++-- gdb/testsuite/gdb.python/py-unwind-user-regs.exp | 2 +- gdb/testsuite/gdb.python/py-unwind.exp | 2 +- gdb/testsuite/gdb.python/py-value-cc.exp | 2 +- gdb/testsuite/gdb.python/py-value.exp | 2 +- gdb/testsuite/gdb.python/py-varobj.exp | 2 +- gdb/testsuite/gdb.python/py-watchpoint.exp | 2 +- gdb/testsuite/gdb.python/py-xmethods.exp | 2 +- gdb/testsuite/gdb.python/python.exp | 2 +- gdb/testsuite/gdb.python/tui-window-disabled.exp | 2 +- gdb/testsuite/gdb.python/tui-window.exp | 2 +- 92 files changed, 122 insertions(+), 122 deletions(-) diff --git a/gdb/testsuite/gdb.python/lib-types.exp b/gdb/testsuite/gdb.python/lib-types.exp index f871abc633a5..aa281c6443d5 100644 --- a/gdb/testsuite/gdb.python/lib-types.exp +++ b/gdb/testsuite/gdb.python/lib-types.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/pretty-print-call-by-hand.exp b/gdb/testsuite/gdb.python/pretty-print-call-by-hand.exp index c9846b877ac3..52162fc99522 100644 --- a/gdb/testsuite/gdb.python/pretty-print-call-by-hand.exp +++ b/gdb/testsuite/gdb.python/pretty-print-call-by-hand.exp @@ -23,11 +23,11 @@ require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { untested "failed to compile" - return -1 + return } # This proc restarts GDB, makes the inferior reach the desired spot - marked # by a comment in the .c file - and turns on the pretty printer for testing. # Starting with a new GDB is important because the test may crash GDB. The diff --git a/gdb/testsuite/gdb.python/py-arch-reg-groups.exp b/gdb/testsuite/gdb.python/py-arch-reg-groups.exp index 5c06ebff9426..6630143f0373 100644 --- a/gdb/testsuite/gdb.python/py-arch-reg-groups.exp +++ b/gdb/testsuite/gdb.python/py-arch-reg-groups.exp @@ -18,11 +18,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile py-arch.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-arch-reg-names.exp b/gdb/testsuite/gdb.python/py-arch-reg-names.exp index 954cbb77754a..7bbb171e13e1 100644 --- a/gdb/testsuite/gdb.python/py-arch-reg-names.exp +++ b/gdb/testsuite/gdb.python/py-arch-reg-names.exp @@ -18,11 +18,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile py-arch.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-arch.exp b/gdb/testsuite/gdb.python/py-arch.exp index 12b0e4a10c80..a2ac6ad4bfa1 100644 --- a/gdb/testsuite/gdb.python/py-arch.exp +++ b/gdb/testsuite/gdb.python/py-arch.exp @@ -15,11 +15,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-as-string.exp b/gdb/testsuite/gdb.python/py-as-string.exp index fd4d5d740f45..3dc858db1ada 100644 --- a/gdb/testsuite/gdb.python/py-as-string.exp +++ b/gdb/testsuite/gdb.python/py-as-string.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-auto-load-chaining.exp b/gdb/testsuite/gdb.python/py-auto-load-chaining.exp index 5033f21526cc..7a92ff0fac71 100644 --- a/gdb/testsuite/gdb.python/py-auto-load-chaining.exp +++ b/gdb/testsuite/gdb.python/py-auto-load-chaining.exp @@ -44,11 +44,11 @@ set remote_python_file [gdb_remote_download host \ set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}-f2.o-gdb.py] # Build the main test executable and start GDB. if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-autoloaded-pretty-printers-in-newobjfile-event.exp b/gdb/testsuite/gdb.python/py-autoloaded-pretty-printers-in-newobjfile-event.exp index d4498dfc8cd8..9b8a10cf84f5 100644 --- a/gdb/testsuite/gdb.python/py-autoloaded-pretty-printers-in-newobjfile-event.exp +++ b/gdb/testsuite/gdb.python/py-autoloaded-pretty-printers-in-newobjfile-event.exp @@ -30,19 +30,19 @@ set python_autoload_file "${srcdir}/${subdir}/${libname}.so-gdb.py" set binfile_lib [standard_output_file "${libname}.so"] # Compile library. if { [gdb_compile_shlib ${srcdir}/${subdir}/${srcfile_lib} ${binfile_lib} \ {debug c++}] != "" } { - return -1 + return } # Compile main program. if { [gdb_compile ${srcdir}/${subdir}/${srcfile} \ ${binfile} \ executable \ [list debug c++ shlib=$binfile_lib]] != "" } { - return -1 + return } clean_restart # Make the -gdb.py script available to gdb, it is automatically loaded by diff --git a/gdb/testsuite/gdb.python/py-bad-printers.exp b/gdb/testsuite/gdb.python/py-bad-printers.exp index 70704c668118..a96030d6b483 100644 --- a/gdb/testsuite/gdb.python/py-bad-printers.exp +++ b/gdb/testsuite/gdb.python/py-bad-printers.exp @@ -21,15 +21,15 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-block.exp b/gdb/testsuite/gdb.python/py-block.exp index e4e309da05f0..b0123c4d3b57 100644 --- a/gdb/testsuite/gdb.python/py-block.exp +++ b/gdb/testsuite/gdb.python/py-block.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-bp-locations.exp b/gdb/testsuite/gdb.python/py-bp-locations.exp index 00ff1c9912ac..879306ea0f24 100644 --- a/gdb/testsuite/gdb.python/py-bp-locations.exp +++ b/gdb/testsuite/gdb.python/py-bp-locations.exp @@ -18,19 +18,19 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {c++ debug}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { clean_restart $testfile } if {![runto_main]} { - return -1 + return } # Build a regexp string that represents the __repr__ of a # gdb.BreakpointLocation object. Accepts arguments -enabled, -address, # -source, -line, and -func. @@ -78,11 +78,11 @@ gdb_test "python print(gdb.breakpoints()\[1\].locations\[0\])" \ -line "$expected_line_a" -func ".*"] \ "check repr of disabled breakpoint location" gdb_continue_to_breakpoint "" ".*25.*" if {![runto_main]} { - return -1 + return } gdb_breakpoint "add" # Disable "add" owner breakpoint and verify all locations still are enabled. gdb_test "python gdb.breakpoints()\[1\].enabled = False" "" "Disable add owner breakpoint." diff --git a/gdb/testsuite/gdb.python/py-breakpoint-create-fail.exp b/gdb/testsuite/gdb.python/py-breakpoint-create-fail.exp index 74983a899bdc..0b9d493ada29 100644 --- a/gdb/testsuite/gdb.python/py-breakpoint-create-fail.exp +++ b/gdb/testsuite/gdb.python/py-breakpoint-create-fail.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } clean_restart "${testfile}" if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.python/py-breakpoint.exp b/gdb/testsuite/gdb.python/py-breakpoint.exp index 4215f3ca1de0..692d55eb0a21 100644 --- a/gdb/testsuite/gdb.python/py-breakpoint.exp +++ b/gdb/testsuite/gdb.python/py-breakpoint.exp @@ -31,11 +31,11 @@ require allow_python_tests standard_testfile set options {debug c++} if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} ${options}] } { - return -1 + return } set past_throw_catch_line [gdb_get_line_number "Past throw-catch."] # Build a regexp string that can match against the repr of a gdb.Breakpoint diff --git a/gdb/testsuite/gdb.python/py-caller-is.exp b/gdb/testsuite/gdb.python/py-caller-is.exp index e512b97d5169..e195e42a8ca6 100644 --- a/gdb/testsuite/gdb.python/py-caller-is.exp +++ b/gdb/testsuite/gdb.python/py-caller-is.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-cmd-exception.exp b/gdb/testsuite/gdb.python/py-cmd-exception.exp index 51c35f32ac9e..789a8b15c3e0 100644 --- a/gdb/testsuite/gdb.python/py-cmd-exception.exp +++ b/gdb/testsuite/gdb.python/py-cmd-exception.exp @@ -22,11 +22,11 @@ load_lib gdb-python.exp require !use_gdb_stub allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_test_no_output "source $pyfile" "source the script" diff --git a/gdb/testsuite/gdb.python/py-cmd-prompt.exp b/gdb/testsuite/gdb.python/py-cmd-prompt.exp index a83c52ae1214..5b81d88bbe71 100644 --- a/gdb/testsuite/gdb.python/py-cmd-prompt.exp +++ b/gdb/testsuite/gdb.python/py-cmd-prompt.exp @@ -26,11 +26,11 @@ require !use_gdb_stub require allow_python_tests allow_gdbserver_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set bp_line [gdb_get_line_number "break-here"] gdb_breakpoint $bp_line diff --git a/gdb/testsuite/gdb.python/py-cmd.exp b/gdb/testsuite/gdb.python/py-cmd.exp index be5c955e29b1..766a594d2f49 100644 --- a/gdb/testsuite/gdb.python/py-cmd.exp +++ b/gdb/testsuite/gdb.python/py-cmd.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-commands-breakpoint.exp b/gdb/testsuite/gdb.python/py-commands-breakpoint.exp index ba2de2f68db7..2b3842c816f6 100644 --- a/gdb/testsuite/gdb.python/py-commands-breakpoint.exp +++ b/gdb/testsuite/gdb.python/py-commands-breakpoint.exp @@ -20,11 +20,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile .c .py if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if { ![runto_main] } { return 0 } diff --git a/gdb/testsuite/gdb.python/py-connection-removed.exp b/gdb/testsuite/gdb.python/py-connection-removed.exp index f2027043761b..abe3f78d73b1 100644 --- a/gdb/testsuite/gdb.python/py-connection-removed.exp +++ b/gdb/testsuite/gdb.python/py-connection-removed.exp @@ -28,11 +28,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile py-connection.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.python/py-connection.exp b/gdb/testsuite/gdb.python/py-connection.exp index 3045e9817312..e520e91368aa 100644 --- a/gdb/testsuite/gdb.python/py-connection.exp +++ b/gdb/testsuite/gdb.python/py-connection.exp @@ -23,11 +23,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-event-load.exp b/gdb/testsuite/gdb.python/py-event-load.exp index 8e4f8d2992bf..a0ba644a7f67 100644 --- a/gdb/testsuite/gdb.python/py-event-load.exp +++ b/gdb/testsuite/gdb.python/py-event-load.exp @@ -22,20 +22,20 @@ require allow_shlib_tests allow_python_tests standard_testfile .c if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug shlib_load}] != ""} { untested "failed to compile" - return -1 + return } set testfile2 py-events-shlib set srcfile2 ${testfile2}.c set binfile2 [standard_output_file ${testfile2}.so] if {[gdb_compile_shlib "${srcdir}/${subdir}/${srcfile2}" \ ${binfile2} {debug}] != ""} { untested "failed to compile shared library" - return -1 + return } set binfile2_dlopen [gdb_download_shlib $binfile2] clean_restart $testfile diff --git a/gdb/testsuite/gdb.python/py-events.exp b/gdb/testsuite/gdb.python/py-events.exp index 1e0513b997bf..1177dd54e482 100644 --- a/gdb/testsuite/gdb.python/py-events.exp +++ b/gdb/testsuite/gdb.python/py-events.exp @@ -26,11 +26,11 @@ standard_testfile set exec_opts [list debug shlib=$lib_sl] if { [gdb_compile_shlib $libsrc $lib_sl $lib_opts] != "" || [gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} { untested "failed to compile" - return -1 + return } # Start with a fresh gdb. clean_restart ${testfile} diff --git a/gdb/testsuite/gdb.python/py-evsignal.exp b/gdb/testsuite/gdb.python/py-evsignal.exp index e91f9af8f159..e9d4d2aa442f 100644 --- a/gdb/testsuite/gdb.python/py-evsignal.exp +++ b/gdb/testsuite/gdb.python/py-evsignal.exp @@ -14,21 +14,21 @@ # along with this program. If not, see . if {[gdb_protocol_is_remote]} { # RuntimeError: Could not find event thread kfail "python/12966" "Signal Thread 3" - return -1 + return } load_lib gdb-python.exp require allow_python_tests standard_testfile py-evthreads.c if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart $testfile set pyfile [gdb_remote_download host ${srcdir}/${subdir}/py-events.py] gdb_test_no_output "source ${pyfile}" "load python file" diff --git a/gdb/testsuite/gdb.python/py-evthreads.exp b/gdb/testsuite/gdb.python/py-evthreads.exp index 1ab5b58c03c2..09efc3adb3a4 100644 --- a/gdb/testsuite/gdb.python/py-evthreads.exp +++ b/gdb/testsuite/gdb.python/py-evthreads.exp @@ -18,11 +18,11 @@ require support_displaced_stepping allow_python_tests load_lib gdb-python.exp standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" clean_restart $testfile diff --git a/gdb/testsuite/gdb.python/py-exec-file.exp b/gdb/testsuite/gdb.python/py-exec-file.exp index 180de990f5ba..6a73efc406ad 100644 --- a/gdb/testsuite/gdb.python/py-exec-file.exp +++ b/gdb/testsuite/gdb.python/py-exec-file.exp @@ -24,16 +24,16 @@ set binfile1 [standard_output_file $testfile1] set testfile2 $testfile-b set binfile2 [standard_output_file $testfile2] if {[build_executable "failed to prepare first executable" \ $binfile1 $srcfile]} { - return -1 + return } if {[build_executable "failed to prepare second executable" \ $binfile2 $srcfile]} { - return -1 + return } set binfile1 [gdb_remote_download host $binfile1] set binfile2 [gdb_remote_download host $binfile2] diff --git a/gdb/testsuite/gdb.python/py-explore-cc.exp b/gdb/testsuite/gdb.python/py-explore-cc.exp index 7c04b227cfc0..772886b931f9 100644 --- a/gdb/testsuite/gdb.python/py-explore-cc.exp +++ b/gdb/testsuite/gdb.python/py-explore-cc.exp @@ -19,11 +19,11 @@ require allow_cplus_tests allow_python_tests standard_testfile py-explore.cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } set int_ptr_ref_desc "The value of 'int_ptr_ref' is of type 'int_ptr' which is a typedef of type 'int \\*'.*\'int_ptr_ref' is a pointer to a value of type 'int'.*" set b_desc "The value of 'b' is a struct/class of type 'B' with the following fields:.*\ diff --git a/gdb/testsuite/gdb.python/py-explore.exp b/gdb/testsuite/gdb.python/py-explore.exp index 78df5b9314fe..276148da8f10 100644 --- a/gdb/testsuite/gdb.python/py-explore.exp +++ b/gdb/testsuite/gdb.python/py-explore.exp @@ -16,11 +16,11 @@ standard_testfile require allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set SS "struct SimpleStruct" set SU "union SimpleUnion" set CS "struct ComplexStruct" diff --git a/gdb/testsuite/gdb.python/py-finish-breakpoint-deletion.exp b/gdb/testsuite/gdb.python/py-finish-breakpoint-deletion.exp index 52be47b68cf7..627c9d0b6ef5 100644 --- a/gdb/testsuite/gdb.python/py-finish-breakpoint-deletion.exp +++ b/gdb/testsuite/gdb.python/py-finish-breakpoint-deletion.exp @@ -20,11 +20,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.python/py-finish-breakpoint.exp b/gdb/testsuite/gdb.python/py-finish-breakpoint.exp index eb0790523e82..043416c724cc 100644 --- a/gdb/testsuite/gdb.python/py-finish-breakpoint.exp +++ b/gdb/testsuite/gdb.python/py-finish-breakpoint.exp @@ -29,11 +29,11 @@ standard_testfile set exec_opts [list debug shlib=$lib_sl] if { [gdb_compile_shlib $libsrc $lib_sl $lib_opts] != "" || [gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} { untested "failed to compile" - return -1 + return } # Start with a fresh gdb. clean_restart ${testfile} diff --git a/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp b/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp index 86a876650ee3..d782c577cfc1 100644 --- a/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp +++ b/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-frame-args.exp b/gdb/testsuite/gdb.python/py-frame-args.exp index ae688b2cc753..3129c90ae401 100644 --- a/gdb/testsuite/gdb.python/py-frame-args.exp +++ b/gdb/testsuite/gdb.python/py-frame-args.exp @@ -16,15 +16,15 @@ standard_testfile require allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-frame-inline.exp b/gdb/testsuite/gdb.python/py-frame-inline.exp index f007a2ca4aa1..a44136990c02 100644 --- a/gdb/testsuite/gdb.python/py-frame-inline.exp +++ b/gdb/testsuite/gdb.python/py-frame-inline.exp @@ -18,11 +18,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-frame.exp b/gdb/testsuite/gdb.python/py-frame.exp index dd0b948581c7..92a0ef3f7ebb 100644 --- a/gdb/testsuite/gdb.python/py-frame.exp +++ b/gdb/testsuite/gdb.python/py-frame.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # The following tests require execution. if {![runto_main]} { @@ -204,11 +204,11 @@ gdb_test "python print(gdb.selected_frame().read_register(bad_object))" \ "test Frame.read_register with bad_type object" # Compile again without debug info. gdb_exit if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-framefilter-addr.exp b/gdb/testsuite/gdb.python/py-framefilter-addr.exp index 087da1b690f9..3c0436ce1972 100644 --- a/gdb/testsuite/gdb.python/py-framefilter-addr.exp +++ b/gdb/testsuite/gdb.python/py-framefilter-addr.exp @@ -22,11 +22,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-framefilter-invalidarg.exp b/gdb/testsuite/gdb.python/py-framefilter-invalidarg.exp index 7cd5e2e66536..8a4bf001a694 100644 --- a/gdb/testsuite/gdb.python/py-framefilter-invalidarg.exp +++ b/gdb/testsuite/gdb.python/py-framefilter-invalidarg.exp @@ -22,11 +22,11 @@ standard_testfile amd64-py-framefilter-invalidarg.S require is_x86_64_m64_target # We cannot use prepare_for_testing as we have to set the safe-patch # to check objfile and progspace printers. if {[build_executable $testfile.exp $testfile $srcfile {}] == -1} { - return -1 + return } # Start with a fresh gdb. gdb_exit gdb_start diff --git a/gdb/testsuite/gdb.python/py-framefilter-mi.exp b/gdb/testsuite/gdb.python/py-framefilter-mi.exp index 7b091b8f3652..3b4cedba0918 100644 --- a/gdb/testsuite/gdb.python/py-framefilter-mi.exp +++ b/gdb/testsuite/gdb.python/py-framefilter-mi.exp @@ -23,20 +23,20 @@ set MIFLAGS "-i=mi2" standard_testfile py-framefilter-mi.c set pyfile py-framefilter.py if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug additional_flags=-DMI}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } if {[lsearch -exact [mi_get_features] python] < 0} { unsupported "python support is disabled" - return -1 + return } mi_runto_main set remote_python_file [gdb_remote_download host ${srcdir}/${subdir}/${pyfile}] diff --git a/gdb/testsuite/gdb.python/py-framefilter.exp b/gdb/testsuite/gdb.python/py-framefilter.exp index 292b72d66dc7..a993ac5d54fd 100644 --- a/gdb/testsuite/gdb.python/py-framefilter.exp +++ b/gdb/testsuite/gdb.python/py-framefilter.exp @@ -23,11 +23,11 @@ require allow_python_tests standard_testfile # We cannot use prepare_for_testing as we have to set the safe-patch # to check objfile and progspace printers. if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } # Start with a fresh gdb. gdb_exit gdb_start @@ -281,11 +281,11 @@ gdb_test "bt 1" "Quit" "bt 1 with KeyboardInterrupt" # Test with no debuginfo # We cannot use prepare_for_testing as we have to set the safe-patch # to check objfile and progspace printers. if {[build_executable $testfile.exp $testfile $srcfile {nodebug}] == -1} { - return -1 + return } # Start with a fresh gdb. gdb_exit gdb_start diff --git a/gdb/testsuite/gdb.python/py-inferior.exp b/gdb/testsuite/gdb.python/py-inferior.exp index 0c27da1a7a4e..8479427f726a 100644 --- a/gdb/testsuite/gdb.python/py-inferior.exp +++ b/gdb/testsuite/gdb.python/py-inferior.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [gdb_compile_pthreads ${srcdir}/${subdir}/${srcfile} ${binfile} executable {debug}] != "" } { - return -1 + return } # Start with a fresh gdb. save_vars { env(ASAN_OPTIONS) env(TSAN_OPTIONS) } { # The call to gdb.selected_inferior().read_memory (0, 0xffffffffffffffff) diff --git a/gdb/testsuite/gdb.python/py-infthread.exp b/gdb/testsuite/gdb.python/py-infthread.exp index 5859fff284cd..65ccc8f9a9e8 100644 --- a/gdb/testsuite/gdb.python/py-infthread.exp +++ b/gdb/testsuite/gdb.python/py-infthread.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } gdb_test_multiline "install new_thread event handler" \ "python" "" \ "seen_a_thread = False" "" \ diff --git a/gdb/testsuite/gdb.python/py-label-symbol-value.exp b/gdb/testsuite/gdb.python/py-label-symbol-value.exp index b4d598773989..c97ae72ec58d 100644 --- a/gdb/testsuite/gdb.python/py-label-symbol-value.exp +++ b/gdb/testsuite/gdb.python/py-label-symbol-value.exp @@ -19,11 +19,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-lazy-string.exp b/gdb/testsuite/gdb.python/py-lazy-string.exp index aabcc3be6e50..87d8eea46546 100644 --- a/gdb/testsuite/gdb.python/py-lazy-string.exp +++ b/gdb/testsuite/gdb.python/py-lazy-string.exp @@ -21,15 +21,15 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main ]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break here"] gdb_continue_to_breakpoint "break here" diff --git a/gdb/testsuite/gdb.python/py-linetable-empty.exp b/gdb/testsuite/gdb.python/py-linetable-empty.exp index 6113d35c1e37..651fe9b6dbf3 100644 --- a/gdb/testsuite/gdb.python/py-linetable-empty.exp +++ b/gdb/testsuite/gdb.python/py-linetable-empty.exp @@ -37,11 +37,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-linetable.exp b/gdb/testsuite/gdb.python/py-linetable.exp index 1e4402a089f2..5290c4a9beac 100644 --- a/gdb/testsuite/gdb.python/py-linetable.exp +++ b/gdb/testsuite/gdb.python/py-linetable.exp @@ -25,15 +25,15 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_py_test_silent_cmd "python lt = gdb.selected_frame().find_sal().symtab.linetable()" \ "get instruction" 0 diff --git a/gdb/testsuite/gdb.python/py-mi-cmd.exp b/gdb/testsuite/gdb.python/py-mi-cmd.exp index e13da6a31404..b66a73c331f5 100644 --- a/gdb/testsuite/gdb.python/py-mi-cmd.exp +++ b/gdb/testsuite/gdb.python/py-mi-cmd.exp @@ -23,11 +23,11 @@ if {[mi_gdb_start]} { return } if {[lsearch -exact [mi_get_features] python] < 0} { unsupported "python support is disabled" - return -1 + return } standard_testfile mi_gdb_test "set python print-stack full" \ diff --git a/gdb/testsuite/gdb.python/py-mi-events.exp b/gdb/testsuite/gdb.python/py-mi-events.exp index a6c724e0c4d5..a2314aed3221 100644 --- a/gdb/testsuite/gdb.python/py-mi-events.exp +++ b/gdb/testsuite/gdb.python/py-mi-events.exp @@ -24,11 +24,11 @@ standard_testfile set pyfile ${testfile}-gdb.py if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } set remote_python_file [gdb_remote_download host ${srcdir}/${subdir}/${pyfile}] if {[mi_clean_restart]} { diff --git a/gdb/testsuite/gdb.python/py-mi-notify.exp b/gdb/testsuite/gdb.python/py-mi-notify.exp index 220c5ca0babe..b08a667ae846 100644 --- a/gdb/testsuite/gdb.python/py-mi-notify.exp +++ b/gdb/testsuite/gdb.python/py-mi-notify.exp @@ -23,11 +23,11 @@ if {[mi_gdb_start]} { return } if {[lsearch -exact [mi_get_features] python] < 0} { unsupported "python support is disabled" - return -1 + return } standard_testfile mi_gdb_test "set python print-stack full" \ diff --git a/gdb/testsuite/gdb.python/py-mi-objfile.exp b/gdb/testsuite/gdb.python/py-mi-objfile.exp index 4c8846981eb9..99cd6b750a7c 100644 --- a/gdb/testsuite/gdb.python/py-mi-objfile.exp +++ b/gdb/testsuite/gdb.python/py-mi-objfile.exp @@ -23,11 +23,11 @@ require allow_python_tests standard_testfile set pyfile ${testfile}-gdb.py if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } # Make the -gdb.py script available to gdb, it is automagically loaded by gdb. # Care is taken to put it in the same directory as the binary so that # gdb will find it. diff --git a/gdb/testsuite/gdb.python/py-mi-var-info-path-expression.exp b/gdb/testsuite/gdb.python/py-mi-var-info-path-expression.exp index dd97de3be677..f300efe9caea 100644 --- a/gdb/testsuite/gdb.python/py-mi-var-info-path-expression.exp +++ b/gdb/testsuite/gdb.python/py-mi-var-info-path-expression.exp @@ -24,11 +24,11 @@ require allow_python_tests # Start here # standard_testfile if {[gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable {debug}] != "" } { - return -1 + return } mi_clean_restart $::testfile set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-mi.exp b/gdb/testsuite/gdb.python/py-mi.exp index 73b351e58ccb..51025653b620 100644 --- a/gdb/testsuite/gdb.python/py-mi.exp +++ b/gdb/testsuite/gdb.python/py-mi.exp @@ -21,20 +21,20 @@ set MIFLAGS "-i=mi2" standard_testfile py-prettyprint.c set pyfile py-prettyprint.py if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug additional_flags=-DMI}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } if {[lsearch -exact [mi_get_features] python] < 0} { unsupported "python support is disabled" - return -1 + return } mi_runto_main set remote_python_file [gdb_remote_download host ${srcdir}/${subdir}/${pyfile}] @@ -340,20 +340,20 @@ mi_gdb_test "-var-update c" \ # C++ MI tests gdb_exit if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}-cxx" \ executable {debug c++ additional_flags=-DMI}] != "" } { untested "failed to compile in C++ mode" - return -1 + return } if {[mi_clean_restart ${::testfile}-cxx]} { return } if {[lsearch -exact [mi_get_features] python] < 0} { unsupported "python support is disabled" - return -1 + return } with_test_prefix "varobj fake" { mi_runto_main mi_continue_to_line \ diff --git a/gdb/testsuite/gdb.python/py-missing-debug.exp b/gdb/testsuite/gdb.python/py-missing-debug.exp index 2aebebd453c7..256e3e955c77 100644 --- a/gdb/testsuite/gdb.python/py-missing-debug.exp +++ b/gdb/testsuite/gdb.python/py-missing-debug.exp @@ -19,18 +19,18 @@ require allow_python_tests standard_testfile if {[build_executable "failed to prepare" ${testfile} ${srcfile} \ {debug build-id}]} { - return -1 + return } # Remove debug information from BINFILE and place it into # BINFILE.debug. if {[gdb_gnu_strip_debug $binfile]} { unsupported "cannot produce separate debug info files" - return -1 + return } set remote_python_file \ [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-nested-maps.exp b/gdb/testsuite/gdb.python/py-nested-maps.exp index 7869c9138d52..f73829cb09a9 100644 --- a/gdb/testsuite/gdb.python/py-nested-maps.exp +++ b/gdb/testsuite/gdb.python/py-nested-maps.exp @@ -22,15 +22,15 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug}] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "run to testing point" ".*Break here.*" diff --git a/gdb/testsuite/gdb.python/py-objfile-script.exp b/gdb/testsuite/gdb.python/py-objfile-script.exp index 099a9986cfd7..c22163ae3565 100644 --- a/gdb/testsuite/gdb.python/py-objfile-script.exp +++ b/gdb/testsuite/gdb.python/py-objfile-script.exp @@ -19,11 +19,11 @@ standard_testfile require allow_python_tests if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } # Start with a fresh gdb. gdb_exit gdb_start diff --git a/gdb/testsuite/gdb.python/py-objfile.exp b/gdb/testsuite/gdb.python/py-objfile.exp index e823efbf3b15..0127b82936cb 100644 --- a/gdb/testsuite/gdb.python/py-objfile.exp +++ b/gdb/testsuite/gdb.python/py-objfile.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } @@ -114,11 +114,11 @@ gdb_test "python print(objfile.username)" "None" \ "objfile.username after objfile is unloaded" # Now build another copy of the testcase, this time without debug info. if { [prepare_for_testing "failed to prepare" ${testfile}2 ${srcfile} {nodebug ldflags=-Wl,--strip-debug}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-pending-frame-level.exp b/gdb/testsuite/gdb.python/py-pending-frame-level.exp index 8fc1d2653b15..204c7c36c54b 100644 --- a/gdb/testsuite/gdb.python/py-pending-frame-level.exp +++ b/gdb/testsuite/gdb.python/py-pending-frame-level.exp @@ -20,11 +20,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-pp-cast.exp b/gdb/testsuite/gdb.python/py-pp-cast.exp index 0184565872df..fe14a9a430f5 100644 --- a/gdb/testsuite/gdb.python/py-pp-cast.exp +++ b/gdb/testsuite/gdb.python/py-pp-cast.exp @@ -20,15 +20,15 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto break_function]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-pp-integral.exp b/gdb/testsuite/gdb.python/py-pp-integral.exp index 73dd86f4ea76..190af2b219d1 100644 --- a/gdb/testsuite/gdb.python/py-pp-integral.exp +++ b/gdb/testsuite/gdb.python/py-pp-integral.exp @@ -16,15 +16,15 @@ standard_testfile require allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto tick_tock]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-pp-maint.exp b/gdb/testsuite/gdb.python/py-pp-maint.exp index 7f3659450db6..8bb537c8d0e6 100644 --- a/gdb/testsuite/gdb.python/py-pp-maint.exp +++ b/gdb/testsuite/gdb.python/py-pp-maint.exp @@ -23,15 +23,15 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "b [gdb_get_line_number {break to inspect} ${testfile}.c ]" \ ".*Breakpoint.*" gdb_test "continue" ".*Breakpoint.*" diff --git a/gdb/testsuite/gdb.python/py-pp-re-notag.exp b/gdb/testsuite/gdb.python/py-pp-re-notag.exp index 73dd86f4ea76..190af2b219d1 100644 --- a/gdb/testsuite/gdb.python/py-pp-re-notag.exp +++ b/gdb/testsuite/gdb.python/py-pp-re-notag.exp @@ -16,15 +16,15 @@ standard_testfile require allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto tick_tock]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-pp-registration.exp b/gdb/testsuite/gdb.python/py-pp-registration.exp index ed65ed87a281..3d974b2120b6 100644 --- a/gdb/testsuite/gdb.python/py-pp-registration.exp +++ b/gdb/testsuite/gdb.python/py-pp-registration.exp @@ -21,18 +21,18 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] if {![runto_main ]} { - return -1 + return } proc prepare_test { } { global testfile remote_python_file diff --git a/gdb/testsuite/gdb.python/py-prettyprint-stub.exp b/gdb/testsuite/gdb.python/py-prettyprint-stub.exp index 49723980a0b1..491e8c369596 100644 --- a/gdb/testsuite/gdb.python/py-prettyprint-stub.exp +++ b/gdb/testsuite/gdb.python/py-prettyprint-stub.exp @@ -27,11 +27,11 @@ set srcfiles [list $srcfile $srcfile2] if { [build_executable_from_specs \ "failed to prepare" \ $testfile {c++} \ $srcfile {c++ debug} \ $srcfile2 {c++}] == -1 } { - return -1 + return } # Start with a fresh gdb. clean_restart $testfile diff --git a/gdb/testsuite/gdb.python/py-progspace-events.exp b/gdb/testsuite/gdb.python/py-progspace-events.exp index 143fa17126b8..c07a659910fa 100644 --- a/gdb/testsuite/gdb.python/py-progspace-events.exp +++ b/gdb/testsuite/gdb.python/py-progspace-events.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "preparing" $testfile $srcfile] == -1} { - return -1 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/py-progspace-events.py] gdb_test_no_output "source ${pyfile}" "load python file" diff --git a/gdb/testsuite/gdb.python/py-progspace.exp b/gdb/testsuite/gdb.python/py-progspace.exp index d11bb941acbf..b3fc203c4b98 100644 --- a/gdb/testsuite/gdb.python/py-progspace.exp +++ b/gdb/testsuite/gdb.python/py-progspace.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } clean_restart gdb_test "python print (gdb.current_progspace().filename)" "None" \ diff --git a/gdb/testsuite/gdb.python/py-prompt.exp b/gdb/testsuite/gdb.python/py-prompt.exp index 60186f71db69..cc149ae62303 100644 --- a/gdb/testsuite/gdb.python/py-prompt.exp +++ b/gdb/testsuite/gdb.python/py-prompt.exp @@ -22,11 +22,11 @@ load_lib gdb-python.exp load_lib prompt.exp require allow_python_tests if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } save_vars { INTERNAL_GDBFLAGS GDBFLAGS } { set INTERNAL_GDBFLAGS [string map {"-q" ""} $INTERNAL_GDBFLAGS] diff --git a/gdb/testsuite/gdb.python/py-read-memory-leak.exp b/gdb/testsuite/gdb.python/py-read-memory-leak.exp index e7fcbf79b37d..58343126e67c 100644 --- a/gdb/testsuite/gdb.python/py-read-memory-leak.exp +++ b/gdb/testsuite/gdb.python/py-read-memory-leak.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-record-btrace-threads.exp b/gdb/testsuite/gdb.python/py-record-btrace-threads.exp index 0b3115a5a6dd..995e733a4aab 100644 --- a/gdb/testsuite/gdb.python/py-record-btrace-threads.exp +++ b/gdb/testsuite/gdb.python/py-record-btrace-threads.exp @@ -21,16 +21,16 @@ require allow_btrace_tests allow_python_tests standard_testfile if { [gdb_compile_pthreads "$srcdir/$subdir/$srcfile" "$binfile" executable {debug} ] != "" } { untested "failed to prepare" - return -1 + return } clean_restart $testfile if { ![runto_main] } { - return -1 + return } # set up breakpoints gdb_breakpoint $srcfile:[gdb_get_line_number "bp1" $srcfile] gdb_breakpoint $srcfile:[gdb_get_line_number "bp2" $srcfile] diff --git a/gdb/testsuite/gdb.python/py-record-btrace.exp b/gdb/testsuite/gdb.python/py-record-btrace.exp index ade569c480c7..4e324e71fc09 100644 --- a/gdb/testsuite/gdb.python/py-record-btrace.exp +++ b/gdb/testsuite/gdb.python/py-record-btrace.exp @@ -24,11 +24,11 @@ load_lib gdb-python.exp standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { return -1 } if {![runto_main]} { - return -1 + return } with_test_prefix "no or double record" { gdb_test "python print(gdb.current_recording())" "None" diff --git a/gdb/testsuite/gdb.python/py-record-full.exp b/gdb/testsuite/gdb.python/py-record-full.exp index 125cecebfd25..95640770e9a5 100644 --- a/gdb/testsuite/gdb.python/py-record-full.exp +++ b/gdb/testsuite/gdb.python/py-record-full.exp @@ -24,11 +24,11 @@ load_lib gdb-python.exp standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { return -1 } if {![runto_main]} { - return -1 + return } with_test_prefix "no or double record" { gdb_test "python print(gdb.current_recording())" "None" diff --git a/gdb/testsuite/gdb.python/py-recurse-unwind.exp b/gdb/testsuite/gdb.python/py-recurse-unwind.exp index fbb538f39064..4df47a6e8b4b 100644 --- a/gdb/testsuite/gdb.python/py-recurse-unwind.exp +++ b/gdb/testsuite/gdb.python/py-recurse-unwind.exp @@ -27,11 +27,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_test "source ${pyfile}" "Python script imported" \ diff --git a/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp b/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp index 2b2fe112d9e5..576fd5a85d3d 100644 --- a/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp +++ b/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp @@ -21,11 +21,11 @@ require allow_cplus_tests allow_python_tests standard_testfile .cc if {[prepare_for_testing $testfile.exp $testfile $srcfile \ {debug c++ additional_flags="-std=c++11"}]} { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-send-packet.exp b/gdb/testsuite/gdb.python/py-send-packet.exp index b0ca70e61a65..4464c1c5123b 100644 --- a/gdb/testsuite/gdb.python/py-send-packet.exp +++ b/gdb/testsuite/gdb.python/py-send-packet.exp @@ -25,11 +25,11 @@ load_lib gdbserver-support.exp standard_testfile require allow_gdbserver_tests allow_python_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. gdb_test "disconnect" ".*" diff --git a/gdb/testsuite/gdb.python/py-shared.exp b/gdb/testsuite/gdb.python/py-shared.exp index 6b8f0f0c1bde..0eef359d0b87 100644 --- a/gdb/testsuite/gdb.python/py-shared.exp +++ b/gdb/testsuite/gdb.python/py-shared.exp @@ -25,18 +25,18 @@ set libfile "py-shared-sl" set libsrc ${libfile}.c set library [standard_output_file ${libfile}.sl] if { [gdb_compile_shlib ${srcdir}/${subdir}/${libsrc} ${library} "debug"] != "" } { untested "failed to compile shared library" - return -1 + return } set exec_opts [list debug shlib=${library}] if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $exec_opts] != "" } { untested "failed to compile" - return -1 + return } # Start with a fresh gdb. clean_restart $testfile gdb_load_shlib ${library} diff --git a/gdb/testsuite/gdb.python/py-strfns.exp b/gdb/testsuite/gdb.python/py-strfns.exp index 79de2c4d8357..539ba984db02 100644 --- a/gdb/testsuite/gdb.python/py-strfns.exp +++ b/gdb/testsuite/gdb.python/py-strfns.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-sym-artificial.exp b/gdb/testsuite/gdb.python/py-sym-artificial.exp index e0592bc068b6..1ea2ea4a13fb 100644 --- a/gdb/testsuite/gdb.python/py-sym-artificial.exp +++ b/gdb/testsuite/gdb.python/py-sym-artificial.exp @@ -47,15 +47,15 @@ Dwarf::assemble $asm_file { } } if {[prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_py_test_silent_cmd "python v = gdb.lookup_symbol('the_variable')" \ "get variable" 1 gdb_test "python print(v\[0\].is_artificial)" True \ diff --git a/gdb/testsuite/gdb.python/py-symbol.exp b/gdb/testsuite/gdb.python/py-symbol.exp index 7d172d792e9f..90e724ca0313 100644 --- a/gdb/testsuite/gdb.python/py-symbol.exp +++ b/gdb/testsuite/gdb.python/py-symbol.exp @@ -23,11 +23,11 @@ require allow_python_tests standard_testfile py-symbol.c py-symbol-2.c py-symbol-3.c set opts { debug additional_flags=-DUSE_TWO_FILES } if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2 $srcfile3] $opts]} { - return -1 + return } set readnow_p [readnow] # Check that we find all static symbols before the inferior has @@ -194,11 +194,11 @@ gdb_test "python print (t\[0\].symtab)" "${py_symbol_c}" "get symtab" lappend opts c++ set testfile $testfile-cxx set binfile [standard_output_file $testfile] if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2] $opts] } { - return -1 + return } gdb_test "python print (gdb.lookup_global_symbol ('(anonymous namespace)::anon') is None)" \ "True" "anon is None" gdb_test "python print (gdb.lookup_static_symbol ('(anonymous namespace)::anon').value ())" \ diff --git a/gdb/testsuite/gdb.python/py-symtab.exp b/gdb/testsuite/gdb.python/py-symtab.exp index 7a426faf3a57..786bdc75fc4d 100644 --- a/gdb/testsuite/gdb.python/py-symtab.exp +++ b/gdb/testsuite/gdb.python/py-symtab.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile py-symbol.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-sync-interp.exp b/gdb/testsuite/gdb.python/py-sync-interp.exp index 4323ee0443e5..5fb67b1eb5b4 100644 --- a/gdb/testsuite/gdb.python/py-sync-interp.exp +++ b/gdb/testsuite/gdb.python/py-sync-interp.exp @@ -23,11 +23,11 @@ standard_testfile require can_spawn_for_attach allow_python_tests load_lib gdb-python.exp if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.python/py-template.exp b/gdb/testsuite/gdb.python/py-template.exp index 1bf3604e98fa..9099e7e32dc0 100644 --- a/gdb/testsuite/gdb.python/py-template.exp +++ b/gdb/testsuite/gdb.python/py-template.exp @@ -20,11 +20,11 @@ require allow_cplus_tests allow_python_tests standard_testfile .cc if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ {debug c++}] != "" } { untested "failed to compile" - return -1 + return } clean_restart proc test_template_arg {exefile type} { diff --git a/gdb/testsuite/gdb.python/py-thread-exited.exp b/gdb/testsuite/gdb.python/py-thread-exited.exp index 862adeb4587d..908af96d9d5b 100644 --- a/gdb/testsuite/gdb.python/py-thread-exited.exp +++ b/gdb/testsuite/gdb.python/py-thread-exited.exp @@ -18,11 +18,11 @@ require allow_python_tests load_lib gdb-python.exp standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { clean_restart $testfile } @@ -31,11 +31,11 @@ set pyfile [gdb_remote_download host ${srcdir}/${subdir}/py-thread-exited.py] gdb_test_no_output "source ${pyfile}" "load python file" gdb_test "test-events" "Event testers registered." if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "In thread" ${testfile}.c] gdb_breakpoint [gdb_get_line_number "Done" ${testfile}.c] diff --git a/gdb/testsuite/gdb.python/py-thrhandle.exp b/gdb/testsuite/gdb.python/py-thrhandle.exp index 2aeb7777f0d3..3c9effc8d6be 100644 --- a/gdb/testsuite/gdb.python/py-thrhandle.exp +++ b/gdb/testsuite/gdb.python/py-thrhandle.exp @@ -24,11 +24,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} runto_main diff --git a/gdb/testsuite/gdb.python/py-typeprint.exp b/gdb/testsuite/gdb.python/py-typeprint.exp index f8ccdbf49544..ab53f26d8172 100644 --- a/gdb/testsuite/gdb.python/py-typeprint.exp +++ b/gdb/testsuite/gdb.python/py-typeprint.exp @@ -19,11 +19,11 @@ load_lib gdb-python.exp load_lib cp-support.exp standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-unwind-inline.exp b/gdb/testsuite/gdb.python/py-unwind-inline.exp index 0f63e4310f71..ef9b00eccc8b 100644 --- a/gdb/testsuite/gdb.python/py-unwind-inline.exp +++ b/gdb/testsuite/gdb.python/py-unwind-inline.exp @@ -22,11 +22,11 @@ require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ debug] } { - return -1 + return } # The following tests require execution. if {![runto_main]} { return 0 diff --git a/gdb/testsuite/gdb.python/py-unwind-maint.exp b/gdb/testsuite/gdb.python/py-unwind-maint.exp index 10d1f722db2d..e2ec925a0808 100644 --- a/gdb/testsuite/gdb.python/py-unwind-maint.exp +++ b/gdb/testsuite/gdb.python/py-unwind-maint.exp @@ -21,17 +21,17 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] if {![runto_main]} { - return -1 + return } gdb_test "source ${pyfile}" "Python script imported" \ "import python scripts" diff --git a/gdb/testsuite/gdb.python/py-unwind-user-regs.exp b/gdb/testsuite/gdb.python/py-unwind-user-regs.exp index ac81d98c5826..c594bf74ceef 100644 --- a/gdb/testsuite/gdb.python/py-unwind-user-regs.exp +++ b/gdb/testsuite/gdb.python/py-unwind-user-regs.exp @@ -41,11 +41,11 @@ load_lib gdb-python.exp require allow_python_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.python/py-unwind.exp b/gdb/testsuite/gdb.python/py-unwind.exp index 784d9dfcb64d..058caaf1efc7 100644 --- a/gdb/testsuite/gdb.python/py-unwind.exp +++ b/gdb/testsuite/gdb.python/py-unwind.exp @@ -26,11 +26,11 @@ standard_testfile # assumptions this test has about its layout. set flags "additional_flags=-fno-stack-protector" if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} "debug $flags"] } { - return -1 + return } # This test runs on a specific platform. require is_x86_64_m64_target diff --git a/gdb/testsuite/gdb.python/py-value-cc.exp b/gdb/testsuite/gdb.python/py-value-cc.exp index 70135bd7ec76..1d65d617e30d 100644 --- a/gdb/testsuite/gdb.python/py-value-cc.exp +++ b/gdb/testsuite/gdb.python/py-value-cc.exp @@ -19,11 +19,11 @@ require allow_cplus_tests allow_python_tests standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/py-value.exp b/gdb/testsuite/gdb.python/py-value.exp index a384f4139dd4..3746a6cbc0bc 100644 --- a/gdb/testsuite/gdb.python/py-value.exp +++ b/gdb/testsuite/gdb.python/py-value.exp @@ -798,11 +798,11 @@ proc test_unavailable {} { } } # Build C version of executable. C++ is built later. if { [build_inferior "${binfile}" "c"] < 0 } { - return -1 + return } # Start with a fresh gdb. clean_restart ${::testfile} diff --git a/gdb/testsuite/gdb.python/py-varobj.exp b/gdb/testsuite/gdb.python/py-varobj.exp index 2b1de110e3b9..e8428e3d0745 100644 --- a/gdb/testsuite/gdb.python/py-varobj.exp +++ b/gdb/testsuite/gdb.python/py-varobj.exp @@ -20,11 +20,11 @@ set MIFLAGS "-i=mi" require allow_python_tests standard_testfile if {[gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable {debug}] != ""} { - return -1 + return } mi_clean_restart $::testfile set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-watchpoint.exp b/gdb/testsuite/gdb.python/py-watchpoint.exp index 50ffaab6594b..2fc366228a14 100644 --- a/gdb/testsuite/gdb.python/py-watchpoint.exp +++ b/gdb/testsuite/gdb.python/py-watchpoint.exp @@ -18,11 +18,11 @@ load_lib gdb-python.exp standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } require allow_python_tests if {![runto_main]} { diff --git a/gdb/testsuite/gdb.python/py-xmethods.exp b/gdb/testsuite/gdb.python/py-xmethods.exp index 087e93e3a6f4..52f0a7597093 100644 --- a/gdb/testsuite/gdb.python/py-xmethods.exp +++ b/gdb/testsuite/gdb.python/py-xmethods.exp @@ -21,11 +21,11 @@ load_lib gdb-python.exp require allow_cplus_tests allow_python_tests standard_testfile py-xmethods.cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } if {![runto_main]} { return -1 } diff --git a/gdb/testsuite/gdb.python/python.exp b/gdb/testsuite/gdb.python/python.exp index 07c51e7ac3fa..f2f32019e4c2 100644 --- a/gdb/testsuite/gdb.python/python.exp +++ b/gdb/testsuite/gdb.python/python.exp @@ -20,11 +20,11 @@ load_lib gdb-python.exp standard_testfile python.c python-1.c if {[build_executable $testfile.exp $testfile \ [list $srcfile $srcfile2] debug] == -1} { - return -1 + return } clean_restart set remote_source2_py [gdb_remote_download host \ diff --git a/gdb/testsuite/gdb.python/tui-window-disabled.exp b/gdb/testsuite/gdb.python/tui-window-disabled.exp index b90f95c05ac0..35e94b278215 100644 --- a/gdb/testsuite/gdb.python/tui-window-disabled.exp +++ b/gdb/testsuite/gdb.python/tui-window-disabled.exp @@ -30,11 +30,11 @@ standard_testfile set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/attributes.h if {[build_executable "failed to prepare" ${testfile} ${srcfile} $flags] == -1} { - return -1 + return } clean_restart # Copy the Python script to where the tests are being run. diff --git a/gdb/testsuite/gdb.python/tui-window.exp b/gdb/testsuite/gdb.python/tui-window.exp index 01f290be6aa0..f813908dba49 100644 --- a/gdb/testsuite/gdb.python/tui-window.exp +++ b/gdb/testsuite/gdb.python/tui-window.exp @@ -21,11 +21,11 @@ tuiterm_env # This test doesn't care about the inferior. standard_testfile py-arch.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } clean_restart Term::clean_restart 24 80 $testfile From patchwork Wed Apr 29 23:04:14 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134208 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id BB6C14358A4D for ; Wed, 29 Apr 2026 23:07:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BB6C14358A4D Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=Qp/rDCkN X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2e.google.com (mail-vk1-xa2e.google.com [IPv6:2607:f8b0:4864:20::a2e]) by sourceware.org (Postfix) with ESMTPS id BAD824BB58A5 for ; Wed, 29 Apr 2026 23:06:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org BAD824BB58A5 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org BAD824BB58A5 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2e ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503960; cv=none; b=ZfjI2kW0pdtvHBLx7gV5JMnS3TQw0mw0bNUnVrcmMJcV6nV57GJEqEpFGcMtUEahOYXQGb+UrTFC6hX+tCxC0CBwCyYGFq5e5tI3x6hfhx6X6rNumkmvreJcn3f7/fk1B28vJnfQzm9PDnJcbrIVJO69j0CSTnQSr8y03xX/a+w= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503960; c=relaxed/simple; bh=WZ+kbQPyrZt6U+WDs6yqmqn6SfoQyHUhP1FqU0BZb84=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=eDaD2278iaovf/K11tuCj3gQOM7bmrCXnNoHC3eoa6S00RqDfi7LdPRqV0AQGFqLe+Ipmvhyym3sQyj4Py9gQx3w9XyNnbZgyE5seND1cOVnfdYV4twBhC7ouo3kWRr1kxqJoaGx5WF6pzhiiE8Kk8LrV2/NTB2SbE3w+/ktqTY= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BAD824BB58A5 Received: by mail-vk1-xa2e.google.com with SMTP id 71dfb90a1353d-56a86f0a23bso301972e0c.0 for ; Wed, 29 Apr 2026 16:06:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503960; x=1778108760; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=bMOJc5xpIWk1OrctRXc8P/Blf0dimOKgDcQMKSmFtE0=; b=Qp/rDCkNc8vxXlMCU9XnOgyVKHozShYDjSXkEL4z497f3I28QxUeVmLPeWPKpEo0YB S1Q3Nn/ll+/GGYNowAlaXIjEAfcthj+J3IqpipOPVX6Kae2TR0FTLWjMT3f184QvdOZZ v8cHySKerMFBInp9ufDdzFZ8UGSmVn1Za8Km1yVRwjHlHsiwTyxpwU5wFHUXTw3fnhcP gDaO2OhD6cEleqgH+q3t6kgH3w2oZtZVXl39Peqo7ir1m+7/Kxbmqtag4taIkBfVivMb GwR3b+quP4zmzpiUQP40+CRb27qBqIECkVN4cg/T7rxlZzSb13sw+fzXGJKokWaY4TE2 jRmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503960; x=1778108760; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=bMOJc5xpIWk1OrctRXc8P/Blf0dimOKgDcQMKSmFtE0=; b=l9Ar447Ic7BUYjQiccYNUXDfsTtfR7wuLwd1We6fbDuxm8hKHu23pZr/nTTLUk4kBQ b2LOOAgpQLW4sHzArwFe/py24DBJy+BBgyBeS1N7hZbbMocsTHgjX3DtYMU62fh1lQNC tNHRphzzl/Bx5ayjftnriSgxPtzmfR2flmZ82MZJ1BnWpGPkgEdJ5pNRotRaFaCfRdUP EOARw0Q89Trs9No8z/vgS9wAnZgBxqd3/zi3ubcoUhlnNYu8nn/scHrThKKQ80KPyIJo kPb5hwCdKBz2XrPtMwuBCFSAUVDv3+L43UXHuWCbzWugm4/2t3obF9Khlx8mii/Qu/Jd Z/OQ== X-Gm-Message-State: AOJu0YyB8tqHsWUA8ACfC88rxADl0wsbQalEW91u0CXSzVZDyzELXoPg CWpT8bop1r5D6K0l0HiC7wCjIEogEQ2bxS2aicaciXtQOu0yA9t5BaQgsfiCChUxtzhxWS8yMgv wX0cY X-Gm-Gg: AeBDietIKH1OFZtR1csO2Iqf7Xj+1aZ+I9Bq1vhsp360cF0xBXL8kCdTqePp+rXMZAB Yt/BHyzDNQalSuOPBEsMpj9gugw2vmRHwBEJLdA3rbC2biW784D4/4FT42iCnGQvkOIe0YnTTEi QhoeA0EG2HgUGsUTqoiRdjBkxPFTKfsVk8YuY9VakGFDdDI7F7OXSB6PqiOsSodLvE23qkjLAwi j26yTQe1Pvpw2Y00klkjbw3Ld00kq5/zyKsHN8U8glep/lNVGFUXu37o0i5N0j4r+mGfLJGBFn1 Y83d1MLUp9su22fSyIDTBKTtiNd+/gLGqsWYixoajletQANMVNXSZcbeibNf5KnW/c/botsE1W4 Mx3i9eoxlwTmeom+3+byckN1+jWNaz+Zi2YZUrp2gtXpQw/n+khd5zkmMCqR2F1GtC2De5FowkI N/O1i4eVGOn6wGdMBobmSfHguo2X5jESTGW7xC4eheTFbo X-Received: by 2002:a05:6122:208b:b0:56e:f262:9109 with SMTP id 71dfb90a1353d-573c953836cmr108031e0c.2.1777503959976; Wed, 29 Apr 2026 16:05:59 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb75c4030sm1925625241.4.2026.04.29.16.05.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:05:59 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 23/37] GDB: testsuite: Python: Don't return 0 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:14 -0300 Message-ID: <20260429230432.60487-24-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_STOCKGEN, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.python. A couple of false positives weren't included. --- gdb/testsuite/gdb.python/lib-types.exp | 2 +- gdb/testsuite/gdb.python/py-as-string.exp | 2 +- gdb/testsuite/gdb.python/py-block.exp | 2 +- gdb/testsuite/gdb.python/py-caller-is.exp | 2 +- gdb/testsuite/gdb.python/py-cmd.exp | 2 +- gdb/testsuite/gdb.python/py-commands-breakpoint.exp | 2 +- gdb/testsuite/gdb.python/py-connection.exp | 2 +- gdb/testsuite/gdb.python/py-error.exp | 2 +- gdb/testsuite/gdb.python/py-finish-breakpoint2.exp | 2 +- gdb/testsuite/gdb.python/py-frame-inline.exp | 2 +- gdb/testsuite/gdb.python/py-frame.exp | 4 ++-- gdb/testsuite/gdb.python/py-inferior.exp | 2 +- gdb/testsuite/gdb.python/py-infthread.exp | 2 +- gdb/testsuite/gdb.python/py-missing-objfile.exp | 2 +- gdb/testsuite/gdb.python/py-objfile.exp | 4 ++-- gdb/testsuite/gdb.python/py-pending-frame-level.exp | 2 +- gdb/testsuite/gdb.python/py-rbreak.exp | 2 +- gdb/testsuite/gdb.python/py-recurse-unwind.exp | 2 +- gdb/testsuite/gdb.python/py-shared.exp | 2 +- gdb/testsuite/gdb.python/py-strfns.exp | 2 +- gdb/testsuite/gdb.python/py-symbol.exp | 6 +++--- gdb/testsuite/gdb.python/py-symtab.exp | 2 +- gdb/testsuite/gdb.python/py-unwind-inline.exp | 2 +- gdb/testsuite/gdb.python/py-unwind-user-regs.exp | 2 +- gdb/testsuite/gdb.python/py-unwind.exp | 2 +- gdb/testsuite/gdb.python/py-value.exp | 2 +- gdb/testsuite/gdb.python/python.exp | 6 +++--- 27 files changed, 33 insertions(+), 33 deletions(-) diff --git a/gdb/testsuite/gdb.python/lib-types.exp b/gdb/testsuite/gdb.python/lib-types.exp index aa281c6443d5..d2e7d391a779 100644 --- a/gdb/testsuite/gdb.python/lib-types.exp +++ b/gdb/testsuite/gdb.python/lib-types.exp @@ -25,11 +25,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { return } if {![runto_main]} { - return 0 + return } gdb_test_no_output "python import gdb.types" # test get_basic_type const stripping diff --git a/gdb/testsuite/gdb.python/py-as-string.exp b/gdb/testsuite/gdb.python/py-as-string.exp index 3dc858db1ada..41cefbe0411f 100644 --- a/gdb/testsuite/gdb.python/py-as-string.exp +++ b/gdb/testsuite/gdb.python/py-as-string.exp @@ -25,11 +25,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } proc test_as_string { } { gdb_test "p \$_as_string(2)" "\"2\"" gdb_test "p \$_as_string(enum_valid)" "\"ENUM_VALUE_B\"" diff --git a/gdb/testsuite/gdb.python/py-block.exp b/gdb/testsuite/gdb.python/py-block.exp index b0123c4d3b57..30983ac35f25 100644 --- a/gdb/testsuite/gdb.python/py-block.exp +++ b/gdb/testsuite/gdb.python/py-block.exp @@ -25,11 +25,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } global hex decimal gdb_breakpoint [gdb_get_line_number "Block break here."] gdb_continue_to_breakpoint "Block break here." diff --git a/gdb/testsuite/gdb.python/py-caller-is.exp b/gdb/testsuite/gdb.python/py-caller-is.exp index e195e42a8ca6..d9b826cb6a23 100644 --- a/gdb/testsuite/gdb.python/py-caller-is.exp +++ b/gdb/testsuite/gdb.python/py-caller-is.exp @@ -25,11 +25,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } gdb_breakpoint "bottom_func" gdb_continue_to_breakpoint "bottom_func" diff --git a/gdb/testsuite/gdb.python/py-cmd.exp b/gdb/testsuite/gdb.python/py-cmd.exp index 766a594d2f49..0bda3cdc934c 100644 --- a/gdb/testsuite/gdb.python/py-cmd.exp +++ b/gdb/testsuite/gdb.python/py-cmd.exp @@ -25,11 +25,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } # Test a simple command. gdb_test_multiline "input simple command" \ diff --git a/gdb/testsuite/gdb.python/py-commands-breakpoint.exp b/gdb/testsuite/gdb.python/py-commands-breakpoint.exp index 2b3842c816f6..1afb41c80ea2 100644 --- a/gdb/testsuite/gdb.python/py-commands-breakpoint.exp +++ b/gdb/testsuite/gdb.python/py-commands-breakpoint.exp @@ -24,11 +24,11 @@ standard_testfile .c .py if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { return } if { ![runto_main] } { - return 0 + return } set host_python_file \ [gdb_remote_download host $srcdir/$subdir/$srcfile2] diff --git a/gdb/testsuite/gdb.python/py-connection.exp b/gdb/testsuite/gdb.python/py-connection.exp index e520e91368aa..7f3b46eff797 100644 --- a/gdb/testsuite/gdb.python/py-connection.exp +++ b/gdb/testsuite/gdb.python/py-connection.exp @@ -27,11 +27,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } if { [target_info exists gdb_protocol] } { set connection_type "RemoteTargetConnection" } else { diff --git a/gdb/testsuite/gdb.python/py-error.exp b/gdb/testsuite/gdb.python/py-error.exp index 583e63571a4a..3285746a47ca 100644 --- a/gdb/testsuite/gdb.python/py-error.exp +++ b/gdb/testsuite/gdb.python/py-error.exp @@ -42,11 +42,11 @@ gdb_test_multiple $test $test { set test2 "" } } if {$test2 == ""} { - return 0 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp b/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp index d782c577cfc1..9fa3faa7b9f5 100644 --- a/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp +++ b/gdb/testsuite/gdb.python/py-finish-breakpoint2.exp @@ -25,11 +25,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { return } if {![runto_main]} { - return 0 + return } set pyfile [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/py-frame-inline.exp b/gdb/testsuite/gdb.python/py-frame-inline.exp index a44136990c02..c90aed09e677 100644 --- a/gdb/testsuite/gdb.python/py-frame-inline.exp +++ b/gdb/testsuite/gdb.python/py-frame-inline.exp @@ -22,11 +22,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "Block break here." diff --git a/gdb/testsuite/gdb.python/py-frame.exp b/gdb/testsuite/gdb.python/py-frame.exp index 92a0ef3f7ebb..ca350cf03c2d 100644 --- a/gdb/testsuite/gdb.python/py-frame.exp +++ b/gdb/testsuite/gdb.python/py-frame.exp @@ -27,11 +27,11 @@ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { } # The following tests require execution. if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "Block break here."] gdb_continue_to_breakpoint "Block break here." gdb_py_test_silent_cmd "python bf1 = gdb.selected_frame ()" "get frame" 0 @@ -208,11 +208,11 @@ gdb_exit if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {}] } { return } if {![runto_main]} { - return 0 + return } # Test if Frame.static_link works for a frame without debug info. gdb_test "python print(gdb.selected_frame().static_link())" "None" \ "test Frame.static_link for a frame without debug info" diff --git a/gdb/testsuite/gdb.python/py-inferior.exp b/gdb/testsuite/gdb.python/py-inferior.exp index 8479427f726a..f69ad8fc0d8d 100644 --- a/gdb/testsuite/gdb.python/py-inferior.exp +++ b/gdb/testsuite/gdb.python/py-inferior.exp @@ -60,11 +60,11 @@ gdb_test "python \ "read memory without execution" # The following tests require execution. if {![runto_main]} { - return 0 + return } # The most recently added inferior. set most_recent_inf 1 diff --git a/gdb/testsuite/gdb.python/py-infthread.exp b/gdb/testsuite/gdb.python/py-infthread.exp index 65ccc8f9a9e8..93022e8ade3b 100644 --- a/gdb/testsuite/gdb.python/py-infthread.exp +++ b/gdb/testsuite/gdb.python/py-infthread.exp @@ -38,11 +38,11 @@ gdb_test_multiline "install new_thread event handler" \ "end" "" # The following tests require execution. if {![runto_main]} { - return 0 + return } gdb_test "python print(seen_a_thread)" "True" # Test basic gdb.Inferior attributes and methods. diff --git a/gdb/testsuite/gdb.python/py-missing-objfile.exp b/gdb/testsuite/gdb.python/py-missing-objfile.exp index e5e086130b00..907bdec76f4b 100644 --- a/gdb/testsuite/gdb.python/py-missing-objfile.exp +++ b/gdb/testsuite/gdb.python/py-missing-objfile.exp @@ -54,11 +54,11 @@ set remote_python_file \ # Generate a core file. set corefile [core_find $binfile {}] if {$corefile == ""} { unsupported "core file not generated" - return 0 + return } # Create a directory named DIRNAME for use as the # debug-file-directory. Populate the directory with links (based on # the build-ids) to each file in the list FILES. diff --git a/gdb/testsuite/gdb.python/py-objfile.exp b/gdb/testsuite/gdb.python/py-objfile.exp index 0127b82936cb..64c626029300 100644 --- a/gdb/testsuite/gdb.python/py-objfile.exp +++ b/gdb/testsuite/gdb.python/py-objfile.exp @@ -25,11 +25,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } set python_error_text "Error occurred in Python.*" gdb_py_test_silent_cmd "python sym = gdb.lookup_symbol(\"some_var\")" \ @@ -118,11 +118,11 @@ gdb_test "python print(objfile.username)" "None" \ if { [prepare_for_testing "failed to prepare" ${testfile}2 ${srcfile} {nodebug ldflags=-Wl,--strip-debug}] } { return } if {![runto_main]} { - return 0 + return } gdb_py_test_silent_cmd "python objfile = gdb.objfiles()\[0\]" \ "Get no-debug objfile file" 1 diff --git a/gdb/testsuite/gdb.python/py-pending-frame-level.exp b/gdb/testsuite/gdb.python/py-pending-frame-level.exp index 204c7c36c54b..0e10b8065d16 100644 --- a/gdb/testsuite/gdb.python/py-pending-frame-level.exp +++ b/gdb/testsuite/gdb.python/py-pending-frame-level.exp @@ -24,11 +24,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_breakpoint [gdb_get_line_number "Break here"] diff --git a/gdb/testsuite/gdb.python/py-rbreak.exp b/gdb/testsuite/gdb.python/py-rbreak.exp index eead513caeb2..ba02758ae798 100644 --- a/gdb/testsuite/gdb.python/py-rbreak.exp +++ b/gdb/testsuite/gdb.python/py-rbreak.exp @@ -25,11 +25,11 @@ standard_testfile py-rbreak.c py-rbreak-func2.c if {[prepare_for_testing "failed to prepare" ${testfile} [list $srcfile $srcfile2]] } { return 1 } if {![runto_main]} { - return 0 + return } gdb_test_no_output "nosharedlibrary" gdb_py_test_silent_cmd "py sl = gdb.rbreak(\"\",minsyms=False)" \ "get all function breakpoints" 0 diff --git a/gdb/testsuite/gdb.python/py-recurse-unwind.exp b/gdb/testsuite/gdb.python/py-recurse-unwind.exp index 4df47a6e8b4b..25cefc9b87ed 100644 --- a/gdb/testsuite/gdb.python/py-recurse-unwind.exp +++ b/gdb/testsuite/gdb.python/py-recurse-unwind.exp @@ -38,11 +38,11 @@ gdb_test "source ${pyfile}" "Python script imported" \ "import python scripts" # The following tests require execution. if {![runto_main]} { - return 0 + return } proc cont_and_backtrace { tst } { diff --git a/gdb/testsuite/gdb.python/py-shared.exp b/gdb/testsuite/gdb.python/py-shared.exp index 0eef359d0b87..ff47270c0717 100644 --- a/gdb/testsuite/gdb.python/py-shared.exp +++ b/gdb/testsuite/gdb.python/py-shared.exp @@ -42,11 +42,11 @@ clean_restart $testfile gdb_load_shlib ${library} # The following tests require execution. if {![runto_main]} { - return 0 + return } runto [gdb_get_line_number "Break to end."] # Test gdb.solib_name diff --git a/gdb/testsuite/gdb.python/py-strfns.exp b/gdb/testsuite/gdb.python/py-strfns.exp index 539ba984db02..3a8610a971ed 100644 --- a/gdb/testsuite/gdb.python/py-strfns.exp +++ b/gdb/testsuite/gdb.python/py-strfns.exp @@ -25,11 +25,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } proc test_all_strfns { } { gdb_test "p \$_streq (str1, str2)" " = 1" gdb_test "p \$_streq (str1, str3)" " = 0" diff --git a/gdb/testsuite/gdb.python/py-symbol.exp b/gdb/testsuite/gdb.python/py-symbol.exp index 90e724ca0313..af187857176a 100644 --- a/gdb/testsuite/gdb.python/py-symbol.exp +++ b/gdb/testsuite/gdb.python/py-symbol.exp @@ -88,11 +88,11 @@ gdb_test "python print (gdb.lookup_static_symbol ('nonexistent') is None)" \ gdb_test "python print (gdb.lookup_static_symbol ('qq') is None)" \ "True" "lookup_static_symbol for global var" if {![runto_main]} { - return 0 + return } global hex decimal gdb_breakpoint [gdb_get_line_number "Block break here."] @@ -203,11 +203,11 @@ gdb_test "python print (gdb.lookup_global_symbol ('(anonymous namespace)::anon') "True" "anon is None" gdb_test "python print (gdb.lookup_static_symbol ('(anonymous namespace)::anon').value ())" \ "10" "print value of anon" if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "Break in class."] gdb_continue_to_breakpoint "Break in class." @@ -231,11 +231,11 @@ gdb_test "python print (cplusfunc.addr_class == gdb.SYMBOL_LOC_BLOCK)" "True" "t # Test is_valid when the objfile is unloaded. This must be the last # test as it unloads the object file in GDB. # Start with a fresh gdb. clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "Break at end."] gdb_continue_to_breakpoint "Break at end for symbol validity" ".*Break at end.*" gdb_py_test_silent_cmd "python a = gdb.lookup_symbol(\'a\')" "Get variable a" 0 diff --git a/gdb/testsuite/gdb.python/py-symtab.exp b/gdb/testsuite/gdb.python/py-symtab.exp index 786bdc75fc4d..b5dd0c26988e 100644 --- a/gdb/testsuite/gdb.python/py-symtab.exp +++ b/gdb/testsuite/gdb.python/py-symtab.exp @@ -25,11 +25,11 @@ standard_testfile py-symbol.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { return } if {![runto_main]} { - return 0 + return } set debug_types [debug_types] global hex decimal diff --git a/gdb/testsuite/gdb.python/py-unwind-inline.exp b/gdb/testsuite/gdb.python/py-unwind-inline.exp index ef9b00eccc8b..d7d82913f61a 100644 --- a/gdb/testsuite/gdb.python/py-unwind-inline.exp +++ b/gdb/testsuite/gdb.python/py-unwind-inline.exp @@ -27,11 +27,11 @@ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ return } # The following tests require execution. if {![runto_main]} { - return 0 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_breakpoint "foo" diff --git a/gdb/testsuite/gdb.python/py-unwind-user-regs.exp b/gdb/testsuite/gdb.python/py-unwind-user-regs.exp index c594bf74ceef..248996c51615 100644 --- a/gdb/testsuite/gdb.python/py-unwind-user-regs.exp +++ b/gdb/testsuite/gdb.python/py-unwind-user-regs.exp @@ -45,11 +45,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return 0 + return } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_breakpoint [gdb_get_line_number "Break here"] diff --git a/gdb/testsuite/gdb.python/py-unwind.exp b/gdb/testsuite/gdb.python/py-unwind.exp index 058caaf1efc7..af864dceedfd 100644 --- a/gdb/testsuite/gdb.python/py-unwind.exp +++ b/gdb/testsuite/gdb.python/py-unwind.exp @@ -35,11 +35,11 @@ if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} "debug $fla require is_x86_64_m64_target # The following tests require execution. if {![runto_main]} { - return 0 + return } # Check for the corrupt backtrace. proc check_for_broken_backtrace {testname} { gdb_test_sequence "where" $testname { diff --git a/gdb/testsuite/gdb.python/py-value.exp b/gdb/testsuite/gdb.python/py-value.exp index 3746a6cbc0bc..4337928ddef4 100644 --- a/gdb/testsuite/gdb.python/py-value.exp +++ b/gdb/testsuite/gdb.python/py-value.exp @@ -819,11 +819,11 @@ test_float_conversion test_add_to_history # The following tests require execution. if {![runto_main]} { - return 0 + return } test_unavailable test_value_in_inferior test_value_from_buffer diff --git a/gdb/testsuite/gdb.python/python.exp b/gdb/testsuite/gdb.python/python.exp index f2f32019e4c2..7d3cd299bc8c 100644 --- a/gdb/testsuite/gdb.python/python.exp +++ b/gdb/testsuite/gdb.python/python.exp @@ -208,11 +208,11 @@ gdb_expect { clean_restart ${testfile} # The following tests require execution. if {![runto_main]} { - return 0 + return } set lineno [gdb_get_line_number "Break to end."] runto $lineno @@ -422,11 +422,11 @@ gdb_test_multiple "set extended-prompt some param \\p{python print-stack} " \ clean_restart ${testfile} # The following tests require execution. if {![runto_main]} { - return 0 + return } # print-stack settings gdb_test "show python print-stack" \ "The mode of Python stack printing on error is \"message\".*" \ @@ -477,11 +477,11 @@ gdb_py_test_silent_cmd "python gdb.prompt_hook = None" \ clean_restart ${testfile} # The following tests require execution. if {![runto_main]} { - return 0 + return } runto [gdb_get_line_number "Break at func2 call site."] gdb_py_test_silent_cmd "python line = gdb.selected_frame().find_sal().line" "Get line number of func2 call site" 1 From patchwork Wed Apr 29 23:04:15 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134214 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 4E71F4BB58A9 for ; Wed, 29 Apr 2026 23:08:58 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4E71F4BB58A9 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=NFvj7vEs X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa33.google.com (mail-vk1-xa33.google.com [IPv6:2607:f8b0:4864:20::a33]) by sourceware.org (Postfix) with ESMTPS id CFB624B920E5 for ; Wed, 29 Apr 2026 23:06:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org CFB624B920E5 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org CFB624B920E5 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a33 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503963; cv=none; b=jzjosbbjNv3pKZNrKnUbBGqUnaHAYirWy+AselpEh88H0B7CULQAtGNJQdx9Q7cuzifZA6YDllaYc+EIobqVcznRzonsmz39F9tgZ1e9lry90Eiq+G3GZ6QEmYgH/QE2/VjfR8NsMjblNjlikyLdEp0Hqs/ojLKnC8vSFHlxvWM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503963; c=relaxed/simple; bh=P1x2TOIV5B5x7pP6+yUeuhQhJagbe/VYcWVU4RFBxvI=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=f74zfe9KAX7tGJ9SNK9LuwhvohKul5qR4HV3XZRKFoPFDaA/OP8rx3hYk8blikUozEdRuBIlEcsTnzfxJfzAnnlfxkCPUFnWP2152QzvuhFyaUhqcP2lTvN5HExBr42XOHKmAXRJ8Dfl/R4g0Ci0ouTC/7mAlgO5hr0WNtNnAYA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CFB624B920E5 Received: by mail-vk1-xa33.google.com with SMTP id 71dfb90a1353d-56faf1cfe04so99049e0c.3 for ; Wed, 29 Apr 2026 16:06:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503963; x=1778108763; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=LPb2DRzhdJcSv5EYjn3uPdQngzUU0hhIF/zv09mK2YE=; b=NFvj7vEs1lSHlKzDyD+EGVQGsqI0fj9Fi6e73k+JnbOHkDnK1qeNvLK1Tx2AErAlkm LJw05boi6SDI2FgSlrp4jQ850c+qSlg1Dwuk7LvjVAQcSlv8RLeW3JpMg0uBH68UMfiI bOdpxE9cAUQT46WVVqPlYjDjMJNbkCZsw+CthsThlpzCun2CQ+a7XEFU21l93x/TUBRw EDQ0KYoS1GE2zNn47jknH8IdYxSU8YLDk5CCkeYbDe+pkMks6FakHON4dp4zHC3Toyp+ CDJD92vTMSBbGjqj0eulsA38PVfVEmQ2VdWEzrc1Zvusf8L8RA/RSiT6Uh9ByQ9+PCbw l9bg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503963; x=1778108763; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=LPb2DRzhdJcSv5EYjn3uPdQngzUU0hhIF/zv09mK2YE=; b=AsN59bvfv6q1nbFfAXqTgWtF0NdAclY8etcM3HWZ5Ch67JVrFLhuAeSYmrb4kKbNI5 Toc7TI81wahWU0fy6sGAEX5i8pdX+qf22/oCKVJVaAQex/+0FMpntTIfI5w9pFCMyXHr uairugcNeXU/1DonSwneiOn1Ae+oTQt//Ds7kurOdOxSJEhosb29G9utR3HiSp2rQg64 H0yhladbxwQeSonOaNaEYwtITeMz4Qnhh9fofInXs3mYXqfHwKEmuOoXOf5Mku+OAhHw cl50AUaOyqYhUSv4tQ4DJA41ABnVFu3IiBYw4ECXnAyab8aepgtncb7Pkm4yErqH9s7F 9DkA== X-Gm-Message-State: AOJu0YxBynze29p82SRTGBFvHFMANP1CPBQqVCRHDzwRT0Iv1l3Bnwxj W331ZR7OnxhBJy1ePKALhUYDog4iApG4LXlGi4AA9iQag17756ixOjwQ+HVmvG5oR3SI/YWNIyo gT9/s X-Gm-Gg: AeBDieuY6UCzMRJwyVX6xtuAAoybZsUwpBQzDSmTc2xsWMsJuJqVnEJ2rAHcrWBrtAi tN1YicbIkqv1Z9CyLlABGA42VAD+oFR79KfPUuSyKXJcdoHju5vduZOLR5aheCN2zEnD8+G5IyN JQRKDWeyESK5YJJNqHo9etAOodg1uHqLwe7EuiqH92JgrMMfcXXjcKDDgYkHr8dRAvrcB8x+eOB UbnkGM2apiY8JC30iZ74vYBL4iTfj7MiJXuamkW11qsdrcIax3ghIlipNv7ruC+1QmFQoku/wj6 zmU3I0RPVq8ogb3EtkFxf0E0T1lFpBIJHthR+LpltVN5AfO+jwA5l67RyStHZ+Hi3YJk+TzpQ2/ FQTZHyqB+BfaEHisxDfM4KhgI29qOcKdeJsfyBKHL2BxYBW+Mr9m7AqW2yZXnDv+OyfylaBFvvY bHp45MjeR4YXrlpoPRDKVGYm7+lYfGANaHVX63LBW0cYRb X-Received: by 2002:a05:6122:289b:b0:56f:7300:37c9 with SMTP id 71dfb90a1353d-573c96cd014mr99415e0c.10.1777503962893; Wed, 29 Apr 2026 16:06:02 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb7765a76sm1894987241.10.2026.04.29.16.06.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:02 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 24/37] GDB: testsuite: Python: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:15 -0300 Message-ID: <20260429230432.60487-25-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" and "return 0" statements that weren't caught by the sed command. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside block such as save_vars, with_test_prefix, foreach, gdb_test_multiple. In a couple of cases the whole if block was in a single line: if { condition } { return -1 } In those cases the formatting was changed to the multi-line style we tend to use. --- gdb/testsuite/gdb.python/py-arch-reg-groups.exp | 2 +- gdb/testsuite/gdb.python/py-arch-reg-names.exp | 2 +- gdb/testsuite/gdb.python/py-arch.exp | 2 +- .../gdb.python/py-auto-load-chaining.exp | 10 +++++----- gdb/testsuite/gdb.python/py-disasm.exp.tcl | 6 +++--- gdb/testsuite/gdb.python/py-events.exp | 2 +- gdb/testsuite/gdb.python/py-explore-cc.exp | 2 +- gdb/testsuite/gdb.python/py-explore.exp | 2 +- .../gdb.python/py-finish-breakpoint.exp | 16 ++++++++-------- gdb/testsuite/gdb.python/py-format-address.exp | 4 ++-- gdb/testsuite/gdb.python/py-framefilter-addr.exp | 2 +- .../gdb.python/py-label-symbol-value.exp | 2 +- gdb/testsuite/gdb.python/py-linetable-empty.exp | 2 +- gdb/testsuite/gdb.python/py-pp-registration.exp | 6 +++--- gdb/testsuite/gdb.python/py-prompt.exp | 2 +- gdb/testsuite/gdb.python/py-read-memory-leak.exp | 2 +- gdb/testsuite/gdb.python/py-record-btrace.exp | 4 +++- gdb/testsuite/gdb.python/py-record-full.exp | 4 +++- .../gdb.python/py-rvalue-ref-value-cc.exp | 2 +- gdb/testsuite/gdb.python/py-value-cc.exp | 2 +- gdb/testsuite/gdb.python/py-value.exp | 2 +- gdb/testsuite/gdb.python/py-xmethods.exp | 2 +- gdb/testsuite/gdb.python/python.exp | 2 +- 23 files changed, 43 insertions(+), 39 deletions(-) diff --git a/gdb/testsuite/gdb.python/py-arch-reg-groups.exp b/gdb/testsuite/gdb.python/py-arch-reg-groups.exp index 6630143f0373..7a1025841f46 100644 --- a/gdb/testsuite/gdb.python/py-arch-reg-groups.exp +++ b/gdb/testsuite/gdb.python/py-arch-reg-groups.exp @@ -22,11 +22,11 @@ standard_testfile py-arch.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return -1 + return } # First, use 'maint print reggroups' to get a list of all register # groups. set groups {} diff --git a/gdb/testsuite/gdb.python/py-arch-reg-names.exp b/gdb/testsuite/gdb.python/py-arch-reg-names.exp index 7bbb171e13e1..6807098fbda8 100644 --- a/gdb/testsuite/gdb.python/py-arch-reg-names.exp +++ b/gdb/testsuite/gdb.python/py-arch-reg-names.exp @@ -22,11 +22,11 @@ standard_testfile py-arch.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return -1 + return } # First, use 'info registers' to get a list of register names. set regs {} gdb_test_multiple "info registers general" "info registers general" { diff --git a/gdb/testsuite/gdb.python/py-arch.exp b/gdb/testsuite/gdb.python/py-arch.exp index a2ac6ad4bfa1..b1dd81a05839 100644 --- a/gdb/testsuite/gdb.python/py-arch.exp +++ b/gdb/testsuite/gdb.python/py-arch.exp @@ -19,11 +19,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return -1 + return } # Test python/15461. Invalid architectures should not trigger an # internal GDB assert. gdb_py_test_silent_cmd "python empty = gdb.Architecture()" "get empty arch" 0 diff --git a/gdb/testsuite/gdb.python/py-auto-load-chaining.exp b/gdb/testsuite/gdb.python/py-auto-load-chaining.exp index 7a92ff0fac71..bd0d1c4b11ef 100644 --- a/gdb/testsuite/gdb.python/py-auto-load-chaining.exp +++ b/gdb/testsuite/gdb.python/py-auto-load-chaining.exp @@ -27,17 +27,17 @@ standard_testfile .c -f1.c -f2.c set f1_o [standard_output_file ${gdb_test_file_name}-f1.o] set f2_o [standard_output_file ${gdb_test_file_name}-f2.o] # Now build the object files. if {[gdb_compile "${srcdir}/${subdir}/${srcfile2}" ${f1_o} object {}] != ""} { - untested "failed to compile object file f1.o" - return -1 + untested "failed to compile object file f1.o" + return } if {[gdb_compile "${srcdir}/${subdir}/${srcfile3}" ${f2_o} object {}] != ""} { - untested "failed to compile object file f2.o" - return -1 + untested "failed to compile object file f2.o" + return } # Copy the two Python scripts to where the tests are being run. set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}-f1.o-gdb.py] @@ -48,11 +48,11 @@ set remote_python_file [gdb_remote_download host \ if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { return } if {![runto_main]} { - return -1 + return } set safe_path [standard_output_file ""] gdb_test_no_output "set auto-load safe-path ${safe_path}" \ "set auto-load safe-path" diff --git a/gdb/testsuite/gdb.python/py-disasm.exp.tcl b/gdb/testsuite/gdb.python/py-disasm.exp.tcl index e4391fa59ced..6382005eee52 100644 --- a/gdb/testsuite/gdb.python/py-disasm.exp.tcl +++ b/gdb/testsuite/gdb.python/py-disasm.exp.tcl @@ -28,24 +28,24 @@ if { $kind == "obj" } { set binfile [standard_output_file $testfile] if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile object \ "debug"] != "" } { untested "failed to compile object file $testfile" - return -1 + return } clean_restart $testfile } else { if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if { ![runto_main] } { fail "can't run to main" - return 0 + return } } set pyfile [gdb_remote_download host ${srcdir}/${subdir}/py-disasm.py] diff --git a/gdb/testsuite/gdb.python/py-events.exp b/gdb/testsuite/gdb.python/py-events.exp index 1177dd54e482..16a290c31c29 100644 --- a/gdb/testsuite/gdb.python/py-events.exp +++ b/gdb/testsuite/gdb.python/py-events.exp @@ -313,11 +313,11 @@ with_test_prefix "gdb exiting: normal" { with_test_prefix "gdb exiting: error" { clean_restart ${testfile} if {![runto_main]} { fail "cannot run to main." - return 0 + return } gdb_test_no_output "source ${pyfile}" "load python file" gdb_test "test-exiting-event error" "GDB exiting event registered\\." gdb_test "test-events" "Event testers registered\\." diff --git a/gdb/testsuite/gdb.python/py-explore-cc.exp b/gdb/testsuite/gdb.python/py-explore-cc.exp index 772886b931f9..70b1beeada0a 100644 --- a/gdb/testsuite/gdb.python/py-explore-cc.exp +++ b/gdb/testsuite/gdb.python/py-explore-cc.exp @@ -35,11 +35,11 @@ set B_desc "'B' is a struct/class with the following fields:.*\ A = .*\ i = .*\ c = .*" if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here."] gdb_continue_to_breakpoint "Break here" ".*Break here.*" diff --git a/gdb/testsuite/gdb.python/py-explore.exp b/gdb/testsuite/gdb.python/py-explore.exp index 276148da8f10..debe30315356 100644 --- a/gdb/testsuite/gdb.python/py-explore.exp +++ b/gdb/testsuite/gdb.python/py-explore.exp @@ -74,11 +74,11 @@ proc scalar_value { value_name value } { } set SS_fields [field_values {a = 10} {d = 100[.].*}] if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here."] gdb_continue_to_breakpoint "Break here" ".*Break here.*" diff --git a/gdb/testsuite/gdb.python/py-finish-breakpoint.exp b/gdb/testsuite/gdb.python/py-finish-breakpoint.exp index 043416c724cc..960a44f412a6 100644 --- a/gdb/testsuite/gdb.python/py-finish-breakpoint.exp +++ b/gdb/testsuite/gdb.python/py-finish-breakpoint.exp @@ -44,11 +44,11 @@ clean_restart ${testfile} with_test_prefix "normal conditions" { clean_restart ${testfile} gdb_load_shlib ${lib_sl} if {![runto_main]} { - return 0 + return } set python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] @@ -96,11 +96,11 @@ with_test_prefix "return to inlined function" { gdb_test "source $python_file" "Python script imported.*" \ "import python scripts" if {![runto_main]} { - return 0 + return } gdb_breakpoint "increase_2" gdb_test "continue" "Breakpoint .*at.*" "continue to the function to finish" @@ -122,11 +122,11 @@ with_test_prefix "no debug symbol" { gdb_test "source $python_file" "Python script imported.*" \ "import python scripts" set cond_line [gdb_get_line_number "Condition Break."] if {![runto_main]} { - return 0 + return } gdb_test "print do_nothing" "no debug info.*" "ensure that shared lib has no debug info" gdb_breakpoint "do_nothing" {temporary} gdb_test "continue" "Temporary breakpoint .*in \\.?do_nothing.*" \ @@ -177,11 +177,11 @@ with_test_prefix "finish in dummy frame" { gdb_test "source $python_file" "Python script imported.*" \ "import python scripts" if {![runto_main]} { - return 0 + return } gdb_test "break ${cond_line} if test_1(i,8)" "Breakpoint .* at .*" \ "set a conditional BP" gdb_test "python TestBreakpoint()" "TestBreakpoint init" \ @@ -204,11 +204,11 @@ with_test_prefix "finish in normal frame" { gdb_test "source $python_file" "Python script imported.*" \ "import python scripts" if {![runto_main]} { - return 0 + return } gdb_test "break ${cond_line} if test(i,8)" \ "Breakpoint .* at .*" "set conditional BP" gdb_test "python TestBreakpoint()" "TestBreakpoint init" "set BP in condition" @@ -233,11 +233,11 @@ with_test_prefix "explicit inferior function call" { gdb_test "source $python_file" "Python script imported.*" \ "import python scripts" if {![runto_main]} { - return 0 + return } # return address in dummy frame gdb_test "python TestExplicitBreakpoint('increase_1')" "Breakpoint.*at.*" \ @@ -260,11 +260,11 @@ with_test_prefix "explicit inferior function call" { # Test FinishBreakpoint when inferior exits # with_test_prefix "inferior exit" { if {![runto "test_exec_exit"]} { - return 0 + return } gdb_test_no_output "set var self_exec = 0" "switch to exit() test" gdb_test "python SimpleFinishBreakpoint(gdb.newest_frame())" "SimpleFinishBreakpoint init" "set FinishBP after the exit()" gdb_test "continue" "SimpleFinishBreakpoint out of scope.*" "catch out of scope after exit" @@ -274,11 +274,11 @@ with_test_prefix "inferior exit" { # Test FinishBreakpoint when inferior execs # with_test_prefix "inferior exec" { if {![runto "test_exec_exit"]} { - return 0 + return } gdb_test "python SimpleFinishBreakpoint(gdb.newest_frame())" "SimpleFinishBreakpoint init" "set FinishBP after the exec" gdb_test "catch exec" "Catchpoint.*\(exec\).*" gdb_test "continue" "SimpleFinishBreakpoint out of scope.*" "catch out of scope after exec" diff --git a/gdb/testsuite/gdb.python/py-format-address.exp b/gdb/testsuite/gdb.python/py-format-address.exp index dda012234b77..9f32686dfd3d 100644 --- a/gdb/testsuite/gdb.python/py-format-address.exp +++ b/gdb/testsuite/gdb.python/py-format-address.exp @@ -21,11 +21,11 @@ foreach func_name { foo bar } { if {[build_executable "build binary with ${func_name} function" \ "$testfile-${func_name}" $srcfile \ [list debug \ nopie \ additional_flags=-DFUNCTION_NAME=${func_name}]] == -1} { - return -1 + return } } set testfile_foo $testfile-foo set testfile_bar $testfile-bar @@ -33,11 +33,11 @@ set binary_foo [standard_output_file $testfile_foo] set binary_bar [standard_output_file $testfile_bar] clean_restart $testfile_foo if {![runto_main]} { - return -1 + return } # Check the gdb.format_address method when using the default values # for the program space and architecture (these will be selected based # on the current inferior). diff --git a/gdb/testsuite/gdb.python/py-framefilter-addr.exp b/gdb/testsuite/gdb.python/py-framefilter-addr.exp index 3c0436ce1972..1c85a8afcb36 100644 --- a/gdb/testsuite/gdb.python/py-framefilter-addr.exp +++ b/gdb/testsuite/gdb.python/py-framefilter-addr.exp @@ -26,11 +26,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return -1 + return } # Run to our test breakpoint. gdb_breakpoint [gdb_get_line_number "Break here"] gdb_continue_to_breakpoint "run to test breakpoint" diff --git a/gdb/testsuite/gdb.python/py-label-symbol-value.exp b/gdb/testsuite/gdb.python/py-label-symbol-value.exp index c97ae72ec58d..bd3f9ee689e9 100644 --- a/gdb/testsuite/gdb.python/py-label-symbol-value.exp +++ b/gdb/testsuite/gdb.python/py-label-symbol-value.exp @@ -23,11 +23,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return -1 + return } # Use Python to print the value of the 'some_label' symbol. gdb_test "python frame = gdb.selected_frame()" gdb_test "python frame_pc = frame.pc()" diff --git a/gdb/testsuite/gdb.python/py-linetable-empty.exp b/gdb/testsuite/gdb.python/py-linetable-empty.exp index 651fe9b6dbf3..3244d88a9367 100644 --- a/gdb/testsuite/gdb.python/py-linetable-empty.exp +++ b/gdb/testsuite/gdb.python/py-linetable-empty.exp @@ -41,11 +41,11 @@ if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug}] } { return } if {![runto_main]} { - return -1 + return } gdb_test "python print(gdb.selected_frame().function().symtab.fullname())" \ "py-linetable-empty.c" "Test main has symtab" diff --git a/gdb/testsuite/gdb.python/py-pp-registration.exp b/gdb/testsuite/gdb.python/py-pp-registration.exp index 3d974b2120b6..ab84a0f7f905 100644 --- a/gdb/testsuite/gdb.python/py-pp-registration.exp +++ b/gdb/testsuite/gdb.python/py-pp-registration.exp @@ -62,11 +62,11 @@ proc test_printers { s_prefix } { # Test registration with verbose off. with_test_prefix "verbose off" { if {![prepare_test]} { - return -1 + return } gdb_test_no_output "set verbose off" gdb_test_no_output "py gdb.printing.register_pretty_printer(gdb, lookup_function_lookup_test)" @@ -77,11 +77,11 @@ with_test_prefix "verbose off" { # Test registration with verbose on. with_test_prefix "verbose on" { if {![prepare_test]} { - return -1 + return } gdb_test_no_output "set verbose on" gdb_test "py gdb.printing.register_pretty_printer(gdb, lookup_function_lookup_test)" \ @@ -94,11 +94,11 @@ with_test_prefix "verbose on" { # Exercise the "replace" argument to register_pretty_printer. with_test_prefix "replace" { if {![prepare_test]} { - return -1 + return } gdb_test_no_output "py gdb.printing.register_pretty_printer(gdb, lookup_function_lookup_test)" gdb_test_no_output "py gdb.printing.register_pretty_printer(progspace, my_pretty_printer1)" gdb_test "py gdb.printing.register_pretty_printer(progspace, my_pretty_printer2, replace=False)" \ diff --git a/gdb/testsuite/gdb.python/py-prompt.exp b/gdb/testsuite/gdb.python/py-prompt.exp index cc149ae62303..96ea52843442 100644 --- a/gdb/testsuite/gdb.python/py-prompt.exp +++ b/gdb/testsuite/gdb.python/py-prompt.exp @@ -68,11 +68,11 @@ save_vars { INTERNAL_GDBFLAGS GDBFLAGS } { "prompt_hook argument is default prompt. 2" gdb_exit } if {![can_spawn_for_attach]} { - return 0 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.python/py-read-memory-leak.exp b/gdb/testsuite/gdb.python/py-read-memory-leak.exp index 58343126e67c..1a361c990533 100644 --- a/gdb/testsuite/gdb.python/py-read-memory-leak.exp +++ b/gdb/testsuite/gdb.python/py-read-memory-leak.exp @@ -25,10 +25,10 @@ standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return } if {![runto_main]} { - return -1 + return } gdb_py_run_memory_leak_test ${srcdir}/${subdir}/${testfile}.py \ "buffers returned by read_memory() deallocates correctly" diff --git a/gdb/testsuite/gdb.python/py-record-btrace.exp b/gdb/testsuite/gdb.python/py-record-btrace.exp index 4e324e71fc09..d5a647ebc59a 100644 --- a/gdb/testsuite/gdb.python/py-record-btrace.exp +++ b/gdb/testsuite/gdb.python/py-record-btrace.exp @@ -21,11 +21,13 @@ require allow_btrace_tests allow_python_tests load_lib gdb-python.exp standard_testfile -if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { return -1 } +if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { + return +} if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.python/py-record-full.exp b/gdb/testsuite/gdb.python/py-record-full.exp index 95640770e9a5..37bf07a64bfd 100644 --- a/gdb/testsuite/gdb.python/py-record-full.exp +++ b/gdb/testsuite/gdb.python/py-record-full.exp @@ -21,11 +21,13 @@ require supports_process_record allow_python_tests load_lib gdb-python.exp standard_testfile -if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { return -1 } +if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { + return +} if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp b/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp index 576fd5a85d3d..5e2b769cf71f 100644 --- a/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp +++ b/gdb/testsuite/gdb.python/py-rvalue-ref-value-cc.exp @@ -25,11 +25,11 @@ if {[prepare_for_testing $testfile.exp $testfile $srcfile \ {debug c++ additional_flags="-std=c++11"}]} { return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here."] gdb_continue_to_breakpoint "Break here" ".*Break here.*" diff --git a/gdb/testsuite/gdb.python/py-value-cc.exp b/gdb/testsuite/gdb.python/py-value-cc.exp index 1d65d617e30d..fa0cd066978b 100644 --- a/gdb/testsuite/gdb.python/py-value-cc.exp +++ b/gdb/testsuite/gdb.python/py-value-cc.exp @@ -23,11 +23,11 @@ standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "Break here."] gdb_continue_to_breakpoint "Break here" ".*Break here.*" diff --git a/gdb/testsuite/gdb.python/py-value.exp b/gdb/testsuite/gdb.python/py-value.exp index 4337928ddef4..ba3b1376ff5a 100644 --- a/gdb/testsuite/gdb.python/py-value.exp +++ b/gdb/testsuite/gdb.python/py-value.exp @@ -838,11 +838,11 @@ test_value_after_death test_subscript_regression "${binfile}" "c" if {[allow_cplus_tests]} { if { [build_inferior "${binfile}-cxx" "c++"] < 0 } { - return -1 + return } with_test_prefix "c++" { test_subscript_regression "${binfile}-cxx" "c++" } } diff --git a/gdb/testsuite/gdb.python/py-xmethods.exp b/gdb/testsuite/gdb.python/py-xmethods.exp index 52f0a7597093..b8a8b46c1db3 100644 --- a/gdb/testsuite/gdb.python/py-xmethods.exp +++ b/gdb/testsuite/gdb.python/py-xmethods.exp @@ -25,11 +25,11 @@ standard_testfile py-xmethods.cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { return } if {![runto_main]} { - return -1 + return } set xmethods_script [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.python/python.exp b/gdb/testsuite/gdb.python/python.exp index 7d3cd299bc8c..27dbc555a17b 100644 --- a/gdb/testsuite/gdb.python/python.exp +++ b/gdb/testsuite/gdb.python/python.exp @@ -46,11 +46,11 @@ gdb_test_multiple "python print (23)" "verify python support" { gdb_test_multiline "multi-line python command" \ "python" "" \ "print (23)" "" \ "end" "not supported.*" - return -1 + return } -re "$gdb_prompt $" {} } gdb_test_multiline "multi-line python command" \ From patchwork Wed Apr 29 23:04:16 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134212 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 5BCD04358A4F for ; Wed, 29 Apr 2026 23:08:26 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 5BCD04358A4F Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=ep/m773x X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x930.google.com (mail-ua1-x930.google.com [IPv6:2607:f8b0:4864:20::930]) by sourceware.org (Postfix) with ESMTPS id B78984358A58 for ; Wed, 29 Apr 2026 23:06:07 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B78984358A58 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B78984358A58 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::930 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503967; cv=none; b=lol31xN7CflUwe+dxTGG6BCMKGZj1hWpl0pQ4aXqyZ2nJJ8n+xJFK0lL85xdTG3g2V8sMo6TjFIpXK53WlL2Dw+jl89JciCVjQMV69cRouru1kOk2Ng1WcyhsVRcaaHL+/XhIjElX8E7qI7fWv6rR1tq3sh3Uw+4sbsNs62wWCY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503967; c=relaxed/simple; bh=jKtsUd/1gbV8iyhcwx/EeHc20yK03Ch1IP/A1hiz9LI=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=A+5G6P/WxvBCWpfzBhaG5rGueX4xIupmofXViMa7LLcs9x9D/wCJgqPMmu8BcYYhCsfHOslWrGs1X4WRKZUgwPTMRAa0E7ItVHg87sUcYdPOKr5Wx/3zQessdWeQJeWXtoTtLeiGryJsZlpHcJp9tlFo3QP3ejjGIuVtBK60X8g= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B78984358A58 Received: by mail-ua1-x930.google.com with SMTP id a1e0cc1a2514c-9567aa1a047so130135241.0 for ; Wed, 29 Apr 2026 16:06:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503967; x=1778108767; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Ps19zM6j01uTw904i5pLmJ1ctEMASGIP1j3zx4TYRLU=; b=ep/m773x8RByD7qDMDVUIIYSeV/I7e6nyFC8e4b97OVl6ZNQHSvJChPgSmxu+TUlt0 Lz38ihnbHRdkL2bt3W4DpwVoPuLXwOEPcyAvPW/8JGq5YWCIeOWUr+pPnf63yjHPEzWI pZIdmWcVpxIudVOFIIYaR/p/8LySaejxJ9BiN4GZFW+V6xJsSBpXQCqvuMs8dh876dO+ Wyk0j83jtEiuTFjPZKCPP81jaXT+bvcKnt4icIldnU2TCQne+4wFG0SWp4i1+gUPdkCg bfs7fOli9eD/y8p0EekJ4Aif3WVkdan6tPeCum0gjKulZt+StdhqadxMeyAoCr2zssdH YKyQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503967; x=1778108767; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=Ps19zM6j01uTw904i5pLmJ1ctEMASGIP1j3zx4TYRLU=; b=UQgsPbknl6xn9r025R+ymUS75o6gkjdACu04/HhkGciFIOO4WeZgkugTQ8p2rGPDo5 3S0fIflg4jUOdpsvNhzTvI7EbWSgla1+7wPFJs7Q0pmo26sxOUAPLefMpy7uWnv/2oaT h10gCnHbuTAltYfT03f0wOkqvGABVuRnBhNHbSQ1XR1tHpmu+F8di7SM6rDTXRGhNcDp aE54VpANkd3/jnjx01sCBIbwfFhQllmkOJzb8gensu3QeNF+6Rr2LGV2TF9u/89sozgG fCOSfI91Se4IsaA9Cgucu6T/mwe/qIkEQgZ3P00fBQEHb9g0paFN3aPn22nZPFSb8MYd DFdg== X-Gm-Message-State: AOJu0YyF8au3CJ5Jh2JElaeTeOk3UeEyGHtSB3JTkdadjaZZ7QKKefGA mHYIZmpaQfN4WOzGUsPi3vJOSBqvXxlX86H+IBO9veBHB0dmbTVMyifeW9poourdQArZWyCKTqA Mzh8o X-Gm-Gg: AeBDievK5ln3DzSIEMR8jUFO+Re1rlga0y5kx+bsvqwW6/GbKNEDgmcIbLwHNY1uDK1 AxyJs9w6GuglPLygL5TVs26KJ9yh69ypgokEDHKXxBv9C8QM3YdD2eiOpoF2Kv0g/8Bg1D8RYMs vLONATvTtMl2pofZhEmDta+6Wun5Mosho6NjqFcnfGs9HXTdZGCNAl4K5UMHnZ+/Cxh1pXDk9Me Hs5rdzcxUkMj+RUIfqWvgf/YDiCSTjzl3XcHA3ub7UuXqoM7hZrz2hgxzRffnsx1rjoRY7hfp3T YxlXjHUKEtpmLSQRp2EP7fOCkElwiMA39AI/RhFUawHG1E7DN2KXE5s7S9+ocyNf9GJGHTDS8FU qNPSDcUkdF806YQyxOmkSXkxnE6h2ST62gi+ywZTW1RkQGoP+UZNGDdY/Infm8GJGrwLTFMfeSs FPv/FIcvi3yuli/74avZhA0nNl7efnACaVqCs1DzRrAfew X-Received: by 2002:a05:6102:441d:b0:5f5:4055:4558 with SMTP id ada2fe7eead31-62ad1529961mr296244137.2.1777503966955; Wed, 29 Apr 2026 16:06:06 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb717d119sm1912227241.0.2026.04.29.16.06.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:06 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 25/37] GDB: testsuite: linespec: Don't return value from top-level Date: Wed, 29 Apr 2026 20:04:16 -0300 Message-ID: <20260429230432.60487-26-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org Most changes are the result of running: $ sed -i 's/^ return -1/ return/' *.exp inside gdb/testsuite/gdb.linespec. The exceptions fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside a namespace block. A couple of "return 0" statements were also fixed. --- gdb/testsuite/gdb.linespec/break-ask.exp | 2 +- gdb/testsuite/gdb.linespec/break-asm-file.exp | 8 ++++---- gdb/testsuite/gdb.linespec/cp-completion-aliases.exp | 2 +- .../gdb.linespec/cp-replace-typedefs-ns-template.exp | 2 +- gdb/testsuite/gdb.linespec/cpcompletion.exp | 4 ++-- gdb/testsuite/gdb.linespec/cpexplicit.exp | 4 ++-- gdb/testsuite/gdb.linespec/cpls-abi-tag.exp | 4 ++-- gdb/testsuite/gdb.linespec/cpls-ops.exp | 4 ++-- gdb/testsuite/gdb.linespec/errors.exp | 2 +- gdb/testsuite/gdb.linespec/explicit.exp | 4 ++-- gdb/testsuite/gdb.linespec/keywords.exp | 4 ++-- gdb/testsuite/gdb.linespec/linespec.exp | 2 +- gdb/testsuite/gdb.linespec/ls-dollar.exp | 2 +- gdb/testsuite/gdb.linespec/macro-relative.exp | 2 +- gdb/testsuite/gdb.linespec/skip-two.exp | 6 +++--- gdb/testsuite/gdb.linespec/thread.exp | 4 ++-- 16 files changed, 28 insertions(+), 28 deletions(-) diff --git a/gdb/testsuite/gdb.linespec/break-ask.exp b/gdb/testsuite/gdb.linespec/break-ask.exp index ed91d7defb15..90d5044765e4 100644 --- a/gdb/testsuite/gdb.linespec/break-ask.exp +++ b/gdb/testsuite/gdb.linespec/break-ask.exp @@ -40,11 +40,11 @@ with_cwd $srcdir/${subdir}/base/two { } } if { [gdb_compile "$srcdir/${subdir}/$srcfile $objfile1 $objfile2" \ $binfile executable $opts] != "" } { - return -1 + return } clean_restart ${testfile} gdb_test_no_output "set multiple-symbols ask" diff --git a/gdb/testsuite/gdb.linespec/break-asm-file.exp b/gdb/testsuite/gdb.linespec/break-asm-file.exp index b8dadc15c4ca..c6ae8dea7be9 100644 --- a/gdb/testsuite/gdb.linespec/break-asm-file.exp +++ b/gdb/testsuite/gdb.linespec/break-asm-file.exp @@ -26,26 +26,26 @@ set asm_file0 break-asm-file0.S # This test can only be run on targets which support DWARF-2 and use gas. require dwarf2_support if {[gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile}1.o \ object {debug nowarnings optimize=-O0}] != ""} { - return -1 + return } # Compile .s files without debug information. if {[gdb_compile ${srcdir}/${subdir}/$asm_file0 ${binfile}2.o \ object {nodebug}] != ""} { - return -1 + return } if {[gdb_compile ${srcdir}/${subdir}/$asm_file1 ${binfile}3.o \ object {nodebug}] != ""} { - return -1 + return } if {[gdb_compile [list ${binfile}1.o ${binfile}2.o ${binfile}3.o] \ "${binfile}" executable {}] != ""} { - return -1 + return } clean_restart $execfile gdb_test "break a/$asm_file0:func" \ diff --git a/gdb/testsuite/gdb.linespec/cp-completion-aliases.exp b/gdb/testsuite/gdb.linespec/cp-completion-aliases.exp index fe7ae40c9a22..a3f99998840f 100644 --- a/gdb/testsuite/gdb.linespec/cp-completion-aliases.exp +++ b/gdb/testsuite/gdb.linespec/cp-completion-aliases.exp @@ -19,11 +19,11 @@ load_lib completion-support.exp standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} { - return -1 + return } # Disable the completion limit for the whole testcase. gdb_test_no_output "set max-completions unlimited" diff --git a/gdb/testsuite/gdb.linespec/cp-replace-typedefs-ns-template.exp b/gdb/testsuite/gdb.linespec/cp-replace-typedefs-ns-template.exp index b12f14da1543..c82410e29325 100644 --- a/gdb/testsuite/gdb.linespec/cp-replace-typedefs-ns-template.exp +++ b/gdb/testsuite/gdb.linespec/cp-replace-typedefs-ns-template.exp @@ -21,11 +21,11 @@ load_lib completion-support.exp standard_testfile .cc if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug c++ additional_flags=-std=c++11}]} { - return -1 + return } # Disable the completion limit for the whole testcase. gdb_test_no_output "set max-completions unlimited" diff --git a/gdb/testsuite/gdb.linespec/cpcompletion.exp b/gdb/testsuite/gdb.linespec/cpcompletion.exp index 14eb1a68c81a..96c7a968ed6c 100644 --- a/gdb/testsuite/gdb.linespec/cpcompletion.exp +++ b/gdb/testsuite/gdb.linespec/cpcompletion.exp @@ -28,19 +28,19 @@ lappend opts additional_flags=-std=c++11 set flags {} lappend flags debug if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2 $srcfile3 $srcfile4] $opts]} { - return -1 + return } # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } # # Some convenience procedures for testing template parameter list # completion. diff --git a/gdb/testsuite/gdb.linespec/cpexplicit.exp b/gdb/testsuite/gdb.linespec/cpexplicit.exp index b5dbc6dceece..8c9de2aa8991 100644 --- a/gdb/testsuite/gdb.linespec/cpexplicit.exp +++ b/gdb/testsuite/gdb.linespec/cpexplicit.exp @@ -20,11 +20,11 @@ require allow_cplus_tests standard_testfile .cc set exefile $testfile if {[prepare_for_testing "failed to prepare" $exefile $srcfile \ {c++ debug nowarnings}]} { - return -1 + return } # Wrap this whole test in a namespace to avoid contaminating other tests. namespace eval $testfile { upvar #0 ::srcfile srcfile @@ -88,11 +88,11 @@ namespace eval $testfile { add linespecs "-function \"myclass::operator,\"" $location(operator) # Fire up gdb. if {![runto_main]} { namespace delete $testfile - return -1 + return } # Test explicit linespecs, with and without conditions. foreach linespec $linespecs(linespecs) loc_pattern $linespecs(locations) { # Test the linespec diff --git a/gdb/testsuite/gdb.linespec/cpls-abi-tag.exp b/gdb/testsuite/gdb.linespec/cpls-abi-tag.exp index 6399f252d71d..80c8a3937e11 100644 --- a/gdb/testsuite/gdb.linespec/cpls-abi-tag.exp +++ b/gdb/testsuite/gdb.linespec/cpls-abi-tag.exp @@ -29,19 +29,19 @@ if { [test_compiler_info gcc-*] } { require {expr {[gcc_major_version] >= 5}} } if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile] {c++ debug}]} { - return -1 + return } # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } gdb_test_no_output "set max-completions unlimited" # Check that the explicit location completer manages to find the next diff --git a/gdb/testsuite/gdb.linespec/cpls-ops.exp b/gdb/testsuite/gdb.linespec/cpls-ops.exp index 4cef26e6767e..c49afaa9856c 100644 --- a/gdb/testsuite/gdb.linespec/cpls-ops.exp +++ b/gdb/testsuite/gdb.linespec/cpls-ops.exp @@ -23,19 +23,19 @@ set flags {} lappend flags debug lappend flags c++ if {[prepare_for_testing "failed to prepare" $testfile \ [list $srcfile] $flags]} { - return -1 + return } # Tests below are about tab-completion, which doesn't work if readline # library isn't used. Check it first. if { ![readline_is_used] } { untested "no tab completion support without readline" - return -1 + return } gdb_test_no_output "set max-completions unlimited" # Check that the explicit location completer manages to find the next diff --git a/gdb/testsuite/gdb.linespec/errors.exp b/gdb/testsuite/gdb.linespec/errors.exp index 8f60f0eca30b..8e69dd6fa058 100644 --- a/gdb/testsuite/gdb.linespec/errors.exp +++ b/gdb/testsuite/gdb.linespec/errors.exp @@ -17,11 +17,11 @@ # We don't currently need our own test case for testing, so grab # another one. if {[prepare_for_testing "failed to prepare" linespecs keywords.c]} { - return -1 + return } # PR gdb/12843 gdb_test "list c:/foo/bar/baz.c:1" "No source file named c:/foo/bar/baz.c." gdb_test "list c:/foo/bar/baz.c" "Function \"c:/foo/bar/baz.c\" not defined." diff --git a/gdb/testsuite/gdb.linespec/explicit.exp b/gdb/testsuite/gdb.linespec/explicit.exp index faee27bab4a5..ccf74d3863d6 100644 --- a/gdb/testsuite/gdb.linespec/explicit.exp +++ b/gdb/testsuite/gdb.linespec/explicit.exp @@ -25,11 +25,11 @@ lappend opts debug lappend opts nowarnings lappend opts additional_flags=-nostdlib if {[prepare_for_testing "failed to prepare" $exefile \ [list $srcfile $srcfile2 $srcfile3] $opts]} { - return -1 + return } # Wrap the entire test in a namespace to avoid contaminating other tests. namespace eval $testfile { upvar #0 ::srcfile srcfile @@ -96,11 +96,11 @@ namespace eval $testfile { add linespecs "-function myfunction -label top -line 3" $location(top) add linespecs "-line 25" $location(normal) # Fire up gdb. if {![runto_main]} { - return -1 + return } # Turn off queries gdb_test_no_output "set confirm off" diff --git a/gdb/testsuite/gdb.linespec/keywords.exp b/gdb/testsuite/gdb.linespec/keywords.exp index 36069868f444..ae9380575cf6 100644 --- a/gdb/testsuite/gdb.linespec/keywords.exp +++ b/gdb/testsuite/gdb.linespec/keywords.exp @@ -17,15 +17,15 @@ standard_testfile set exefile $testfile if {[prepare_for_testing "failed to prepare" $exefile $srcfile {debug}]} { - return -1 + return } if {![runto_main]} { - return 0 + return } # Turn off pending breakpoints to facilitate testing errors. gdb_test_no_output "set breakpoint pending off" diff --git a/gdb/testsuite/gdb.linespec/linespec.exp b/gdb/testsuite/gdb.linespec/linespec.exp index 0345fc5098ef..771dede9bb64 100644 --- a/gdb/testsuite/gdb.linespec/linespec.exp +++ b/gdb/testsuite/gdb.linespec/linespec.exp @@ -25,11 +25,11 @@ set basetwo base/two/thefile.cc require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $exefile \ [list $srcfile $baseone $basetwo] \ {debug nowarnings c++}]} { - return -1 + return } gdb_test_no_output "set multiple-symbols all" \ "set multiple-symbols to all for linespec tests" diff --git a/gdb/testsuite/gdb.linespec/ls-dollar.exp b/gdb/testsuite/gdb.linespec/ls-dollar.exp index 584ea35447e4..a000c5b39695 100644 --- a/gdb/testsuite/gdb.linespec/ls-dollar.exp +++ b/gdb/testsuite/gdb.linespec/ls-dollar.exp @@ -20,11 +20,11 @@ set exefile $testfile require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $exefile $srcfile \ {debug nowarnings c++}]} { - return -1 + return } gdb_test_no_output "set listsize 1" set line [gdb_get_line_number {dollar_func}] diff --git a/gdb/testsuite/gdb.linespec/macro-relative.exp b/gdb/testsuite/gdb.linespec/macro-relative.exp index b0ac538be69d..99a6dac78921 100644 --- a/gdb/testsuite/gdb.linespec/macro-relative.exp +++ b/gdb/testsuite/gdb.linespec/macro-relative.exp @@ -40,9 +40,9 @@ clean_restart ${testfile} # Test macros respect DW_AT_comp_dir. # "list header_two_func" does not set exactly the one line we want. if {![runto header_two_func]} { - return -1 + return } gdb_test "info macro HEADER" "\r\n#define HEADER 2" diff --git a/gdb/testsuite/gdb.linespec/skip-two.exp b/gdb/testsuite/gdb.linespec/skip-two.exp index 0a8af84441a3..3c5e438f1177 100644 --- a/gdb/testsuite/gdb.linespec/skip-two.exp +++ b/gdb/testsuite/gdb.linespec/skip-two.exp @@ -23,18 +23,18 @@ set basetwo base/two/thefile.cc require allow_cplus_tests if {[prepare_for_testing "failed to prepare" $execfile \ [list $srcfile $baseone $basetwo] \ {debug nowarnings c++}]} { - return -1 + return } gdb_test "skip function dupname" \ {Function dupname will be skipped when stepping\.} if {![runto_main]} { - return -1 + return } set test "dupname ignored from main" gdb_test_multiple "step" $test { -re "^step\r\ndupname .*\r\n$gdb_prompt $" { @@ -62,11 +62,11 @@ gdb_test_no_output "skip delete 1" gdb_test "skip file thefile.cc" \ {File thefile\.cc will be skipped when stepping\.} if {![runto_main]} { - return -1 + return } gdb_test "step" "static int dupname .*" "step into dupname" gdb_test "finish" "return dupname.* body_elsewhere.*" "finish from dupname" diff --git a/gdb/testsuite/gdb.linespec/thread.exp b/gdb/testsuite/gdb.linespec/thread.exp index 30a21e8fe2fd..ab63fe52a1d9 100644 --- a/gdb/testsuite/gdb.linespec/thread.exp +++ b/gdb/testsuite/gdb.linespec/thread.exp @@ -18,15 +18,15 @@ standard_testfile set exefile $testfile if {[prepare_for_testing "failed to prepare" $exefile $srcfile {debug}]} { - return -1 + return } if {![runto_main]} { - return 0 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] gdb_test "break $srcfile:$bp_location1" \ From patchwork Wed Apr 29 23:04:17 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134211 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id E0EE54358A53 for ; Wed, 29 Apr 2026 23:08:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E0EE54358A53 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=vsXukBaS X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x92f.google.com (mail-ua1-x92f.google.com [IPv6:2607:f8b0:4864:20::92f]) by sourceware.org (Postfix) with ESMTPS id 90C3A4358A66 for ; Wed, 29 Apr 2026 23:06:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 90C3A4358A66 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 90C3A4358A66 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::92f ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503971; cv=none; b=QDuZbG8g+tsDRjidO2GK1K6+lZfvcCVUdJiUw2PymqF2kDIrQzY3AzM3b6Z0jy9xJDd11FqjD+E5n1XuJs6cISCOASBHBDUAnEqakjdFhoQH5i1qF/fZLl1x3Zj2YyDb068RSPhfMve8Eyh0/z5VyMr9ZKtx1ZgaN63Mlb79anw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503971; c=relaxed/simple; bh=mIQKAaTvYBLg+ld2bON8RwwiOLcBAPpmJUfEK+lpZIs=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=WMCIQVvQ+X2U6cndmDh/2YZklIf9MJTKp+FkxcSIH9TC9hgI1sm9o6trDAlTiFzg/gw1d44MlLQxOdrweULsvMU7lug56bkGBcjYDvXK/m9rymPtIS1gW69GXTCVxVT1Zd7MaWW1s2p98yrROx14a9Sc2OQFAxSJu9/mGpMNxQM= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 90C3A4358A66 Received: by mail-ua1-x92f.google.com with SMTP id a1e0cc1a2514c-954997c9014so123115241.3 for ; Wed, 29 Apr 2026 16:06:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503971; x=1778108771; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=YXitib46yVWMZ6/pgrwwzeCXDyLYXA2PZv9ysPYR8R0=; b=vsXukBaSLDfuNbOScI2V4RPDIqlhdEBFTkkWhMrffI2OjEhvGcNqC9qpKoRMiS4hmi 11FJKlTNGNDxSTdMmKp7KpRVMBcpM6yznh3syWA6LT4UwOc9b60wBLSGWU5DxhgKjeKh huuT72z39zlWeqEGLAoHbOpiwODoEZdYR4iev9yl8dTW/LaOMtdLPKHkyhexfXoxIjqD tq7O0VmSxZD/dAdZJtxEHj1cTLCAMFsTuHERZKPudK8b9TYjA2xe7DvofaCiLjE2LFMu mWdjZRnuTzUKZ5aI9kVV/QEA3kD27COnJ1nwe8P+WfesIW/1vUZ8I1gslvT55af2eAYk 65Pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503971; x=1778108771; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=YXitib46yVWMZ6/pgrwwzeCXDyLYXA2PZv9ysPYR8R0=; b=rznk7A4UA+pcKyduDn6suLg3fPEUzSab27kQRbZePAReq8/F7rpirwrfQnsPo8P1l2 0IxtE4CE4OM6I8X4CpN++tlXpRVK+/MyO869z5Vbh8Mq4e5smr807vQtld/eru+DQ27J aE6mGMugp8+N5AkHzdqepAqnJaY8TWknqUc19j19WMCW2B9MPaAgYnFlqHG6DhRdrS+n C7oRFfg5LWn+ItPU5FnKm0s5L/1Gw+LbmDraPvGO4J9Luwz0zjynEs07pIsS/YHFE6LR q2JxnjEPYmhYOKbaSKRhzfXDZFpAcslYO/l70O485+GgjG7eB17caHo+04T5KIGXrUrs vYxw== X-Gm-Message-State: AOJu0YwM9Oyzw5z1lue8S26trL4Wn1Y2s9CTDAVrt2HdfxLuf2Pg5SS5 hcYcIPRqZcDLZsBhQ+S6dfVkwwQ2T+7PPPpCYdGJPN6kEnhGJSDBrSriv5JNiBzecjn/wjqNspZ 1Dp2z X-Gm-Gg: AeBDieu0VF4uVBy0K7ivdRj/xQpGJi8hulL2xDApSTE1biHAbZYOLGUHf6V0IIHOJA8 tiJufq5iOuvQE0tD3z3Xu6AAEEAmuOgF9PCNqqfztrM8QyGeyNNWbAIUKWBAJMgByW0jmvccOJa M5HE1PU6b3hdHrsgRTdSRXi+w5sH32Hb2qPLd65z/MwYvUmTIvinzd6JzdjiQsbL+3iiFJ+WCAe +1WCNLMcxQRApLyUMJFW4y8auEhAzI7qwbsszAw1bK1uFI4Pr0E2fgGf2iySj43hiqAfJYPRI6E ev2qscj/6z9+FPJiMVCTpiPWmOQcT4la8Jue06DRYSlQVsVtACn5kRkEL+LqKHEVXVfSmF4mpAr nK4kPoKeRDmLiuP5NIkRogRilOxbes5wMx034zB4sS5DjD7FgNV/nlUZWZqrwx/VCkF45yMSNKD Q38D6+oEmgnSNck5ThNliC77RYQYzWHDqotd6/d1Rvm2dp X-Received: by 2002:a05:6102:2c87:b0:604:f29d:84be with SMTP id ada2fe7eead31-62ad1e3f367mr343504137.3.1777503970557; Wed, 29 Apr 2026 16:06:10 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-62982736ba5sm2026871137.5.2026.04.29.16.06.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:09 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 26/37] GDB: testsuite: MI: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:17 -0300 Message-ID: <20260429230432.60487-27-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.mi. --- gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp | 2 +- gdb/testsuite/gdb.mi/gdb669.exp | 2 +- gdb/testsuite/gdb.mi/interrupt-thread-group.exp | 2 +- gdb/testsuite/gdb.mi/list-thread-groups-available.exp | 2 +- gdb/testsuite/gdb.mi/mi-add-inferior.exp | 2 +- gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp | 2 +- gdb/testsuite/gdb.mi/mi-breakpoint-script.exp | 2 +- gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-catch-load.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-cmd-user-context.exp | 2 +- gdb/testsuite/gdb.mi/mi-condbreak-fail.exp | 2 +- gdb/testsuite/gdb.mi/mi-condbreak-throw.exp | 2 +- gdb/testsuite/gdb.mi/mi-corefile.exp | 2 +- gdb/testsuite/gdb.mi/mi-dprintf-pending.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-dprintf.exp | 2 +- gdb/testsuite/gdb.mi/mi-exit-code.exp | 2 +- gdb/testsuite/gdb.mi/mi-file-transfer.exp | 2 +- gdb/testsuite/gdb.mi/mi-fortran-modules.exp | 2 +- gdb/testsuite/gdb.mi/mi-fullname-deleted.exp | 6 +++--- gdb/testsuite/gdb.mi/mi-info-os.exp | 6 +++--- gdb/testsuite/gdb.mi/mi-info-sources.exp | 2 +- gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp | 2 +- gdb/testsuite/gdb.mi/mi-logging.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-memory-changed.exp | 2 +- gdb/testsuite/gdb.mi/mi-nonstop-exit.exp | 2 +- gdb/testsuite/gdb.mi/mi-nonstop.exp | 2 +- gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp | 2 +- gdb/testsuite/gdb.mi/mi-nsintrall.exp | 2 +- gdb/testsuite/gdb.mi/mi-nsmoribund.exp | 2 +- gdb/testsuite/gdb.mi/mi-nsthrexec.exp | 2 +- gdb/testsuite/gdb.mi/mi-pending.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-pthreads.exp | 2 +- gdb/testsuite/gdb.mi/mi-py-modify-bp.exp | 2 +- gdb/testsuite/gdb.mi/mi-record-changed.exp | 2 +- gdb/testsuite/gdb.mi/mi-reg-undefined.exp | 2 +- gdb/testsuite/gdb.mi/mi-stepn.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-sym-info.exp | 2 +- gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp | 2 +- gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp | 2 +- gdb/testsuite/gdb.mi/mi-threads-interrupt.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-block.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-child-f.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-child.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-var-cmd.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-create-rtti.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-var-display.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-invalidate-shlib.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-var-invalidate.exp | 6 +++--- .../gdb.mi/mi-var-list-children-invalid-grandchild.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-rtti.exp | 2 +- gdb/testsuite/gdb.mi/mi-watch-nonstop.exp | 2 +- gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp | 2 +- gdb/testsuite/gdb.mi/mi2-cli-display.exp | 2 +- gdb/testsuite/gdb.mi/mi2-var-child.exp | 2 +- gdb/testsuite/gdb.mi/new-ui-bp-deleted.exp | 2 +- gdb/testsuite/gdb.mi/new-ui-mi-sync.exp | 2 +- gdb/testsuite/gdb.mi/print-simple-values.exp | 2 +- gdb/testsuite/gdb.mi/user-selected-context-sync.exp | 2 +- 59 files changed, 75 insertions(+), 75 deletions(-) diff --git a/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp b/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp index ad0dd162c495..94f42fe77ab8 100644 --- a/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp +++ b/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp @@ -37,11 +37,11 @@ set objmainfile [standard_output_file ${testfile}-main.o] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" $objsfile object {}] != "" || [gdb_compile "${srcdir}/${subdir}/${srcfile2}" $objfuncfile object {}] != "" || [gdb_compile "${srcdir}/${subdir}/${srcfile3}" $objmainfile object {debug}] != "" || [gdb_compile "$objfuncfile $objsfile $objmainfile" $binfile executable {}] != "" } { - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/gdb669.exp b/gdb/testsuite/gdb.mi/gdb669.exp index a07117a3804c..b03577d85748 100644 --- a/gdb/testsuite/gdb.mi/gdb669.exp +++ b/gdb/testsuite/gdb.mi/gdb669.exp @@ -25,11 +25,11 @@ set MIFLAGS "-i=mi" # standard_testfile pthreads.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } mi_clean_restart $::testfile mi_runto_main check_mi_and_console_threads "at main" diff --git a/gdb/testsuite/gdb.mi/interrupt-thread-group.exp b/gdb/testsuite/gdb.mi/interrupt-thread-group.exp index 17a2a42c5e6c..f2c45a9dc27e 100644 --- a/gdb/testsuite/gdb.mi/interrupt-thread-group.exp +++ b/gdb/testsuite/gdb.mi/interrupt-thread-group.exp @@ -23,11 +23,11 @@ set MIFLAGS "-i=mi" standard_testfile .c if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile \ executable {debug additional_flags=-std=gnu99}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\" -ex \"set mi-async\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/list-thread-groups-available.exp b/gdb/testsuite/gdb.mi/list-thread-groups-available.exp index 426e39ff2b63..77f932cd167e 100644 --- a/gdb/testsuite/gdb.mi/list-thread-groups-available.exp +++ b/gdb/testsuite/gdb.mi/list-thread-groups-available.exp @@ -24,11 +24,11 @@ standard_testfile require allow_xml_test require can_spawn_for_attach if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_gdb_start]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-add-inferior.exp b/gdb/testsuite/gdb.mi/mi-add-inferior.exp index fc9002bd6279..607eaacdf22d 100644 --- a/gdb/testsuite/gdb.mi/mi-add-inferior.exp +++ b/gdb/testsuite/gdb.mi/mi-add-inferior.exp @@ -21,11 +21,11 @@ set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug}] != "" } { untested "failed to compile" - return -1 + return } mi_clean_restart ${::testfile} # Start execution to establish a connection. diff --git a/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp b/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp index 78e2ebc3ea88..688ad46f1b39 100644 --- a/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp @@ -30,19 +30,19 @@ set lib_sl2 [standard_output_file pendshr2.sl] set lib_opts "debug" if { [gdb_compile_shlib $libsrc1 $lib_sl1 $lib_opts] != "" || [gdb_compile_shlib $libsrc2 $lib_sl2 $lib_opts] != ""} { untested "failed to compile shared library" - return -1 + return } set MIFLAGS "-i=mi" set exec_opts [list debug shlib=$lib_sl1 shlib_load] if { [gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != "" } { untested "failed to compile" - return -1 + return } proc test_insert_delete_modify { } { global mi_gdb_prompt global lib_sl1 lib_sl2 diff --git a/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp b/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp index eb20460f7594..95097568624e 100644 --- a/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp +++ b/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp @@ -17,11 +17,11 @@ load_lib mi-support.exp standard_testfile .cc if {[gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable {debug c++}] != "" } { - return -1 + return } # Generate the regexp pattern used to match the breakpoint description emitted # in the various breakpoint command results/events. # diff --git a/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp b/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp index 70a03d9e0a08..0ec3b4d1abca 100644 --- a/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp +++ b/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp @@ -18,11 +18,11 @@ load_lib mi-support.exp standard_testfile .c if {[gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable {debug}] != "" } { - return -1 + return } # Generate the regexp pattern used to match the breakpoint description emitted # in the various breakpoint command results/events. # diff --git a/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp b/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp index ef3164034e79..3581bbe8d794 100644 --- a/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp +++ b/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp @@ -22,16 +22,16 @@ set MIFLAGS "-i=mi" standard_testfile .cc if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}] != "" } { untested "failed to compile" - return -1 + return } mi_clean_restart $::testfile if {[mi_runto_main] < 0} { - return -1 + return } set libstdcxx_probe_tests_supported [expr {![mi_skip_libstdcxx_probe_tests]}] # Grab some line numbers we'll need. set catch_1_lineno [gdb_get_line_number "Catch 1"] diff --git a/gdb/testsuite/gdb.mi/mi-catch-load.exp b/gdb/testsuite/gdb.mi/mi-catch-load.exp index 4afd9154eb39..e42f9c075ab0 100644 --- a/gdb/testsuite/gdb.mi/mi-catch-load.exp +++ b/gdb/testsuite/gdb.mi/mi-catch-load.exp @@ -18,20 +18,20 @@ require allow_shlib_tests standard_testfile mi-catch-load.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug shlib_load}] != "" } { untested "failed to compile" - return -1 + return } set testfile2 mi-catch-load-so set srcfile2 ${testfile2}.c set binfile2 [standard_output_file ${testfile2}.so] set binfile2_dlopen [shlib_target_file ${testfile2}.so] if { [gdb_compile_shlib "${srcdir}/${subdir}/${srcfile2}" ${binfile2} {debug}] != "" } { untested "failed to compile shared library" - return -1 + return } gdb_download_shlib $binfile2 # test -catch-load diff --git a/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp b/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp index 6e5be0d27764..7ee1949e4405 100644 --- a/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp +++ b/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp @@ -20,11 +20,11 @@ load_lib mi-support.exp standard_testfile if {[build_executable $testfile.exp $testfile ${srcfile} "debug pthreads"] == -1} { untested "failed to compile" - return -1 + return } set main_break_line [gdb_get_line_number "main break line"] set any "\[^\r\n\]*" diff --git a/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp b/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp index db3b61e320fd..99629840e04e 100644 --- a/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp +++ b/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp @@ -21,11 +21,11 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile if {[build_executable ${testfile}.exp ${binfile} ${srcfile}]} { - return -1 + return } # Create a breakpoint with a condition that invokes an inferior # function call, that will segfault. Run until GDB hits the # breakpoint and check how GDB reports the failed condition check. diff --git a/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp b/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp index 97e671cd2dab..e367f7a24200 100644 --- a/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp +++ b/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp @@ -24,11 +24,11 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile .cc if {[build_executable ${testfile}.exp ${binfile} ${srcfile} {debug c++}]} { - return -1 + return } # Create a breakpoint with a condition that invokes an inferior # function call, that will segfault. Run until GDB hits the # breakpoint and check how GDB reports the failed condition check. diff --git a/gdb/testsuite/gdb.mi/mi-corefile.exp b/gdb/testsuite/gdb.mi/mi-corefile.exp index d3fd841abf40..67c6183f3867 100644 --- a/gdb/testsuite/gdb.mi/mi-corefile.exp +++ b/gdb/testsuite/gdb.mi/mi-corefile.exp @@ -22,11 +22,11 @@ require isnative standard_testfile if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { untested "failed to compile" - return -1 + return } set corefile [core_find $binfile {}] if {$corefile == ""} { untested "unable to create or find corefile" diff --git a/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp b/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp index f9767fb8c27c..b2e1cc3438cb 100644 --- a/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp +++ b/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp @@ -29,16 +29,16 @@ set lib_sl1 [standard_output_file $libfile1.sl] set lib_opts debug set exec_opts [list debug shlib=$lib_sl1 shlib_load] if {[gdb_compile_shlib $libsrc1 $lib_sl1 $lib_opts] != ""} { untested "failed to compile shared library" - return -1 + return } if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-dprintf.exp b/gdb/testsuite/gdb.mi/mi-dprintf.exp index 3f0e4dba1d99..9b2c192e5041 100644 --- a/gdb/testsuite/gdb.mi/mi-dprintf.exp +++ b/gdb/testsuite/gdb.mi/mi-dprintf.exp @@ -23,11 +23,11 @@ set flags {} lappend flags debug lappend_include_file flags $srcdir/lib/unbuffer_output.c if {[build_executable $testfile.exp $testfile $srcfile $flags] == -1} { untested "failed to compile" - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set dp_location1 [gdb_get_line_number "set dprintf 1 here"] diff --git a/gdb/testsuite/gdb.mi/mi-exit-code.exp b/gdb/testsuite/gdb.mi/mi-exit-code.exp index c12d1158c07b..2e48c7ce028d 100644 --- a/gdb/testsuite/gdb.mi/mi-exit-code.exp +++ b/gdb/testsuite/gdb.mi/mi-exit-code.exp @@ -18,11 +18,11 @@ set MIFLAGS "-i=mi" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } proc test_list_thread_groups { } { global hex global decimal diff --git a/gdb/testsuite/gdb.mi/mi-file-transfer.exp b/gdb/testsuite/gdb.mi/mi-file-transfer.exp index 7a42766964e7..5fc137ba5a05 100644 --- a/gdb/testsuite/gdb.mi/mi-file-transfer.exp +++ b/gdb/testsuite/gdb.mi/mi-file-transfer.exp @@ -24,11 +24,11 @@ require allow_gdbserver_tests standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-fortran-modules.exp b/gdb/testsuite/gdb.mi/mi-fortran-modules.exp index 2d874612e05d..c08d5c2038a7 100644 --- a/gdb/testsuite/gdb.mi/mi-fortran-modules.exp +++ b/gdb/testsuite/gdb.mi/mi-fortran-modules.exp @@ -23,11 +23,11 @@ set MIFLAGS "-i=mi" standard_testfile "mi-fortran-modules.f90" "mi-fortran-modules-2.f90" if {[build_executable "failed to prepare" ${testfile} \ [list $srcfile2 $srcfile] {debug f90}]} { - return -1 + return } mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp b/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp index 803c07b3ea03..9f56e03d747a 100644 --- a/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp +++ b/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp @@ -30,17 +30,17 @@ set srcfileabs [standard_output_file $srcfile] # storing it in the executable's debug info, removing the double # slash. This nullifies the "compare_filenames_for_search does # not match" test when using Clang (it can never fail). if { [regsub {/[^/]+$} $srcfileabs {/\0} srcfileabs] != 1 } { xfail "cannot double the last slash separator" - return -1 + return } if { [regsub {^(/[^/]+)/} $srcfileabs {\1subst/} srcfileabssubst] != 1 || [regsub {^(/[^/]+)/.*$} $srcfileabs {\1} initdir] != 1 } { xfail "missing root subdirectory" - return -1 + return } # Generate a regular expression which to match $srcfileabs with # or without the doubled slash. This is used by the substituted # fullname test. @@ -51,11 +51,11 @@ set f [open $srcfileabs "w"] puts $f "int main (void) { return 0; }" close $f if { [gdb_compile "$srcfileabs" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } file delete -- $srcfileabs if {[mi_clean_restart $::testfile]} { diff --git a/gdb/testsuite/gdb.mi/mi-info-os.exp b/gdb/testsuite/gdb.mi/mi-info-os.exp index 9adc8d31c4ed..f802d8cfd92e 100644 --- a/gdb/testsuite/gdb.mi/mi-info-os.exp +++ b/gdb/testsuite/gdb.mi/mi-info-os.exp @@ -17,21 +17,21 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" # This test is Linux-only. if {![istarget *-*-linux*]} { unsupported "mi-info-os.exp" - return -1 + return } # Support for XML-output is needed to run this test. require allow_xml_test standard_testfile basics.c if {[build_executable "Failed to build $testfile" $testfile $srcfile \ debug]} { - return -1; + return; } if {[mi_clean_restart $::testfile]} { return } @@ -42,11 +42,11 @@ if {[mi_clean_restart $::testfile]} { # that and cover all targets is to run to main, with mi_runto_main. # However, with native configurations, -info-os should work before # running any program, so we want to avoid "run". Using # mi_gdb_target_load directly instead achieves this. if {[mi_gdb_target_load] < 0} { - return -1 + return } # Try the argument-less form that lists all the types in a table. mi_gdb_test "-info-os" ".*\\^done,OSDataTable=.*" "-info-os" diff --git a/gdb/testsuite/gdb.mi/mi-info-sources.exp b/gdb/testsuite/gdb.mi/mi-info-sources.exp index ab92fff197c0..0b3016c0b55d 100644 --- a/gdb/testsuite/gdb.mi/mi-info-sources.exp +++ b/gdb/testsuite/gdb.mi/mi-info-sources.exp @@ -21,11 +21,11 @@ set MIFLAGS "-i=mi" standard_testfile .c -base.c if {[build_executable $testfile.exp $testfile \ [list $srcfile $srcfile2] debug]} { untested $testfile.exp - return -1 + return } mi_clean_restart $::testfile set readnow_p [mi_readnow] diff --git a/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp b/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp index b06f4686e082..91261597fa91 100644 --- a/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp +++ b/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp @@ -24,11 +24,11 @@ set MIFLAGS "-i=mi" standard_testfile .cc set exefile $testfile if {[build_executable "failed to prepare" $exefile $srcfile {debug c++}]} { - return -1 + return } mi_clean_restart $::testfile # Turn off the pending breakpoint queries. diff --git a/gdb/testsuite/gdb.mi/mi-logging.exp b/gdb/testsuite/gdb.mi/mi-logging.exp index 6cff709cfc5c..1ed0d229bae0 100644 --- a/gdb/testsuite/gdb.mi/mi-logging.exp +++ b/gdb/testsuite/gdb.mi/mi-logging.exp @@ -19,17 +19,17 @@ set MIFLAGS "-i=mi" standard_testfile basics.c set opts {debug} if {[build_executable $testfile.exp $testfile $srcfile $opts]} { untested "failed to compile" - return -1 + return } mi_clean_restart $::testfile if {[mi_runto_main] < 0} { - return -1 + return } set milogfile [standard_output_file "milog.txt"] mi_gdb_test "-gdb-set logging file $milogfile" "\\^done" \ diff --git a/gdb/testsuite/gdb.mi/mi-memory-changed.exp b/gdb/testsuite/gdb.mi/mi-memory-changed.exp index 6f41ecd8ad32..916d240b09bc 100644 --- a/gdb/testsuite/gdb.mi/mi-memory-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-memory-changed.exp @@ -15,11 +15,11 @@ standard_testfile basics.c if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ executable {debug nowarnings}] != "" } { untested "failed to compile" - return -1 + return } load_lib mi-support.exp if {[mi_clean_restart $::testfile]} { diff --git a/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp b/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp index 8958755c57a4..ba62f74bf015 100644 --- a/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp +++ b/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp @@ -23,11 +23,11 @@ set MIFLAGS "-i=mi" # standard_testfile non-stop-exit.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi-nonstop.exp b/gdb/testsuite/gdb.mi/mi-nonstop.exp index e85049191583..970b11a2f8e2 100644 --- a/gdb/testsuite/gdb.mi/mi-nonstop.exp +++ b/gdb/testsuite/gdb.mi/mi-nonstop.exp @@ -33,11 +33,11 @@ proc mi_nonstop_resume { command test } { # standard_testfile non-stop.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" diff --git a/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp b/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp index 34257ee5c776..d5f6a1ec16bf 100644 --- a/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp +++ b/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp @@ -36,11 +36,11 @@ proc mi_nonstop_resume { command test } { standard_testfile ns-stale-regcache.c set options [list debug] if {[gdb_compile "$srcdir/$subdir/$srcfile" \ $binfile executable $options] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi-nsintrall.exp b/gdb/testsuite/gdb.mi/mi-nsintrall.exp index 84319b142a51..7850b5ad98f3 100644 --- a/gdb/testsuite/gdb.mi/mi-nsintrall.exp +++ b/gdb/testsuite/gdb.mi/mi-nsintrall.exp @@ -23,11 +23,11 @@ set MIFLAGS "-i=mi" # standard_testfile nsintrall.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi-nsmoribund.exp b/gdb/testsuite/gdb.mi/mi-nsmoribund.exp index 04c6162d87ba..b82996b72b94 100644 --- a/gdb/testsuite/gdb.mi/mi-nsmoribund.exp +++ b/gdb/testsuite/gdb.mi/mi-nsmoribund.exp @@ -23,11 +23,11 @@ set MIFLAGS "-i=mi" # standard_testfile nsmoribund.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi-nsthrexec.exp b/gdb/testsuite/gdb.mi/mi-nsthrexec.exp index 9446d6f3c6cf..64b27eacf91f 100644 --- a/gdb/testsuite/gdb.mi/mi-nsthrexec.exp +++ b/gdb/testsuite/gdb.mi/mi-nsthrexec.exp @@ -28,11 +28,11 @@ set MIFLAGS "-i=mi" # standard_testfile nsthrexec.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi-pending.exp b/gdb/testsuite/gdb.mi/mi-pending.exp index 99719be76a12..1ad9aecdc8b4 100644 --- a/gdb/testsuite/gdb.mi/mi-pending.exp +++ b/gdb/testsuite/gdb.mi/mi-pending.exp @@ -34,16 +34,16 @@ set lib_opts debug set exec_opts [list debug shlib=$lib_sl1 shlib_load] if { [gdb_compile_shlib $libsrc1 $lib_sl1 $lib_opts] != "" || [gdb_compile_shlib $libsrc2 $lib_sl2 $lib_opts] != ""} { untested "failed to compile shared library" - return -1 + return } if { [gdb_compile_pthreads $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} { untested "failed to compile" - return -1 + return } # Start with a fresh gdb. if {[mi_clean_restart $::testfile]} { return diff --git a/gdb/testsuite/gdb.mi/mi-pthreads.exp b/gdb/testsuite/gdb.mi/mi-pthreads.exp index 7e1d0123500b..1db1aba5afad 100644 --- a/gdb/testsuite/gdb.mi/mi-pthreads.exp +++ b/gdb/testsuite/gdb.mi/mi-pthreads.exp @@ -58,11 +58,11 @@ proc check_mi_thread_command_set {} { # standard_testfile pthreads.c set options [list debug] if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp b/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp index 022f6761362c..5b4ba362ef0f 100644 --- a/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp +++ b/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp @@ -23,11 +23,11 @@ set MIFLAGS "-i=mi" standard_testfile require allow_python_tests if {[build_executable $testfile.exp $testfile $srcfile] == -1} { - return -1 + return } set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] diff --git a/gdb/testsuite/gdb.mi/mi-record-changed.exp b/gdb/testsuite/gdb.mi/mi-record-changed.exp index e4e54f1adf1e..1f4dbf7b686b 100644 --- a/gdb/testsuite/gdb.mi/mi-record-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-record-changed.exp @@ -17,11 +17,11 @@ require supports_process_record standard_testfile basics.c if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ executable {debug nowarnings}] != "" } { untested "failed to compile" - return -1 + return } load_lib mi-support.exp mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi-reg-undefined.exp b/gdb/testsuite/gdb.mi/mi-reg-undefined.exp index 5b6e998d7d72..dd7b2961b03f 100644 --- a/gdb/testsuite/gdb.mi/mi-reg-undefined.exp +++ b/gdb/testsuite/gdb.mi/mi-reg-undefined.exp @@ -33,11 +33,11 @@ if {[mi_clean_restart $::testfile]} { return } if {![mi_runto stop_frame]} { perror "Failed to stop in stop_frame" - return -1 + return } mi_gdb_test "111-stack-list-frames" \ "111\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"stop_frame\",.*\},frame=\{level=\"1\",addr=\"$hex\",func=\"first_frame\",.*\},frame=\{level=\"2\",addr=\"$hex\",func=\"main\",.*\}\\\]" \ "stack frame listing" diff --git a/gdb/testsuite/gdb.mi/mi-stepn.exp b/gdb/testsuite/gdb.mi/mi-stepn.exp index 42255de20b3d..77a32060203b 100644 --- a/gdb/testsuite/gdb.mi/mi-stepn.exp +++ b/gdb/testsuite/gdb.mi/mi-stepn.exp @@ -21,17 +21,17 @@ set MIFLAGS "-i=mi" standard_testfile set opts {debug} if {[build_executable ${testfile}.exp ${testfile} ${srcfile} $opts]} { - return -1 + return } mi_clean_restart $::testfile if {[mi_runto_main] < 0} { - return -1 + return } mi_create_breakpoint do_nothing \ "breakpoint at do_nothing" \ -number 2 -func do_nothing diff --git a/gdb/testsuite/gdb.mi/mi-sym-info.exp b/gdb/testsuite/gdb.mi/mi-sym-info.exp index 96d261ded404..e129d5746a32 100644 --- a/gdb/testsuite/gdb.mi/mi-sym-info.exp +++ b/gdb/testsuite/gdb.mi/mi-sym-info.exp @@ -28,11 +28,11 @@ set MIFLAGS "-i=mi" standard_testfile mi-sym-info-1.c mi-sym-info-2.c if {[build_executable "failed to prepare" ${testfile} \ [list $srcfile $srcfile2] {debug}]} { - return -1 + return } mi_clean_restart $::testfile # Don't run to main to avoid increasing the search scope to include diff --git a/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp b/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp index bd7b606b87cd..e80475911fcf 100644 --- a/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp +++ b/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp @@ -30,11 +30,11 @@ set is_remote \ standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile \ {debug pthreads}] } { - return -1 + return } foreach_mi_ui_mode mode { if {$mode eq "separate"} { set start_ops "separate-mi-tty" diff --git a/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp b/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp index 9f250912b2ce..ac76a5579c0c 100644 --- a/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp +++ b/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp @@ -24,11 +24,11 @@ if {[mi_clean_restart]} { } standard_testfile if {[build_executable ${testfile}.exp ${binfile} ${srcfile}]} { - return -1 + return } proc make_loc {num} { return [mi_make_breakpoint_loc -thread "1" -number "$::decimal\\.$num"] } diff --git a/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp b/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp index 0d8b091d0ac9..5de4fc06c80f 100644 --- a/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp +++ b/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp @@ -19,11 +19,11 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable {debug}] != "" } { - return -1 + return } # This tests the resolution of PR 20039. # # With a multi-threaded inferior and with MI/all-stop, it was not possible diff --git a/gdb/testsuite/gdb.mi/mi-var-block.exp b/gdb/testsuite/gdb.mi/mi-var-block.exp index e2450527de60..27836717ef8d 100644 --- a/gdb/testsuite/gdb.mi/mi-var-block.exp +++ b/gdb/testsuite/gdb.mi/mi-var-block.exp @@ -24,11 +24,11 @@ set MIFLAGS "-i=mi" standard_testfile var-cmd.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-child-f.exp b/gdb/testsuite/gdb.mi/mi-var-child-f.exp index cb249364b68f..ad81441db057 100644 --- a/gdb/testsuite/gdb.mi/mi-var-child-f.exp +++ b/gdb/testsuite/gdb.mi/mi-var-child-f.exp @@ -23,11 +23,11 @@ require allow_fortran_tests standard_testfile array.f90 if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug f90}] != ""} { - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-child.exp b/gdb/testsuite/gdb.mi/mi-var-child.exp index cbc672a14c2c..8c0b8472272b 100644 --- a/gdb/testsuite/gdb.mi/mi-var-child.exp +++ b/gdb/testsuite/gdb.mi/mi-var-child.exp @@ -24,11 +24,11 @@ set MIFLAGS "-i=mi" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } @@ -1199,10 +1199,10 @@ mi_varobj_update * {psnp->ptrs.0.next.next.long_ptr} \ "update all vars psnp->next->next->long_ptr (and 2.long_ptr) changed" mi_prepare_inline_tests $srcfile if { [mi_run_inline_test child_deletion] < 0 } { - return -1 + return } mi_gdb_exit diff --git a/gdb/testsuite/gdb.mi/mi-var-cmd.exp b/gdb/testsuite/gdb.mi/mi-var-cmd.exp index d95c9847e96e..bf207dad255e 100644 --- a/gdb/testsuite/gdb.mi/mi-var-cmd.exp +++ b/gdb/testsuite/gdb.mi/mi-var-cmd.exp @@ -24,11 +24,11 @@ set MIFLAGS "-i=mi" standard_testfile var-cmd.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp b/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp index 918d0497806d..08b6076dea05 100644 --- a/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp +++ b/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp @@ -18,17 +18,17 @@ set MIFLAGS "-i=mi" standard_testfile .c set opts {debug} if {[build_executable $testfile.exp $testfile $srcfile $opts]} { - return -1 + return } mi_clean_restart $::testfile if {[mi_runto_main] < 0} { - return -1 + return } # Test creating a register-based variable. We pick # register SP since it is a pointer to data. This checks # for a regression when creating MI variables from pointers diff --git a/gdb/testsuite/gdb.mi/mi-var-display.exp b/gdb/testsuite/gdb.mi/mi-var-display.exp index 2efbd2903a13..325291efe500 100644 --- a/gdb/testsuite/gdb.mi/mi-var-display.exp +++ b/gdb/testsuite/gdb.mi/mi-var-display.exp @@ -24,11 +24,11 @@ set MIFLAGS "-i=mi" standard_testfile var-cmd.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-invalidate-shlib.exp b/gdb/testsuite/gdb.mi/mi-var-invalidate-shlib.exp index 45e64bcc2c51..80a97fbcbf2a 100644 --- a/gdb/testsuite/gdb.mi/mi-var-invalidate-shlib.exp +++ b/gdb/testsuite/gdb.mi/mi-var-invalidate-shlib.exp @@ -25,11 +25,11 @@ require allow_shlib_tests standard_testfile .c -lib.c set shlib_path [standard_output_file ${testfile}-lib.so] if { [gdb_compile_shlib $srcdir/$subdir/$srcfile2 $shlib_path {debug}] != "" } { untested "failed to compile" - return -1 + return } set shlib_path_target [gdb_download_shlib $shlib_path] set opts {} @@ -37,11 +37,11 @@ lappend opts shlib_load lappend opts debug lappend opts additional_flags=-DSHLIB_PATH=[quote_for_host $shlib_path_target] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $opts] != "" } { untested "failed to compile" - return -1 + return } proc do_test { separate_debuginfo } { if { [mi_clean_restart] } { unsupported "failed to start GDB" diff --git a/gdb/testsuite/gdb.mi/mi-var-invalidate.exp b/gdb/testsuite/gdb.mi/mi-var-invalidate.exp index 693db9977913..0edb5b6b1881 100644 --- a/gdb/testsuite/gdb.mi/mi-var-invalidate.exp +++ b/gdb/testsuite/gdb.mi/mi-var-invalidate.exp @@ -25,25 +25,25 @@ set MIFLAGS "-i=mi" standard_testfile var-cmd.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } # Just change the output binary. set binfile_bis [standard_output_file mi-var-invalidate_bis] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile_bis}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } set testfile2 "basics" set srcfile2 ${testfile2}.c set binfile2 [standard_output_file ${testfile2}] if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp b/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp index 42495401702c..366e15aa676c 100644 --- a/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp +++ b/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp @@ -21,11 +21,11 @@ set MIFLAGS "-i=mi" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-rtti.exp b/gdb/testsuite/gdb.mi/mi-var-rtti.exp index b254de20c1e9..9a98e2adfa9c 100644 --- a/gdb/testsuite/gdb.mi/mi-var-rtti.exp +++ b/gdb/testsuite/gdb.mi/mi-var-rtti.exp @@ -20,11 +20,11 @@ set MIFLAGS "-i=mi" standard_testfile .cc set opts {debug c++} if {[build_executable $testfile.exp $testfile $srcfile $opts]} { - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp b/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp index 856a1a370080..7f972ea6ea6a 100644 --- a/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp +++ b/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp @@ -31,11 +31,11 @@ proc mi_nonstop_resume { command test } { # Start here # standard_testfile watch-nonstop.c if {[gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable {debug}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" mi_clean_restart $::testfile diff --git a/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp b/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp index 16a45d00265f..fcea890d78af 100644 --- a/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp +++ b/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp @@ -26,11 +26,11 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if {[build_executable ${testfile}.exp ${binfile} ${srcfile} $opts]} { - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi2-cli-display.exp b/gdb/testsuite/gdb.mi/mi2-cli-display.exp index 263568c39665..f339f3fbebf5 100644 --- a/gdb/testsuite/gdb.mi/mi2-cli-display.exp +++ b/gdb/testsuite/gdb.mi/mi2-cli-display.exp @@ -20,11 +20,11 @@ set MIFLAGS "-i=mi2" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi2-var-child.exp b/gdb/testsuite/gdb.mi/mi2-var-child.exp index e5b4adada38d..def9faf36d5b 100644 --- a/gdb/testsuite/gdb.mi/mi2-var-child.exp +++ b/gdb/testsuite/gdb.mi/mi2-var-child.exp @@ -24,11 +24,11 @@ set MIFLAGS "-i=mi2" standard_testfile var-cmd.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/new-ui-bp-deleted.exp b/gdb/testsuite/gdb.mi/new-ui-bp-deleted.exp index ea81a9ab2f6b..910dd2636847 100644 --- a/gdb/testsuite/gdb.mi/new-ui-bp-deleted.exp +++ b/gdb/testsuite/gdb.mi/new-ui-bp-deleted.exp @@ -29,11 +29,11 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile] } { - return -1 + return } # Helper proc to create a breakpoint location regexp. NUM is the # regexp to match the number field of this location. proc make_bp_loc { num } { diff --git a/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp b/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp index 915f40571e15..fe679b09f976 100644 --- a/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp +++ b/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp @@ -27,11 +27,11 @@ load_lib mi-support.exp standard_testfile if {[build_executable $testfile.exp $testfile ${srcfile} "debug"] == -1} { untested "failed to compile" - return -1 + return } # The test driver. SYNC_COMMAND specifies which command is used to # synchronously start the program running. diff --git a/gdb/testsuite/gdb.mi/print-simple-values.exp b/gdb/testsuite/gdb.mi/print-simple-values.exp index 4de81c4cbd4c..875da82ff7cc 100644 --- a/gdb/testsuite/gdb.mi/print-simple-values.exp +++ b/gdb/testsuite/gdb.mi/print-simple-values.exp @@ -29,11 +29,11 @@ set opts {} lappend opts debug lappend opts c++ lappend opts additional_flags=-std=c++11 if {[build_executable "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/user-selected-context-sync.exp b/gdb/testsuite/gdb.mi/user-selected-context-sync.exp index 844206f75116..fea284b70125 100644 --- a/gdb/testsuite/gdb.mi/user-selected-context-sync.exp +++ b/gdb/testsuite/gdb.mi/user-selected-context-sync.exp @@ -43,11 +43,11 @@ require !use_gdb_stub require allow_multi_inferior_tests set compile_options "debug pthreads" if {[build_executable $testfile.exp $testfile ${srcfile} ${compile_options}] == -1} { untested "failed to compile" - return -1 + return } set main_break_line [gdb_get_line_number "main break line"] set thread_loop_line [gdb_get_line_number "thread loop line"] set thread_caller_line [gdb_get_line_number "thread caller line"] From patchwork Wed Apr 29 23:04:18 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134228 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 194574BA902B for ; Wed, 29 Apr 2026 23:14:49 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 194574BA902B Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=RM2K/PIC X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa32.google.com (mail-vk1-xa32.google.com [IPv6:2607:f8b0:4864:20::a32]) by sourceware.org (Postfix) with ESMTPS id 00EB44BB3BE6 for ; Wed, 29 Apr 2026 23:06:14 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 00EB44BB3BE6 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 00EB44BB3BE6 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a32 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503975; cv=none; b=MEyOXG8mW/T/FucrE9r68O0w0uSV4GPRXudMDbZ+JleU+Yl/MwXm4iTOs6pda5Bok60GIYDRSARAbTsTpnmK2p8EY4fxY/4q9dART0N/epNSqm43p/cod4Cge1IFoHz8KzkS08pp3fzC6E2Zjc9CfbpOWgIp23rSfZTwuXfApPE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503975; c=relaxed/simple; bh=CIHXanMm/Q3+b/NJSbBbII6jgRaAmbpl3RLMS8Ys6js=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=BRQHp7J4XE2z9UbVz7T3EEBxmByPoD/2UwUQfTgSJkHsgUX8+cmd+PWV5JaZaQ5LrQfhhMAMp2UyHRPiFg9YxYlHtnk4FIboxKjh9tnm+hdlv33V+YaXdHDw3PfnjsLnynHlZ6jgSTouS7oM8C2GuTEvlGypzq75lpTfmiIGsI8= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 00EB44BB3BE6 Received: by mail-vk1-xa32.google.com with SMTP id 71dfb90a1353d-56f3e6bbecdso115436e0c.2 for ; Wed, 29 Apr 2026 16:06:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503974; x=1778108774; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=zDUhLHGhcrNwNPeS5umgxDM640tY5ZdJIyvmDvjI8oE=; b=RM2K/PICNnrEWei/gJtuisNU8xN9+DIFAy3qDazrEtZaHVvC0PFUkaeZoqi/GDrSft 4ivQAtjinZtf+8qd2UbF+zLijes+/4cGer75gTiSMJxZL5fWhBjH2qoYIRpTl16iHvC6 SmIL7CsYqGXwZ6SqBtiHOjbX4t8VOD4OsZKXwgCz/lQeD1nJGxmPBknhfS3GDV2JtXwK TgA5p0YLqxJAaO7iRhTsmvO1XSAshNQxyyQB35l+NLvdOQsPtP8UiNIkFDIFQtO5KIVa vrXDJxmwUxhWj5n4lABTcr8duEtzrpTFWFqLK37tPveCzgncH8Iwkb9kBddrf3Lc47kG bq3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503974; x=1778108774; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=zDUhLHGhcrNwNPeS5umgxDM640tY5ZdJIyvmDvjI8oE=; b=VcveHh5qQkH96VMnIgnnb0e1qJk3hL/c799MmVzBeajMqKzwOw5yeOmw97xgncSfLH zFzOKP8SjKUl/7M9w2b6jx8A0Jh0Ikn2WAr2JFzASilz8qzl8knQlbhNWdsoRm/dS1NK expsND4RU80Zb1H1Jk3mssVV6Ddwu4Oc0yqCSjkzCFfEFyXH/WiBm22I5P17QkXqeUeE 2CTAnKEo2NHotHfeTyR5GddFnTQ2PtqwMoxOZPftpjvcyRdXT1CDWoDGvphD25+wefeI h/piNtSwrBcTAIG9dL5nKwH/qpZ2QyNKv7MQ5tAtGpfmE/hONAzvmFGN5/az8m3B52E6 HcEA== X-Gm-Message-State: AOJu0YxkpASKm1eWQzSZ8qV3vtIf2lOrnEvTRREfXxaymt2rgpLFbvIb WYE5P958S3qaLk/lZtSa6BP33APVl/JULPlwj/6uTYhegzZtMSVAe7iY1Tbo1R4yM+nyTH6BJqo 2ccM9 X-Gm-Gg: AeBDieucwmWcDd90r69KRiaz0Ap9jX0Aba/XdmKc4ZgfK10Am0qEvOj95Gpk3dRnl2M a8X1v9CgYEB06Fa7Z7V84E9HVhWfUn5NKtyhc7fg72Fh/wdovdDYCt2dNixcNyEOlMobTEJGf1Y W5c0ldcCM/Q2QTd/pQVYsPBCxqlPLL74qOKSAXy8zmdjdCDUeYm1iiOAjlYKkDYyFelCGmXKehs NVpxdTX3RjMHFKNZOVas0Bs11kGhX6HHO0NoDPYTg+FVZ2zQqFkP98guJpl5pAD6tenCMjZMp9s Tkf2KXEBGB3wBKQahnWOeTBn8SnkZRSZwnoYCqEDOEtVmmLIPpFinQlkVyw+Xkz+ruR2SRfF91x MGjoNETyVgM/8lLxIpkGjp8UXsy8938O+5XHRnXvnFoze2sDPl8XddawGqRgr6hPEuOt9nMZEDJ vFth/Enmb1ceoRHLleGJNXvt96Ml8doW5f+mDL69Kx49ocdGz9aCYO+Cw= X-Received: by 2002:a05:6122:4084:b0:56e:e33f:2ffd with SMTP id 71dfb90a1353d-573c972378emr90023e0c.14.1777503974030; Wed, 29 Apr 2026 16:06:14 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6b7d4eesm2097539e0c.2.2026.04.29.16.06.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:13 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 27/37] GDB: testsuite: MI: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:18 -0300 Message-ID: <20260429230432.60487-28-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" statements that weren't caught by the sed command. It also changes a couple of "return 0" statements. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside block such as with_test_prefix, foreach_with_prefix, gdb_expect. --- gdb/testsuite/gdb.mi/gdb2549.exp | 4 ++-- gdb/testsuite/gdb.mi/gdb701.exp | 4 ++-- gdb/testsuite/gdb.mi/gdb792.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-async-run.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-async.exp | 6 +++--- gdb/testsuite/gdb.mi/mi-basics.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-break-qualified.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-break.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-cli.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-complete.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-console.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-corefile.exp | 2 +- gdb/testsuite/gdb.mi/mi-detach.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-disassemble.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-eval.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-exec-run.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-file.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-fill-memory.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-frame-regs.exp | 4 ++-- .../gdb.mi/mi-inheritance-syntax-error.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-pending.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-read-memory.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-reg-undefined.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-regs.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-return.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-reverse.exp | 6 +++--- gdb/testsuite/gdb.mi/mi-simplerun.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-solib.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-stack.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-start.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-stepi.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-syn-frame.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-until.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-var-cmd.exp | 2 +- gdb/testsuite/gdb.mi/mi-var-cp.exp | 6 +++--- gdb/testsuite/gdb.mi/mi-var-rtti.exp | 2 +- gdb/testsuite/gdb.mi/mi-vla-c99.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-vla-fortran.exp | 4 ++-- gdb/testsuite/gdb.mi/mi-watch.exp | 4 ++-- gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp | 14 +++++++------- 41 files changed, 87 insertions(+), 87 deletions(-) diff --git a/gdb/testsuite/gdb.mi/gdb2549.exp b/gdb/testsuite/gdb.mi/gdb2549.exp index c644e3bd1d32..570e1bdeb4a9 100644 --- a/gdb/testsuite/gdb.mi/gdb2549.exp +++ b/gdb/testsuite/gdb.mi/gdb2549.exp @@ -26,12 +26,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc register_tests_no_exec { } { # Test the generic IDT chip. mi_gdb_test "111-data-list-register-values" \ diff --git a/gdb/testsuite/gdb.mi/gdb701.exp b/gdb/testsuite/gdb.mi/gdb701.exp index d72bd1ae81bf..dd6fd6181b2c 100644 --- a/gdb/testsuite/gdb.mi/gdb701.exp +++ b/gdb/testsuite/gdb.mi/gdb701.exp @@ -21,12 +21,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable debug] != ""} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # When varobj reports the types of objects, it often isn't really reporting # the type as GDB knows it. For example, in this testcase, we have a # structure which has been typedefed. A varobj of this type would really have diff --git a/gdb/testsuite/gdb.mi/gdb792.exp b/gdb/testsuite/gdb.mi/gdb792.exp index e2df8216956a..d0b7a97f02de 100644 --- a/gdb/testsuite/gdb.mi/gdb792.exp +++ b/gdb/testsuite/gdb.mi/gdb792.exp @@ -22,12 +22,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile .cc if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != ""} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-async-run.exp b/gdb/testsuite/gdb.mi/mi-async-run.exp index 5a4077b6d198..a60a85393225 100644 --- a/gdb/testsuite/gdb.mi/mi-async-run.exp +++ b/gdb/testsuite/gdb.mi/mi-async-run.exp @@ -16,12 +16,12 @@ load_lib mi-support.exp standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # Test the resolution of PR 18077 # # When doing an -exec-run with a fresh copy of GDB, it would result in diff --git a/gdb/testsuite/gdb.mi/mi-async.exp b/gdb/testsuite/gdb.mi/mi-async.exp index d1674cdfe49f..7f7603cf7068 100644 --- a/gdb/testsuite/gdb.mi/mi-async.exp +++ b/gdb/testsuite/gdb.mi/mi-async.exp @@ -21,23 +21,23 @@ # mi_run_cmd, it ignores whatever target the rest of GDB testsuite is # using, and always tries to run natively. So, don't do anything unless # we're actually testing native. require isnative if {![istarget *-linux*]} { - return + return } # Check if start command is supported. require !use_gdb_stub load_lib mi-support.exp standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # The plan is for async mode to become the default but toggle for now. save_vars { GDBFLAGS } { set GDBFLAGS [concat $GDBFLAGS " -ex \"set mi-async on\""] diff --git a/gdb/testsuite/gdb.mi/mi-basics.exp b/gdb/testsuite/gdb.mi/mi-basics.exp index 27ac334e4a30..8f18f41af04b 100644 --- a/gdb/testsuite/gdb.mi/mi-basics.exp +++ b/gdb/testsuite/gdb.mi/mi-basics.exp @@ -35,12 +35,12 @@ standard_testfile basics.c set escapedobjdir [string_to_regexp ${objdir}] set testsubdir [standard_output_file ""] set envirodir [string_to_regexp $testsubdir] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # In this file we want to test if the operations needed by the following # procedures work, so it makes no sense using them here. diff --git a/gdb/testsuite/gdb.mi/mi-break-qualified.exp b/gdb/testsuite/gdb.mi/mi-break-qualified.exp index 1bb8258b9536..d196c37ef78b 100644 --- a/gdb/testsuite/gdb.mi/mi-break-qualified.exp +++ b/gdb/testsuite/gdb.mi/mi-break-qualified.exp @@ -22,12 +22,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile .cc if {[build_executable $testfile.exp $testfile $srcfile {c++ debug}] == -1} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } set loc_ns_func_line [gdb_get_line_number "location NS::func here"] set loc_foo_func_line [gdb_get_line_number "location foo::func here"] set loc_func_line [gdb_get_line_number "location func here"] diff --git a/gdb/testsuite/gdb.mi/mi-break.exp b/gdb/testsuite/gdb.mi/mi-break.exp index a7b64faa8a5a..b0df2cedc4e5 100644 --- a/gdb/testsuite/gdb.mi/mi-break.exp +++ b/gdb/testsuite/gdb.mi/mi-break.exp @@ -24,12 +24,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # Locate line numbers in basics.c. set line_callee4_head [gdb_get_line_number "callee4 ("] set line_callee4_body [expr {$line_callee4_head + 2}] diff --git a/gdb/testsuite/gdb.mi/mi-cli.exp b/gdb/testsuite/gdb.mi/mi-cli.exp index e3a5d3b87a25..9d696e4b291c 100644 --- a/gdb/testsuite/gdb.mi/mi-cli.exp +++ b/gdb/testsuite/gdb.mi/mi-cli.exp @@ -23,12 +23,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_gdb_test "-interpreter-exec" \ diff --git a/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp b/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp index 29c44c8475c3..9d43fc6e21c0 100644 --- a/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp @@ -20,12 +20,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc test_command_param_changed { } { global scheduler_locking_supported global binfile diff --git a/gdb/testsuite/gdb.mi/mi-complete.exp b/gdb/testsuite/gdb.mi/mi-complete.exp index 4038ae57f8ac..54084cab86d3 100644 --- a/gdb/testsuite/gdb.mi/mi-complete.exp +++ b/gdb/testsuite/gdb.mi/mi-complete.exp @@ -20,12 +20,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile .cc if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile # Don't run to main to avoid increasing the search scope to include diff --git a/gdb/testsuite/gdb.mi/mi-console.exp b/gdb/testsuite/gdb.mi/mi-console.exp index a7a083a56766..23ae1a280997 100644 --- a/gdb/testsuite/gdb.mi/mi-console.exp +++ b/gdb/testsuite/gdb.mi/mi-console.exp @@ -47,12 +47,12 @@ proc semihosted_string { string } { } standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-corefile.exp b/gdb/testsuite/gdb.mi/mi-corefile.exp index 67c6183f3867..864c8f74ddcf 100644 --- a/gdb/testsuite/gdb.mi/mi-corefile.exp +++ b/gdb/testsuite/gdb.mi/mi-corefile.exp @@ -28,11 +28,11 @@ if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { } set corefile [core_find $binfile {}] if {$corefile == ""} { untested "unable to create or find corefile" - return 0 + return } if {[mi_gdb_start]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-detach.exp b/gdb/testsuite/gdb.mi/mi-detach.exp index 62bd699ea8ac..e82e216315e7 100644 --- a/gdb/testsuite/gdb.mi/mi-detach.exp +++ b/gdb/testsuite/gdb.mi/mi-detach.exp @@ -19,12 +19,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if {[build_executable $testfile.exp $testfile $srcfile {debug}] == -1} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-disassemble.exp b/gdb/testsuite/gdb.mi/mi-disassemble.exp index cd4c91bd06a6..2ecbce193c75 100644 --- a/gdb/testsuite/gdb.mi/mi-disassemble.exp +++ b/gdb/testsuite/gdb.mi/mi-disassemble.exp @@ -24,12 +24,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc test_disassembly_only {} { global mi_gdb_prompt global hex diff --git a/gdb/testsuite/gdb.mi/mi-eval.exp b/gdb/testsuite/gdb.mi/mi-eval.exp index 6720f878538a..f2761f46219b 100644 --- a/gdb/testsuite/gdb.mi/mi-eval.exp +++ b/gdb/testsuite/gdb.mi/mi-eval.exp @@ -26,12 +26,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-exec-run.exp b/gdb/testsuite/gdb.mi/mi-exec-run.exp index 9707504aa21c..d7a680daa6c6 100644 --- a/gdb/testsuite/gdb.mi/mi-exec-run.exp +++ b/gdb/testsuite/gdb.mi/mi-exec-run.exp @@ -33,12 +33,12 @@ require !use_gdb_stub set have_startup_shell [have_startup_shell] standard_testfile mi-start.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "could not build mi-exec-run" - return -1 + untested "could not build mi-exec-run" + return } # The test proper. INFTTY_MODE determines whether "set inferior-tty" # is in effect. MI_MODE determines whether MI is run on the main UI, # or as a separate UI. FORCE_FAIL is true when we want -exec-run to diff --git a/gdb/testsuite/gdb.mi/mi-file.exp b/gdb/testsuite/gdb.mi/mi-file.exp index 8ca0511f55d8..80411b82ff74 100644 --- a/gdb/testsuite/gdb.mi/mi-file.exp +++ b/gdb/testsuite/gdb.mi/mi-file.exp @@ -19,12 +19,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-fill-memory.exp b/gdb/testsuite/gdb.mi/mi-fill-memory.exp index 524732bebbd6..f9bd13209822 100644 --- a/gdb/testsuite/gdb.mi/mi-fill-memory.exp +++ b/gdb/testsuite/gdb.mi/mi-fill-memory.exp @@ -21,12 +21,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile "mi-read-memory" if { [gdb_compile "${srcdir}/${subdir}/${srcfile}.c" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_runto_main mi_next_to "main" "" "mi-read-memory.c" "20" "next at main" diff --git a/gdb/testsuite/gdb.mi/mi-frame-regs.exp b/gdb/testsuite/gdb.mi/mi-frame-regs.exp index 65e3bd93d4a4..dbcda5ef7551 100644 --- a/gdb/testsuite/gdb.mi/mi-frame-regs.exp +++ b/gdb/testsuite/gdb.mi/mi-frame-regs.exp @@ -24,12 +24,12 @@ set MIFLAGS "-i=mi" standard_testfile basics.c if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug}] != "" } then { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # Return the address of the specified breakpoint. proc breakpoint_address {bpnum} { diff --git a/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp b/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp index d9baa7639525..17ed3f1dcefd 100644 --- a/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp +++ b/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp @@ -19,12 +19,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile .cc if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != ""} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-pending.exp b/gdb/testsuite/gdb.mi/mi-pending.exp index 1ad9aecdc8b4..51be357d4c0a 100644 --- a/gdb/testsuite/gdb.mi/mi-pending.exp +++ b/gdb/testsuite/gdb.mi/mi-pending.exp @@ -139,12 +139,12 @@ mi_send_resuming_command "exec-continue" "continuing execution to thread conditi # Check if we stopped in thread 2 like we should. set testname "run till MI pending breakpoint on pendfunc3 on thread 2" gdb_expect { -re "\\*stopped,reason=\"breakpoint-hit\",disp=\"keep\",bkptno=\"4\",frame=\{addr=\"$hex\",func=\"pendfunc3\".*thread-id=\"2\".*" { pass $testname - return 0 + return } timeout { fail "$testname (timeout)" - return -1 + return } } diff --git a/gdb/testsuite/gdb.mi/mi-read-memory.exp b/gdb/testsuite/gdb.mi/mi-read-memory.exp index 782c0ee13dca..035c31e2ae84 100644 --- a/gdb/testsuite/gdb.mi/mi-read-memory.exp +++ b/gdb/testsuite/gdb.mi/mi-read-memory.exp @@ -19,12 +19,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-reg-undefined.exp b/gdb/testsuite/gdb.mi/mi-reg-undefined.exp index dd7b2961b03f..725925d01a81 100644 --- a/gdb/testsuite/gdb.mi/mi-reg-undefined.exp +++ b/gdb/testsuite/gdb.mi/mi-reg-undefined.exp @@ -23,12 +23,12 @@ require dwarf2_support require is_x86_64_m64_target standard_testfile .S if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug nopie}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-regs.exp b/gdb/testsuite/gdb.mi/mi-regs.exp index 7aa4fb62c7ac..756855d9ded0 100644 --- a/gdb/testsuite/gdb.mi/mi-regs.exp +++ b/gdb/testsuite/gdb.mi/mi-regs.exp @@ -26,12 +26,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc sparc_register_tests_no_exec { } { # Test the generic IDT chip. mi_gdb_test "111-data-list-register-values" \ diff --git a/gdb/testsuite/gdb.mi/mi-return.exp b/gdb/testsuite/gdb.mi/mi-return.exp index bd90ac79893f..c9265c80317a 100644 --- a/gdb/testsuite/gdb.mi/mi-return.exp +++ b/gdb/testsuite/gdb.mi/mi-return.exp @@ -25,12 +25,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-reverse.exp b/gdb/testsuite/gdb.mi/mi-reverse.exp index 100857c6e299..dacb86048f60 100644 --- a/gdb/testsuite/gdb.mi/mi-reverse.exp +++ b/gdb/testsuite/gdb.mi/mi-reverse.exp @@ -33,12 +33,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_runto_main @@ -46,11 +46,11 @@ if {[supports_process_record]} { # Activate process record/replay if {[mi_gdb_test "-interpreter-exec console record" \ "=record-started,thread-group=\"i1\",method=\"full\"\r\n\\^done" \ "Turn on process record"]} { warning "Fail to activate process record/replay, tests in this group will not be performed.\n" - return -1 + return } } # Locate line numbers in basics.c. set line_callee4_head [gdb_get_line_number "callee4 ("] diff --git a/gdb/testsuite/gdb.mi/mi-simplerun.exp b/gdb/testsuite/gdb.mi/mi-simplerun.exp index 8f18a63e46cc..98bc3da89191 100644 --- a/gdb/testsuite/gdb.mi/mi-simplerun.exp +++ b/gdb/testsuite/gdb.mi/mi-simplerun.exp @@ -28,12 +28,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-solib.exp b/gdb/testsuite/gdb.mi/mi-solib.exp index 0a13df407a09..a3c4d20b0004 100644 --- a/gdb/testsuite/gdb.mi/mi-solib.exp +++ b/gdb/testsuite/gdb.mi/mi-solib.exp @@ -28,12 +28,12 @@ set lib_flags [list debug] set srcfile_main ${srcdir}/${subdir}/$srcfile set bin_flags [list debug shlib=${binfile_lib}] if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib} $lib_flags] != "" || [gdb_compile ${srcfile_main} ${binfile} executable $bin_flags] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-stack.exp b/gdb/testsuite/gdb.mi/mi-stack.exp index 2b7884076da1..fbfc0619d008 100644 --- a/gdb/testsuite/gdb.mi/mi-stack.exp +++ b/gdb/testsuite/gdb.mi/mi-stack.exp @@ -26,12 +26,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-start.exp b/gdb/testsuite/gdb.mi/mi-start.exp index 5a232f0e6cd4..ff18866987f0 100644 --- a/gdb/testsuite/gdb.mi/mi-start.exp +++ b/gdb/testsuite/gdb.mi/mi-start.exp @@ -22,12 +22,12 @@ set MIFLAGS "-i=mi" require !use_gdb_stub standard_testfile mi-start.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "could not build mi-start" - return -1 + untested "could not build mi-start" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-stepi.exp b/gdb/testsuite/gdb.mi/mi-stepi.exp index fe8854a79050..8b9ca60ac434 100644 --- a/gdb/testsuite/gdb.mi/mi-stepi.exp +++ b/gdb/testsuite/gdb.mi/mi-stepi.exp @@ -24,12 +24,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc test_stepi_nexti {} { global mi_gdb_prompt global hex fullname_syntax srcfile diff --git a/gdb/testsuite/gdb.mi/mi-syn-frame.exp b/gdb/testsuite/gdb.mi/mi-syn-frame.exp index 410849a910a5..f3b1a71ccb3c 100644 --- a/gdb/testsuite/gdb.mi/mi-syn-frame.exp +++ b/gdb/testsuite/gdb.mi/mi-syn-frame.exp @@ -23,12 +23,12 @@ set MIFLAGS "-i=mi" set any "\[^\"\]+" standard_testfile if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-until.exp b/gdb/testsuite/gdb.mi/mi-until.exp index a84a1238ae45..f508ce292e1f 100644 --- a/gdb/testsuite/gdb.mi/mi-until.exp +++ b/gdb/testsuite/gdb.mi/mi-until.exp @@ -25,12 +25,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile until.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-cmd.exp b/gdb/testsuite/gdb.mi/mi-var-cmd.exp index bf207dad255e..a08528002cb1 100644 --- a/gdb/testsuite/gdb.mi/mi-var-cmd.exp +++ b/gdb/testsuite/gdb.mi/mi-var-cmd.exp @@ -590,11 +590,11 @@ set inline_tests { # Needs to be last, following tests rely on this. lappend inline_tests floating foreach_with_prefix inline_test $inline_tests { if { [mi_run_inline_test $inline_test] < 0 } { - return -1 + return } } # Since the inline test framework does not really work with # function calls, first to inline tests and then do the remainder diff --git a/gdb/testsuite/gdb.mi/mi-var-cp.exp b/gdb/testsuite/gdb.mi/mi-var-cp.exp index db9efd67fd3d..fb850ad51db5 100644 --- a/gdb/testsuite/gdb.mi/mi-var-cp.exp +++ b/gdb/testsuite/gdb.mi/mi-var-cp.exp @@ -19,12 +19,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile .cc if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != ""} { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } @@ -39,11 +39,11 @@ set inline_tests { path_expression } foreach_with_prefix inline_test $inline_tests { if { [mi_run_inline_test $inline_test] < 0 } { - return -1 + return } } set lineno [gdb_get_line_number "/* anonymous_structs_and_unions */"] mi_create_breakpoint "$srcfile:$lineno" \ diff --git a/gdb/testsuite/gdb.mi/mi-var-rtti.exp b/gdb/testsuite/gdb.mi/mi-var-rtti.exp index 9a98e2adfa9c..4a1bee241f9f 100644 --- a/gdb/testsuite/gdb.mi/mi-var-rtti.exp +++ b/gdb/testsuite/gdb.mi/mi-var-rtti.exp @@ -116,10 +116,10 @@ set inline_tests { skip_type_update_when_not_use_rtti } foreach_with_prefix inline_test $inline_tests { if { [mi_run_inline_test $inline_test] < 0 } { - return -1 + return } } mi_gdb_exit diff --git a/gdb/testsuite/gdb.mi/mi-vla-c99.exp b/gdb/testsuite/gdb.mi/mi-vla-c99.exp index 91934de2491d..5e3c8f549407 100644 --- a/gdb/testsuite/gdb.mi/mi-vla-c99.exp +++ b/gdb/testsuite/gdb.mi/mi-vla-c99.exp @@ -23,12 +23,12 @@ set MIFLAGS "-i=mi" standard_testfile vla.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" \ "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-vla-fortran.exp b/gdb/testsuite/gdb.mi/mi-vla-fortran.exp index fd144cb51e7a..0cc51a36f5ef 100644 --- a/gdb/testsuite/gdb.mi/mi-vla-fortran.exp +++ b/gdb/testsuite/gdb.mi/mi-vla-fortran.exp @@ -24,12 +24,12 @@ set MIFLAGS "-i=mi" standard_testfile vla.f90 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ {debug f90}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } # Depending on the compiler being used, # the type names can be printed differently. set real [fortran_real4] diff --git a/gdb/testsuite/gdb.mi/mi-watch.exp b/gdb/testsuite/gdb.mi/mi-watch.exp index 4fcba501224c..5b01793aa3da 100644 --- a/gdb/testsuite/gdb.mi/mi-watch.exp +++ b/gdb/testsuite/gdb.mi/mi-watch.exp @@ -32,12 +32,12 @@ load_lib mi-support.exp set MIFLAGS "-i=mi" standard_testfile basics.c if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } proc test_watchpoint_creation_and_listing {} { global mi_gdb_prompt global srcfile diff --git a/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp b/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp index fcea890d78af..adcd713453c6 100644 --- a/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp +++ b/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp @@ -42,11 +42,11 @@ foreach name {different breakhere_different breakhere_validity breakhere_invalid # Test various kinds of `set print entry-values'. with_test_prefix "entry-values=no" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values no" {\^done} "no: set print entry-values" mi_send_resuming_command "exec-continue" "no: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val",value="5"}} .* .* {.* disp="keep"} "no: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val",arg="1",value="5"}\]} "no: entry_equal: -stack-list-variables" @@ -61,11 +61,11 @@ with_test_prefix "entry-values=no" { mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="inv",arg="1",value=""}\]} "no: invalid: -stack-list-variables" } with_test_prefix "entry-values=only" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values only" {\^done} "only: set print entry-values" mi_send_resuming_command "exec-continue" "only: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val@entry",value="5"}} .* .* {.* disp="keep"} "only: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val@entry",arg="1",value="5"}\]} "only: entry_equal: -stack-list-variables" @@ -80,11 +80,11 @@ with_test_prefix "entry-values=only" { mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="inv@entry",arg="1",value=""}\]} "only: invalid: -stack-list-variables" } with_test_prefix "entry-values=preferred" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values preferred" {\^done} "preferred: set print entry-values" mi_send_resuming_command "exec-continue" "preferred: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val@entry",value="5"}} .* .* {.* disp="keep"} "preferred: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val@entry",arg="1",value="5"}\]} "preferred: entry_equal: -stack-list-variables" @@ -99,11 +99,11 @@ with_test_prefix "entry-values=preferred" { mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="inv@entry",arg="1",value=""}\]} "preferred: invalid: -stack-list-variables" } with_test_prefix "entry-values=if-needed" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values if-needed" {\^done} "if-needed: set print entry-values" mi_send_resuming_command "exec-continue" "if-needed: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val",value="5"}} .* .* {.* disp="keep"} "if-needed: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val",arg="1",value="5"}\]} "if-needed: entry_equal: -stack-list-variables" @@ -118,11 +118,11 @@ with_test_prefix "entry-values=if-needed" { mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="inv",arg="1",value=""}\]} "if-needed: invalid: -stack-list-variables" } with_test_prefix "entry-values=both" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values both" {\^done} "both: set print entry-values" mi_send_resuming_command "exec-continue" "both: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val",value="5"},{name="val@entry",value="5"}} .* .* {.* disp="keep"} "both: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val",arg="1",value="5"},{name="val@entry",arg="1",value="5"}\]} "both: entry_equal: -stack-list-variables" @@ -137,11 +137,11 @@ with_test_prefix "entry-values=both" { mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="inv",arg="1",value=""},{name="inv@entry",arg="1",value=""}\]} "both: invalid: -stack-list-variables" } with_test_prefix "entry-values=compact" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values compact" {\^done} "compact: set print entry-values" mi_send_resuming_command "exec-continue" "compact: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val",value="5"},{name="val@entry",value="5"}} .* .* {.* disp="keep"} "compact: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val",arg="1",value="5"},{name="val@entry",arg="1",value="5"}\]} "compact: entry_equal: -stack-list-variables" @@ -156,11 +156,11 @@ with_test_prefix "entry-values=compact" { mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="inv",arg="1",value=""}\]} "compact: invalid: -stack-list-variables" } with_test_prefix "entry-values=default" { if {[mi_runto_main] == -1} { - return -1 + return } mi_gdb_test "-gdb-set print entry-values default" {\^done} "default: set print entry-values" mi_send_resuming_command "exec-continue" "default: entry_equal: continue" mi_expect_stop "breakpoint-hit" .* {{name="val",value="5"},{name="val@entry",value="5"}} .* .* {.* disp="keep"} "default: entry_equal: stop" mi_gdb_test "-stack-list-variables --all-values" {\^done,variables=\[{name="val",arg="1",value="5"},{name="val@entry",arg="1",value="5"}\]} "default: entry_equal: -stack-list-variables" From patchwork Wed Apr 29 23:04:19 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134213 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 8AFC74BB3BD0 for ; Wed, 29 Apr 2026 23:08:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8AFC74BB3BD0 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=kbJ0spUn X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x932.google.com (mail-ua1-x932.google.com [IPv6:2607:f8b0:4864:20::932]) by sourceware.org (Postfix) with ESMTPS id 24C4C4358A58 for ; Wed, 29 Apr 2026 23:06:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 24C4C4358A58 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 24C4C4358A58 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::932 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503978; cv=none; b=RLEi8dHjJl6Ryupu3gWEFwr56OwN57dVN1K9eQt2ckIMRNeDeJjSLESqNrllkd3tu96DhaaEjVkH0qsun2e8EJZn5nr2aLDAD+ntUMrgnNFxx3T1UulCSzjkqXU+UJypwHdEMMEw5sfyvh5p2aIUrFIMQUXPUNLa4s5mn+45K4A= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503978; c=relaxed/simple; bh=YPq/Z5Nd6Q2i3Br9ZPZFngVGf//x/HN3vIRjp9n0k3Y=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=p6H2uFP++tjiLDwfDhuMp0PKDdTl0xxveLZau7QB7RncCgRd1023pVosPa4u7MuvAk0lZ2aAXDcqnLaXPjhCiAHEQjFNTQmNKJizFXGH+faJF7LFSh1IuAwJh85mm28ZHUQQpgRUhbgTeiG/4GyY1Df5i/UpFP3ZRynmxZqQ+Lw= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 24C4C4358A58 Received: by mail-ua1-x932.google.com with SMTP id a1e0cc1a2514c-95699e8e26aso97627241.0 for ; Wed, 29 Apr 2026 16:06:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503977; x=1778108777; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=qnGcooOXZl2Jl76ihM695zr+ClwtfasIWqfU1nL7LbM=; b=kbJ0spUnYaVUdJiIn3a8mLYWOExipmcRr2i6D2ydHw5CWtPDfmUYUNl/u5hju9LoG6 lBPyG0D7+cHP+kOQY2RjK7GTjE7v651sNzcORZNw/lMIG/tFZTAAz9H0462iyrnn3NBt JuPAAtGjOavuHTw5row17drLNITZlp44E48+k9iRnJhGn5z296Ke7n8vwFhBsZuJz21i hosMvk0xSYSG5YCth050IajargQQCx/QWS1dpKS4/vrabHbyiX8Mlut8Qvkj9x6C1nkQ 1L8wWpB+u8dIICTxgvQBBKLn69RpsRyBfLxvgZ/wWcLs+DPiHFVsgcWyKedZsGIigMhl LHDA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503977; x=1778108777; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=qnGcooOXZl2Jl76ihM695zr+ClwtfasIWqfU1nL7LbM=; b=qSiZVH+rFk0jA1y5YlyxtC8ulhIlX7Eg3BuBH/CS9wZh++k1KAfQ+hmGfMKJAAlB6Z WO/Nb0CgB+9QehgC3lrBJcIzkeFx9a6dLsIrlWjegrgKsWIqu03b9yW+ylJoMs3E10pG 5bz97JrNMNgOVgHZ9WAg5Sol6kjf6EmK/OIVUgFUbgZPN/kvlbMC8aNspXDPPicjUV4s iXSrzH806BmTYPwAcSTYOap9hcjzJK/2I3/BP66IHdPfLC0AAA6BTFETJiRaILTgU9s9 UJ4SoI2M75kaIhVNciLv6TDZk5gTlVjdZos3m2fHKkBPrOoB4fhcVazJmHW8t4D3j/F8 z4kQ== X-Gm-Message-State: AOJu0YzAObqcFlGDINjBjc0U6bJY9Lm+gIYq/r75ZeJdki0fMsA8IY1b ISY/NG7/5fPhU0/qUZRZwnTC66dI+EEcuK08FQFBMhP4CY4LllKF3GB3xYuS2xqvC2wr90sF4zB /tFe6 X-Gm-Gg: AeBDietLZ8rsVwIUrWevMj6upo8iDVvelJ6IVrIUOGjxD4fzJ03QYymzaDd5XdFRpNz PARHz/7IqAeY5jkLmcAjgG1uBpBMO9nMz0rtNi5KZ/jPsKl0T/8qzFz+vKkGIxfvV961A/Cgo1H HmG+0OvZkyFJrtYHfCzdP3YYLCPrfV4VNMev7Gbsmq9fpQYxf2FmsllZwJ0xVwEcdd/82PpBrIf lcWrCW4SnN/ARuSU6At9ZR0KZ6UCINZgaRYzZE4R9KyiYSEKc8Ci8f0t+FC0LO4RkrswR0efMkw LBK+I5vV+DfTfxZ5EC4qqJzjVF8oScUkU/ZB78b4ZWMwamWVkFtSdv0HY7eZDw8Z9cB9UOlYJTn fn3Fnoft1L7IfivDxxqMXwXYJaWO0CFX1IE7n4tTiMuVWUta+8jUBQ6miT5N8uQ66PT9cO5P4QB 0o0T29MZ0QD4NbwVhHK2mjI6loQ9WKnx956cYRM/VgwAmj X-Received: by 2002:a05:6102:8096:b0:605:8143:cb67 with SMTP id ada2fe7eead31-62ad4b89086mr252875137.20.1777503977134; Wed, 29 Apr 2026 16:06:17 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id ada2fe7eead31-62982136587sm1929800137.2.2026.04.29.16.06.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:16 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 28/37] GDB: testsuite: reverse: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:19 -0300 Message-ID: <20260429230432.60487-29-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.reverse. --- gdb/testsuite/gdb.reverse/aarch64-mops.exp | 4 ++-- gdb/testsuite/gdb.reverse/amd64-tailcall-reverse.exp | 4 ++-- gdb/testsuite/gdb.reverse/basic-record-full.exp | 2 +- gdb/testsuite/gdb.reverse/break-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/break-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/consecutive-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/consecutive-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/finish-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp | 2 +- gdb/testsuite/gdb.reverse/finish-reverse-next.exp | 2 +- gdb/testsuite/gdb.reverse/finish-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/fstatat-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/getrandom.exp | 2 +- gdb/testsuite/gdb.reverse/getresuid-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/i386-avx-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/i386-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/i386-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/i386-sse-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/i387-env-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/i387-stack-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/insn-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/machinestate-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/machinestate.exp | 2 +- gdb/testsuite/gdb.reverse/maint-print-instruction.exp | 2 +- gdb/testsuite/gdb.reverse/map-to-same-line.exp | 4 ++-- gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp | 2 +- gdb/testsuite/gdb.reverse/pipe-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/ppc_record_test_isa_2_06.exp | 2 +- gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp | 2 +- gdb/testsuite/gdb.reverse/readv-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/recursion.exp | 2 +- gdb/testsuite/gdb.reverse/recvmsg-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/rerun-prec.exp | 2 +- gdb/testsuite/gdb.reverse/s390-mvcle.exp | 2 +- gdb/testsuite/gdb.reverse/sigall-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/sigall-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/singlejmp-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/solib-precsave.exp | 6 +++--- gdb/testsuite/gdb.reverse/solib-reverse.exp | 6 +++--- gdb/testsuite/gdb.reverse/step-indirect-call-thunk.exp | 4 ++-- gdb/testsuite/gdb.reverse/step-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/step-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/test_ioctl_TCSETSW.exp | 2 +- gdb/testsuite/gdb.reverse/until-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/until-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/waitpid-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/watch-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/watch-reverse.exp | 2 +- 48 files changed, 56 insertions(+), 56 deletions(-) diff --git a/gdb/testsuite/gdb.reverse/aarch64-mops.exp b/gdb/testsuite/gdb.reverse/aarch64-mops.exp index 14602d4feb8a..97f1efe82994 100644 --- a/gdb/testsuite/gdb.reverse/aarch64-mops.exp +++ b/gdb/testsuite/gdb.reverse/aarch64-mops.exp @@ -35,15 +35,15 @@ require allow_aarch64_mops_tests standard_testfile if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ [list debug additional_flags=-march=armv9.3-a]] } { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test_no_output "record full" foreach_with_prefix insn_prefix {"set" "cpy" "cpyf"} { diff --git a/gdb/testsuite/gdb.reverse/amd64-tailcall-reverse.exp b/gdb/testsuite/gdb.reverse/amd64-tailcall-reverse.exp index 6db4b43ac0a1..c3289fa4c6ff 100644 --- a/gdb/testsuite/gdb.reverse/amd64-tailcall-reverse.exp +++ b/gdb/testsuite/gdb.reverse/amd64-tailcall-reverse.exp @@ -25,15 +25,15 @@ if {[info exists COMPILE]} { } else { require is_x86_64_m64_target } if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $opts] } { - return -1 + return } if {![runto_main]} { - return -1 + return } if {[supports_process_record]} { gdb_test_no_output "record" } diff --git a/gdb/testsuite/gdb.reverse/basic-record-full.exp b/gdb/testsuite/gdb.reverse/basic-record-full.exp index 78d6f4d02af6..67655417db28 100644 --- a/gdb/testsuite/gdb.reverse/basic-record-full.exp +++ b/gdb/testsuite/gdb.reverse/basic-record-full.exp @@ -22,11 +22,11 @@ require supports_process_record standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main gdb_test_no_output "record" "turn on process record" diff --git a/gdb/testsuite/gdb.reverse/break-precsave.exp b/gdb/testsuite/gdb.reverse/break-precsave.exp index bee9fd548f60..994457d4439c 100644 --- a/gdb/testsuite/gdb.reverse/break-precsave.exp +++ b/gdb/testsuite/gdb.reverse/break-precsave.exp @@ -21,11 +21,11 @@ require supports_process_record standard_testfile break-reverse.c set precsave [standard_output_file break.precsave] if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } set foo_location [gdb_get_line_number "break in foo" ] set bar_location [gdb_get_line_number "break in bar" ] set main_location [gdb_get_line_number "break in main"] diff --git a/gdb/testsuite/gdb.reverse/break-reverse.exp b/gdb/testsuite/gdb.reverse/break-reverse.exp index 5aeaf22e6ada..7ba681828d33 100644 --- a/gdb/testsuite/gdb.reverse/break-reverse.exp +++ b/gdb/testsuite/gdb.reverse/break-reverse.exp @@ -19,11 +19,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } set foo_location [gdb_get_line_number "break in foo" ] set bar_location [gdb_get_line_number "break in bar" ] set main_location [gdb_get_line_number "break in main"] diff --git a/gdb/testsuite/gdb.reverse/consecutive-precsave.exp b/gdb/testsuite/gdb.reverse/consecutive-precsave.exp index 7d57661055e9..9a9132d9a4f1 100644 --- a/gdb/testsuite/gdb.reverse/consecutive-precsave.exp +++ b/gdb/testsuite/gdb.reverse/consecutive-precsave.exp @@ -21,11 +21,11 @@ require supports_process_record standard_testfile consecutive-reverse.c set precsave [standard_output_file consecutive.precsave] if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main # Activate process record/replay diff --git a/gdb/testsuite/gdb.reverse/consecutive-reverse.exp b/gdb/testsuite/gdb.reverse/consecutive-reverse.exp index c22cb96504b4..1b44a134cb84 100644 --- a/gdb/testsuite/gdb.reverse/consecutive-reverse.exp +++ b/gdb/testsuite/gdb.reverse/consecutive-reverse.exp @@ -19,11 +19,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/finish-precsave.exp b/gdb/testsuite/gdb.reverse/finish-precsave.exp index 7430b890d545..00c7d8caa419 100644 --- a/gdb/testsuite/gdb.reverse/finish-precsave.exp +++ b/gdb/testsuite/gdb.reverse/finish-precsave.exp @@ -20,11 +20,11 @@ require supports_reverse standard_testfile finish-reverse.c set precsave [standard_output_file finish.precsave] if { [prepare_for_testing "failed to prepare" "$testfile" $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp b/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp index 67df198bb051..19ebebf6a126 100644 --- a/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp +++ b/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp @@ -43,11 +43,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" "$testfile" $srcfile] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.reverse/finish-reverse-next.exp b/gdb/testsuite/gdb.reverse/finish-reverse-next.exp index 325282855c64..96af034af1ef 100644 --- a/gdb/testsuite/gdb.reverse/finish-reverse-next.exp +++ b/gdb/testsuite/gdb.reverse/finish-reverse-next.exp @@ -46,11 +46,11 @@ if {![supports_reverse]} { } standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/finish-reverse.exp b/gdb/testsuite/gdb.reverse/finish-reverse.exp index 3f3ef666323a..b234d7fec143 100644 --- a/gdb/testsuite/gdb.reverse/finish-reverse.exp +++ b/gdb/testsuite/gdb.reverse/finish-reverse.exp @@ -19,11 +19,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" "$testfile" $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/fstatat-reverse.exp b/gdb/testsuite/gdb.reverse/fstatat-reverse.exp index 7ccdcd4ae9e8..4c8dfed07b17 100644 --- a/gdb/testsuite/gdb.reverse/fstatat-reverse.exp +++ b/gdb/testsuite/gdb.reverse/fstatat-reverse.exp @@ -22,11 +22,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/getrandom.exp b/gdb/testsuite/gdb.reverse/getrandom.exp index 410d4ab3bde6..c65de709c4ad 100644 --- a/gdb/testsuite/gdb.reverse/getrandom.exp +++ b/gdb/testsuite/gdb.reverse/getrandom.exp @@ -23,11 +23,11 @@ require supports_reverse require {have_system_header sys/random.h} standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/getresuid-reverse.exp b/gdb/testsuite/gdb.reverse/getresuid-reverse.exp index af8311344bfb..27d10afc4e91 100644 --- a/gdb/testsuite/gdb.reverse/getresuid-reverse.exp +++ b/gdb/testsuite/gdb.reverse/getresuid-reverse.exp @@ -22,11 +22,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/i386-avx-reverse.exp b/gdb/testsuite/gdb.reverse/i386-avx-reverse.exp index bdb76733e959..2268f2c28722 100644 --- a/gdb/testsuite/gdb.reverse/i386-avx-reverse.exp +++ b/gdb/testsuite/gdb.reverse/i386-avx-reverse.exp @@ -39,11 +39,11 @@ standard_testfile set additional_flags [gdb_target_symbol_prefix_flags] lappend_include_file alloc_lib $srcdir/lib/precise-aligned-alloc.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug $additional_flags $alloc_lib]]} { - return -1 + return } # Shorthand to test reversing through one instruction and # testing if a register has the expected value. # Prefix, if included, should end with a colon and space. diff --git a/gdb/testsuite/gdb.reverse/i386-precsave.exp b/gdb/testsuite/gdb.reverse/i386-precsave.exp index 4841c1b65aa2..4bde399bc457 100644 --- a/gdb/testsuite/gdb.reverse/i386-precsave.exp +++ b/gdb/testsuite/gdb.reverse/i386-precsave.exp @@ -28,11 +28,11 @@ set precsave [standard_output_file i386.precsave] # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug $additional_flags]]} { - return -1 + return } set end_of_main [gdb_get_line_number " end of main "] set end_of_inc_dec_tests [gdb_get_line_number " end inc_dec_tests "] diff --git a/gdb/testsuite/gdb.reverse/i386-reverse.exp b/gdb/testsuite/gdb.reverse/i386-reverse.exp index 0d27454d0101..2013a969f8ca 100644 --- a/gdb/testsuite/gdb.reverse/i386-reverse.exp +++ b/gdb/testsuite/gdb.reverse/i386-reverse.exp @@ -26,11 +26,11 @@ standard_testfile # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug $additional_flags]]} { - return -1 + return } set end_of_main [gdb_get_line_number " end of main "] set end_of_inc_dec_tests [gdb_get_line_number " end inc_dec_tests "] diff --git a/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp b/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp index ad8eaeaadc23..dc1308861e2c 100644 --- a/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp +++ b/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp @@ -31,11 +31,11 @@ standard_testfile # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug $additional_flags]]} { - return -1 + return } set end_of_main [gdb_get_line_number " end of main "] set end_sse_test [gdb_get_line_number " end sse_test "] set end_ssse3_test [gdb_get_line_number " end ssse3_test "] diff --git a/gdb/testsuite/gdb.reverse/i387-env-reverse.exp b/gdb/testsuite/gdb.reverse/i387-env-reverse.exp index 5fc6346f86bf..ebf7d8dec425 100644 --- a/gdb/testsuite/gdb.reverse/i387-env-reverse.exp +++ b/gdb/testsuite/gdb.reverse/i387-env-reverse.exp @@ -23,11 +23,11 @@ standard_testfile # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug $additional_flags]]} { - return -1 + return } runto_main # Record to end of main diff --git a/gdb/testsuite/gdb.reverse/i387-stack-reverse.exp b/gdb/testsuite/gdb.reverse/i387-stack-reverse.exp index c6d3cca23424..384faade5eee 100644 --- a/gdb/testsuite/gdb.reverse/i387-stack-reverse.exp +++ b/gdb/testsuite/gdb.reverse/i387-stack-reverse.exp @@ -23,11 +23,11 @@ standard_testfile # some targets have leading underscores on assembly symbols. set additional_flags [gdb_target_symbol_prefix_flags] if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug $additional_flags]]} { - return -1 + return } runto_main # Record to end of main diff --git a/gdb/testsuite/gdb.reverse/insn-reverse.exp b/gdb/testsuite/gdb.reverse/insn-reverse.exp index c92059143ece..5b4f6a28f7af 100644 --- a/gdb/testsuite/gdb.reverse/insn-reverse.exp +++ b/gdb/testsuite/gdb.reverse/insn-reverse.exp @@ -17,11 +17,11 @@ require supports_reverse !use_gdb_stub standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug]]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.reverse/machinestate-precsave.exp b/gdb/testsuite/gdb.reverse/machinestate-precsave.exp index 74c041143d87..8a11c6d24b98 100644 --- a/gdb/testsuite/gdb.reverse/machinestate-precsave.exp +++ b/gdb/testsuite/gdb.reverse/machinestate-precsave.exp @@ -41,11 +41,11 @@ require supports_process_record standard_testfile machinestate.c ms1.c set precsave [standard_output_file machinestate.precsave] if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2]] } { - return -1 + return } set newline "\[\r\n\]+" set beginmain [gdb_get_line_number " begin main " $srcfile] diff --git a/gdb/testsuite/gdb.reverse/machinestate.exp b/gdb/testsuite/gdb.reverse/machinestate.exp index 0026af7704bd..de16fbcbb23a 100644 --- a/gdb/testsuite/gdb.reverse/machinestate.exp +++ b/gdb/testsuite/gdb.reverse/machinestate.exp @@ -39,11 +39,11 @@ require supports_reverse standard_testfile .c ms1.c if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2]] } { - return -1 + return } set newline "\[\r\n\]+" set beginmain [gdb_get_line_number " begin main " $srcfile] diff --git a/gdb/testsuite/gdb.reverse/maint-print-instruction.exp b/gdb/testsuite/gdb.reverse/maint-print-instruction.exp index dc3bb6b547af..ad8009b415a9 100644 --- a/gdb/testsuite/gdb.reverse/maint-print-instruction.exp +++ b/gdb/testsuite/gdb.reverse/maint-print-instruction.exp @@ -28,11 +28,11 @@ if {![supports_reverse]} { } standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } proc test_print { has_history level test_name } { gdb_test_multiple "maint print record-instruction $level" $test_name { -re -wrap ".*Not enough recorded history.*" { diff --git a/gdb/testsuite/gdb.reverse/map-to-same-line.exp b/gdb/testsuite/gdb.reverse/map-to-same-line.exp index 4e3c1a50229b..1cfb060dfaab 100644 --- a/gdb/testsuite/gdb.reverse/map-to-same-line.exp +++ b/gdb/testsuite/gdb.reverse/map-to-same-line.exp @@ -31,11 +31,11 @@ require is_c_compiler_gcc require supports_reverse standard_testfile .c .S if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } set asm_file [standard_output_file $srcfile2] Dwarf::assemble $asm_file { global srcdir subdir srcfile @@ -107,11 +107,11 @@ Dwarf::assemble $asm_file { } } if { [prepare_for_testing "failed to prepare" ${testfile} \ [list $srcfile $asm_file] {nodebug} ] } { - return -1 + return } if { ![runto_main] } { return } diff --git a/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp b/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp index 83162e59dfc6..d34fe130e8e5 100644 --- a/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp +++ b/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp @@ -43,11 +43,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.reverse/pipe-reverse.exp b/gdb/testsuite/gdb.reverse/pipe-reverse.exp index d4b99c91a8e7..67035866af9a 100644 --- a/gdb/testsuite/gdb.reverse/pipe-reverse.exp +++ b/gdb/testsuite/gdb.reverse/pipe-reverse.exp @@ -22,11 +22,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/ppc_record_test_isa_2_06.exp b/gdb/testsuite/gdb.reverse/ppc_record_test_isa_2_06.exp index aa69e5d00c99..6bbe98116385 100644 --- a/gdb/testsuite/gdb.reverse/ppc_record_test_isa_2_06.exp +++ b/gdb/testsuite/gdb.reverse/ppc_record_test_isa_2_06.exp @@ -38,11 +38,11 @@ set executable record_test_isa_2_06 set options [list debug] require {istarget "powerpc*"} if {[build_executable "failed to prepare" $executable $srcfile $options] == -1} { - return -1 + return } clean_restart $executable if {![runto_main]} { diff --git a/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp b/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp index d4ecbbb7fb66..8435d3d840d6 100644 --- a/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp +++ b/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp @@ -39,11 +39,11 @@ set executable record_test_isa_3_1 require {istarget "powerpc*"} allow_power_isa_3_1_tests set options [list additional_flags=-mcpu=power10 debug] if {[build_executable "failed to prepare" $executable $srcfile $options] == -1} { - return -1 + return } clean_restart $executable if {![runto_main]} { diff --git a/gdb/testsuite/gdb.reverse/readv-reverse.exp b/gdb/testsuite/gdb.reverse/readv-reverse.exp index e05e3de351b6..e5467d8051f8 100644 --- a/gdb/testsuite/gdb.reverse/readv-reverse.exp +++ b/gdb/testsuite/gdb.reverse/readv-reverse.exp @@ -22,11 +22,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/recursion.exp b/gdb/testsuite/gdb.reverse/recursion.exp index 6284ebc0c16e..6a81821d62bd 100644 --- a/gdb/testsuite/gdb.reverse/recursion.exp +++ b/gdb/testsuite/gdb.reverse/recursion.exp @@ -19,11 +19,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/recvmsg-reverse.exp b/gdb/testsuite/gdb.reverse/recvmsg-reverse.exp index ce91b59e7edc..3fa433dde569 100644 --- a/gdb/testsuite/gdb.reverse/recvmsg-reverse.exp +++ b/gdb/testsuite/gdb.reverse/recvmsg-reverse.exp @@ -22,11 +22,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/rerun-prec.exp b/gdb/testsuite/gdb.reverse/rerun-prec.exp index aed3c9e52266..a1a41b007561 100644 --- a/gdb/testsuite/gdb.reverse/rerun-prec.exp +++ b/gdb/testsuite/gdb.reverse/rerun-prec.exp @@ -16,11 +16,11 @@ require supports_reverse supports_process_record standard_testfile if {[prepare_for_testing "failed to prepare" $testfile [list $srcfile]]} { - return -1 + return } # The bug is a regression in the sequence "run; record; run". runto_main gdb_test_no_output "record" "turn on process record" diff --git a/gdb/testsuite/gdb.reverse/s390-mvcle.exp b/gdb/testsuite/gdb.reverse/s390-mvcle.exp index 4bb89c678b48..12fd622f08db 100644 --- a/gdb/testsuite/gdb.reverse/s390-mvcle.exp +++ b/gdb/testsuite/gdb.reverse/s390-mvcle.exp @@ -20,11 +20,11 @@ require supports_reverse {istarget "s390*-*-*"} standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/sigall-precsave.exp b/gdb/testsuite/gdb.reverse/sigall-precsave.exp index 2635e6fdcda4..d8bc6dfaccfa 100644 --- a/gdb/testsuite/gdb.reverse/sigall-precsave.exp +++ b/gdb/testsuite/gdb.reverse/sigall-precsave.exp @@ -19,11 +19,11 @@ require supports_reverse standard_testfile sigall-reverse.c set precsave [standard_output_file sigall.precsave] if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } proc test_one_sig {nextsig} { global sig_supported global gdb_prompt diff --git a/gdb/testsuite/gdb.reverse/sigall-reverse.exp b/gdb/testsuite/gdb.reverse/sigall-reverse.exp index 5f0ab640d186..2dae1933d818 100644 --- a/gdb/testsuite/gdb.reverse/sigall-reverse.exp +++ b/gdb/testsuite/gdb.reverse/sigall-reverse.exp @@ -18,11 +18,11 @@ require {!target_info exists gdb,nosignals} require supports_reverse standard_testfile if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } proc test_one_sig {nextsig} { global sig_supported global gdb_prompt diff --git a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp index 00fd8b8bd957..830292cd6669 100644 --- a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp +++ b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp @@ -35,11 +35,11 @@ if {[info exists COMPILE]} { } clean_restart $executable if {![runto_main]} { - return -1 + return } if {[supports_process_record]} { gdb_test_no_output "record" } diff --git a/gdb/testsuite/gdb.reverse/solib-precsave.exp b/gdb/testsuite/gdb.reverse/solib-precsave.exp index 0e0dd3668ac7..ef3229c74927 100644 --- a/gdb/testsuite/gdb.reverse/solib-precsave.exp +++ b/gdb/testsuite/gdb.reverse/solib-precsave.exp @@ -30,16 +30,16 @@ set library2 [standard_output_file ${lib2file}.sl] # Compile the first without debug info so that # stepping and reverse stepping doesn't end up inside them. if { [gdb_compile_shlib ${srcdir}/${subdir}/${lib1src} ${library1} ""] != "" } { untested "failed to compile shared library 1" - return -1 + return } if { [gdb_compile_shlib ${srcdir}/${subdir}/${lib2src} ${library2} "debug"] != "" } { untested "failed to compile shared library 2" - return -1 + return } set exec_opts [list debug shlib=${library1} shlib=${library2}] # Attempt to prevent -Wl,-z,relro which may happen by default with some @@ -48,11 +48,11 @@ set exec_opts [list debug shlib=${library1} shlib=${library2}] if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable \ [concat $exec_opts ldflags=-Wl,-z,norelro]] != "" && [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $exec_opts] != "" } { untested "failed to compile" - return -1 + return } # Note: The test previously did "set debug-file-directory" to (try to) # ensure the debug info for the dynamic loader and libc weren't found. # This doesn't work if the debug info is in the .debug subdirectory. diff --git a/gdb/testsuite/gdb.reverse/solib-reverse.exp b/gdb/testsuite/gdb.reverse/solib-reverse.exp index 04bbf56757cb..c5a610fcb391 100644 --- a/gdb/testsuite/gdb.reverse/solib-reverse.exp +++ b/gdb/testsuite/gdb.reverse/solib-reverse.exp @@ -28,23 +28,23 @@ set library2 [standard_output_file ${lib2file}.sl] # Compile the first without debug info so that # stepping and reverse stepping doesn't end up inside them. if { [gdb_compile_shlib ${srcdir}/${subdir}/${lib1src} ${library1} ""] != "" } { untested "failed to compile shared library 1" - return -1 + return } if { [gdb_compile_shlib ${srcdir}/${subdir}/${lib2src} ${library2} "debug"] != "" } { untested "failed to compile shared library 2" - return -1 + return } set exec_opts [list debug shlib=${library1} shlib=${library2}] if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${binfile} executable $exec_opts] != "" } { untested "failed to compile" - return -1 + return } # Note: The test previously did "set debug-file-directory" to (try to) # ensure the debug info for the dynamic loader and libc weren't found. # This doesn't work if the debug info is in the .debug subdirectory. diff --git a/gdb/testsuite/gdb.reverse/step-indirect-call-thunk.exp b/gdb/testsuite/gdb.reverse/step-indirect-call-thunk.exp index 3b00a2fb0895..feb7a840d8a0 100644 --- a/gdb/testsuite/gdb.reverse/step-indirect-call-thunk.exp +++ b/gdb/testsuite/gdb.reverse/step-indirect-call-thunk.exp @@ -29,15 +29,15 @@ if { [gdb_can_simple_compile fcf-protection-none {int main () { return 0; }} \ executable $fcf_protection_none] } { lappend cflags $fcf_protection_none } if { [prepare_for_testing "failed to prepare" $testfile $srcfile $cflags] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_test_no_output "record" gdb_test "next" ".*" "record trace" diff --git a/gdb/testsuite/gdb.reverse/step-precsave.exp b/gdb/testsuite/gdb.reverse/step-precsave.exp index 33fabd7ec196..761713436771 100644 --- a/gdb/testsuite/gdb.reverse/step-precsave.exp +++ b/gdb/testsuite/gdb.reverse/step-precsave.exp @@ -25,11 +25,11 @@ require supports_process_record standard_testfile step-reverse.c set precsave [standard_output_file step.precsave] if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main # Activate process record/replay diff --git a/gdb/testsuite/gdb.reverse/step-reverse.exp b/gdb/testsuite/gdb.reverse/step-reverse.exp index b14273e8bcf6..d72638c9169b 100644 --- a/gdb/testsuite/gdb.reverse/step-reverse.exp +++ b/gdb/testsuite/gdb.reverse/step-reverse.exp @@ -23,11 +23,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/test_ioctl_TCSETSW.exp b/gdb/testsuite/gdb.reverse/test_ioctl_TCSETSW.exp index c3fb0487d187..17d4369ee4ee 100644 --- a/gdb/testsuite/gdb.reverse/test_ioctl_TCSETSW.exp +++ b/gdb/testsuite/gdb.reverse/test_ioctl_TCSETSW.exp @@ -19,11 +19,11 @@ require supports_process_record standard_testfile .c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } if {![runto_main]} { untested "could not run to main" continue diff --git a/gdb/testsuite/gdb.reverse/until-precsave.exp b/gdb/testsuite/gdb.reverse/until-precsave.exp index a0bed8dfba51..411fc14fed27 100644 --- a/gdb/testsuite/gdb.reverse/until-precsave.exp +++ b/gdb/testsuite/gdb.reverse/until-precsave.exp @@ -22,11 +22,11 @@ require supports_process_record standard_testfile until-reverse.c ur1.c set precsave [standard_output_file until.precsave] if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2]] } { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location7 [gdb_get_line_number "set breakpoint 7 here"] set bp_location8 [gdb_get_line_number "set breakpoint 8 here" "$srcfile2"] diff --git a/gdb/testsuite/gdb.reverse/until-reverse.exp b/gdb/testsuite/gdb.reverse/until-reverse.exp index dc8fcbe78d68..74703223c643 100644 --- a/gdb/testsuite/gdb.reverse/until-reverse.exp +++ b/gdb/testsuite/gdb.reverse/until-reverse.exp @@ -20,11 +20,11 @@ require supports_reverse standard_testfile .c ur1.c if { [prepare_for_testing "failed to prepare" $testfile \ [list $srcfile $srcfile2]] } { - return -1 + return } set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set bp_location7 [gdb_get_line_number "set breakpoint 7 here"] set bp_location8 [gdb_get_line_number "set breakpoint 8 here" "$srcfile2"] diff --git a/gdb/testsuite/gdb.reverse/waitpid-reverse.exp b/gdb/testsuite/gdb.reverse/waitpid-reverse.exp index bc6b32cdc663..dc213259bf0f 100644 --- a/gdb/testsuite/gdb.reverse/waitpid-reverse.exp +++ b/gdb/testsuite/gdb.reverse/waitpid-reverse.exp @@ -24,11 +24,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { diff --git a/gdb/testsuite/gdb.reverse/watch-precsave.exp b/gdb/testsuite/gdb.reverse/watch-precsave.exp index 2cc668fdc6a5..474012f74c73 100644 --- a/gdb/testsuite/gdb.reverse/watch-precsave.exp +++ b/gdb/testsuite/gdb.reverse/watch-precsave.exp @@ -22,11 +22,11 @@ require supports_process_record standard_testfile watch-reverse.c set precsave [standard_output_file watch.precsave] if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main # Activate process record/replay diff --git a/gdb/testsuite/gdb.reverse/watch-reverse.exp b/gdb/testsuite/gdb.reverse/watch-reverse.exp index e165aa084dc7..52b36c6f70ae 100644 --- a/gdb/testsuite/gdb.reverse/watch-reverse.exp +++ b/gdb/testsuite/gdb.reverse/watch-reverse.exp @@ -21,11 +21,11 @@ require supports_reverse standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { - return -1 + return } runto_main if {[supports_process_record]} { From patchwork Wed Apr 29 23:04:20 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134216 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 55A764B920DF for ; Wed, 29 Apr 2026 23:09:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 55A764B920DF Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=XVRdtuPx X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2c.google.com (mail-vk1-xa2c.google.com [IPv6:2607:f8b0:4864:20::a2c]) by sourceware.org (Postfix) with ESMTPS id D0ADE4BB589A for ; Wed, 29 Apr 2026 23:06:20 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org D0ADE4BB589A Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org D0ADE4BB589A Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2c ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503980; cv=none; b=GjPPDgt0jLuAov5fliYwKJgdYs6QSaeau5iiSSfwO1jBQnPLoPahtrKLN/+lm7yTLkyejC4CUoyMqt7D1s+24dFBLC1K7MbWRMWhYH2h4uiQAnQb8eI1idz8QiL3pHPL3a1F06sibzKjtZHOGmkTIZOEmhZ+pW02QUTIxM4wOK0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503980; c=relaxed/simple; bh=9SRDuqMt1PyWyklVUVebqmzDlRKVT9i16km8b7isTdY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=kWrFzQLLaYIutbwLP5csHtcQgNBZi8OjCszRx3OHAMdOKLHqV8fEqVoBIHYFrQ+1r2GrvqjSmRZp48A5kpJY+Pvcny9kQwBdQwn02Jk6bJqrinb70jeUDVeIMmiD5w7GwPXxn6PWRrsOMJiSEiI6gakTDsLi/tZHctBuRN+2gXQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D0ADE4BB589A Received: by mail-vk1-xa2c.google.com with SMTP id 71dfb90a1353d-56a8e0ea02aso298571e0c.0 for ; Wed, 29 Apr 2026 16:06:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503980; x=1778108780; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=ywjyD9CeuvTYp3upDgeqwjMwMYYzAZ5JiREE1LLFWQc=; b=XVRdtuPxp/pYjSWz+UQWwJ6mitE1TdPkPNej1KnTMfJ8lL35saQi2zosUBf1tChTiD gzCmajZ9KNoAr9rHPkOristwhTgzEMc1P/YSJN7qDtOx5o3vSnQM/MRjarM+566b9gC7 B+1tJXnBL9QfvmmNy19NzhIj7lOfhuaYbdMD9nD+tHGLGQBgG4F7UNXQm/2nC4qRtfm9 HZg6vusydhPA7Ovm9SQpOT3K+wpZA+gOQBQTBoALzEUfmNMKys0WQh7ilbtV4Ur1WeqP E79rBuRh5JruQfTOxdQt5X06cwav22s5ijxlq2IbffoNxzTxvjwYwiF98IOPGgF6ZWny wK2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503980; x=1778108780; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=ywjyD9CeuvTYp3upDgeqwjMwMYYzAZ5JiREE1LLFWQc=; b=N+Dqq7md48kE9oLDRdamhD10z7dR3psPuzFr1KU18fxufCorL9+kbSf0tLrmqu/Jf3 P97zndc5GDlkYEblwcCcTgj66bl7On4OcVRv44FZHU7CuNFAxwP3eCcP2wTCer+QJSwq ta1Edo9ojYJiAvAD9nL6GeuFJj5yv8/GCPa4d17r/7ywxzwR65wsX1IhEQb5ozXKoS/y re1wMP9exiZu/MZXYEECZ2rgvgkoD7WbCDyNHiSUtunWgu+5e/WQitC7fXHGfn5X7RTx QD5/ba8CdZ+3gMQcoxgl2xrDE2uAcAz2fA9vwTm5WxfPCse6JfKOJUglu81jsYSzb5D9 K92w== X-Gm-Message-State: AOJu0YzvfenCeOlsuoheju6/3fuTQx7QXs8pNvHPoKacdvTChJgfhHLa eAFtS8fwmIFZZL8/41lLxtWMEIUnnl/5jYuswNfTrOuExerZG0R0CkDz4wFkApEWPZ/cTEP6sj7 dF/mF X-Gm-Gg: AeBDiesp3jFkA8g8/v1I9dJoLyoZeaCPipYUDzKRzYQmT+QmoEa+Nt8oFqm1OQCJEXo VvXO44T6HjoMOmqCQaA1/yahL4YeHYPOK0+CFBovU/5ZGL6YpfZANZZHqAcPCOdyi1VnVeaef/q UZOp4DEyz7nbPi5WKQyQWby5/9S/jYSdA0UHYy5NYZDuGsfOMTYrFku9vCgCKnCzbY2h1AEhcoA Vzm41IXg/8wvtc0TMWhOPYW6LUTEPaHvDBBEjYDc9xtl/DbImC9Z6sdfVs409WH8qpptJVNTVmI +KvoES4rHIlVFpL/EQxbyigpUKjo5byxw4nc0PS+Bs/ToewLka55RyWn4O7VBnlkUy5wfS6SXuK GAgQ4oS4A8wLArvFs1s89QEMEx7QWsQSr3edxoc7rton75J+yGaf5NrtoTrymXuZcyvhmGZOhRa emZN+oCuBPqXfWevjQBTGuMFGpseRedm1EGoxE2JthAQQoEOsYtFWAbNE= X-Received: by 2002:a05:6122:490d:b0:56f:6add:9029 with SMTP id 71dfb90a1353d-573c9568354mr122458e0c.1.1777503980208; Wed, 29 Apr 2026 16:06:20 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6b7d905sm2054570e0c.1.2026.04.29.16.06.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:19 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 29/37] GDB: testsuite: reverse: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:20 -0300 Message-ID: <20260429230432.60487-30-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" statements that weren't caught by the sed command. It also changes a few "return 0" statements. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside block such as with_test_prefix, foreach_with_prefix, with_timeout_factor, gdb_test_multiple. --- gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp | 2 +- gdb/testsuite/gdb.reverse/func-map-to-same-line.exp | 2 +- gdb/testsuite/gdb.reverse/i386-sse-reverse.exp | 6 +++--- gdb/testsuite/gdb.reverse/maint-print-instruction.exp | 2 +- gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp | 2 +- gdb/testsuite/gdb.reverse/sigall-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/sigall-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/singlejmp-reverse.exp | 4 ++-- gdb/testsuite/gdb.reverse/solib-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/solib-reverse.exp | 2 +- gdb/testsuite/gdb.reverse/until-precsave.exp | 2 +- gdb/testsuite/gdb.reverse/until-reverse.exp | 2 +- 12 files changed, 15 insertions(+), 15 deletions(-) diff --git a/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp b/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp index 19ebebf6a126..0432dd47cc08 100644 --- a/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp +++ b/gdb/testsuite/gdb.reverse/finish-reverse-bkpt.exp @@ -47,11 +47,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" "$testfile" $srcfile] } { return } if {![runto_main]} { - return 0 + return } if {[supports_process_record]} { # Activate process record/replay gdb_test_no_output "record" "turn on process record" diff --git a/gdb/testsuite/gdb.reverse/func-map-to-same-line.exp b/gdb/testsuite/gdb.reverse/func-map-to-same-line.exp index dd36528eb3ef..76febe312f58 100644 --- a/gdb/testsuite/gdb.reverse/func-map-to-same-line.exp +++ b/gdb/testsuite/gdb.reverse/func-map-to-same-line.exp @@ -131,10 +131,10 @@ standard_testfile .c foreach_with_prefix column_info_flag {column-info no-column-info} { set options [list debug $column_info_flag] if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ $options]} { - return -1 + return } run_tests } diff --git a/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp b/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp index dc1308861e2c..3ed1d7e6fae2 100644 --- a/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp +++ b/gdb/testsuite/gdb.reverse/i386-sse-reverse.exp @@ -62,11 +62,11 @@ gdb_test_multiple "continue" $test { -re " end sse_test .*\r\n$gdb_prompt $" { pass $test } -re " Illegal instruction.*\r\n$gdb_prompt $" { untested i386-sse-reverse - return -1 + return } } gdb_test "reverse-step" "xorps.*" "reverse-step to xorps" @@ -588,11 +588,11 @@ gdb_test_multiple "continue" $test { -re " end ssse3_test .*\r\n$gdb_prompt $" { pass $test } -re " Illegal instruction.*\r\n$gdb_prompt $" { untested i386-ssse3-reverse - return -1 + return } } gdb_test "info register xmm0" \ "xmm0 .*uint128 = 0x1f1e1d1c1b1a19181716151413121110.*" \ @@ -664,11 +664,11 @@ gdb_test_multiple "continue" $test { -re " end sse4_test .*\r\n$gdb_prompt $" { pass $test } -re " Illegal instruction.*\r\n$gdb_prompt $" { untested i386-sse4-reverse - return -1 + return } } gdb_test "reverse-step" "blendvps.*" "reverse-step to blendvps" diff --git a/gdb/testsuite/gdb.reverse/maint-print-instruction.exp b/gdb/testsuite/gdb.reverse/maint-print-instruction.exp index ad8009b415a9..edf6ec081cdf 100644 --- a/gdb/testsuite/gdb.reverse/maint-print-instruction.exp +++ b/gdb/testsuite/gdb.reverse/maint-print-instruction.exp @@ -44,11 +44,11 @@ proc test_print { has_history level test_name } { } } } if { ![runto_main] } { - return 0 + return } #confirm that GDB doesn't go crazy if recording isn't enabled test_print false "" "print before starting to record" diff --git a/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp b/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp index d34fe130e8e5..b175774aee4f 100644 --- a/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp +++ b/gdb/testsuite/gdb.reverse/next-reverse-bkpt-over-sr.exp @@ -47,11 +47,11 @@ standard_testfile if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } { return } if {![runto_main]} { - return 0 + return } if {[supports_process_record]} { # Activate process record/replay gdb_test_no_output "record" "turn on process record" diff --git a/gdb/testsuite/gdb.reverse/sigall-precsave.exp b/gdb/testsuite/gdb.reverse/sigall-precsave.exp index d8bc6dfaccfa..5ce7de0ea1fe 100644 --- a/gdb/testsuite/gdb.reverse/sigall-precsave.exp +++ b/gdb/testsuite/gdb.reverse/sigall-precsave.exp @@ -256,11 +256,11 @@ gdb_test_multiple "continue" "run to end of main" { send_gdb "continue\n" exp_continue } -wrap -re "Process record does not support instruction 0xfae64 at.*" { kfail "gdb/25038" $gdb_test_name - return -1 + return } } delete_breakpoints diff --git a/gdb/testsuite/gdb.reverse/sigall-reverse.exp b/gdb/testsuite/gdb.reverse/sigall-reverse.exp index 2dae1933d818..45bb49ecfebe 100644 --- a/gdb/testsuite/gdb.reverse/sigall-reverse.exp +++ b/gdb/testsuite/gdb.reverse/sigall-reverse.exp @@ -237,11 +237,11 @@ set thissig "ABRT" with_test_prefix "sig-test-1" { set record_instruction_kfail 0 foreach sig [lrange $signals 1 end] { test_one_sig $sig if { $record_instruction_kfail } { - return -1 + return } } } # The last signal (SIGTERM) gets handled slightly differently because diff --git a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp index 830292cd6669..dfa8ac179f07 100644 --- a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp +++ b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp @@ -22,17 +22,17 @@ if {[info exists COMPILE]} { # make check RUNTESTFLAGS="gdb.reverse/singlejmp-reverse.exp COMPILE=1" if { [build_executable_from_specs ${testfile}.exp $executable {} \ ${testfile}.c {debug optimize=-O2} \ ${testfile}-nodebug.c {optimize=-O2} \ ] == -1 } { - return -1 + return } } else { require is_x86_64_m64_target if { [build_executable ${testfile}.exp ${testfile} \ [list ${srcfile} ${srcfile2}] {}] == -1 } { - return -1 + return } } clean_restart $executable diff --git a/gdb/testsuite/gdb.reverse/solib-precsave.exp b/gdb/testsuite/gdb.reverse/solib-precsave.exp index ef3229c74927..cad30320048b 100644 --- a/gdb/testsuite/gdb.reverse/solib-precsave.exp +++ b/gdb/testsuite/gdb.reverse/solib-precsave.exp @@ -78,11 +78,11 @@ gdb_test_multiple "continue" "run to end of main" { -wrap -re "Breakpoint .* end of main .*" { pass $gdb_test_name } -wrap -re "Process record does not support instruction 0xfae64 at.*" { kfail "gdb/25038" $gdb_test_name - return -1 + return } } gdb_test "record save $precsave" \ "Saved core file $precsave with execution log\." \ diff --git a/gdb/testsuite/gdb.reverse/solib-reverse.exp b/gdb/testsuite/gdb.reverse/solib-reverse.exp index c5a610fcb391..b5f49fb72994 100644 --- a/gdb/testsuite/gdb.reverse/solib-reverse.exp +++ b/gdb/testsuite/gdb.reverse/solib-reverse.exp @@ -75,11 +75,11 @@ gdb_test_multiple "until $end_part_one" "run until end part one" { -wrap -re " end part one.*" { pass $gdb_test_name } -wrap -re "Process record does not support instruction 0xfae64 at.*" { kfail "gdb/25038" $gdb_test_name - return -1 + return } } gdb_test "reverse-step" " shr1 three .*" "reverse-step third shr1" gdb_test "reverse-step" " shr1 two .*" "reverse-step second shr1" diff --git a/gdb/testsuite/gdb.reverse/until-precsave.exp b/gdb/testsuite/gdb.reverse/until-precsave.exp index 411fc14fed27..075a87dc2d87 100644 --- a/gdb/testsuite/gdb.reverse/until-precsave.exp +++ b/gdb/testsuite/gdb.reverse/until-precsave.exp @@ -50,11 +50,11 @@ with_timeout_factor 20 { -wrap -re "Breakpoint .* set breakpoint 10a here .*" { pass $gdb_test_name } -wrap -re "Process record does not support instruction 0xfae64 at.*" { kfail "gdb/25038" $gdb_test_name - return -1 + return } } } # So can this, against gdbserver, for example. diff --git a/gdb/testsuite/gdb.reverse/until-reverse.exp b/gdb/testsuite/gdb.reverse/until-reverse.exp index 74703223c643..19ec2fee6b05 100644 --- a/gdb/testsuite/gdb.reverse/until-reverse.exp +++ b/gdb/testsuite/gdb.reverse/until-reverse.exp @@ -51,11 +51,11 @@ gdb_test_multiple "advance factorial" "" { -wrap -re "factorial .value=6..*$srcfile:$bp_location7.*" { pass $gdb_test_name } -wrap -re "Process record does not support instruction 0xfae64 at.*" { kfail "gdb/25038" $gdb_test_name - return -1 + return } } # At this point, 'until' should continue the inferior up to when all the # inner invocations of factorial() are completed and we are back at this From patchwork Wed Apr 29 23:04:21 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134229 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 48D5E4BAE7CF for ; Wed, 29 Apr 2026 23:15:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 48D5E4BAE7CF Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=gIbOnyHk X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vs1-xe2a.google.com (mail-vs1-xe2a.google.com [IPv6:2607:f8b0:4864:20::e2a]) by sourceware.org (Postfix) with ESMTPS id EEE814358A79 for ; Wed, 29 Apr 2026 23:06:23 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org EEE814358A79 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org EEE814358A79 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::e2a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503984; cv=none; b=wrLpDlK8ORpOPYEjDuJ8A9VsZdkjePXKOb3P5PWjZzWFTK1kVXKv0/OE2ynLIbO/5c61jCS6TnEw0pSWabKo5TPjtzpTRHHQNZdVFp7j3dhrjx6h+U9o7TTUiNfS6PruBbGirY/4dSyR64x/FwWgku1c1x6hD/xyuDWfCIQ7YMg= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503984; c=relaxed/simple; bh=8a0afmV92UHfhIVeVpL4NH/QCQp8Jqzod588BAky7FE=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=ljCYk0ZFFy5StkHhW9gRxcoYR1i+Rm4weXo14FG+U0oRu/PrdDvLRYQydCPJ4CMvA1v63u2c9pmCDSqtTHtDxf9y39xJnZ+vDv3zJSsS1hl07R/2Js4Xn19g9FOfHpWnhboPQaajpLaH9ccgL+a2gnOhzCsDtGYLio8gmWRl/zo= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org EEE814358A79 Received: by mail-vs1-xe2a.google.com with SMTP id ada2fe7eead31-61316792e42so168664137.2 for ; Wed, 29 Apr 2026 16:06:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503983; x=1778108783; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=YLzkI72oGqGa6fsS/tE8ukjBHnjUL1OHV3ggr2JW4RY=; b=gIbOnyHkGt6A75e/A2g8r7gMykfvQA2JgTTRPzalbozw9+m8JKKkX8KnltMAhha4yy dkscFD6iUtpuYqMry4c0pp+e6XXNs2P1Ovgzp71Ujv0CdEG5MZH2+zFM9OgMqX9g8omP VwC1PISvgnwSTqjr5hgVJ8VEqj61385ybKZ4xu3bXeU2rudNuBO5su7SizRDqEAw/1QW 3olCHZgWO1MYPi1dxsfiWAWvlnqe2spXpgwxLyWjR5YUb8BD3UDCkystmr8ZR7JiKyLA cVGXUKMQgMdJgshl9ec5xpKtbmnMbqkuDcMoTz4XQjLagBvTnhhfKoGBn7cKDlsYWorl 0LaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503983; x=1778108783; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=YLzkI72oGqGa6fsS/tE8ukjBHnjUL1OHV3ggr2JW4RY=; b=Mr8Lv6nGEI43jGGGx8nV6cJn50E1am9mYp0OxRDJZEpu5SEsUZRDlL/NiP+m3cVJwx a5SyT64O0YSetaKs/80ZMdMeFQXhnzAeNzDf29hXviWkfB1A8XCUCB7athbHl8Rj+RJM hyahTc+HQ9xYq1R8oWxupWdX1cgGxEHmlMNkurjglIJjck9zLKJkn7jpLyhTZFAcObV/ eOXQjIqEiq5HPvOmggDmutDINvw9+WRwxvlW/M13Wf044fUEiJwPs30i2BeM2XG6QAsf 3whcGo2baGFLvRr0CUi1s61wmGPcwUJ0RdhyTnozpBE6ilxSdDvW/ZYqY/gtxh14E+iM F78g== X-Gm-Message-State: AOJu0YyV/y4IODKMhCdtpCJT6wF2vDsC0l5pRez1t+REfWgiYH0sbPCK mQKi5d+sHICs1qJHKNGpdK2WrsN+vkyn7Jp6YZ/EnnKR2z0DwgPuFX2gA6rNA99cGKup6rCHE2W 3cNP/ X-Gm-Gg: AeBDievsbIPBN+EAwzT+LSjrbrPMvRyUgSRGvGsMkkz56WZGXDVQoLOQO4NdFgT+RsG vPWA6kk1XNnhyiB5hjaZ4vlpMtjJarHr5AXevMEmB0f4zTwGj0YcR2TVzZcV7KwfUBJKf0Qxcwm V8oMAqNDbtQPZ0kd/yH7rU0ZELC8Xlf5EG+y1gfzy4Xn7rXtAf/U5i2xXx50ROaRawv1Rfap+oZ w28SwP2t45IEx88E24yM0hOXrIqQPmTEpRbNoYSqad15MWMXfwua5S9b454kMHcgZ6kieozASHW Mfv7VcmucRhG6zobEpUW1sNaqRajRCB5+vH6EPXlJwPhMmll4uF9FdAMitn8VQkJk3ymWymUVq5 pJz/oHrXGB60rew/KpYGfhUhg8C7BsIU6x4N5iMO3zBT6SjjzyZaFFyecVLW9Cs0mr5Kh8ME7i4 NW04zNznfiA0pIDRVSp5+5QZuALpkxMsgi99VmJdkSdotF X-Received: by 2002:a05:6102:554c:b0:604:f029:224c with SMTP id ada2fe7eead31-62ad223bf06mr287533137.8.1777503983079; Wed, 29 Apr 2026 16:06:23 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cb7830468sm1841694241.13.2026.04.29.16.06.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:22 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 30/37] GDB: testsuite: server: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:21 -0300 Message-ID: <20260429230432.60487-31-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.server. --- gdb/testsuite/gdb.server/build-id-seqno.exp | 4 ++-- gdb/testsuite/gdb.server/connect-stopped-target.exp | 2 +- gdb/testsuite/gdb.server/connect-with-no-symbol-file.exp | 2 +- gdb/testsuite/gdb.server/connect-without-multi-process.exp | 2 +- gdb/testsuite/gdb.server/ext-attach.exp | 2 +- gdb/testsuite/gdb.server/ext-run.exp | 2 +- gdb/testsuite/gdb.server/ext-wrapper.exp | 2 +- gdb/testsuite/gdb.server/extended-remote-restart.exp | 2 +- gdb/testsuite/gdb.server/file-transfer.exp | 2 +- gdb/testsuite/gdb.server/inferior-args.exp | 2 +- gdb/testsuite/gdb.server/monitor-exit-quit.exp | 2 +- gdb/testsuite/gdb.server/no-thread-db.exp | 2 +- gdb/testsuite/gdb.server/pread-offset-size.exp | 2 +- gdb/testsuite/gdb.server/remote-read-msgs.exp | 4 ++-- gdb/testsuite/gdb.server/run-without-local-binary.exp | 2 +- gdb/testsuite/gdb.server/server-connect.exp | 2 +- gdb/testsuite/gdb.server/server-exec-info.exp | 2 +- gdb/testsuite/gdb.server/server-kill-python.exp | 2 +- gdb/testsuite/gdb.server/server-kill.exp | 2 +- gdb/testsuite/gdb.server/server-mon.exp | 2 +- gdb/testsuite/gdb.server/server-pipe.exp | 2 +- gdb/testsuite/gdb.server/server-run.exp | 2 +- gdb/testsuite/gdb.server/solib-list.exp | 2 +- gdb/testsuite/gdb.server/stop-reply-no-thread-multi.exp | 2 +- gdb/testsuite/gdb.server/stop-reply-no-thread.exp | 2 +- gdb/testsuite/gdb.server/sysroot.exp | 2 +- gdb/testsuite/gdb.server/target-exec-file.exp | 4 ++-- gdb/testsuite/gdb.server/twice-connect.exp | 2 +- gdb/testsuite/gdb.server/wrapper.exp | 2 +- 29 files changed, 32 insertions(+), 32 deletions(-) diff --git a/gdb/testsuite/gdb.server/build-id-seqno.exp b/gdb/testsuite/gdb.server/build-id-seqno.exp index 44bdb09b60ad..1fa27e80aa0f 100644 --- a/gdb/testsuite/gdb.server/build-id-seqno.exp +++ b/gdb/testsuite/gdb.server/build-id-seqno.exp @@ -34,16 +34,16 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile] == -1} { - return -1 + return } # Split out BINFILE.debug. Remove debug from BINFILE. if {[gdb_gnu_strip_debug $binfile] != 0} { - return -1 + return } # Get the '.build-id/xx/xxx...xxx' part of the filename. set build_id_filename [build_id_debug_filename_get $binfile] diff --git a/gdb/testsuite/gdb.server/connect-stopped-target.exp b/gdb/testsuite/gdb.server/connect-stopped-target.exp index cfe38fcbfc6a..74ccd774561e 100644 --- a/gdb/testsuite/gdb.server/connect-stopped-target.exp +++ b/gdb/testsuite/gdb.server/connect-stopped-target.exp @@ -24,11 +24,11 @@ require allow_gdbserver_tests standard_testfile set executable ${testfile} if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } proc do_test {nonstop} { global binfile global gdb_prompt diff --git a/gdb/testsuite/gdb.server/connect-with-no-symbol-file.exp b/gdb/testsuite/gdb.server/connect-with-no-symbol-file.exp index fcdc6978d618..7e2b33e09a98 100644 --- a/gdb/testsuite/gdb.server/connect-with-no-symbol-file.exp +++ b/gdb/testsuite/gdb.server/connect-with-no-symbol-file.exp @@ -26,11 +26,11 @@ load_lib gdbserver-support.exp standard_testfile require allow_gdbserver_tests if { [build_executable "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } # Test connecting GDB to GDBserver without loading a symbol file. # # SYSROOT is the desired sysroot string diff --git a/gdb/testsuite/gdb.server/connect-without-multi-process.exp b/gdb/testsuite/gdb.server/connect-without-multi-process.exp index 4b41f461a79d..33787acded51 100644 --- a/gdb/testsuite/gdb.server/connect-without-multi-process.exp +++ b/gdb/testsuite/gdb.server/connect-without-multi-process.exp @@ -21,11 +21,11 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Test spawning gdbserver with a program, connect to it and run to # main, with both multiprocess extensions on and off. proc do_test {multiprocess} { diff --git a/gdb/testsuite/gdb.server/ext-attach.exp b/gdb/testsuite/gdb.server/ext-attach.exp index 0dd02c145ac4..cb4c12772289 100644 --- a/gdb/testsuite/gdb.server/ext-attach.exp +++ b/gdb/testsuite/gdb.server/ext-attach.exp @@ -25,11 +25,11 @@ standard_testfile require allow_gdbserver_tests require can_spawn_for_attach if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Run the test. TARGET_NON_STOP and TARGET_ASYNC should be 'on' # or 'off'. TO_DISABLE should be either the empty string, or # something that can be passed to gdbserver's --disable-packet command diff --git a/gdb/testsuite/gdb.server/ext-run.exp b/gdb/testsuite/gdb.server/ext-run.exp index 83de771902b4..4fb2fe004f26 100644 --- a/gdb/testsuite/gdb.server/ext-run.exp +++ b/gdb/testsuite/gdb.server/ext-run.exp @@ -22,11 +22,11 @@ load_lib gdbserver-support.exp standard_testfile server.c require allow_gdbserver_tests if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } # allow_xml_test must be called while gdb is not running. set do_xml_test [allow_xml_test] diff --git a/gdb/testsuite/gdb.server/ext-wrapper.exp b/gdb/testsuite/gdb.server/ext-wrapper.exp index 836c32a75745..912a8ce37708 100644 --- a/gdb/testsuite/gdb.server/ext-wrapper.exp +++ b/gdb/testsuite/gdb.server/ext-wrapper.exp @@ -20,11 +20,11 @@ load_lib gdbserver-support.exp standard_testfile wrapper.c require allow_gdbserver_tests if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } save_vars { GDBFLAGS } { # If GDB and GDBserver are both running locally, set the sysroot to avoid # reading files via the remote protocol. diff --git a/gdb/testsuite/gdb.server/extended-remote-restart.exp b/gdb/testsuite/gdb.server/extended-remote-restart.exp index 5fe4ebd57297..f10d2f374c09 100644 --- a/gdb/testsuite/gdb.server/extended-remote-restart.exp +++ b/gdb/testsuite/gdb.server/extended-remote-restart.exp @@ -46,11 +46,11 @@ if { [info proc gdb_reconnect] == "" } { } standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Core of the test. DO_KILL_P controls whether we kill one of the # inferiors before reconnecting. And FOLLOW_CHILD_P controls whether # we follow the child or the parent at the fork. diff --git a/gdb/testsuite/gdb.server/file-transfer.exp b/gdb/testsuite/gdb.server/file-transfer.exp index f33c589c961e..a4517582b257 100644 --- a/gdb/testsuite/gdb.server/file-transfer.exp +++ b/gdb/testsuite/gdb.server/file-transfer.exp @@ -21,11 +21,11 @@ load_lib gdbserver-support.exp standard_testfile server.c require allow_gdbserver_tests if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. gdb_test "disconnect" ".*" diff --git a/gdb/testsuite/gdb.server/inferior-args.exp b/gdb/testsuite/gdb.server/inferior-args.exp index 312e756f0d80..f6ad3e69b407 100644 --- a/gdb/testsuite/gdb.server/inferior-args.exp +++ b/gdb/testsuite/gdb.server/inferior-args.exp @@ -33,11 +33,11 @@ if { $gdbserver == "" } { return } standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile]} { - return -1 + return } # EXTENDED_P is a boolean, when true gdbserver is started with --multi, and # GDB connects using extended-remote protocol. Otherwise, no --multi flag # is passed, and GDB connects with the remote protocol. diff --git a/gdb/testsuite/gdb.server/monitor-exit-quit.exp b/gdb/testsuite/gdb.server/monitor-exit-quit.exp index c5f8426cb5de..cb90169ef0cc 100644 --- a/gdb/testsuite/gdb.server/monitor-exit-quit.exp +++ b/gdb/testsuite/gdb.server/monitor-exit-quit.exp @@ -22,11 +22,11 @@ load_lib gdbserver-support.exp standard_testfile server.c require allow_gdbserver_tests if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } save_vars { GDBFLAGS } { # If GDB and GDBserver are both running locally, set the sysroot to avoid # reading files via the remote protocol. diff --git a/gdb/testsuite/gdb.server/no-thread-db.exp b/gdb/testsuite/gdb.server/no-thread-db.exp index e04e43c78a3c..9cbe962bc3c0 100644 --- a/gdb/testsuite/gdb.server/no-thread-db.exp +++ b/gdb/testsuite/gdb.server/no-thread-db.exp @@ -26,11 +26,11 @@ standard_testfile set unresolvable_thread_db_path "/foo/bar" require allow_gdbserver_tests if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } save_vars { GDBFLAGS } { # If GDB and GDBserver are both running locally, set the sysroot to avoid # reading files via the remote protocol. diff --git a/gdb/testsuite/gdb.server/pread-offset-size.exp b/gdb/testsuite/gdb.server/pread-offset-size.exp index 4362878c8e6e..68f938d42c67 100644 --- a/gdb/testsuite/gdb.server/pread-offset-size.exp +++ b/gdb/testsuite/gdb.server/pread-offset-size.exp @@ -22,11 +22,11 @@ require allow_gdbserver_tests standard_testfile .S if { [prepare_for_testing ${testfile}.exp $testfile \ $srcfile {debug additional_flags=-nostdlib} ] } { - return -1 + return } clean_restart gdb_test_no_output "set remote exec-file $binfile" \ diff --git a/gdb/testsuite/gdb.server/remote-read-msgs.exp b/gdb/testsuite/gdb.server/remote-read-msgs.exp index 86c2d610c00b..e9d03388e398 100644 --- a/gdb/testsuite/gdb.server/remote-read-msgs.exp +++ b/gdb/testsuite/gdb.server/remote-read-msgs.exp @@ -30,16 +30,16 @@ require {!is_remote host} standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile \ {debug build-id}] == -1} { - return -1 + return } # Split out BINFILE.debug. Remove debug from BINFILE. if {[gdb_gnu_strip_debug $binfile] != 0} { - return -1 + return } # Get the '.build-id/xx/xxx...xxx' part of the filename. set build_id_filename [build_id_debug_filename_get $binfile] diff --git a/gdb/testsuite/gdb.server/run-without-local-binary.exp b/gdb/testsuite/gdb.server/run-without-local-binary.exp index 3aa9eba2d05d..24521f21b0f9 100644 --- a/gdb/testsuite/gdb.server/run-without-local-binary.exp +++ b/gdb/testsuite/gdb.server/run-without-local-binary.exp @@ -18,11 +18,11 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests standard_testfile normal.c if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } set target_binfile [gdb_remote_download target $binfile] # Test running GDB without providing a local binary for it. In order diff --git a/gdb/testsuite/gdb.server/server-connect.exp b/gdb/testsuite/gdb.server/server-connect.exp index bb6a5758d359..3c8dd114166a 100644 --- a/gdb/testsuite/gdb.server/server-connect.exp +++ b/gdb/testsuite/gdb.server/server-connect.exp @@ -26,11 +26,11 @@ require allow_gdbserver_tests # We want to have control over where we start gdbserver. require {!is_remote target} if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. gdb_test "disconnect" ".*" diff --git a/gdb/testsuite/gdb.server/server-exec-info.exp b/gdb/testsuite/gdb.server/server-exec-info.exp index 7163785348d9..4ef9ede9cec0 100644 --- a/gdb/testsuite/gdb.server/server-exec-info.exp +++ b/gdb/testsuite/gdb.server/server-exec-info.exp @@ -20,11 +20,11 @@ load_lib gdbserver-support.exp # are present. require allow_gdbserver_tests allow_shlib_tests standard_testfile server.c if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { - return -1 + return } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. gdb_test "disconnect" ".*" diff --git a/gdb/testsuite/gdb.server/server-kill-python.exp b/gdb/testsuite/gdb.server/server-kill-python.exp index 09e4d561bee9..7c08090c1656 100644 --- a/gdb/testsuite/gdb.server/server-kill-python.exp +++ b/gdb/testsuite/gdb.server/server-kill-python.exp @@ -25,11 +25,11 @@ standard_testfile multi-ui-errors.c require allow_gdbserver_tests allow_python_tests if {[build_executable "failed to prepare" ${testfile} \ ${srcfile}] == -1} { - return -1 + return } set target_binfile [gdb_remote_download target $binfile] set host_binfile [gdb_remote_download host $binfile] diff --git a/gdb/testsuite/gdb.server/server-kill.exp b/gdb/testsuite/gdb.server/server-kill.exp index 9a92ef2a6c75..d4bbb466f04c 100644 --- a/gdb/testsuite/gdb.server/server-kill.exp +++ b/gdb/testsuite/gdb.server/server-kill.exp @@ -23,11 +23,11 @@ load_lib gdbserver-support.exp standard_testfile require allow_gdbserver_tests if { [build_executable "failed to prepare" ${testfile}] } { - return -1 + return } # Spawn GDBserver, run to main, extract GDBserver's PID and save it in # the SERVER_PID global. diff --git a/gdb/testsuite/gdb.server/server-mon.exp b/gdb/testsuite/gdb.server/server-mon.exp index 8811a0c8afa7..ef054059faf8 100644 --- a/gdb/testsuite/gdb.server/server-mon.exp +++ b/gdb/testsuite/gdb.server/server-mon.exp @@ -22,11 +22,11 @@ load_lib gdbserver-support.exp standard_testfile server.c require allow_gdbserver_tests if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. gdb_test "disconnect" ".*" diff --git a/gdb/testsuite/gdb.server/server-pipe.exp b/gdb/testsuite/gdb.server/server-pipe.exp index ca9d9cab8b67..724e5a047b1e 100644 --- a/gdb/testsuite/gdb.server/server-pipe.exp +++ b/gdb/testsuite/gdb.server/server-pipe.exp @@ -40,11 +40,11 @@ if { $gdbserver == "" } { standard_testfile normal.c set executable ${testfile} if {[build_executable "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } # Start GDB using remote type TARGET, which should be either "remote" # or "extended-remote". Check the output of 'info connections', and # the contents of the gdb.TargetConnection.details string. diff --git a/gdb/testsuite/gdb.server/server-run.exp b/gdb/testsuite/gdb.server/server-run.exp index 776851b36955..a20ef0a5a1fc 100644 --- a/gdb/testsuite/gdb.server/server-run.exp +++ b/gdb/testsuite/gdb.server/server-run.exp @@ -22,11 +22,11 @@ load_lib gdbserver-support.exp standard_testfile server.c require allow_gdbserver_tests if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} { - return -1 + return } save_vars { GDBFLAGS } { # If GDB and GDBserver are both running locally, set the sysroot to avoid # reading files via the remote protocol. diff --git a/gdb/testsuite/gdb.server/solib-list.exp b/gdb/testsuite/gdb.server/solib-list.exp index ab0fd1586cb1..c529bb6edd06 100644 --- a/gdb/testsuite/gdb.server/solib-list.exp +++ b/gdb/testsuite/gdb.server/solib-list.exp @@ -30,11 +30,11 @@ set srclibfile ${testfile}-lib.c set binlibfile [standard_output_file ${testfile}.so] if { [gdb_compile_shlib "${srcdir}/${subdir}/${srclibfile}" "${binlibfile}" {debug}] != "" || [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable "shlib=${binlibfile} build-id"] != "" } { untested "failed to compile" - return -1 + return } set interp_system [section_get ${binfile} .interp] verbose -log "system interpreter is: $interp_system" diff --git a/gdb/testsuite/gdb.server/stop-reply-no-thread-multi.exp b/gdb/testsuite/gdb.server/stop-reply-no-thread-multi.exp index 01bf3ef67dca..a7eda3f76f06 100644 --- a/gdb/testsuite/gdb.server/stop-reply-no-thread-multi.exp +++ b/gdb/testsuite/gdb.server/stop-reply-no-thread-multi.exp @@ -32,11 +32,11 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1 } { - return -1 + return } set target_binfile [gdb_remote_download target $binfile] # Run the tests with different features of GDBserver disabled. diff --git a/gdb/testsuite/gdb.server/stop-reply-no-thread.exp b/gdb/testsuite/gdb.server/stop-reply-no-thread.exp index fec2246b4791..700b70224151 100644 --- a/gdb/testsuite/gdb.server/stop-reply-no-thread.exp +++ b/gdb/testsuite/gdb.server/stop-reply-no-thread.exp @@ -24,11 +24,11 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile] == -1 } { - return -1 + return } set target_binfile [gdb_remote_download target $binfile] # Run the tests with different features of GDBserver disabled. diff --git a/gdb/testsuite/gdb.server/sysroot.exp b/gdb/testsuite/gdb.server/sysroot.exp index 634168db4693..7e4a796e8791 100644 --- a/gdb/testsuite/gdb.server/sysroot.exp +++ b/gdb/testsuite/gdb.server/sysroot.exp @@ -22,11 +22,11 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile "additional_flags=--no-builtin"] == -1} { - return -1 + return } set target_binfile [gdb_remote_download target $binfile] set host_binfile [gdb_remote_download host $binfile] diff --git a/gdb/testsuite/gdb.server/target-exec-file.exp b/gdb/testsuite/gdb.server/target-exec-file.exp index 7c204cc9abde..a9e6f801165d 100644 --- a/gdb/testsuite/gdb.server/target-exec-file.exp +++ b/gdb/testsuite/gdb.server/target-exec-file.exp @@ -24,11 +24,11 @@ load_lib gdbserver-support.exp require allow_gdbserver_tests !use_gdb_stub standard_testfile if { [build_executable "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } clean_restart # Some boards specifically set the sysroot to the empty string to @@ -221,11 +221,11 @@ if { [allow_python_tests] } { sleep 1 set res [remote_exec target "touch $target_exec"] set status [lindex $res 0] if { $status != 0 } { fail "touching executable on target" - return -1 + return } # Start the inferior again, we expect to see the symbols being re-read # from the remote file. start_inferior "start inferior a third time" true diff --git a/gdb/testsuite/gdb.server/twice-connect.exp b/gdb/testsuite/gdb.server/twice-connect.exp index eaf910179f7f..45f2eb5aa596 100644 --- a/gdb/testsuite/gdb.server/twice-connect.exp +++ b/gdb/testsuite/gdb.server/twice-connect.exp @@ -21,11 +21,11 @@ standard_testfile require allow_gdbserver_tests if { [build_executable "failed to prepare" $::testfile $::srcfile \ {debug}] } { - return -1 + return } # Don't use $binfile arg, to make sure we use the remote file target:$binfile. clean_restart diff --git a/gdb/testsuite/gdb.server/wrapper.exp b/gdb/testsuite/gdb.server/wrapper.exp index 9478640c40e2..15643fb92a7c 100644 --- a/gdb/testsuite/gdb.server/wrapper.exp +++ b/gdb/testsuite/gdb.server/wrapper.exp @@ -24,11 +24,11 @@ standard_testfile require allow_gdbserver_tests if { [istarget *-*-mingw*] || [istarget *-*-cygwin*] } { unsupported "gdbserver does not support --wrapper on this target (PR server/15967)" - return -1 + return } save_vars { GDBFLAGS } { # If GDB and GDBserver are both running locally, set the sysroot to avoid # reading files via the remote protocol. From patchwork Wed Apr 29 23:04:22 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134217 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 12B8A4BAE7C9 for ; Wed, 29 Apr 2026 23:09:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 12B8A4BAE7C9 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=qB8lYMa6 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-ua1-x92f.google.com (mail-ua1-x92f.google.com [IPv6:2607:f8b0:4864:20::92f]) by sourceware.org (Postfix) with ESMTPS id ADFD24BB3BE9 for ; Wed, 29 Apr 2026 23:06:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org ADFD24BB3BE9 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org ADFD24BB3BE9 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::92f ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503987; cv=none; b=m1OB//A4osFhDgbJGh7klhUxCYwzKsUlywPQoGZaSLCM61AvK7bb+i9HRfLbN0DYmxm1aT8BI8uGB/Y6mFqGSTJMR64sF1VCX2T6OjzR+C4xiFXPBBGkps/ayEtExwcFRzd6mxVORqut1OFGC6qYLj7zG1tmuA3DXMaYJOwfbhQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503987; c=relaxed/simple; bh=8UuNgweJSa5e/SSPTG6c1oG/5EXdwVALfPfRPGSTvZc=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=c+SqUsqoQEf0RqK5FVAxnFnnzrEit9FgI6/XW21hed/hiLclS3hOgfj1g9Fk16Cxk4lKiMirbphhC83YfBv+3eaijgI9780jk5RPlJgqRljuTCCwqCtFkqKIQsbotJY5TE+QWrX2zdyJQHHSMwHBCzs6G9yPncTncMsMK1f9ucA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org ADFD24BB3BE9 Received: by mail-ua1-x92f.google.com with SMTP id a1e0cc1a2514c-953a44f8404so120279241.0 for ; Wed, 29 Apr 2026 16:06:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503987; x=1778108787; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=kX5XOo/uK60yqBS7sro77nCo5Y/QPlP5bbIRzqBCV9E=; b=qB8lYMa6OaXffUb+w6P4nWLJ7LAsyVDqIjB4iEdxt0F6k08+2cyN8LHgsRIIz+wznC IGEo9YhSt3hytxH0TS4O8CGK9cDcGl0axKE5SG6m7xstYLdl+W//iBNk+Xu2MeQcvjoS dkcoL/5ALgnu3s6BJQC4sUn+jNrryS7XZ1pIE5Ki5SqZ9PpUtR/oeEYnWziEdH7ljhV8 Os8RqznFp18guSHjDnW+fj7nF1rL5IGHUy6ZBOt4Nvk2LAhn+4Qg7RDz4u4RNsTEZ1Nu m7KiDkypcPyj2vIlZ/fSBMoDK1fiTgW1CSL4iuKkLZeC7mvpRgYT4AfMND61N+KNyAKB RI7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503987; x=1778108787; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=kX5XOo/uK60yqBS7sro77nCo5Y/QPlP5bbIRzqBCV9E=; b=HaRQa4Oq4G2EgBwSJOoInq/Ts1dz2jrj/uonkICKORpKMVTU0hdggWnL6cZFHsiz+h JbWy57tAz2GzOJwETZqz0v0MDtJ+0WV+GKrZG3gQmYbwXmCnann/J41xjd531R7z30Dk DwD21sKn4x6W4K9u/+0+WUfBECreIn2DZZHR49V0uwGccKlplnvNgptkBD7fPsO2ULDq ls2+KQ8QTtMpCB7fK4uEu7ITUwRZsd04NnPB0/e3JLYvnGx0pcoXS+7Mn79Phhr076Pc bSN6YM792q81+clUgXiExbyl6x9qWR4Yfmhg+hQMTvEbGQjxQz4fDud9m3PndmZyayX4 H5oQ== X-Gm-Message-State: AOJu0Yy3rg4BYH9bf2itpe/jCrxSKsyI9fBgY2xydZUnYqzj6MsE0GbT kbhkoyJkbm7nCv3vNV8r53iaS+yTO3PUEDbGgDF9IXRQG6bcBzYU2Kb35sJGJChkXGkBirZRRT0 NmrOG X-Gm-Gg: AeBDiev0hLuLu+2GNPDWxGaaflcFAhdACPDgv5XzC0iHL6SxSemv1OEOIn+Df/ih+WT Ejdq502mpDPb03DlCcjuDWBLE1tMWbrY5ds9MR8PAEg9a/YjuH30TCcvy3BB8Ca4Lm4dBCRR4+m r+uXvPhphcjzeloxwvr2ew3EFGqCHrNQ6sPpR3mUJ+irQWW9OF0R50TtiDwBmOK5L7LQq4TsHnx n5Cua8ciPMMwumyFq8ITNg1y+aSm8bLoO6uQyhc0nbWXDPideGF/47ahUfcXu7L7SllDRz9Zo7f o2gfQjtlczHnux0MecPJSGxD+NFgfqOJYoUty0674Yrh2DrJBXBR/i/VFTk15espGFo8tiN/bWC SuSZ5xJqpFIQmMuWX1Or9q2V52BiahuPshSR8ogo3ZQSn3HL4xQ+pbIHM/U7ebSee3mtQtBcG95 d2xF8oKdMO2Y9RErdJS7OoVezVu9bsv4nEE6OMiVaKCDCv X-Received: by 2002:a05:6102:508e:b0:60f:7499:9b63 with SMTP id ada2fe7eead31-62adc184180mr209045137.17.1777503987036; Wed, 29 Apr 2026 16:06:27 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cc4f4d418sm807065241.9.2026.04.29.16.06.25 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:26 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 31/37] GDB: testsuite: server: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:22 -0300 Message-ID: <20260429230432.60487-32-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" statements that weren't caught by the sed command. These return statements return at top level but inside block such as save_vars and with_test_prefix. I also fixed one case of top-level "return 0". --- gdb/testsuite/gdb.server/abspath.exp | 2 +- gdb/testsuite/gdb.server/exit-multiple-threads.exp | 2 +- gdb/testsuite/gdb.server/ext-restart.exp | 2 +- gdb/testsuite/gdb.server/ext-wrapper.exp | 2 +- gdb/testsuite/gdb.server/extended-remote-restart.exp | 2 +- gdb/testsuite/gdb.server/multi-ui-errors.exp | 2 +- gdb/testsuite/gdb.server/reconnect-ctrl-c.exp | 2 +- gdb/testsuite/gdb.server/wrapper.exp | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/gdb/testsuite/gdb.server/abspath.exp b/gdb/testsuite/gdb.server/abspath.exp index 5bd7f7e842bb..7c4d43ff474d 100644 --- a/gdb/testsuite/gdb.server/abspath.exp +++ b/gdb/testsuite/gdb.server/abspath.exp @@ -36,11 +36,11 @@ save_vars { GDBFLAGS } { if { ![is_remote host] } { set GDBFLAGS "$GDBFLAGS -ex \"set sysroot\"" } if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. diff --git a/gdb/testsuite/gdb.server/exit-multiple-threads.exp b/gdb/testsuite/gdb.server/exit-multiple-threads.exp index 1b0941eb3c78..c6e19f8dfb44 100644 --- a/gdb/testsuite/gdb.server/exit-multiple-threads.exp +++ b/gdb/testsuite/gdb.server/exit-multiple-threads.exp @@ -138,11 +138,11 @@ foreach_with_prefix test { exit signal } { set func "run_${test}_test" set executable "$binfile-${test}" if {[build_executable "failed to prepare" $executable $srcfile \ [list debug pthreads additional_flags=-D${def}]]} { - return -1 + return } set target_executable [gdb_remote_download target $executable] foreach_with_prefix multi_process { 0 1 } { diff --git a/gdb/testsuite/gdb.server/ext-restart.exp b/gdb/testsuite/gdb.server/ext-restart.exp index 39d42d7a4416..031aaeb5db85 100644 --- a/gdb/testsuite/gdb.server/ext-restart.exp +++ b/gdb/testsuite/gdb.server/ext-restart.exp @@ -29,11 +29,11 @@ save_vars { GDBFLAGS } { if { ![is_remote host] && ![is_remote target] } { set GDBFLAGS "$GDBFLAGS -ex \"set sysroot\"" } if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. diff --git a/gdb/testsuite/gdb.server/ext-wrapper.exp b/gdb/testsuite/gdb.server/ext-wrapper.exp index 912a8ce37708..757127b15488 100644 --- a/gdb/testsuite/gdb.server/ext-wrapper.exp +++ b/gdb/testsuite/gdb.server/ext-wrapper.exp @@ -31,11 +31,11 @@ save_vars { GDBFLAGS } { if { ![is_remote host] && ![is_remote target] } { set GDBFLAGS "$GDBFLAGS -ex \"set sysroot\"" } if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. diff --git a/gdb/testsuite/gdb.server/extended-remote-restart.exp b/gdb/testsuite/gdb.server/extended-remote-restart.exp index f10d2f374c09..a592dba79ed5 100644 --- a/gdb/testsuite/gdb.server/extended-remote-restart.exp +++ b/gdb/testsuite/gdb.server/extended-remote-restart.exp @@ -40,11 +40,11 @@ require {is_any_target "*-*-linux*" "*-*-openbsd*"} # And we need to be able to reconnect to gdbserver. set gdbserver_reconnect_p 1 if { [info proc gdb_reconnect] == "" } { unsupported "requires gdbserver reconnect" - return 0 + return } standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { diff --git a/gdb/testsuite/gdb.server/multi-ui-errors.exp b/gdb/testsuite/gdb.server/multi-ui-errors.exp index c17de8bf2e48..dde936c1a455 100644 --- a/gdb/testsuite/gdb.server/multi-ui-errors.exp +++ b/gdb/testsuite/gdb.server/multi-ui-errors.exp @@ -35,11 +35,11 @@ save_vars { GDBFLAGS } { if { ![is_remote host] && ![is_remote target] } { set GDBFLAGS "$GDBFLAGS -ex \"set sysroot\"" } if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. diff --git a/gdb/testsuite/gdb.server/reconnect-ctrl-c.exp b/gdb/testsuite/gdb.server/reconnect-ctrl-c.exp index 63502887bf55..c0e129db76d5 100644 --- a/gdb/testsuite/gdb.server/reconnect-ctrl-c.exp +++ b/gdb/testsuite/gdb.server/reconnect-ctrl-c.exp @@ -31,11 +31,11 @@ save_vars { GDBFLAGS } { if { ![is_remote host] && ![is_remote target] } { set GDBFLAGS "$GDBFLAGS -ex \"set sysroot\"" } if {[prepare_for_testing "failed to prepare" $testfile $srcfile]} { - return -1 + return } } set target_binfile [gdb_remote_download target $binfile] diff --git a/gdb/testsuite/gdb.server/wrapper.exp b/gdb/testsuite/gdb.server/wrapper.exp index 15643fb92a7c..40c29c441fab 100644 --- a/gdb/testsuite/gdb.server/wrapper.exp +++ b/gdb/testsuite/gdb.server/wrapper.exp @@ -35,11 +35,11 @@ save_vars { GDBFLAGS } { if { ![is_remote host] && ![is_remote target] } { set GDBFLAGS "$GDBFLAGS -ex \"set sysroot\"" } if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } } # Make sure we're disconnected, in case we're testing with an # extended-remote board, therefore already connected. From patchwork Wed Apr 29 23:04:23 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134221 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 012CF4358A46 for ; Wed, 29 Apr 2026 23:10:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 012CF4358A46 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=aWlNVakx X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa33.google.com (mail-vk1-xa33.google.com [IPv6:2607:f8b0:4864:20::a33]) by sourceware.org (Postfix) with ESMTPS id 2D8E04BB58A5 for ; Wed, 29 Apr 2026 23:06:32 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 2D8E04BB58A5 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 2D8E04BB58A5 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a33 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503992; cv=none; b=rjGfl65EkFWrAnf8U3Yb01t91DODnNUjPrRrsZpLMJyFD0X9l9yTDuukj4AQnEYsDXc6mJ+lQ24MCfKvGGWHVm+wrMLM3fC7aJIBYTlPPUziNxnbrXhWL6gE/H3OnMmDk6EkEYskXt41BYHhiiJx0+p6kn0tG4xqKK8kuAqC4Gs= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503992; c=relaxed/simple; bh=8NzZgz8EN2Wmm9apbgDTb0bhX5SrVdl92jpq3wygn5Q=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=naJBQpDhmo1yNlw+uINifpcNWtb6n7lp28f863qb4MzPahyQBcf7pnBoFkaDCS67gK+8jg9/5U6FFUXuR2VVBHN9r/A5wLQp8LpgPhtXfiDAOozPgBYI30wB/B4rSz3qhLS9ljASW44D+swALXAHGZqKOHVpZ1s5tufmBC8NanY= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2D8E04BB58A5 Received: by mail-vk1-xa33.google.com with SMTP id 71dfb90a1353d-56dfd007d31so177344e0c.3 for ; Wed, 29 Apr 2026 16:06:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503991; x=1778108791; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=fDc2QEaf9E3qY1OVL3S/pACeK/COVIs8utVPDut5aKY=; b=aWlNVakxDv+0AMHRIB9ADu4JBFSl9Os/soJC0Qk1WGNsUZxWOlAfIsj/UxxA8oXEMK UragVwK14znTk9xHrV/N88/8dR4ncHULU7mldrmqSY78LrLaOxUbdobfmnA9k89ly87W PfKjo9MHqwGVw46ZNBz+Lpp2SEoUGS/lQ4QPem97ZsgTNJMrVY27ejarqyO4mbZD9s2O Dd2MiAHFSr0XCG5ZaVOmIB3urm0pVpK0L6v+MLqHBEJQ5dcDxMZbqS8ImIZbQIP6Ymid 3DMvX8ZEgqlZFbgsA3XVZP2UStgVnXiLKWiWrNoEGrE310ebceoQJgOPA3p9A2re+SHC f5oQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503991; x=1778108791; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=fDc2QEaf9E3qY1OVL3S/pACeK/COVIs8utVPDut5aKY=; b=GUUUorZdTt73NQ6OFQIojedy37jstm1FhuNjbXj34C1kN2g5ZplsOzZYZqSEIQCjJN ZCPTOUWswdMsLfZHZe06xDJEXPz/JQKgHvKPrC4D3/NWZXrmdbSW+0lAzPzOQq78K/BE hChp8BPzjZGt5UpOz1G3xASu7lXGp8OVB0v/N9RaNgAmllwNCkMJtvtto6xdL25gsBwo 4Sbo20OMA/SD8QKtUbvXFH0IDmIZev0HTxIyJHV3dOqlEPRwkvgtfp/KEQG5ruoIE+hN RMxNXQvP6Jc/1BcD2m2u+vRq1p/19hitYJ27JTyH2h12WIYD4CzyIVXmlH+tW+oOQytV 3pcg== X-Gm-Message-State: AOJu0YyhAGE/y1aval7oaARtu9LobLt/ym/S7qk8m+yKA75qca/1vmwe gUmdMO/1N0ETYQ/OCbwZXAu0Ilo7+OVseU8qDbWqFGhkOd01rwsguIQAFqToU3j9E2cWnyE8Nrx iS1QF X-Gm-Gg: AeBDiet6Sl3D/PpbNLvNx+LPl8f1FZn1NIdABCGYeQ9TEh8ICutpi/Ao1L0UtgnX5rx eiJMNe4Pt1hE6uHMlbUx7sc3uHyade34wiVgxOnIuHbdGMXqvzrTzMz21ypPC011YFFwZE5acTz tH16QMACagaBNp/C+Xih4Q5lEuBnVtOgLA5WlBG8bcHq3/XBsGgS/ZZSce7V0Bhb2LVOpl2Cwzp Z8wCxQEQCW1scIAKVCrG4K8AaIqryOq7X7g8hK45zKnRNP3J4cHs7P8ttLIGuAiigXstNADWdb5 xwfzfR1FgqIy8hu04Sn/xjKoLpJtIn0CxGeA+mNtEl2Lepml1zyxqMhOZ+6Tvd4Bv14Nj/VPJoS 6enRtMQ6KP+p2AilnOiKWPKYMwzkM1OrSCgpneAE7W6SPryJl1YE9yXXXn+kKYrlY14zQNZpAeu I9OdzQtc7jtgf5vuSIgge1I4ZZoE1tki/IsoT0O3SZ9g71 X-Received: by 2002:a05:6122:608c:b0:56d:9def:20c8 with SMTP id 71dfb90a1353d-573c95d5b6emr100320e0c.6.1777503990960; Wed, 29 Apr 2026 16:06:30 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6e2aad6sm2099369e0c.18.2026.04.29.16.06.29 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:30 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 32/37] GDB: testsuite: threads: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:23 -0300 Message-ID: <20260429230432.60487-33-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.threads. --- .../gdb.threads/access-mem-running-thread-exit.exp | 2 +- gdb/testsuite/gdb.threads/async.exp | 2 +- gdb/testsuite/gdb.threads/attach-into-signal.exp | 4 ++-- .../gdb.threads/attach-many-short-lived-threads.exp | 2 +- gdb/testsuite/gdb.threads/attach-non-stop.exp | 2 +- gdb/testsuite/gdb.threads/attach-slow-waitpid.exp | 2 +- gdb/testsuite/gdb.threads/attach-stopped.exp | 4 ++-- gdb/testsuite/gdb.threads/bp_in_thread.exp | 2 +- gdb/testsuite/gdb.threads/break-while-running.exp | 2 +- gdb/testsuite/gdb.threads/check-libthread-db.exp | 2 +- gdb/testsuite/gdb.threads/clone-attach-detach.exp | 2 +- gdb/testsuite/gdb.threads/clone-new-thread-event.exp | 4 ++-- gdb/testsuite/gdb.threads/clone-thread_db.exp | 4 ++-- .../gdb.threads/continue-pending-after-query.exp | 2 +- gdb/testsuite/gdb.threads/continue-pending-status.exp | 4 ++-- gdb/testsuite/gdb.threads/create-fail.exp | 2 +- gdb/testsuite/gdb.threads/current-lwp-dead.exp | 4 ++-- gdb/testsuite/gdb.threads/del-pending-thread-bp.exp | 4 ++-- gdb/testsuite/gdb.threads/detach-step-over.exp | 4 ++-- gdb/testsuite/gdb.threads/dlopen-libpthread.exp | 6 +++--- gdb/testsuite/gdb.threads/execl.exp | 4 ++-- gdb/testsuite/gdb.threads/fork-child-threads.exp | 2 +- gdb/testsuite/gdb.threads/fork-thread-pending.exp | 2 +- .../gdb.threads/forking-threads-plus-breakpoint.exp | 2 +- gdb/testsuite/gdb.threads/gcore-stale-thread.exp | 4 ++-- gdb/testsuite/gdb.threads/gcore-thread.exp | 4 ++-- gdb/testsuite/gdb.threads/hand-call-in-threads.exp | 2 +- gdb/testsuite/gdb.threads/hand-call-new-thread.exp | 2 +- gdb/testsuite/gdb.threads/ia64-sigill.exp | 4 ++-- gdb/testsuite/gdb.threads/inf-thr-count.exp | 8 ++++---- gdb/testsuite/gdb.threads/infcall-thread-announce.exp | 4 ++-- gdb/testsuite/gdb.threads/info-threads-cur-sal.exp | 4 ++-- gdb/testsuite/gdb.threads/info-threads-options.exp | 4 ++-- gdb/testsuite/gdb.threads/interrupt-while-step-over.exp | 4 ++-- gdb/testsuite/gdb.threads/interrupted-hand-call.exp | 2 +- gdb/testsuite/gdb.threads/killed-outside.exp | 6 +++--- gdb/testsuite/gdb.threads/killed.exp | 2 +- gdb/testsuite/gdb.threads/leader-exit.exp | 4 ++-- gdb/testsuite/gdb.threads/linux-dp.exp | 2 +- gdb/testsuite/gdb.threads/local-watch-wrong-thread.exp | 2 +- .../gdb.threads/main-thread-exit-during-detach.exp | 2 +- gdb/testsuite/gdb.threads/manythreads.exp | 2 +- gdb/testsuite/gdb.threads/multi-create-ns-info-thr.exp | 4 ++-- gdb/testsuite/gdb.threads/multi-create.exp | 2 +- gdb/testsuite/gdb.threads/multiple-step-overs.exp | 2 +- gdb/testsuite/gdb.threads/names.exp | 2 +- gdb/testsuite/gdb.threads/next-bp-other-thread.exp | 2 +- .../gdb.threads/next-while-other-thread-longjmps.exp | 2 +- gdb/testsuite/gdb.threads/no-unwaited-for-left.exp | 4 ++-- gdb/testsuite/gdb.threads/non-ldr-exc-1.exp | 2 +- gdb/testsuite/gdb.threads/non-ldr-exc-2.exp | 2 +- gdb/testsuite/gdb.threads/non-ldr-exc-3.exp | 2 +- gdb/testsuite/gdb.threads/non-ldr-exc-4.exp | 2 +- gdb/testsuite/gdb.threads/non-ldr-exit.exp | 4 ++-- gdb/testsuite/gdb.threads/non-stop-fair-events.exp | 4 ++-- gdb/testsuite/gdb.threads/omp-par-scope.exp | 4 ++-- gdb/testsuite/gdb.threads/omp-task.exp | 4 ++-- gdb/testsuite/gdb.threads/pending-step.exp | 2 +- gdb/testsuite/gdb.threads/print-threads.exp | 2 +- .../gdb.threads/process-dies-while-handling-bp.exp | 2 +- .../process-exit-status-is-leader-exit-status.exp | 2 +- gdb/testsuite/gdb.threads/pthread_cond_wait.exp | 2 +- gdb/testsuite/gdb.threads/pthreads.exp | 2 +- gdb/testsuite/gdb.threads/queue-signal.exp | 2 +- gdb/testsuite/gdb.threads/reconnect-signal.exp | 2 +- gdb/testsuite/gdb.threads/schedlock.exp | 2 +- gdb/testsuite/gdb.threads/siginfo-threads.exp | 4 ++-- .../gdb.threads/signal-command-handle-nopass.exp | 2 +- .../signal-command-multiple-signals-pending.exp | 2 +- .../gdb.threads/signal-delivered-right-thread.exp | 2 +- gdb/testsuite/gdb.threads/signal-sigtrap.exp | 2 +- .../signal-while-stepping-over-bp-other-thread.exp | 4 ++-- gdb/testsuite/gdb.threads/sigstep-threads.exp | 4 ++-- gdb/testsuite/gdb.threads/sigthread.exp | 2 +- .../gdb.threads/step-bg-decr-pc-switch-thread.exp | 2 +- .../gdb.threads/step-over-lands-on-breakpoint.exp | 2 +- .../gdb.threads/step-over-trips-on-watchpoint.exp | 2 +- gdb/testsuite/gdb.threads/stepi-random-signal.exp | 4 ++-- gdb/testsuite/gdb.threads/stop-with-handle.exp | 2 +- gdb/testsuite/gdb.threads/switch-threads.exp | 2 +- gdb/testsuite/gdb.threads/thread-bp-deleted.exp | 6 +++--- gdb/testsuite/gdb.threads/thread-execl.exp | 2 +- gdb/testsuite/gdb.threads/thread-find.exp | 2 +- gdb/testsuite/gdb.threads/thread-specific-bp.exp | 2 +- gdb/testsuite/gdb.threads/thread-specific.exp | 2 +- gdb/testsuite/gdb.threads/thread-unwindonsignal.exp | 2 +- gdb/testsuite/gdb.threads/thread_check.exp | 2 +- gdb/testsuite/gdb.threads/thread_events.exp | 2 +- gdb/testsuite/gdb.threads/threadapply.exp | 2 +- gdb/testsuite/gdb.threads/threadcrash.exp | 2 +- gdb/testsuite/gdb.threads/threxit-hop-specific.exp | 2 +- gdb/testsuite/gdb.threads/tid-reuse.exp | 4 ++-- gdb/testsuite/gdb.threads/tls-core.exp | 2 +- gdb/testsuite/gdb.threads/tls-nodebug-pie.exp | 2 +- gdb/testsuite/gdb.threads/tls-nodebug.exp | 2 +- gdb/testsuite/gdb.threads/tls-sepdebug.exp | 4 ++-- gdb/testsuite/gdb.threads/tls-shared.exp | 2 +- gdb/testsuite/gdb.threads/tls-so_extern.exp | 2 +- gdb/testsuite/gdb.threads/tls-var.exp | 2 +- gdb/testsuite/gdb.threads/tls.exp | 2 +- gdb/testsuite/gdb.threads/vfork-follow-child-exec.exp | 2 +- gdb/testsuite/gdb.threads/vfork-follow-child-exit.exp | 2 +- gdb/testsuite/gdb.threads/vfork-multi-inferior.exp | 4 ++-- gdb/testsuite/gdb.threads/watchthreads-reorder.exp | 2 +- gdb/testsuite/gdb.threads/watchthreads.exp | 2 +- gdb/testsuite/gdb.threads/watchthreads2.exp | 4 ++-- gdb/testsuite/gdb.threads/wp-replication.exp | 2 +- 107 files changed, 147 insertions(+), 147 deletions(-) diff --git a/gdb/testsuite/gdb.threads/access-mem-running-thread-exit.exp b/gdb/testsuite/gdb.threads/access-mem-running-thread-exit.exp index 35da068db6b6..d0db40c4be5b 100644 --- a/gdb/testsuite/gdb.threads/access-mem-running-thread-exit.exp +++ b/gdb/testsuite/gdb.threads/access-mem-running-thread-exit.exp @@ -36,11 +36,11 @@ # file open per inferior. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } # The test proper. NON_STOP indicates whether we're testing in # non-stop, or all-stop mode. diff --git a/gdb/testsuite/gdb.threads/async.exp b/gdb/testsuite/gdb.threads/async.exp index fa57796452f2..2fe787f6bed5 100644 --- a/gdb/testsuite/gdb.threads/async.exp +++ b/gdb/testsuite/gdb.threads/async.exp @@ -14,11 +14,11 @@ # along with this program. If not, see . standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } # At this point GDB will be busy handling the breakpoint hits and # re-resuming the program. Even if GDB internally switches thread # context, the user should not notice it. The following part of the diff --git a/gdb/testsuite/gdb.threads/attach-into-signal.exp b/gdb/testsuite/gdb.threads/attach-into-signal.exp index 7c9c30036d2b..2f682ebb0738 100644 --- a/gdb/testsuite/gdb.threads/attach-into-signal.exp +++ b/gdb/testsuite/gdb.threads/attach-into-signal.exp @@ -119,18 +119,18 @@ proc corefunc { threadtype executable } { # build the test case first without threads # if {[build_executable $testfile $executable_nothr $srcfile] == -1} { untested "attach-into-signal.exp (nonthreaded)" - return -1 + return } corefunc nonthreaded ${executable_nothr} # build the test case also with threads # if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" [standard_output_file ${executable_thr}] executable {debug additional_flags=-DUSE_THREADS}] != "" } { untested "attach-into-signal.exp (threaded)" - return -1 + return } corefunc threaded ${executable_thr} diff --git a/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp b/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp index 16e33c027b09..0f1b141b1ea1 100644 --- a/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp +++ b/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp @@ -193,9 +193,9 @@ proc test {} { # failure. set options { "additional_flags=-DTIMEOUT=$timeout" debug pthreads } if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ $options] == -1} { - return -1 + return } test diff --git a/gdb/testsuite/gdb.threads/attach-non-stop.exp b/gdb/testsuite/gdb.threads/attach-non-stop.exp index 3f55459e7ede..3d363398cc23 100644 --- a/gdb/testsuite/gdb.threads/attach-non-stop.exp +++ b/gdb/testsuite/gdb.threads/attach-non-stop.exp @@ -132,11 +132,11 @@ proc test {target_non_stop non_stop cmd} { kill_wait_spawned_process $test_spawn_id } if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } foreach_with_prefix target-non-stop {"off" "on"} { foreach_with_prefix non-stop {"off" "on"} { foreach_with_prefix cmd {"attach" "attach&"} { diff --git a/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp b/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp index c71cd98501f4..343a96bc5112 100644 --- a/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp +++ b/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp @@ -96,11 +96,11 @@ set testpid [spawn_id_get_pid $test_spawn_id] # Start GDB with preload library in place. if { [gdb_spawn_with_ld_preload $libobj] == -1 } { # Make sure we get UNTESTED rather than UNRESOLVED. set errcnt 0 untested "Couldn't start GDB with preloaded lib" - return -1 + return } # Load binary, and attach to running program. gdb_load ${binfile} gdb_test "attach $testpid" "Attaching to program.*" "attach to target" diff --git a/gdb/testsuite/gdb.threads/attach-stopped.exp b/gdb/testsuite/gdb.threads/attach-stopped.exp index 63a8f481e2e0..2f84c6d77f2f 100644 --- a/gdb/testsuite/gdb.threads/attach-stopped.exp +++ b/gdb/testsuite/gdb.threads/attach-stopped.exp @@ -77,18 +77,18 @@ proc corefunc { threadtype } { # build the test case first without threads # if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "attach-stopped.exp (unthreaded)" - return -1 + return } corefunc nonthreaded # build the test case first without threads # if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug additional_flags=-DUSE_THREADS}] != "" } { untested "attach-stopped.exp (threaded)" - return -1 + return } corefunc threaded diff --git a/gdb/testsuite/gdb.threads/bp_in_thread.exp b/gdb/testsuite/gdb.threads/bp_in_thread.exp index 001eeaae6e98..07f5e2f1b807 100644 --- a/gdb/testsuite/gdb.threads/bp_in_thread.exp +++ b/gdb/testsuite/gdb.threads/bp_in_thread.exp @@ -19,11 +19,11 @@ # a breakpoint. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart $::testfile runto_main diff --git a/gdb/testsuite/gdb.threads/break-while-running.exp b/gdb/testsuite/gdb.threads/break-while-running.exp index 9d500f38b148..c4ad127d982c 100644 --- a/gdb/testsuite/gdb.threads/break-while-running.exp +++ b/gdb/testsuite/gdb.threads/break-while-running.exp @@ -23,11 +23,11 @@ # still threads running. standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } # The test proper. UPDATE_THREAD_LIST indicates whether we should do # an "info threads" to sync the thread list after the first stop. # ALWAYS_INSERTED indicates whether testing in "breakpoint diff --git a/gdb/testsuite/gdb.threads/check-libthread-db.exp b/gdb/testsuite/gdb.threads/check-libthread-db.exp index 3e95d7e84a7c..1110c1c848ec 100644 --- a/gdb/testsuite/gdb.threads/check-libthread-db.exp +++ b/gdb/testsuite/gdb.threads/check-libthread-db.exp @@ -25,11 +25,11 @@ require !gdb_debug_enabled standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable debug] != "" } { - return -1 + return } # Case 1: libthread_db fakes a single thread with th_unique == NULL. set thread_re1 "0 => $decimal => 0" # Case 2: libthread_db already initialized. diff --git a/gdb/testsuite/gdb.threads/clone-attach-detach.exp b/gdb/testsuite/gdb.threads/clone-attach-detach.exp index e3294b8c7bfb..cd4544a8057f 100644 --- a/gdb/testsuite/gdb.threads/clone-attach-detach.exp +++ b/gdb/testsuite/gdb.threads/clone-attach-detach.exp @@ -26,11 +26,11 @@ if {![istarget *-*-linux*]} { require can_spawn_for_attach standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug}]} { - return -1 + return } set test_spawn_id [spawn_wait_for_attach $binfile] set testpid [spawn_id_get_pid $test_spawn_id] diff --git a/gdb/testsuite/gdb.threads/clone-new-thread-event.exp b/gdb/testsuite/gdb.threads/clone-new-thread-event.exp index 44f4f7e63109..2e49766f33d1 100644 --- a/gdb/testsuite/gdb.threads/clone-new-thread-event.exp +++ b/gdb/testsuite/gdb.threads/clone-new-thread-event.exp @@ -19,15 +19,15 @@ if {![istarget *-*-linux*]} { return } if { [prepare_for_testing "failed to prepare" clone-new-thread-event] } { - return -1 + return } if { ![runto_main] } { - return -1 + return } gdb_test "continue" \ "Thread 2 received signal SIGUSR1, User defined signal 1.*" \ "catch SIGUSR1" diff --git a/gdb/testsuite/gdb.threads/clone-thread_db.exp b/gdb/testsuite/gdb.threads/clone-thread_db.exp index a5a185ad9c83..77297a8e74b4 100644 --- a/gdb/testsuite/gdb.threads/clone-thread_db.exp +++ b/gdb/testsuite/gdb.threads/clone-thread_db.exp @@ -21,15 +21,15 @@ if {![istarget *-*-linux*]} { } standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_test "break clone_fn" "Breakpoint.*at.*file.*$srcfile.*line.*" gdb_test "continue" "clone_fn .* at .*" "continue to clone_fn" diff --git a/gdb/testsuite/gdb.threads/continue-pending-after-query.exp b/gdb/testsuite/gdb.threads/continue-pending-after-query.exp index 43f5bd368b19..97f9081443a7 100644 --- a/gdb/testsuite/gdb.threads/continue-pending-after-query.exp +++ b/gdb/testsuite/gdb.threads/continue-pending-after-query.exp @@ -43,11 +43,11 @@ # Ref: https://sourceware.org/ml/gdb-patches/2015-01/msg00592.html standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } proc test {} { global srcfile gdb_prompt diff --git a/gdb/testsuite/gdb.threads/continue-pending-status.exp b/gdb/testsuite/gdb.threads/continue-pending-status.exp index 1ffa6fd32425..01fb61c3b525 100644 --- a/gdb/testsuite/gdb.threads/continue-pending-status.exp +++ b/gdb/testsuite/gdb.threads/continue-pending-status.exp @@ -20,15 +20,15 @@ require {!target_info exists gdb,nointerrupts} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}]} { - return -1 + return } if {![runto_main]} { - return -1 + return } set break_line [gdb_get_line_number "break here"] # Return current thread's number. diff --git a/gdb/testsuite/gdb.threads/create-fail.exp b/gdb/testsuite/gdb.threads/create-fail.exp index b2528281b7e1..c77ccab17ae2 100644 --- a/gdb/testsuite/gdb.threads/create-fail.exp +++ b/gdb/testsuite/gdb.threads/create-fail.exp @@ -22,11 +22,11 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } set iterations 10 for {set i 1} {$i <= $iterations} {incr i} { with_test_prefix "iteration $i" { diff --git a/gdb/testsuite/gdb.threads/current-lwp-dead.exp b/gdb/testsuite/gdb.threads/current-lwp-dead.exp index 5c9aa76e9d9a..272771114a3f 100644 --- a/gdb/testsuite/gdb.threads/current-lwp-dead.exp +++ b/gdb/testsuite/gdb.threads/current-lwp-dead.exp @@ -28,15 +28,15 @@ standard_testfile if {![istarget *-*-linux*]} { return } if { [prepare_for_testing "failed to prepare" current-lwp-dead] } { - return -1 + return } if {[runto_main] <= 0} { - return -1 + return } # Run to "fn" so that thread 2 is made current. gdb_breakpoint "fn" gdb_continue_to_breakpoint "fn" ".*do_clone.*" diff --git a/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp b/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp index 1870adcde22a..09a6f56a5660 100644 --- a/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp +++ b/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp @@ -28,20 +28,20 @@ set libname $testfile-lib set srcfile_lib $srcdir/$subdir/$libname.c set binfile_lib [standard_output_file $libname.so] if { [gdb_compile_shlib $srcfile_lib $binfile_lib {}] != "" } { untested "failed to compile shared library 1" - return -1 + return } set binfile_lib_target [gdb_download_shlib $binfile_lib] if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ [list debug \ additional_flags=-DSHLIB_NAME=\"$binfile_lib_target\" \ shlib_load pthreads]] } { - return -1 + return } gdb_locate_shlib $binfile_lib if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/detach-step-over.exp b/gdb/testsuite/gdb.threads/detach-step-over.exp index 85198111fd07..b034788ae6cf 100644 --- a/gdb/testsuite/gdb.threads/detach-step-over.exp +++ b/gdb/testsuite/gdb.threads/detach-step-over.exp @@ -352,15 +352,15 @@ proc_with_prefix test_detach_quit {condition_eval target_non_stop \ # wait at least as long as we may wait before declaring a time out # failure. set options { "additional_flags=-DTIMEOUT=$timeout" debug pthreads } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options] == -1} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Probe support for "set breakpoint condition-evaluation target". # This setting influences who steps over the breakpoint, the (remote) # target (e.g. gdbserver) or gdb, thus exposing issues on either the diff --git a/gdb/testsuite/gdb.threads/dlopen-libpthread.exp b/gdb/testsuite/gdb.threads/dlopen-libpthread.exp index 1dacbdbb1b28..03ce0dd1612d 100644 --- a/gdb/testsuite/gdb.threads/dlopen-libpthread.exp +++ b/gdb/testsuite/gdb.threads/dlopen-libpthread.exp @@ -31,16 +31,16 @@ set lib_dlopen [shlib_target_file ${executable}.so] # PASS - it is OK if GDB processes it still before relocation. set relink_args [build_executable_own_libs ${testfile}.exp ${executable}.so $srclibfile {debug shlib_pthreads} no] if {$relink_args == "" || ![prelink_no $relink_args] || [prepare_for_testing "failed to prepare" ${executable} ${srcmainfile} {debug shlib_load}] } { - return -1 + return } gdb_load_shlib $binfile_lib if { ![runto_main] } { - return -1 + return } set probe_names {} # Fedora 17 name. There's specific code in # svr4_find_and_create_probe_breakpoints to deal with this. @@ -60,11 +60,11 @@ foreach probe_name $probe_names { } } if { !$have_probe } { untested "no matching probes" - return -1 + return } # We link the exec without -lpthread, but libpthread.so may already be loaded at main # due to LD_PRELOAD. set libpthread_maybe_preloaded 0 diff --git a/gdb/testsuite/gdb.threads/execl.exp b/gdb/testsuite/gdb.threads/execl.exp index fcbd865a9e84..a5ad5a48ca92 100644 --- a/gdb/testsuite/gdb.threads/execl.exp +++ b/gdb/testsuite/gdb.threads/execl.exp @@ -17,20 +17,20 @@ # Original image, loads a thread library. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } # New image, that does not load a thread library. set testfile1 "execl1" set srcfile1 ${testfile1}.c set binfile1 [standard_output_file ${testfile1}] if {[gdb_compile "${srcdir}/${subdir}/${srcfile1}" "${binfile1}" executable {debug}] != "" } { - return -1 + return } clean_restart ${::testfile} if { [is_remote target] } { gdb_remote_download target $binfile1 diff --git a/gdb/testsuite/gdb.threads/fork-child-threads.exp b/gdb/testsuite/gdb.threads/fork-child-threads.exp index fec474f4c701..c6090eaaaf42 100644 --- a/gdb/testsuite/gdb.threads/fork-child-threads.exp +++ b/gdb/testsuite/gdb.threads/fork-child-threads.exp @@ -16,11 +16,11 @@ require allow_fork_tests standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/fork-thread-pending.exp b/gdb/testsuite/gdb.threads/fork-thread-pending.exp index 6f81e5e7e491..0cf4878d13f8 100644 --- a/gdb/testsuite/gdb.threads/fork-thread-pending.exp +++ b/gdb/testsuite/gdb.threads/fork-thread-pending.exp @@ -16,11 +16,11 @@ require allow_fork_tests standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/forking-threads-plus-breakpoint.exp b/gdb/testsuite/gdb.threads/forking-threads-plus-breakpoint.exp index 231709369e5c..b3a2fdb9ac16 100644 --- a/gdb/testsuite/gdb.threads/forking-threads-plus-breakpoint.exp +++ b/gdb/testsuite/gdb.threads/forking-threads-plus-breakpoint.exp @@ -21,11 +21,11 @@ require allow_fork_tests standard_testfile set linenum [gdb_get_line_number "set break here"] if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } # Assume yes. set displaced_stepping_supported 1 diff --git a/gdb/testsuite/gdb.threads/gcore-stale-thread.exp b/gdb/testsuite/gdb.threads/gcore-stale-thread.exp index 1f1974109fea..9faa2686c767 100644 --- a/gdb/testsuite/gdb.threads/gcore-stale-thread.exp +++ b/gdb/testsuite/gdb.threads/gcore-stale-thread.exp @@ -15,19 +15,19 @@ standard_testfile set corefile [standard_output_file ${testfile}.core] if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != ""} { - return -1 + return } clean_restart ${testfile} gdb_test_no_output "set non-stop on" if {![runto_main]} { - return -1 + return } gdb_test_multiple "info threads" "threads are supported" { -re ".* main .*\r\n$gdb_prompt $" { # OK, threads are supported. diff --git a/gdb/testsuite/gdb.threads/gcore-thread.exp b/gdb/testsuite/gdb.threads/gcore-thread.exp index 75c538074a92..c3b8c56dd4b9 100644 --- a/gdb/testsuite/gdb.threads/gcore-thread.exp +++ b/gdb/testsuite/gdb.threads/gcore-thread.exp @@ -35,11 +35,11 @@ if {[istarget "*-*-linux"]} { set opts [list debug] if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${objfile}" object $opts] != "" || ([gdb_compile_pthreads "${objfile}" "${binfile}" executable [concat $opts {ldflags=-Wl,-z,norelro}] ] != "" && [gdb_compile_pthreads "${objfile}" "${binfile}" executable $opts] != "") } { - return -1 + return } # Now we can proceed with the real testing. # Start with a fresh gdb. @@ -54,11 +54,11 @@ set horiz "\[^\n\r\]*" set nl "\r\n" set timeout 30 if {![runto_main]} { - return -1 + return } gdb_test_multiple "info threads" "threads are supported" { -re ".* main .*$gdb_prompt $" { # OK, threads are supported. diff --git a/gdb/testsuite/gdb.threads/hand-call-in-threads.exp b/gdb/testsuite/gdb.threads/hand-call-in-threads.exp index f2d93cedfed9..f6d29720cc6f 100644 --- a/gdb/testsuite/gdb.threads/hand-call-in-threads.exp +++ b/gdb/testsuite/gdb.threads/hand-call-in-threads.exp @@ -22,11 +22,11 @@ standard_testfile # Some targets can't do function calls, so don't even bother with this # test. require {!target_info exists gdb,cannot_call_functions} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DNR_THREADS=$NR_THREADS"]] != "" } { - return -1 + return } proc get_dummy_frame_number { } { global gdb_prompt diff --git a/gdb/testsuite/gdb.threads/hand-call-new-thread.exp b/gdb/testsuite/gdb.threads/hand-call-new-thread.exp index f9c59089a2ba..891e47e6c9c4 100644 --- a/gdb/testsuite/gdb.threads/hand-call-new-thread.exp +++ b/gdb/testsuite/gdb.threads/hand-call-new-thread.exp @@ -17,11 +17,11 @@ # to stopped state once the call finishes. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}]} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.threads/ia64-sigill.exp b/gdb/testsuite/gdb.threads/ia64-sigill.exp index e69b9478998f..b19c62e8ded6 100644 --- a/gdb/testsuite/gdb.threads/ia64-sigill.exp +++ b/gdb/testsuite/gdb.threads/ia64-sigill.exp @@ -20,17 +20,17 @@ # breakpoint has been already deleted. moribund locations are not active in # the default all-stop mode. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" ${binfile} executable [list debug additional_flags=-lrt]] != "" } { - return -1 + return } clean_restart $testfile if {![runto_main]} { - return -1 + return } set test "info addr label" gdb_test_multiple $test $test { -re "Symbol \"label\" is at ${::hex}0 in .*\r\n$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.threads/inf-thr-count.exp b/gdb/testsuite/gdb.threads/inf-thr-count.exp index af48648e5ca5..feb81ab6673e 100644 --- a/gdb/testsuite/gdb.threads/inf-thr-count.exp +++ b/gdb/testsuite/gdb.threads/inf-thr-count.exp @@ -35,22 +35,22 @@ standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pthreads}] == -1} { - return -1 + return } # Start GDB. Ensure we are in non-stop mode as we need to read from # the inferior while it is running. save_vars {GDBFLAGS} { append GDBFLAGS { -ex "set non-stop on"} clean_restart $::testfile } if {![runto_main]} { - return -1 + return } gdb_breakpoint breakpt gdb_continue_to_breakpoint "first breakpt call" @@ -129,11 +129,11 @@ proc wait_for_stage { num } { } # Wait until we can see that the extra thread has been created. if {![wait_for_stage 1]} { unresolved "failed to see thread start" - return -1 + return } if {[target_info exists gdb_protocol] && ([target_info gdb_protocol] == "remote" @@ -158,11 +158,11 @@ gdb_test_no_output "set variable spin = 0" \ "set 'spin' flag to allow worker thread to exit" # Wait until the extra thread has exited. if {![wait_for_stage 2]} { unresolved "failed to see thread start" - return -1 + return } # Check that the second thread has gone away. gdb_test {with print thread-events on -- p $_inferior_thread_count} \ "^${exit_thread_re}$re_var = 1" \ diff --git a/gdb/testsuite/gdb.threads/infcall-thread-announce.exp b/gdb/testsuite/gdb.threads/infcall-thread-announce.exp index 311daaca87cc..a554670f1e6e 100644 --- a/gdb/testsuite/gdb.threads/infcall-thread-announce.exp +++ b/gdb/testsuite/gdb.threads/infcall-thread-announce.exp @@ -18,15 +18,15 @@ # function call from GDB. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint breakpt gdb_continue_to_breakpoint "first breakpt call" diff --git a/gdb/testsuite/gdb.threads/info-threads-cur-sal.exp b/gdb/testsuite/gdb.threads/info-threads-cur-sal.exp index 1b4fa3a8d3ee..3e8533674d46 100644 --- a/gdb/testsuite/gdb.threads/info-threads-cur-sal.exp +++ b/gdb/testsuite/gdb.threads/info-threads-cur-sal.exp @@ -18,17 +18,17 @@ standard_testfile info-threads-cur-sal.c info-threads-cur-sal-2.c set executable ${testfile} if {[gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcfile} ${srcdir}/${subdir}/${srcfile2}" \ "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart ${executable} if {![runto_main]} { - return -1 + return } gdb_breakpoint "start" gdb_continue_to_breakpoint "start" diff --git a/gdb/testsuite/gdb.threads/info-threads-options.exp b/gdb/testsuite/gdb.threads/info-threads-options.exp index 15c4904892e7..476c62cb323c 100644 --- a/gdb/testsuite/gdb.threads/info-threads-options.exp +++ b/gdb/testsuite/gdb.threads/info-threads-options.exp @@ -17,20 +17,20 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable debug] != "" } { - return -1 + return } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" clean_restart $::testfile } if {![runto_main]} { - return -1 + return } gdb_breakpoint "stop_here" gdb_test_multiple "continue -a&" "" { -re "Continuing.\r\n$gdb_prompt " { diff --git a/gdb/testsuite/gdb.threads/interrupt-while-step-over.exp b/gdb/testsuite/gdb.threads/interrupt-while-step-over.exp index 446af5e23eca..e8b29dce2fa3 100644 --- a/gdb/testsuite/gdb.threads/interrupt-while-step-over.exp +++ b/gdb/testsuite/gdb.threads/interrupt-while-step-over.exp @@ -18,15 +18,15 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug pthreads}] == -1} { - return -1 + return } if {![runto_main]} { - return -1 + return } # Read the number of threads out of the inferior. set NUM_THREADS [get_integer_valueof "num_threads" -1] diff --git a/gdb/testsuite/gdb.threads/interrupted-hand-call.exp b/gdb/testsuite/gdb.threads/interrupted-hand-call.exp index e921ea0cf06f..23a3d038c09a 100644 --- a/gdb/testsuite/gdb.threads/interrupted-hand-call.exp +++ b/gdb/testsuite/gdb.threads/interrupted-hand-call.exp @@ -23,11 +23,11 @@ standard_testfile # Some targets can't do function calls, so don't even bother with this # test. require {!target_info exists gdb,cannot_call_functions} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DNR_THREADS=$NR_THREADS"]] != "" } { - return -1 + return } clean_restart ${::testfile} if { ![runto_main] } { diff --git a/gdb/testsuite/gdb.threads/killed-outside.exp b/gdb/testsuite/gdb.threads/killed-outside.exp index 51726ebf0e9c..67d6c6b32239 100644 --- a/gdb/testsuite/gdb.threads/killed-outside.exp +++ b/gdb/testsuite/gdb.threads/killed-outside.exp @@ -18,21 +18,21 @@ standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {pthreads debug}] == -1} { - return -1 + return } if { ![runto "all_started"] } { - return -1 + return } delete_breakpoints set testpid [get_valueof "" "pid" -1 "get pid of inferior"] if { $testpid == -1 } { - return -1 + return } remote_exec target "kill -9 ${testpid}" # Give it some time to die. sleep 2 diff --git a/gdb/testsuite/gdb.threads/killed.exp b/gdb/testsuite/gdb.threads/killed.exp index 96fe37dbefed..39b60dff8dd4 100644 --- a/gdb/testsuite/gdb.threads/killed.exp +++ b/gdb/testsuite/gdb.threads/killed.exp @@ -56,11 +56,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} diff --git a/gdb/testsuite/gdb.threads/leader-exit.exp b/gdb/testsuite/gdb.threads/leader-exit.exp index 9aa7d0fdf3f1..b5e6f558ac7b 100644 --- a/gdb/testsuite/gdb.threads/leader-exit.exp +++ b/gdb/testsuite/gdb.threads/leader-exit.exp @@ -19,17 +19,17 @@ require {!target_info exists gdb,nointerrupts} standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart ${executable} if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.threads/linux-dp.exp b/gdb/testsuite/gdb.threads/linux-dp.exp index 5592e364e1f4..42773f2293b5 100644 --- a/gdb/testsuite/gdb.threads/linux-dp.exp +++ b/gdb/testsuite/gdb.threads/linux-dp.exp @@ -39,11 +39,11 @@ if {![istarget *-*-linux-gnu*]} { return } standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != ""} { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set print sevenbit-strings" runto_main diff --git a/gdb/testsuite/gdb.threads/local-watch-wrong-thread.exp b/gdb/testsuite/gdb.threads/local-watch-wrong-thread.exp index a26abab630d5..3a9e7c193a58 100644 --- a/gdb/testsuite/gdb.threads/local-watch-wrong-thread.exp +++ b/gdb/testsuite/gdb.threads/local-watch-wrong-thread.exp @@ -23,11 +23,11 @@ require allow_hw_watchpoint_multi_tests standard_testfile if {[gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcfile}" \ "${binfile}" executable {debug} ] != "" } { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set can-use-hw-watchpoints 1" "" diff --git a/gdb/testsuite/gdb.threads/main-thread-exit-during-detach.exp b/gdb/testsuite/gdb.threads/main-thread-exit-during-detach.exp index 7df41da642c3..717eca236c03 100644 --- a/gdb/testsuite/gdb.threads/main-thread-exit-during-detach.exp +++ b/gdb/testsuite/gdb.threads/main-thread-exit-during-detach.exp @@ -38,11 +38,11 @@ standard_testfile require allow_python_tests if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pthreads}] == -1} { - return -1 + return } # Run the test. When SPAWN_INFERIOR is true the inferior is started # as a separate process which GDB then attaches too. When # SPAWN_INFERIOR is false the inferior is started directly within GDB. diff --git a/gdb/testsuite/gdb.threads/manythreads.exp b/gdb/testsuite/gdb.threads/manythreads.exp index c0c0c8917c81..aabbb24b4d9e 100644 --- a/gdb/testsuite/gdb.threads/manythreads.exp +++ b/gdb/testsuite/gdb.threads/manythreads.exp @@ -26,11 +26,11 @@ if {[info exists DEBUG]} { # make check RUNTESTFLAGS='gdb.threads/manythreads.exp DEBUG=1' lappend opts "additional_flags=-DDEBUG" } if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable $opts] != "" } { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set print sevenbit-strings" runto_main diff --git a/gdb/testsuite/gdb.threads/multi-create-ns-info-thr.exp b/gdb/testsuite/gdb.threads/multi-create-ns-info-thr.exp index 881a489b04d6..cc5fe888f878 100644 --- a/gdb/testsuite/gdb.threads/multi-create-ns-info-thr.exp +++ b/gdb/testsuite/gdb.threads/multi-create-ns-info-thr.exp @@ -17,18 +17,18 @@ # exiting, in non-stop mode. Originally based on multi-create.exp. standard_testfile multi-create.c if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } gdb_test_no_output "set pagination off" gdb_test_no_output "set non-stop on" if {![runto_main]} { - return -1 + return } # Create a breakpoint that does "info threads" when hit, which will be # just while other threads are being created or exiting. set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] diff --git a/gdb/testsuite/gdb.threads/multi-create.exp b/gdb/testsuite/gdb.threads/multi-create.exp index 9bc49b6b7e1a..a34ddfe69957 100644 --- a/gdb/testsuite/gdb.threads/multi-create.exp +++ b/gdb/testsuite/gdb.threads/multi-create.exp @@ -16,11 +16,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug}] != "" } { - return -1 + return } clean_restart ${::testfile} runto_main diff --git a/gdb/testsuite/gdb.threads/multiple-step-overs.exp b/gdb/testsuite/gdb.threads/multiple-step-overs.exp index 8433e16340ad..2159718f2a63 100644 --- a/gdb/testsuite/gdb.threads/multiple-step-overs.exp +++ b/gdb/testsuite/gdb.threads/multiple-step-overs.exp @@ -21,11 +21,11 @@ set executable ${testfile} require {!target_info exists gdb,nosignals} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable [list debug "incdir=${objdir}"]] != "" } { - return -1 + return } # Prepare environment for test. proc setup {} { diff --git a/gdb/testsuite/gdb.threads/names.exp b/gdb/testsuite/gdb.threads/names.exp index dc3ed4eaa2ca..31f36f1b3d7c 100644 --- a/gdb/testsuite/gdb.threads/names.exp +++ b/gdb/testsuite/gdb.threads/names.exp @@ -19,11 +19,11 @@ require {!target_info exists gdb,no_thread_names} standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}]} { - return -1 + return } if {![runto "all_threads_ready"]} { return } diff --git a/gdb/testsuite/gdb.threads/next-bp-other-thread.exp b/gdb/testsuite/gdb.threads/next-bp-other-thread.exp index 56f2c8440e98..9f07ad6aaa9b 100644 --- a/gdb/testsuite/gdb.threads/next-bp-other-thread.exp +++ b/gdb/testsuite/gdb.threads/next-bp-other-thread.exp @@ -20,11 +20,11 @@ standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pthreads}] == -1} { - return -1 + return } # Test all "set scheduler-locking" variants. foreach schedlock {"off" "step" "on" } { with_test_prefix "schedlock=$schedlock" { diff --git a/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp b/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp index aa6fc1965a92..6852e8d7f876 100644 --- a/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp +++ b/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp @@ -22,11 +22,11 @@ standard_testfile set linenum [gdb_get_line_number "set break here"] if {[prepare_for_testing "failed to prepare" \ $testfile $srcfile {c++ debug pthreads}] == -1} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.threads/no-unwaited-for-left.exp b/gdb/testsuite/gdb.threads/no-unwaited-for-left.exp index e21a7fe4c9fa..621da59db46f 100644 --- a/gdb/testsuite/gdb.threads/no-unwaited-for-left.exp +++ b/gdb/testsuite/gdb.threads/no-unwaited-for-left.exp @@ -18,17 +18,17 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } clean_restart ${executable} if {![runto_main]} { - return -1 + return } gdb_breakpoint $srcfile:[gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.threads/non-ldr-exc-1.exp b/gdb/testsuite/gdb.threads/non-ldr-exc-1.exp index 360630e6f66a..442b6fb639ff 100644 --- a/gdb/testsuite/gdb.threads/non-ldr-exc-1.exp +++ b/gdb/testsuite/gdb.threads/non-ldr-exc-1.exp @@ -18,11 +18,11 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } proc do_test { lock_sched nonstop } { global executable diff --git a/gdb/testsuite/gdb.threads/non-ldr-exc-2.exp b/gdb/testsuite/gdb.threads/non-ldr-exc-2.exp index f331e823c2b2..ead262cc2b50 100644 --- a/gdb/testsuite/gdb.threads/non-ldr-exc-2.exp +++ b/gdb/testsuite/gdb.threads/non-ldr-exc-2.exp @@ -19,11 +19,11 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } proc do_test { lock_sched nonstop } { global executable global tdlabel_re diff --git a/gdb/testsuite/gdb.threads/non-ldr-exc-3.exp b/gdb/testsuite/gdb.threads/non-ldr-exc-3.exp index 76ac3f155628..2ad3a84d24bf 100644 --- a/gdb/testsuite/gdb.threads/non-ldr-exc-3.exp +++ b/gdb/testsuite/gdb.threads/non-ldr-exc-3.exp @@ -21,11 +21,11 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } proc do_test { lock_sched nonstop } { global executable diff --git a/gdb/testsuite/gdb.threads/non-ldr-exc-4.exp b/gdb/testsuite/gdb.threads/non-ldr-exc-4.exp index a895a51f4a99..fad49047ac39 100644 --- a/gdb/testsuite/gdb.threads/non-ldr-exc-4.exp +++ b/gdb/testsuite/gdb.threads/non-ldr-exc-4.exp @@ -20,11 +20,11 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - return -1 + return } proc do_test { lock_sched nonstop } { global executable diff --git a/gdb/testsuite/gdb.threads/non-ldr-exit.exp b/gdb/testsuite/gdb.threads/non-ldr-exit.exp index e49f3ce86074..6b5e85fd2fa0 100644 --- a/gdb/testsuite/gdb.threads/non-ldr-exit.exp +++ b/gdb/testsuite/gdb.threads/non-ldr-exit.exp @@ -17,15 +17,15 @@ standard_testfile set executable ${testfile} if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "break-here"] gdb_continue_to_breakpoint "break-here" ".* break-here .*" diff --git a/gdb/testsuite/gdb.threads/non-stop-fair-events.exp b/gdb/testsuite/gdb.threads/non-stop-fair-events.exp index 7593c2432f3c..53d62963f62b 100644 --- a/gdb/testsuite/gdb.threads/non-stop-fair-events.exp +++ b/gdb/testsuite/gdb.threads/non-stop-fair-events.exp @@ -21,17 +21,17 @@ set executable ${testfile} require {!target_info exists gdb,nosignals} set options { "additional_flags=-DTIMEOUT=$timeout" debug pthreads } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options] == -1} { - return -1 + return } gdb_test_no_output "set non-stop on" if {![runto_main]} { - return -1 + return } # We want "handle print", to make sure the target backend reports the # signal to the run control core. gdb_test "handle SIGUSR1 print nostop pass" "" diff --git a/gdb/testsuite/gdb.threads/omp-par-scope.exp b/gdb/testsuite/gdb.threads/omp-par-scope.exp index 5f919a1952a1..b561bf2f4a5b 100644 --- a/gdb/testsuite/gdb.threads/omp-par-scope.exp +++ b/gdb/testsuite/gdb.threads/omp-par-scope.exp @@ -34,11 +34,11 @@ if {[support_nested_function_tests]} { lappend opts "additional_flags=-DHAVE_NESTED_FUNCTION_SUPPORT" set have_nested_function_support 1 } if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } # gdb_openmp_setup may be defined to set auto-load safe-path and possibly # sysroot. These settings are required for gdb to be able to find # the libgomp python plugin. (sysroot only needs to be defined for @@ -59,11 +59,11 @@ if {[info procs gdb_openmp_setup] != ""} { return -1 } } if {![runto_main]} { - return -1 + return } # We want to invoke setup_kfail (and in some cases setup_xfail) when # GDB does not yet have support for finding the values of variables in # (non-master) threads. We'll check this by looking at the output of diff --git a/gdb/testsuite/gdb.threads/omp-task.exp b/gdb/testsuite/gdb.threads/omp-task.exp index a77ffe86cf95..636bcf989159 100644 --- a/gdb/testsuite/gdb.threads/omp-task.exp +++ b/gdb/testsuite/gdb.threads/omp-task.exp @@ -22,22 +22,22 @@ standard_testfile set have_nested_function_support 0 set opts {openmp debug} if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { - return -1 + return } if {[info procs gdb_openmp_setup] != ""} { if {[gdb_openmp_setup $binfile] != ""} { untested "could not set up OpenMP environment" return -1 } } if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "omp task shared"] gdb_test "continue" ".*Breakpoint 2.*" "continue 1" gdb_test "print share1" "= 9" diff --git a/gdb/testsuite/gdb.threads/pending-step.exp b/gdb/testsuite/gdb.threads/pending-step.exp index 4395195a703f..c9ff1de32c89 100644 --- a/gdb/testsuite/gdb.threads/pending-step.exp +++ b/gdb/testsuite/gdb.threads/pending-step.exp @@ -49,11 +49,11 @@ # breakpoint hit. GDB reports to the user a spurious SIGTRAP. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/print-threads.exp b/gdb/testsuite/gdb.threads/print-threads.exp index e03e2e48ccb5..a1ac1fdd230b 100644 --- a/gdb/testsuite/gdb.threads/print-threads.exp +++ b/gdb/testsuite/gdb.threads/print-threads.exp @@ -25,11 +25,11 @@ standard_testfile # regexp for "horizontal" text (i.e. doesn't include newline or # carriage return) set horiz "\[^\n\r\]*" if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } # Now we can proceed with the real testing. clean_restart ${::testfile} diff --git a/gdb/testsuite/gdb.threads/process-dies-while-handling-bp.exp b/gdb/testsuite/gdb.threads/process-dies-while-handling-bp.exp index e4ec42e0dd53..624422bb7ea2 100644 --- a/gdb/testsuite/gdb.threads/process-dies-while-handling-bp.exp +++ b/gdb/testsuite/gdb.threads/process-dies-while-handling-bp.exp @@ -26,11 +26,11 @@ standard_testfile set linenum [gdb_get_line_number "set break here"] if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } # The test proper. If COND_BP_TARGET is true, then test with # conditional breakpoints evaluated on the target side, if possible. diff --git a/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp b/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp index 7876e9f763c7..8ecacba59d5e 100644 --- a/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp +++ b/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp @@ -30,11 +30,11 @@ if { ![istarget "*-*-linux*"] } { } standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } for {set iteration 0} {$iteration < 10} {incr iteration} { with_test_prefix "iteration=$iteration" { if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/pthread_cond_wait.exp b/gdb/testsuite/gdb.threads/pthread_cond_wait.exp index a3d5cc2f2081..ae700b8715ca 100644 --- a/gdb/testsuite/gdb.threads/pthread_cond_wait.exp +++ b/gdb/testsuite/gdb.threads/pthread_cond_wait.exp @@ -20,11 +20,11 @@ # being blocked on a call to pthread_cond_wait(). standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} runto_main diff --git a/gdb/testsuite/gdb.threads/pthreads.exp b/gdb/testsuite/gdb.threads/pthreads.exp index 0e382af9835b..93d242b56f20 100644 --- a/gdb/testsuite/gdb.threads/pthreads.exp +++ b/gdb/testsuite/gdb.threads/pthreads.exp @@ -29,11 +29,11 @@ if {[istarget "*-*-linux"]} { } else { set target_cflags "" } if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set print sevenbit-strings" diff --git a/gdb/testsuite/gdb.threads/queue-signal.exp b/gdb/testsuite/gdb.threads/queue-signal.exp index c461df0aa28d..905f47c1243b 100644 --- a/gdb/testsuite/gdb.threads/queue-signal.exp +++ b/gdb/testsuite/gdb.threads/queue-signal.exp @@ -15,11 +15,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable { debug }] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/reconnect-signal.exp b/gdb/testsuite/gdb.threads/reconnect-signal.exp index bbd5e651b7f7..e1079f3d1feb 100644 --- a/gdb/testsuite/gdb.threads/reconnect-signal.exp +++ b/gdb/testsuite/gdb.threads/reconnect-signal.exp @@ -27,11 +27,11 @@ set executable ${testfile} if { [gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcfile}" \ "${binfile}" \ executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $executable if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/schedlock.exp b/gdb/testsuite/gdb.threads/schedlock.exp index a6c453c59c2c..0136d625e777 100644 --- a/gdb/testsuite/gdb.threads/schedlock.exp +++ b/gdb/testsuite/gdb.threads/schedlock.exp @@ -26,11 +26,11 @@ standard_testfile # The number of threads, including the main thread. set NUM 2 if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } # Now we can proceed with the real testing. # Get the current contents of the `args` array in the test program. diff --git a/gdb/testsuite/gdb.threads/siginfo-threads.exp b/gdb/testsuite/gdb.threads/siginfo-threads.exp index 81fc03ef5a52..acf1185cdfc5 100644 --- a/gdb/testsuite/gdb.threads/siginfo-threads.exp +++ b/gdb/testsuite/gdb.threads/siginfo-threads.exp @@ -18,17 +18,17 @@ set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" \ ${binfile} \ executable \ [list debug additional_flags=-lrt]] != "" } { - return -1 + return } clean_restart $testfile if {![runto_main]} { - return -1 + return } # `nostop noprint pass' could in some cases report false PASS due to # the (preempt 'handle') code path in linux-nat.c. diff --git a/gdb/testsuite/gdb.threads/signal-command-handle-nopass.exp b/gdb/testsuite/gdb.threads/signal-command-handle-nopass.exp index 4eff994fa098..d5b657bfc3dd 100644 --- a/gdb/testsuite/gdb.threads/signal-command-handle-nopass.exp +++ b/gdb/testsuite/gdb.threads/signal-command-handle-nopass.exp @@ -22,11 +22,11 @@ standard_testfile require {!target_info exists gdb,nosignals} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable { debug }] != "" } { - return -1 + return } # Run the test proper. STEP_OVER indicates whether we leave in place # a breakpoint that needs to be stepped over when we explicitly # request a signal be delivered with the "signal" command. diff --git a/gdb/testsuite/gdb.threads/signal-command-multiple-signals-pending.exp b/gdb/testsuite/gdb.threads/signal-command-multiple-signals-pending.exp index 983a5e8dc43c..9aeb8597fc93 100644 --- a/gdb/testsuite/gdb.threads/signal-command-multiple-signals-pending.exp +++ b/gdb/testsuite/gdb.threads/signal-command-multiple-signals-pending.exp @@ -20,11 +20,11 @@ standard_testfile require {!target_info exists gdb,nosignals} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable { debug }] != "" } { - return -1 + return } # Run the test proper. SCHEDLOCK indicates which variant (around # scheduler-locking) of the test to perform. diff --git a/gdb/testsuite/gdb.threads/signal-delivered-right-thread.exp b/gdb/testsuite/gdb.threads/signal-delivered-right-thread.exp index 0138cc0036a7..745447d3a075 100644 --- a/gdb/testsuite/gdb.threads/signal-delivered-right-thread.exp +++ b/gdb/testsuite/gdb.threads/signal-delivered-right-thread.exp @@ -17,11 +17,11 @@ standard_testfile require {!target_info exists gdb,nosignals} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable { debug }] != "" } { - return -1 + return } # Run test proper. COMMAND indicates whether to resume the inferior # with "signal 0" or "continue". diff --git a/gdb/testsuite/gdb.threads/signal-sigtrap.exp b/gdb/testsuite/gdb.threads/signal-sigtrap.exp index c3f5af8905e6..55c2ee626d5f 100644 --- a/gdb/testsuite/gdb.threads/signal-sigtrap.exp +++ b/gdb/testsuite/gdb.threads/signal-sigtrap.exp @@ -20,11 +20,11 @@ standard_testfile require {!target_info exists gdb,nosignals} if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pthreads}]} { - return -1 + return } # Run test proper. SIGTRAP_THREAD is the thread that should get the # SIGTRAP. diff --git a/gdb/testsuite/gdb.threads/signal-while-stepping-over-bp-other-thread.exp b/gdb/testsuite/gdb.threads/signal-while-stepping-over-bp-other-thread.exp index 589da62a15b2..f7bc6cb36b9e 100644 --- a/gdb/testsuite/gdb.threads/signal-while-stepping-over-bp-other-thread.exp +++ b/gdb/testsuite/gdb.threads/signal-while-stepping-over-bp-other-thread.exp @@ -27,11 +27,11 @@ set executable ${testfile} require {!target_info exists gdb,nosignals} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable [list debug "incdir=${objdir}"]] != "" } { - return -1 + return } proc get_value {var test} { global expect_out global gdb_prompt @@ -50,11 +50,11 @@ proc get_value {var test} { # Start with a fresh gdb. clean_restart $executable if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "set wait-thread-2 breakpoint here"] gdb_continue_to_breakpoint "run to wait-thread-2 breakpoint" gdb_test "info threads" "" "info threads with thread 2" diff --git a/gdb/testsuite/gdb.threads/sigstep-threads.exp b/gdb/testsuite/gdb.threads/sigstep-threads.exp index 77f65cf359d6..1ad86f01440c 100644 --- a/gdb/testsuite/gdb.threads/sigstep-threads.exp +++ b/gdb/testsuite/gdb.threads/sigstep-threads.exp @@ -16,17 +16,17 @@ standard_testfile set executable ${testfile} if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $executable if {![runto_main]} { - return -1 + return } # `noprint' would not test the full logic of GDB. gdb_test "handle SIGUSR1 nostop print pass" \ "\r\nSIGUSR1\[ \t\]+No\[ \t\]+Yes\[ \t\]+Yes\[ \t\].*" diff --git a/gdb/testsuite/gdb.threads/sigthread.exp b/gdb/testsuite/gdb.threads/sigthread.exp index 5e6094d9691a..af5941a41cdd 100644 --- a/gdb/testsuite/gdb.threads/sigthread.exp +++ b/gdb/testsuite/gdb.threads/sigthread.exp @@ -19,11 +19,11 @@ standard_testfile # This test requires sending ^C to interrupt the running target. require {!target_info exists gdb,nointerrupts} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable { debug }] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/step-bg-decr-pc-switch-thread.exp b/gdb/testsuite/gdb.threads/step-bg-decr-pc-switch-thread.exp index a87e076398ea..deb3432c9a8e 100644 --- a/gdb/testsuite/gdb.threads/step-bg-decr-pc-switch-thread.exp +++ b/gdb/testsuite/gdb.threads/step-bg-decr-pc-switch-thread.exp @@ -29,11 +29,11 @@ # been single-stepped, not continued. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { - return -1 + return } if {![runto_main]} { return } diff --git a/gdb/testsuite/gdb.threads/step-over-lands-on-breakpoint.exp b/gdb/testsuite/gdb.threads/step-over-lands-on-breakpoint.exp index ccd81078ba9c..d391239f5018 100644 --- a/gdb/testsuite/gdb.threads/step-over-lands-on-breakpoint.exp +++ b/gdb/testsuite/gdb.threads/step-over-lands-on-breakpoint.exp @@ -19,11 +19,11 @@ standard_testfile set executable ${testfile} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable [list debug "incdir=${objdir}"]] != "" } { - return -1 + return } # The test proper. DISPLACED is true if we should try with displaced # stepping. COMMAND is the execution command to test. proc do_test {displaced command} { diff --git a/gdb/testsuite/gdb.threads/step-over-trips-on-watchpoint.exp b/gdb/testsuite/gdb.threads/step-over-trips-on-watchpoint.exp index 0a0c5edb97a3..877309a9f4ef 100644 --- a/gdb/testsuite/gdb.threads/step-over-trips-on-watchpoint.exp +++ b/gdb/testsuite/gdb.threads/step-over-trips-on-watchpoint.exp @@ -24,11 +24,11 @@ set executable ${testfile} # watchpoints. require allow_hw_watchpoint_tests if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable [list debug "incdir=${objdir}"]] != "" } { - return -1 + return } # The test proper. DISPLACED is true if we should try with displaced # stepping. WITH_BP is true if we should try with a thread-specific # breakpoint (for the wrong thread) right after the instruction that diff --git a/gdb/testsuite/gdb.threads/stepi-random-signal.exp b/gdb/testsuite/gdb.threads/stepi-random-signal.exp index a63b9b76502b..64b07ec00bb8 100644 --- a/gdb/testsuite/gdb.threads/stepi-random-signal.exp +++ b/gdb/testsuite/gdb.threads/stepi-random-signal.exp @@ -23,18 +23,18 @@ set executable ${testfile} if { [gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcfile}" \ "${binfile}" \ executable {debug}] != "" } { untested "failed to compile" - return -1 + return } clean_restart $executable # Start the second thread. if {![runto start]} { - return -1 + return } # Go back to the main thread, and leave it in the loop, where we're # reasonably sure we don't have 'conditional jmp $pc'-like # instructions. We wouldn't be able to detect whether a stepi makes diff --git a/gdb/testsuite/gdb.threads/stop-with-handle.exp b/gdb/testsuite/gdb.threads/stop-with-handle.exp index 895d7ef7bac7..de40a3f1e946 100644 --- a/gdb/testsuite/gdb.threads/stop-with-handle.exp +++ b/gdb/testsuite/gdb.threads/stop-with-handle.exp @@ -23,11 +23,11 @@ standard_testfile if {[prepare_for_testing "failed to prepare" \ "${testfile}" "${srcfile}" {debug pthreads}]} { - return -1 + return } if {![runto_main]} { return 0 } diff --git a/gdb/testsuite/gdb.threads/switch-threads.exp b/gdb/testsuite/gdb.threads/switch-threads.exp index bd25b1b49ffb..10e40e6843b8 100644 --- a/gdb/testsuite/gdb.threads/switch-threads.exp +++ b/gdb/testsuite/gdb.threads/switch-threads.exp @@ -24,11 +24,11 @@ # command. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} runto_main diff --git a/gdb/testsuite/gdb.threads/thread-bp-deleted.exp b/gdb/testsuite/gdb.threads/thread-bp-deleted.exp index 037e8288b62f..f7791e0ea90f 100644 --- a/gdb/testsuite/gdb.threads/thread-bp-deleted.exp +++ b/gdb/testsuite/gdb.threads/thread-bp-deleted.exp @@ -24,11 +24,11 @@ standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile \ {debug pthreads}] == -1} { - return -1 + return } # We need to do things a little differently when using the remote protocol. set is_remote \ [expr \ @@ -41,19 +41,19 @@ save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"maint set target-non-stop on\"" clean_restart ${::testfile} } if {![runto_main]} { - return -1 + return } # Check we hace non-stop mode. We do try to force this on above, but maybe # the target doesn't support non-stop mode, in which case (hopefully) # non-stop mode will still show as off, and this test should not be run. if {![is_target_non_stop]} { unsupported "required non-stop mode" - return -1 + return } delete_breakpoints gdb_breakpoint "breakpt" diff --git a/gdb/testsuite/gdb.threads/thread-execl.exp b/gdb/testsuite/gdb.threads/thread-execl.exp index b926664b4508..cd6d6e4f57bf 100644 --- a/gdb/testsuite/gdb.threads/thread-execl.exp +++ b/gdb/testsuite/gdb.threads/thread-execl.exp @@ -18,11 +18,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable debug] != "" } { - return -1 + return } # Run the test proper. SCHEDLOCK specifies what scheduler-locking # should be set to. diff --git a/gdb/testsuite/gdb.threads/thread-find.exp b/gdb/testsuite/gdb.threads/thread-find.exp index acaf99f3c02d..b08e148a081a 100644 --- a/gdb/testsuite/gdb.threads/thread-find.exp +++ b/gdb/testsuite/gdb.threads/thread-find.exp @@ -16,11 +16,11 @@ # Please email any bugs, comments, and/or additions to this file to: # bug-gdb@gnu.org standard_testfile linux-dp.c if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != ""} { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set print sevenbit-strings" runto_main diff --git a/gdb/testsuite/gdb.threads/thread-specific-bp.exp b/gdb/testsuite/gdb.threads/thread-specific-bp.exp index 36d2344619a9..d698b0ce96b1 100644 --- a/gdb/testsuite/gdb.threads/thread-specific-bp.exp +++ b/gdb/testsuite/gdb.threads/thread-specific-bp.exp @@ -19,11 +19,11 @@ standard_testfile if {[gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcfile}" \ "${binfile}" executable {debug} ] != "" } { - return -1 + return } # Extract and return the thread ID of the thread stopped at function # FUNC. diff --git a/gdb/testsuite/gdb.threads/thread-specific.exp b/gdb/testsuite/gdb.threads/thread-specific.exp index 814e870bc89b..79932ab9dc17 100644 --- a/gdb/testsuite/gdb.threads/thread-specific.exp +++ b/gdb/testsuite/gdb.threads/thread-specific.exp @@ -19,11 +19,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } # Return a list of the valid thread IDs, with the initial thread first. proc get_thread_list { } { global gdb_prompt diff --git a/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp b/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp index d46c3de8c203..d77b323338cc 100644 --- a/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp +++ b/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp @@ -23,11 +23,11 @@ standard_testfile interrupted-hand-call.c # Some targets can't do function calls, so don't even bother with this # test. require {!target_info exists gdb,cannot_call_functions} if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DNR_THREADS=$NR_THREADS"]] != "" } { - return -1 + return } clean_restart ${::testfile} if { ![runto_main] } { diff --git a/gdb/testsuite/gdb.threads/thread_check.exp b/gdb/testsuite/gdb.threads/thread_check.exp index 1a79e1126502..e48e3d5b3c37 100644 --- a/gdb/testsuite/gdb.threads/thread_check.exp +++ b/gdb/testsuite/gdb.threads/thread_check.exp @@ -33,11 +33,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} diff --git a/gdb/testsuite/gdb.threads/thread_events.exp b/gdb/testsuite/gdb.threads/thread_events.exp index f7075f82724e..37579bdd395d 100644 --- a/gdb/testsuite/gdb.threads/thread_events.exp +++ b/gdb/testsuite/gdb.threads/thread_events.exp @@ -34,11 +34,11 @@ if {[target_info gdb_protocol] == "remote" standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } proc gdb_test_thread_start {messages_enabled command pattern message} { global gdb_prompt diff --git a/gdb/testsuite/gdb.threads/threadapply.exp b/gdb/testsuite/gdb.threads/threadapply.exp index 73b61056a192..f8827ae7ea65 100644 --- a/gdb/testsuite/gdb.threads/threadapply.exp +++ b/gdb/testsuite/gdb.threads/threadapply.exp @@ -20,11 +20,11 @@ # and will continue for each thread even though an error may occur in # backtracing one of the threads. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} # diff --git a/gdb/testsuite/gdb.threads/threadcrash.exp b/gdb/testsuite/gdb.threads/threadcrash.exp index 1699449f0ed6..aa39f6509e9c 100644 --- a/gdb/testsuite/gdb.threads/threadcrash.exp +++ b/gdb/testsuite/gdb.threads/threadcrash.exp @@ -271,11 +271,11 @@ proc_with_prefix test_gcore {} { standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile \ {debug pthreads}]} { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set backtrace limit unlimited" diff --git a/gdb/testsuite/gdb.threads/threxit-hop-specific.exp b/gdb/testsuite/gdb.threads/threxit-hop-specific.exp index f9064b8a19ba..79134a0c5428 100644 --- a/gdb/testsuite/gdb.threads/threxit-hop-specific.exp +++ b/gdb/testsuite/gdb.threads/threxit-hop-specific.exp @@ -18,11 +18,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable debug] != "" } { - return -1 + return } clean_restart ${::testfile} runto_main diff --git a/gdb/testsuite/gdb.threads/tid-reuse.exp b/gdb/testsuite/gdb.threads/tid-reuse.exp index ce5986986507..57a544f90088 100644 --- a/gdb/testsuite/gdb.threads/tid-reuse.exp +++ b/gdb/testsuite/gdb.threads/tid-reuse.exp @@ -17,15 +17,15 @@ # exited thread is reused. GDB should not crash when this happens. standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile { debug pthreads }] == -1} { - return -1 + return } if {![runto_main]} { - return -1 + return } delete_breakpoints # Avoid dumping a ton of thread create/exit info in the logs. diff --git a/gdb/testsuite/gdb.threads/tls-core.exp b/gdb/testsuite/gdb.threads/tls-core.exp index e59f22b24545..d2e49dbde02b 100644 --- a/gdb/testsuite/gdb.threads/tls-core.exp +++ b/gdb/testsuite/gdb.threads/tls-core.exp @@ -15,11 +15,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable { debug }] != "" } { - return -1 + return } # Generate a native core file. set corefile [core_find $binfile] diff --git a/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp b/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp index cca67f882e1d..9d2a805c4a5f 100644 --- a/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp +++ b/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp @@ -15,11 +15,11 @@ standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ {pie}] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { return 0 diff --git a/gdb/testsuite/gdb.threads/tls-nodebug.exp b/gdb/testsuite/gdb.threads/tls-nodebug.exp index cc6573aae6c5..e02788700d89 100644 --- a/gdb/testsuite/gdb.threads/tls-nodebug.exp +++ b/gdb/testsuite/gdb.threads/tls-nodebug.exp @@ -21,11 +21,11 @@ if {[istarget "*-*-linux"]} { } else { set target_cflags "" } if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable []] != "" } { - return -1 + return } clean_restart ${::testfile} if {![runto_main]} { return 0 diff --git a/gdb/testsuite/gdb.threads/tls-sepdebug.exp b/gdb/testsuite/gdb.threads/tls-sepdebug.exp index 1b47fe243ee0..5f705d1750d0 100644 --- a/gdb/testsuite/gdb.threads/tls-sepdebug.exp +++ b/gdb/testsuite/gdb.threads/tls-sepdebug.exp @@ -44,11 +44,11 @@ set binsharedfile [standard_output_file ${binsharedbase}] # 'thread_local' to indicate thread local storage. This is available # as a macro starting in C11 and became a C-language keyword in C23. if { [build_executable "build library" ${binsharedfile} ${srcsharedfile} \ {debug shlib additional_flags=-std=c11}] == -1 } { untested "Couldn't compile test library" - return -1 + return } # Strip debug information from $binsharedfile, placing it in # ${binsharedfile}.debug. Also add a .gnu_debuglink in the former, # pointing to the latter. @@ -59,11 +59,11 @@ gdb_gnu_strip_debug ${binsharedfile} if { [gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcmainfile} ${binsharedfile}" \ "${binmainfile}" executable [list debug additional_flags=-std=c11]] \ != "" } { untested "Couldn't compile test program" - return -1 + return } set absdir [file dirname [standard_output_file ${binsharedbase}]] if { [info exists ::env(LD_LIBRARY_PATH)] } { set ld_library_path $::env(LD_LIBRARY_PATH) diff --git a/gdb/testsuite/gdb.threads/tls-shared.exp b/gdb/testsuite/gdb.threads/tls-shared.exp index 768b84a2103a..a293809105d6 100644 --- a/gdb/testsuite/gdb.threads/tls-shared.exp +++ b/gdb/testsuite/gdb.threads/tls-shared.exp @@ -23,11 +23,11 @@ set binfile_lib [standard_output_file ${libfile}.so] remote_exec build "rm -f ${binfile}" if { [gdb_compile_shlib_pthreads ${srcdir}/${subdir}/${srcfile_lib} ${binfile_lib} {debug}] != "" || [gdb_compile_pthreads ${srcdir}/${subdir}/${srcfile} ${binfile} executable [list debug shlib=${binfile_lib}]] != ""} { - return -1 + return } clean_restart ${::testfile} gdb_load_shlib ${binfile_lib} diff --git a/gdb/testsuite/gdb.threads/tls-so_extern.exp b/gdb/testsuite/gdb.threads/tls-so_extern.exp index 91205308067b..eb3f32df6210 100644 --- a/gdb/testsuite/gdb.threads/tls-so_extern.exp +++ b/gdb/testsuite/gdb.threads/tls-so_extern.exp @@ -22,11 +22,11 @@ set srcfile_lib ${libfile}.c set binfile_lib [standard_output_file ${libfile}.so] if { [gdb_compile_shlib_pthreads ${srcdir}/${subdir}/${srcfile_lib} ${binfile_lib} {debug}] != "" || [gdb_compile_pthreads ${srcdir}/${subdir}/${srcfile} ${binfile} executable [list debug shlib=${binfile_lib}]] != ""} { - return -1 + return } clean_restart ${::testfile} gdb_load_shlib ${binfile_lib} diff --git a/gdb/testsuite/gdb.threads/tls-var.exp b/gdb/testsuite/gdb.threads/tls-var.exp index fe95df91dbbd..5b2968a7bd01 100644 --- a/gdb/testsuite/gdb.threads/tls-var.exp +++ b/gdb/testsuite/gdb.threads/tls-var.exp @@ -20,11 +20,11 @@ set objmainfile [standard_output_file ${testfile}-main.o] set executable ${testfile} if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${objfile} object {debug}] != "" || [gdb_compile ${srcdir}/${subdir}/${srcmainfile} ${objmainfile} object {}] != "" || [gdb_compile_pthreads "${objfile} ${objmainfile}" ${binfile} executable {}] != ""} { - return -1 + return } clean_restart ${executable} if {![runto_main]} { diff --git a/gdb/testsuite/gdb.threads/tls.exp b/gdb/testsuite/gdb.threads/tls.exp index 4a93433e8333..bf48a6f9fc9e 100644 --- a/gdb/testsuite/gdb.threads/tls.exp +++ b/gdb/testsuite/gdb.threads/tls.exp @@ -23,11 +23,11 @@ if {[istarget "*-*-linux"]} { } else { set target_cflags "" } if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile} ${srcdir}/${subdir}/${srcfile2}" "${binfile}" executable [list c++ debug]] != "" } { - return -1 + return } ### Compute the value of the a_thread_local variable. proc compute_expected_value {value} { set expected_value 0 diff --git a/gdb/testsuite/gdb.threads/vfork-follow-child-exec.exp b/gdb/testsuite/gdb.threads/vfork-follow-child-exec.exp index ade63410da9d..555bc463bb5b 100644 --- a/gdb/testsuite/gdb.threads/vfork-follow-child-exec.exp +++ b/gdb/testsuite/gdb.threads/vfork-follow-child-exec.exp @@ -19,11 +19,11 @@ require allow_fork_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}]} { - return -1 + return } # DETACH indicates whether "set detach-on-fork" is enabled. It is # either "on" or "off". diff --git a/gdb/testsuite/gdb.threads/vfork-follow-child-exit.exp b/gdb/testsuite/gdb.threads/vfork-follow-child-exit.exp index 0f35bd5faa04..b0e8079cf2df 100644 --- a/gdb/testsuite/gdb.threads/vfork-follow-child-exit.exp +++ b/gdb/testsuite/gdb.threads/vfork-follow-child-exit.exp @@ -19,11 +19,11 @@ require allow_fork_tests standard_testfile if {[build_executable "failed to prepare" $testfile $srcfile {debug pthreads}]} { - return -1 + return } # DETACH indicates whether "set detach-on-fork" is enabled. It is # either "on" or "off". diff --git a/gdb/testsuite/gdb.threads/vfork-multi-inferior.exp b/gdb/testsuite/gdb.threads/vfork-multi-inferior.exp index 2686eba08e70..e258ec719e91 100644 --- a/gdb/testsuite/gdb.threads/vfork-multi-inferior.exp +++ b/gdb/testsuite/gdb.threads/vfork-multi-inferior.exp @@ -47,18 +47,18 @@ set nr_loops 20 # Compile the main program that calls vfork and hits a breakpoint. set opts [list debug additional_flags=-DNR_LOOPS=$nr_loops] if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ $opts] != "" } { untested "failed to compile" - return -1 + return } # Compile the secondary program, which just sleeps. if { [gdb_compile "${srcdir}/${subdir}/${srcfile_sleep}" "${binfile_sleep}" executable \ {debug}] != "" } { untested "failed to compile" - return -1 + return } # We exercise two methods of getting a second inferior to execute while the # first one vforks. METHOD can be: # diff --git a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp index 980ca4d66d0c..58b16be70f26 100644 --- a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp +++ b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp @@ -30,11 +30,11 @@ if {![istarget *-*-linux*]} { return 0 } standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" ${binfile} executable [list debug additional_flags=-lrt]] != "" } { - return -1 + return } foreach reorder {0 1} { with_test_prefix "reorder$reorder" { clean_restart $testfile diff --git a/gdb/testsuite/gdb.threads/watchthreads.exp b/gdb/testsuite/gdb.threads/watchthreads.exp index 77a3f7bc5e2c..e975e22e5730 100644 --- a/gdb/testsuite/gdb.threads/watchthreads.exp +++ b/gdb/testsuite/gdb.threads/watchthreads.exp @@ -26,11 +26,11 @@ proc target_no_stopped_data { } { return [istarget s390*-*-*] } standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable debug] != "" } { - return -1 + return } clean_restart $::testfile gdb_test_no_output "set can-use-hw-watchpoints 1" "" diff --git a/gdb/testsuite/gdb.threads/watchthreads2.exp b/gdb/testsuite/gdb.threads/watchthreads2.exp index 00229d384c06..49884f4136dd 100644 --- a/gdb/testsuite/gdb.threads/watchthreads2.exp +++ b/gdb/testsuite/gdb.threads/watchthreads2.exp @@ -26,11 +26,11 @@ set X_INCR_COUNT 10 # so the test is only meaningful on a system with hardware watchpoints. require allow_hw_watchpoint_tests standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DNR_THREADS=$NR_THREADS -DX_INCR_COUNT=$X_INCR_COUNT"]] != "" } { - return -1 + return } clean_restart ${::testfile} gdb_test_no_output "set can-use-hw-watchpoints 1" "" @@ -66,11 +66,11 @@ for { set i 0 } { $i < $NR_THREADS } { incr i } { if { $nr_started == $NR_THREADS } { pass "all threads started" } else { fail "all threads started" # No point in continuing. - return -1 + return } # Check that multiple uses of the 'thread' keyword will give an error. gdb_test "watch x thread 1 thread 2" "You can specify only one thread\\." diff --git a/gdb/testsuite/gdb.threads/wp-replication.exp b/gdb/testsuite/gdb.threads/wp-replication.exp index d5f0ff0068c1..28a5071bd5e5 100644 --- a/gdb/testsuite/gdb.threads/wp-replication.exp +++ b/gdb/testsuite/gdb.threads/wp-replication.exp @@ -29,11 +29,11 @@ set NR_TRIGGERS_PER_THREAD 2 # only meaningful on a target with hardware watchpoint support. require allow_hw_watchpoint_tests standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DNR_THREADS=$NR_THREADS -DNR_TRIGGERS_PER_THREAD=$NR_TRIGGERS_PER_THREAD"]] != "" } { - return -1 + return } clean_restart ${::testfile} # Force hardware watchpoints to be used. From patchwork Wed Apr 29 23:04:24 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134220 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 83C424358A4D for ; Wed, 29 Apr 2026 23:10:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 83C424358A4D Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=ssF7XrxE X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2a.google.com (mail-vk1-xa2a.google.com [IPv6:2607:f8b0:4864:20::a2a]) by sourceware.org (Postfix) with ESMTPS id 475024BB58BE for ; Wed, 29 Apr 2026 23:06:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 475024BB58BE Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 475024BB58BE Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503996; cv=none; b=G1who2koSgTOWp+i560t4yVTLa3cqjeaofk+qAxEn5a/hofAGAxI20OrImwdAo3yP8gqHDt0PFy+37qEg2HgsEEnVwQPyY+2C56wlmQUqR3vaC68m8F9y98z+WGWOinl8lTyt6pgDNtHCnKN5vXyRJmNkmFmNh5Xc6vgRDV4ZlM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503996; c=relaxed/simple; bh=YkitVznedLHaShkMLm36N/RkkLaxMCFLZGoqK3q8gPo=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=iIZCPd7C3//+Wdgw3tGTT9kPkpn+4kluwwd0L3vqzR/2bAmI6iIj4Ek1ZRQJggu106hysgfXwvaW8jm+gOWhoB0UxXRB5tZNOpQmjCpRIy+RC1iYpW0sjyZJ0rhdGdGbeJownIy72tAGu/oztfvIeen4iQZYBA5TBTACzRijbLM= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 475024BB58BE Received: by mail-vk1-xa2a.google.com with SMTP id 71dfb90a1353d-56efdc96b05so177673e0c.1 for ; Wed, 29 Apr 2026 16:06:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503996; x=1778108796; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=TpeKbbld6P+2kbvB5dGEMaNJjINvbiLNtBieaLlof5o=; b=ssF7XrxEhUpSBhjvo7kx7R60mVDthYcAjSj/v+jNMHdni5GWAgE/QgxeGcOkeAJWfh WO/M/z3EwwMpN0R3MG9d+BqI+BfGWnQGNFn8Yby0SNdS0m7JljVB1k8twTPn7AaXA39s Rf7rS8KLryW0nWjf6F/ENQRvrIBjUtfJge8ENMTDpKYeBxSWGq3U8Lu1jE8AqVJ7p2gn SoN8a2ovim+WAvp+2H/xwtZEJ6611ZD2BElYrjD7RKltCHn7Y01zioVmEyVR2fXRFA7U 1VlJUdUpKUbZL2gSaJCbOYOr44FgFywLq/Cm3GDG8ExfrZknc4AyJ17GFWyaDN+ifw52 PZ1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503996; x=1778108796; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=TpeKbbld6P+2kbvB5dGEMaNJjINvbiLNtBieaLlof5o=; b=Av1oYXltqFCirPBu/+GZ7CtKstBx+dV4g3j5PdIKuG3AbwMCqv/TmSd/E99r9OHUfk BHtatWwwa9J7YjJXmruaknOQfwrZ1e3kRig9vOttUOmZXMyzr9JB72gv4ZepElIxDsYk FpraopVZvb3aFnsx19vuTG7yNapA3kntlC95/E2qIzm/3GJ4/xvceojk79RRQlXom7ES iax4IqJItv95Gewoor3LpB7b1TyptJqSBY76mtWOVVePK5CLYs3M3Q6Inx+3+HaASwKy H6WVA+RDQXLM6fBgRxgzKIuQ/6291WWKVYsgGj8bUOHTMXTcxagm8P5Zn/sCC8m2JvE9 awjw== X-Gm-Message-State: AOJu0YykPLswcFyRTdZJ9dXS7NODUqJd4FnSLY09K4N/mUTwL2G3PTfF q8k4cbL0fTeCVjAGtmHdvhzUebIl2/QbrDN8qmHNoxI0rBOcwWhz0xkJrwsvSWng31AQFAH+wie ARDOA X-Gm-Gg: AeBDieuDwupDrovPhCAjhMKARBsjCYHPenRDTs2lkK7nGeqXdiC4v5yTwR3bI4BzNNm 4iQwObcutlseLA9WdpAWBe4tZmYv5SC0DAg49jP3tiN8xhS95qfDB9anaxZ0MmY6932TVpn2hzl QD1rtJMOYqJXktjUUsZwgyz6kw9/lTyPRSaGHq2y4tS0cdqkkcoHnpg4XHtRdlW5TTErudkbm6C V4GQjOyGfvH6hoLtGwxGgI+AGy7KbJi7wA2Lp435hIcOqmglUvSikwRgJ1eTpK1pRj02/xKr/xB rYBhZOBa7XAm0/GHLQoCEMT97txmBW2FSH4n8yNMPCed4SFWF5h167QhP2OYchi3g50D/W0kx4O S8yFVVKek4Ngg19G+/tsL3KQIMX8IEoV4iR8BmHL0H/sjyV2YwxeP7kkE0q6oggLpW97amI2Azm s9a14djUpVbFN4jU4PVxQg0wHBxeWcXHPQtr2E1NsHQe8f X-Received: by 2002:a05:6122:4886:b0:56c:fe16:f54b with SMTP id 71dfb90a1353d-573c96d0565mr105612e0c.11.1777503995533; Wed, 29 Apr 2026 16:06:35 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6d87647sm1991813e0c.9.2026.04.29.16.06.33 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:34 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 33/37] GDB: testsuite: threads: Don't return 0 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:24 -0300 Message-ID: <20260429230432.60487-34-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is a bit different than the others. I noticed that gdb.threads has many cases of "return 0" from the top level, so this patch is purely the result of running: $ sed -i 's/^ return 0/ return/' *.exp* inside gdb/testsuite/gdb.threads. There were a number of false positives so not all sed changes were incorporated. --- .../gdb.threads/attach-many-short-lived-threads.exp | 2 +- gdb/testsuite/gdb.threads/corethreads.exp | 2 +- gdb/testsuite/gdb.threads/del-pending-thread-bp.exp | 2 +- gdb/testsuite/gdb.threads/dlopen-libpthread.exp | 2 +- gdb/testsuite/gdb.threads/hand-call-in-threads.exp | 2 +- gdb/testsuite/gdb.threads/interrupted-hand-call.exp | 2 +- .../gdb.threads/next-while-other-thread-longjmps.exp | 2 +- gdb/testsuite/gdb.threads/pending-step.exp | 2 +- .../process-exit-status-is-leader-exit-status.exp | 2 +- gdb/testsuite/gdb.threads/queue-signal.exp | 2 +- gdb/testsuite/gdb.threads/reconnect-signal.exp | 6 +++--- gdb/testsuite/gdb.threads/stop-with-handle.exp | 2 +- gdb/testsuite/gdb.threads/thread-unwindonsignal.exp | 2 +- gdb/testsuite/gdb.threads/threadapply.exp | 2 +- gdb/testsuite/gdb.threads/tls-nodebug-pie.exp | 2 +- gdb/testsuite/gdb.threads/tls-shared.exp | 2 +- gdb/testsuite/gdb.threads/tls-so_extern.exp | 2 +- gdb/testsuite/gdb.threads/tls-var.exp | 2 +- gdb/testsuite/gdb.threads/watchthreads-reorder.exp | 2 +- gdb/testsuite/gdb.threads/watchthreads.exp | 2 +- gdb/testsuite/gdb.threads/watchthreads2.exp | 2 +- gdb/testsuite/gdb.threads/wp-replication.exp | 2 +- 22 files changed, 24 insertions(+), 24 deletions(-) diff --git a/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp b/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp index 0f1b141b1ea1..6f51e607d77d 100644 --- a/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp +++ b/gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp @@ -44,11 +44,11 @@ proc bad_dejagnu {} { return 0 } if {[bad_dejagnu]} { unsupported "broken DejaGnu" - return 0 + return } require can_spawn_for_attach standard_testfile diff --git a/gdb/testsuite/gdb.threads/corethreads.exp b/gdb/testsuite/gdb.threads/corethreads.exp index 3749e3507bdc..4e520c5e8f22 100644 --- a/gdb/testsuite/gdb.threads/corethreads.exp +++ b/gdb/testsuite/gdb.threads/corethreads.exp @@ -28,11 +28,11 @@ if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executa } set corefile [core_find $binfile] if {$corefile == ""} { untested "unable to create or find corefile" - return 0 + return } clean_restart $executable gdb_test "core-file $corefile" "Core was generated by .*" "load core" diff --git a/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp b/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp index 09a6f56a5660..c318b38b472a 100644 --- a/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp +++ b/gdb/testsuite/gdb.threads/del-pending-thread-bp.exp @@ -43,11 +43,11 @@ if { [prepare_for_testing "failed to prepare" $testfile $srcfile \ } gdb_locate_shlib $binfile_lib if {![runto_main]} { - return 0 + return } # Run until we have two threads. gdb_breakpoint "breakpt" gdb_continue_to_breakpoint "first breakpt call" diff --git a/gdb/testsuite/gdb.threads/dlopen-libpthread.exp b/gdb/testsuite/gdb.threads/dlopen-libpthread.exp index 03ce0dd1612d..01f2186bcdc8 100644 --- a/gdb/testsuite/gdb.threads/dlopen-libpthread.exp +++ b/gdb/testsuite/gdb.threads/dlopen-libpthread.exp @@ -13,11 +13,11 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . require isnative allow_shlib_tests if {![istarget *-linux*]} { - return 0 + return } load_lib prelink-support.exp set testfile "dlopen-libpthread" diff --git a/gdb/testsuite/gdb.threads/hand-call-in-threads.exp b/gdb/testsuite/gdb.threads/hand-call-in-threads.exp index f6d29720cc6f..2f5eaa5405bf 100644 --- a/gdb/testsuite/gdb.threads/hand-call-in-threads.exp +++ b/gdb/testsuite/gdb.threads/hand-call-in-threads.exp @@ -45,11 +45,11 @@ proc get_dummy_frame_number { } { } clean_restart ${::testfile} if { ![runto_main] } { - return 0 + return } gdb_test "break all_threads_running" \ "Breakpoint 2 at .*: file .*${srcfile}, line .*" \ "breakpoint on all_threads_running" diff --git a/gdb/testsuite/gdb.threads/interrupted-hand-call.exp b/gdb/testsuite/gdb.threads/interrupted-hand-call.exp index 23a3d038c09a..fe39b4ee9035 100644 --- a/gdb/testsuite/gdb.threads/interrupted-hand-call.exp +++ b/gdb/testsuite/gdb.threads/interrupted-hand-call.exp @@ -29,11 +29,11 @@ if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executab } clean_restart ${::testfile} if { ![runto_main] } { - return 0 + return } gdb_test "break all_threads_running" \ "Breakpoint 2 at .*: file .*${srcfile}, line .*" \ "breakpoint on all_threads_running" diff --git a/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp b/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp index 6852e8d7f876..0647ff5cb760 100644 --- a/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp +++ b/gdb/testsuite/gdb.threads/next-while-other-thread-longjmps.exp @@ -26,11 +26,11 @@ if {[prepare_for_testing "failed to prepare" \ $testfile $srcfile {c++ debug pthreads}] == -1} { return } if {![runto_main]} { - return 0 + return } gdb_breakpoint $linenum gdb_continue_to_breakpoint "start line" diff --git a/gdb/testsuite/gdb.threads/pending-step.exp b/gdb/testsuite/gdb.threads/pending-step.exp index c9ff1de32c89..a4fc5807167c 100644 --- a/gdb/testsuite/gdb.threads/pending-step.exp +++ b/gdb/testsuite/gdb.threads/pending-step.exp @@ -55,11 +55,11 @@ if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executab } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } gdb_breakpoint [gdb_get_line_number "insert breakpoint here"] gdb_continue_to_breakpoint "continue to first breakpoint hit" diff --git a/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp b/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp index 8ecacba59d5e..80afd0e1f1a2 100644 --- a/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp +++ b/gdb/testsuite/gdb.threads/process-exit-status-is-leader-exit-status.exp @@ -24,11 +24,11 @@ # expected to be able to reproduce the error reliably. Multiple # executions (or increasing the number of iterations) might be # required to reproduce the error with a misbehaving GDB. if { ![istarget "*-*-linux*"] } { - return 0 + return } standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] == -1} { diff --git a/gdb/testsuite/gdb.threads/queue-signal.exp b/gdb/testsuite/gdb.threads/queue-signal.exp index 905f47c1243b..aaa5bc91818a 100644 --- a/gdb/testsuite/gdb.threads/queue-signal.exp +++ b/gdb/testsuite/gdb.threads/queue-signal.exp @@ -49,11 +49,11 @@ gdb_test_multiple "bt" "determine thread functions" { } # No point in continuing if we couldn't figure out which thread is which. if { $sigusr1_thread == 0 } { # FAIL already recorded. - return 0 + return } # Advance each thread to where we want them one at a time. gdb_test_no_output "set scheduler-locking on" gdb_test_no_output "set var ready = 1" diff --git a/gdb/testsuite/gdb.threads/reconnect-signal.exp b/gdb/testsuite/gdb.threads/reconnect-signal.exp index e1079f3d1feb..f7a66ac844db 100644 --- a/gdb/testsuite/gdb.threads/reconnect-signal.exp +++ b/gdb/testsuite/gdb.threads/reconnect-signal.exp @@ -16,11 +16,11 @@ # Test that disconnecting and reconnecting doesn't lose signals. set gdbserver_reconnect_p 1 if { [info proc gdb_reconnect] == "" } { unsupported "requires gdbserver reconnect" - return 0 + return } standard_testfile set executable ${testfile} @@ -33,11 +33,11 @@ if { [gdb_compile_pthreads \ } clean_restart $executable if {![runto_main]} { - return 0 + return } gdb_test "continue" "signal SIGUSR1.*" "continue to signal" # Check that it's thread 2 that is selected. @@ -65,11 +65,11 @@ set test "reconnect after signal" set res [gdb_reconnect] if { [lindex $res 0] == 0 } { pass $test } else { fail $test - return 0 + return } # Check that thread 2 is re-selected. gdb_test "info threads" "\\* 2 .*" "thread 2 is selected on reconnect" diff --git a/gdb/testsuite/gdb.threads/stop-with-handle.exp b/gdb/testsuite/gdb.threads/stop-with-handle.exp index de40a3f1e946..be1d38602778 100644 --- a/gdb/testsuite/gdb.threads/stop-with-handle.exp +++ b/gdb/testsuite/gdb.threads/stop-with-handle.exp @@ -27,11 +27,11 @@ if {[prepare_for_testing "failed to prepare" \ "${testfile}" "${srcfile}" {debug pthreads}]} { return } if {![runto_main]} { - return 0 + return } # Have SIGSTOP sent to the inferior. gdb_test "handle SIGSTOP nostop noprint pass" \ [multi_line \ diff --git a/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp b/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp index d77b323338cc..299d66b0516d 100644 --- a/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp +++ b/gdb/testsuite/gdb.threads/thread-unwindonsignal.exp @@ -29,11 +29,11 @@ if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executab } clean_restart ${::testfile} if { ![runto_main] } { - return 0 + return } gdb_test "break all_threads_running" \ "Breakpoint 2 at .*: file .*${srcfile}, line .*" \ "breakpoint on all_threads_running" diff --git a/gdb/testsuite/gdb.threads/threadapply.exp b/gdb/testsuite/gdb.threads/threadapply.exp index f8827ae7ea65..7fdc647705a9 100644 --- a/gdb/testsuite/gdb.threads/threadapply.exp +++ b/gdb/testsuite/gdb.threads/threadapply.exp @@ -30,11 +30,11 @@ clean_restart ${::testfile} # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } # Break after all threads have been started. set break_line [gdb_get_line_number "Break here"] gdb_test "b $break_line" ".*" diff --git a/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp b/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp index 9d2a805c4a5f..5e9c4ddd2e8b 100644 --- a/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp +++ b/gdb/testsuite/gdb.threads/tls-nodebug-pie.exp @@ -20,10 +20,10 @@ if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executab return } clean_restart ${::testfile} if {![runto_main]} { - return 0 + return } # Formerly: Cannot access memory at address 0xffffef7c0698 gdb_test "p (int) thread_local_var" " = 42" "thread local storage" diff --git a/gdb/testsuite/gdb.threads/tls-shared.exp b/gdb/testsuite/gdb.threads/tls-shared.exp index a293809105d6..2710145c9958 100644 --- a/gdb/testsuite/gdb.threads/tls-shared.exp +++ b/gdb/testsuite/gdb.threads/tls-shared.exp @@ -31,11 +31,11 @@ if { [gdb_compile_shlib_pthreads ${srcdir}/${subdir}/${srcfile_lib} ${binfile_li clean_restart ${::testfile} gdb_load_shlib ${binfile_lib} if {![runto_main]} { - return 0 + return } gdb_test "print i_tls" "2" "print thread local storage variable" gdb_test "ptype i_tls" "int" "ptype of thread local storage variable" diff --git a/gdb/testsuite/gdb.threads/tls-so_extern.exp b/gdb/testsuite/gdb.threads/tls-so_extern.exp index eb3f32df6210..f1c0b66ad935 100644 --- a/gdb/testsuite/gdb.threads/tls-so_extern.exp +++ b/gdb/testsuite/gdb.threads/tls-so_extern.exp @@ -30,11 +30,11 @@ if { [gdb_compile_shlib_pthreads ${srcdir}/${subdir}/${srcfile_lib} ${binfile_li clean_restart ${::testfile} gdb_load_shlib ${binfile_lib} if {![runto_main]} { - return 0 + return } gdb_test "print so_extern" "0x0" "print thread local storage variable" gdb_test "ptype so_extern" "void \\*" "ptype of thread local storage variable" diff --git a/gdb/testsuite/gdb.threads/tls-var.exp b/gdb/testsuite/gdb.threads/tls-var.exp index 5b2968a7bd01..28d0886c6bfd 100644 --- a/gdb/testsuite/gdb.threads/tls-var.exp +++ b/gdb/testsuite/gdb.threads/tls-var.exp @@ -26,11 +26,11 @@ if { [gdb_compile ${srcdir}/${subdir}/${srcfile} ${objfile} object {debug}] != " } clean_restart ${executable} if {![runto_main]} { - return 0 + return } # FAIL was: type = gdb_test "whatis tls_var" {type = const char \*} diff --git a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp index 58b16be70f26..f56661d7a5c2 100644 --- a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp +++ b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp @@ -25,11 +25,11 @@ # could be assigned during continuation of a thread with pending SIGTRAP to the # different/new watchpoint, just based on the watchpoint/debug register number. require allow_hw_watchpoint_access_tests allow_hw_watchpoint_multi_tests if {![istarget *-*-linux*]} { - return 0 + return } standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" ${binfile} executable [list debug additional_flags=-lrt]] != "" } { return diff --git a/gdb/testsuite/gdb.threads/watchthreads.exp b/gdb/testsuite/gdb.threads/watchthreads.exp index e975e22e5730..2682db7b0328 100644 --- a/gdb/testsuite/gdb.threads/watchthreads.exp +++ b/gdb/testsuite/gdb.threads/watchthreads.exp @@ -37,11 +37,11 @@ gdb_test_no_output "set can-use-hw-watchpoints 1" "" # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } set args_0 0 set args_1 0 diff --git a/gdb/testsuite/gdb.threads/watchthreads2.exp b/gdb/testsuite/gdb.threads/watchthreads2.exp index 49884f4136dd..0efef51b7fc6 100644 --- a/gdb/testsuite/gdb.threads/watchthreads2.exp +++ b/gdb/testsuite/gdb.threads/watchthreads2.exp @@ -38,11 +38,11 @@ gdb_test_no_output "set can-use-hw-watchpoints 1" "" # # Run to `main' where we begin our tests. # if {![runto_main]} { - return 0 + return } gdb_test "break thread_started" \ "Breakpoint 2 at .*: file .*${srcfile}, line .*" \ "breakpoint on thread_started" diff --git a/gdb/testsuite/gdb.threads/wp-replication.exp b/gdb/testsuite/gdb.threads/wp-replication.exp index 28a5071bd5e5..cc9bc50f9b2e 100644 --- a/gdb/testsuite/gdb.threads/wp-replication.exp +++ b/gdb/testsuite/gdb.threads/wp-replication.exp @@ -39,11 +39,11 @@ clean_restart ${::testfile} # Force hardware watchpoints to be used. gdb_test_no_output "set can-use-hw-watchpoints 1" "" # Run to `main' where we begin our tests. if {![runto_main]} { - return 0 + return } # Set some default values. set hwatch_count 0 set count 0 From patchwork Wed Apr 29 23:04:25 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134223 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 6DAC04BAE7CF for ; Wed, 29 Apr 2026 23:11:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6DAC04BAE7CF Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=zfaAF7Fb X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa35.google.com (mail-vk1-xa35.google.com [IPv6:2607:f8b0:4864:20::a35]) by sourceware.org (Postfix) with ESMTPS id 37C854358A52 for ; Wed, 29 Apr 2026 23:06:39 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 37C854358A52 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 37C854358A52 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a35 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503999; cv=none; b=G3iJLoMxLeW3ZhTbxi+s32ToYbhu7tAhLqLeQPJznK8ZpJvmxndj9pfQ849w+0UzwbqJ9h/FojVXG8TjTMyPpNIgHx38+Mq72dJLhMRseNsW97/TfGgQHQmXpgea4iQCNK+vTmNZhUJ/sAc51MrS6RH2Ce0CeRK09H2jclPiO5Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777503999; c=relaxed/simple; bh=riQ56Rq6aaG1nQVsgXvY54nJX8BZGXQSFwmS3LablSg=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=ee40yxRlapGh9vWbXE/IHGb8ieJffrrOGOB4fK8SVMWtwzL3ITdMpZXpzmFE1+sD5nVgKPXM2XBBhjVsITqebbYfGlfhMyyHngDfG9u19DAbDzoNjJRBYOqqp/B0+sgvaK8HfHGwvq9RiNEh568r1oorx23eZOJeDL8zzR7fFLk= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 37C854358A52 Received: by mail-vk1-xa35.google.com with SMTP id 71dfb90a1353d-56a8e0ea02aso298798e0c.0 for ; Wed, 29 Apr 2026 16:06:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777503999; x=1778108799; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=LA8CDzygVAcJL1hh0ii7ynHWCwAbhmjuCknU5nBMoAY=; b=zfaAF7Fb2yw1Nu44C3zcX9s6hwjmoiRbbL5V5V6YnYsgjSwfrW+VQTdm7zuj+k1GD6 bDiX/bv+kfY7sGQJHm60SVg5IW4O0zC/SimQ3SPze6y9XfNpxpw8cgofLt04KlLEy5HS tPVCPJag+dLloGqTeYAuk6DBZ4+ITQy/y6gYIlEuwq+zPAPgSL8CkoiV6/0XRHAzEwK9 UsR/b9y/u4ARol7mMZVcana/QgswDsKAjNQdYFwST1szKetkYjqPNlmvEw91edoc3+KW kv1RB+tGo1ePVyyypEbB2v0pDJ/ZUULVv4kmDwUNLtuxrPGBMNESb+t3lDjfFdlKcXod Fx5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777503999; x=1778108799; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=LA8CDzygVAcJL1hh0ii7ynHWCwAbhmjuCknU5nBMoAY=; b=WfdYDqdcaw9J95PkC25wfN4i1wRByH6tuMWPZm4FFIxllTi07JFWOVugiWS7KlmO2g oEN1swA+V1F1bWtyO9cLZcv1U0Y4BUE4vFRLQbUwWE+jnr05nTZ7go8NJBEPR0LW9uT5 +B3ChKCcvVnMuFcBhYYGpRuc5J5X7Z3sQuKS22Y89RtC8Cp412CzdmzN1uNo4pihyW9K UOtYcLiHA5fvdg/y6xBaHxc2N0dopFG/39zG5ZIpSOo5RQNpSfC/ySyP60RDsNarTeiX 9fh/jTt77E0h3Sd+gwYdzaklUX/Ja1Hd3h6pa0vJ3K7kDqrAGSfQOs2sRgJsbUbAJ3R6 jQbg== X-Gm-Message-State: AOJu0YxymC2v/u+5Sp0m2pngdSEq+lHSzyu6XtWmubYVLyJ2902Ap9e5 vwhh8GWSLeb05hhF0I1zwrhZOYVIlXp5UGrhChWYegUYpc2Ep6DvpmaaTuw6F0FGVaeZRj8xrIb ui8HH X-Gm-Gg: AeBDietgqpeCYHt/X/EHcclaXVBTXd/WKsnLBr4rnVNfiMJlnTsKpjmEvxc6xTzadId XeTx/slnHKKSxIquFp223PEUVNiBmvNuAld/YqP+ZcglZUIJYhR2fenw70X71cYZW4ePumqQsg2 yDe9o9oX34OBB3d30P31e+7+7Bs4B5waAYOq19fa7uXq4Y7rnc91Fxt5hm2aFfBd0M/UNYIojGJ LFn/uV2OovZDOCLXbHoeoEgZrwp3/fmBuKui30qJTW8b9eO+O56ap/WAzx7XJwf2XjCO7MV3UO+ R1Bc5upHLgW2TD8HzSs0dg8k6Lee8F1O6AzuZv1yg6yhdAq9LjBm8rWHqYVck0izJicNt+S/uKX C6tZ2MZH8CaC5NcD82zaFQhLPLB6pJWesq1WkuA0A3bmdy1yOjtvGoIHLHJuYsE8ZHFVFeMD2Rw shNTCpwsqsKXOGN7hRTysZThdETNu6t1st1IxR5NF+wERz5kS1nP08jdk= X-Received: by 2002:a05:6122:f06:b0:56c:d6f1:d742 with SMTP id 71dfb90a1353d-573c95f0f37mr115993e0c.8.1777503998564; Wed, 29 Apr 2026 16:06:38 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6dfa5b4sm2001167e0c.16.2026.04.29.16.06.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:38 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 34/37] GDB: testsuite: threads: Don't return value from top-level (manual) Date: Wed, 29 Apr 2026 20:04:25 -0300 Message-ID: <20260429230432.60487-35-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch manually changes "return -1" statements that weren't caught by the sed command. These return statements fall into one of these criteria: - misaligned line, which is then fixed by this patch; - return at top level but inside block such as for loops, with_test_prefix, foreach_with_prefix, gdb_test_multiple. I also fixed a couple cases of "return 0" from top-level that also weren't caught by sed, and even a couple cases of "return 1" from top-level. --- gdb/testsuite/gdb.threads/attach-slow-waitpid.exp | 4 ++-- gdb/testsuite/gdb.threads/corethreads.exp | 4 ++-- gdb/testsuite/gdb.threads/create-fail.exp | 2 +- gdb/testsuite/gdb.threads/gcore-stale-thread.exp | 2 +- gdb/testsuite/gdb.threads/gcore-thread.exp | 4 ++-- gdb/testsuite/gdb.threads/linux-dp.exp | 2 +- gdb/testsuite/gdb.threads/multiple-successive-infcall.exp | 6 +++--- gdb/testsuite/gdb.threads/omp-par-scope.exp | 2 +- gdb/testsuite/gdb.threads/omp-task.exp | 2 +- gdb/testsuite/gdb.threads/siginfo-threads.exp | 2 +- gdb/testsuite/gdb.threads/staticthreads.exp | 4 ++-- gdb/testsuite/gdb.threads/stepi-over-clone.exp | 2 +- gdb/testsuite/gdb.threads/thread-specific.exp | 4 ++-- gdb/testsuite/gdb.threads/thread_check.exp | 2 +- gdb/testsuite/gdb.threads/tls.exp | 4 ++-- gdb/testsuite/gdb.threads/watchthreads-reorder.exp | 2 +- 16 files changed, 24 insertions(+), 24 deletions(-) diff --git a/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp b/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp index 343a96bc5112..de5a901f0b1f 100644 --- a/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp +++ b/gdb/testsuite/gdb.threads/attach-slow-waitpid.exp @@ -51,20 +51,20 @@ set libobj [standard_output_file ${libfile}.so] with_test_prefix "compile preload library" { # Compile the preload library. We only get away with this as we # limit this test to running when ISNATIVE is true. if { [gdb_compile_shlib_pthreads \ $libsrc $libobj {debug}] != "" } then { - return -1 + return } } with_test_prefix "compile test executable" { # Compile the test program if { [gdb_compile_pthreads \ "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ executable {debug}] != "" } { - return -1 + return } } # Spawn GDB with LIB preloaded with LD_PRELOAD. diff --git a/gdb/testsuite/gdb.threads/corethreads.exp b/gdb/testsuite/gdb.threads/corethreads.exp index 4e520c5e8f22..2ea879623368 100644 --- a/gdb/testsuite/gdb.threads/corethreads.exp +++ b/gdb/testsuite/gdb.threads/corethreads.exp @@ -21,12 +21,12 @@ if {![istarget "*-*-linux*"]} { } standard_testfile set executable ${testfile} if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { - untested "failed to compile" - return -1 + untested "failed to compile" + return } set corefile [core_find $binfile] if {$corefile == ""} { untested "unable to create or find corefile" diff --git a/gdb/testsuite/gdb.threads/create-fail.exp b/gdb/testsuite/gdb.threads/create-fail.exp index c77ccab17ae2..bb7c341a5b5b 100644 --- a/gdb/testsuite/gdb.threads/create-fail.exp +++ b/gdb/testsuite/gdb.threads/create-fail.exp @@ -32,11 +32,11 @@ for {set i 1} {$i <= $iterations} {incr i} { with_test_prefix "iteration $i" { clean_restart ${executable} if {![runto_main]} { - return -1 + return } set test "run till end" gdb_test_multiple "continue" "$test" { -re "exited with code 01.*$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.threads/gcore-stale-thread.exp b/gdb/testsuite/gdb.threads/gcore-stale-thread.exp index 9faa2686c767..d0465c87a4ad 100644 --- a/gdb/testsuite/gdb.threads/gcore-stale-thread.exp +++ b/gdb/testsuite/gdb.threads/gcore-stale-thread.exp @@ -32,11 +32,11 @@ gdb_test_multiple "info threads" "threads are supported" { -re ".* main .*\r\n$gdb_prompt $" { # OK, threads are supported. } -re "\r\n$gdb_prompt $" { unsupported "gdb does not support threads on this target" - return -1 + return } } gdb_breakpoint ${srcfile}:[gdb_get_line_number "break-here"] # gdb_continue_to_breakpoint does not work as it uses "$gdb_prompt $" regex diff --git a/gdb/testsuite/gdb.threads/gcore-thread.exp b/gdb/testsuite/gdb.threads/gcore-thread.exp index c3b8c56dd4b9..1d0150da6745 100644 --- a/gdb/testsuite/gdb.threads/gcore-thread.exp +++ b/gdb/testsuite/gdb.threads/gcore-thread.exp @@ -63,11 +63,11 @@ gdb_test_multiple "info threads" "threads are supported" { -re ".* main .*$gdb_prompt $" { # OK, threads are supported. } -re "${nl}$gdb_prompt $" { unsupported "gdb does not support threads on this target" - return -1 + return } } # Make sure thread 1 is running delete_breakpoints @@ -81,11 +81,11 @@ gdb_test "continue" "Continuing.*Breakpoint.* thread2 .*" "thread 2 is running" # Drop corefile set core_supported [gdb_gcore_cmd "$corefile" "save a corefile"] if {!$core_supported} { - return -1 + return } # Test the uninitialized thread list. # Provide the case of glibc td_thr_get_info handling of: diff --git a/gdb/testsuite/gdb.threads/linux-dp.exp b/gdb/testsuite/gdb.threads/linux-dp.exp index 42773f2293b5..f573964ea6a4 100644 --- a/gdb/testsuite/gdb.threads/linux-dp.exp +++ b/gdb/testsuite/gdb.threads/linux-dp.exp @@ -97,11 +97,11 @@ for {set i 0} {$i < 5} {incr i} { -re " received signal.*(Unknown signal|SIGUSR|Real-time event).*$gdb_prompt $" { # It would be nice if we could catch the message that GDB prints # when it first notices that the thread library doesn't support # debugging, or if we could explicitly ask GDB somehow. unsupported "this GDB does not support threads on this system." - return -1 + return } -re "$gdb_prompt $" { } } if { $threads_created == 1 } { diff --git a/gdb/testsuite/gdb.threads/multiple-successive-infcall.exp b/gdb/testsuite/gdb.threads/multiple-successive-infcall.exp index 8d438673cf07..fdcbaa47c7f4 100644 --- a/gdb/testsuite/gdb.threads/multiple-successive-infcall.exp +++ b/gdb/testsuite/gdb.threads/multiple-successive-infcall.exp @@ -17,18 +17,18 @@ # multiple inferiors, one after the other. standard_testfile if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ - executable {debug additional_flags=-std=gnu99}] != "" } { - return -1 + executable {debug additional_flags=-std=gnu99}] != "" } { + return } clean_restart "${::testfile}" if {![runto_main]} { - return 0 + return } # Ensure that each new thread is detected by GDB in the order that the # test case creates them, so the thread identifiers match between # test and test case. diff --git a/gdb/testsuite/gdb.threads/omp-par-scope.exp b/gdb/testsuite/gdb.threads/omp-par-scope.exp index b561bf2f4a5b..7d706078b2c4 100644 --- a/gdb/testsuite/gdb.threads/omp-par-scope.exp +++ b/gdb/testsuite/gdb.threads/omp-par-scope.exp @@ -54,11 +54,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { # is optional and will only be called if it's defined. if {[info procs gdb_openmp_setup] != ""} { if {[gdb_openmp_setup $binfile] != ""} { untested "could not set up OpenMP environment" - return -1 + return } } if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.threads/omp-task.exp b/gdb/testsuite/gdb.threads/omp-task.exp index 636bcf989159..a7f39933d744 100644 --- a/gdb/testsuite/gdb.threads/omp-task.exp +++ b/gdb/testsuite/gdb.threads/omp-task.exp @@ -28,11 +28,11 @@ if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} { } if {[info procs gdb_openmp_setup] != ""} { if {[gdb_openmp_setup $binfile] != ""} { untested "could not set up OpenMP environment" - return -1 + return } } if {![runto_main]} { return diff --git a/gdb/testsuite/gdb.threads/siginfo-threads.exp b/gdb/testsuite/gdb.threads/siginfo-threads.exp index acf1185cdfc5..6b095ac968ad 100644 --- a/gdb/testsuite/gdb.threads/siginfo-threads.exp +++ b/gdb/testsuite/gdb.threads/siginfo-threads.exp @@ -60,11 +60,11 @@ for {set sigcount 0} {$sigcount < 4} {incr sigcount} { set sigusr $expect_out(1,string) pass $test } } if {$sigusr == ""} { - return -1 + return } set test "signal $sigcount si_signo" if {$sigusr == 1} { set signo 10 diff --git a/gdb/testsuite/gdb.threads/staticthreads.exp b/gdb/testsuite/gdb.threads/staticthreads.exp index bc36d87f7d70..b25c0ae4e3b9 100644 --- a/gdb/testsuite/gdb.threads/staticthreads.exp +++ b/gdb/testsuite/gdb.threads/staticthreads.exp @@ -28,11 +28,11 @@ foreach_with_prefix have_tls { "-DHAVE_TLS" "" } { [list debug "additional_flags=${static_flag} ${have_tls}" \ ]] == "" } { break } if { $have_tls == "" } { - return -1 + return } } clean_restart ${::testfile} gdb_test_no_output "set print sevenbit-strings" @@ -97,11 +97,11 @@ gdb_test_multiple "quit" "$test" { clean_restart ${::testfile} if { "$have_tls" != "" } { if {![runto_main]} { - return -1 + return } gdb_breakpoint [gdb_get_line_number "tlsvar-is-set"] gdb_continue_to_breakpoint "tlsvar-is-set" ".* tlsvar-is-set .*" gdb_test "p tlsvar" " = 2" "tlsvar in thread" gdb_test "thread 1" ".*" diff --git a/gdb/testsuite/gdb.threads/stepi-over-clone.exp b/gdb/testsuite/gdb.threads/stepi-over-clone.exp index f59c6275c5d4..673d77f0028b 100644 --- a/gdb/testsuite/gdb.threads/stepi-over-clone.exp +++ b/gdb/testsuite/gdb.threads/stepi-over-clone.exp @@ -83,11 +83,11 @@ gdb_test_multiple "disassemble" "" { exp_continue } -re "^End of assembler dump\\.\r\n$gdb_prompt $" { if { [llength $syscall_addrs] == 0 } { unsupported "no syscalls found" - return -1 + return } } } # The test proc. NON_STOP and DISPLACED are either 'on' or 'off', and are diff --git a/gdb/testsuite/gdb.threads/thread-specific.exp b/gdb/testsuite/gdb.threads/thread-specific.exp index 79932ab9dc17..a5191122b0f8 100644 --- a/gdb/testsuite/gdb.threads/thread-specific.exp +++ b/gdb/testsuite/gdb.threads/thread-specific.exp @@ -79,12 +79,12 @@ gdb_continue_to_breakpoint "all threads started" set line [gdb_get_line_number "thread-specific.exp: thread loop"] set threads [get_thread_list] if {[llength $threads] == 0} { - # We have already issued a FAIL above. - return 1 + # We have already issued a FAIL above. + return } gdb_test {print $_thread} ".* = [lindex $threads 0]" "thread var in main" gdb_test {print $_gthread} ".* = [lindex $threads 0]" "gthread var in main" diff --git a/gdb/testsuite/gdb.threads/thread_check.exp b/gdb/testsuite/gdb.threads/thread_check.exp index e48e3d5b3c37..013fd253e9f9 100644 --- a/gdb/testsuite/gdb.threads/thread_check.exp +++ b/gdb/testsuite/gdb.threads/thread_check.exp @@ -40,11 +40,11 @@ if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executab clean_restart ${::testfile} if {![runto_main]} { - return 1 + return } # # set breakpoint at thread function tf diff --git a/gdb/testsuite/gdb.threads/tls.exp b/gdb/testsuite/gdb.threads/tls.exp index bf48a6f9fc9e..96e41eed411f 100644 --- a/gdb/testsuite/gdb.threads/tls.exp +++ b/gdb/testsuite/gdb.threads/tls.exp @@ -163,11 +163,11 @@ gdb_test_multiple "print a_thread_local" "" { pass $gdb_test_name } } if {![runto_main]} { - return 0 + return } # Set a breakpoint at the "spin" routine to # test the thread local's value. # @@ -188,11 +188,11 @@ send_gdb "continue\n" gdb_expect { -re ".* received signal SIGSEGV.*a_thread_local = 0;.*$gdb_prompt $" { # This is the first symptom if the gcc and binutils versions # in use support TLS, but the system glibc does not. unsupported "continue to first thread: system does not support TLS" - return -1 + return } -re ".*$inferior_exited_re normally.*$gdb_prompt $" { fail "continue to first thread: program runaway" } -re ".*Pass 0 done.*Pass 1 done.*$gdb_prompt $" { diff --git a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp index f56661d7a5c2..192996b51ca9 100644 --- a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp +++ b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp @@ -40,11 +40,11 @@ foreach reorder {0 1} { with_test_prefix "reorder$reorder" { clean_restart $testfile gdb_test "set can-use-hw-watchpoints 1" if {![runto_main]} { - return -1 + return } # Use "rwatch" as "watch" would report the watchpoint changed just based on its # read memory value during a stop by unrelated event. We are interested in not # losing the hardware watchpoint trigger. From patchwork Wed Apr 29 23:04:26 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134230 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 6CBC64B99F5F for ; Wed, 29 Apr 2026 23:16:10 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6CBC64B99F5F Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=j987GU11 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vs1-xe2f.google.com (mail-vs1-xe2f.google.com [IPv6:2607:f8b0:4864:20::e2f]) by sourceware.org (Postfix) with ESMTPS id 6C6544BB58BD for ; Wed, 29 Apr 2026 23:06:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6C6544BB58BD Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 6C6544BB58BD Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::e2f ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777504002; cv=none; b=gbMSZ0UB9MOu9Qteozf9aQI7HTrhYvy6RnDHoKE2qirzQ223ooQNZ3DMx7YdCyJNa03vpKrOmCfztnLI8683NNgOSIZvT2Rw4eLqpApIgW3hLAJHqyM1m5QEBaEwBUdd3Ps4WHWB9X4qhpfDEfVmmIzIOPD/b+EmXBj94yhlyko= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777504002; c=relaxed/simple; bh=8se+mbhFfcH5JNrqOjBA7J7ZhF8L1XG87wJhxD470x4=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=rHVyiQvrkzgy75suOo/laaFHPLsSX3dgfSrLgRB5uBXnPmh56XfaElOL1ZIbzAaBUjMOowJGJh4s+9rVkSJJ1M+uaeZM1Z0MmDAHcSi3VfC/a5xM7GtWp+IboYHulLkmkcV+/NB7DlGcMOR14wlgQOtukjpRDrEN7QZCVKKj4uA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6C6544BB58BD Received: by mail-vs1-xe2f.google.com with SMTP id ada2fe7eead31-60fee2fa3b8so109937137.2 for ; Wed, 29 Apr 2026 16:06:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777504002; x=1778108802; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=evj8QrbNTPZkhSWG79Qh1NlS9j3ILcAjRyaT77B28xY=; b=j987GU11dnQGASpvtrN/W5VZ3IKOElhNZ/O0Hy2Qrzpeeg5oiuvowU4viB6nqy+Ayj Dvg+UMhLWwgj8uGyD0vzON0K46BKpQVdIJDzABfxiruG88qvEwPr3YCaAPAN66BVpPIF C0CvvCOn7Oy1xNNpKLZEJ8+eBfMbSwUnffuxSEtkOcKCq2rkaDKA6/NqGa0Od1X5kr08 L56xKG7UbuWMiNLIO3rIOg7ItyJFtjwNVxloSPN1zP3WVTZsW6/NPVbT37S3tvmoOPaK zzVVgnGoA+c2KouLVNQdXgX7yYQX5DJmaCwGtMO1x46IN5pIrANECGm+h30OszZ7wzAW KuJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777504002; x=1778108802; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=evj8QrbNTPZkhSWG79Qh1NlS9j3ILcAjRyaT77B28xY=; b=mVXWqfMUyj4DWIgedkzRTEnijxkibGpzapyW/6jIkxqv/8hoCD9adu/n3WIgbL/p8F KRilsCwd8fI7O42sDZ6Z193eSIooz1s9pxKWtx4mUUQdCSxvh+os7IGZVg7INWrhyyYe oWbCcAA5spBcxKV2rKa5ywHMtF1fxEBlLgVZGN192uA1PgRJlQ8YfhqXGan0fK/ziU63 +VVOy2AO1FA7q8QPmIobgb+9y6aIF9WMiUeWM+7FZ1dKH3w82n0/Uae4sylfXSWt7DyQ 5Z+TAEJzuuhfYuqpJSXFVNURCzedTv9hxlS7/+3vWMLsL9HpRYXNsDbtL0YJTY3MU5ei I+yQ== X-Gm-Message-State: AOJu0YxRgmwNkJudULNTT+PFhpY0g8OSx3veXhPWVLLzWBtiQ/cuUdxy FaPAA+MVdTEFI4sPObdCUINYNPuW+0aP7AMN9S7w6BytGZeXt5kuDPJfZHTOKmh4ELzFFuGS9IP mb1mL X-Gm-Gg: AeBDieuxfIt6CfucQ6QTCmrw/71RstPMNlQtvwSkbTnWzFOBLRxuHVU6c/lmtx3MLd/ 2lPqPn4hNHHZ2SZ9wZlADWOtcG6bt2ZKoPpTDIUE5bXKHIs3jAV7ih/joyKVEhlSku2+h7DDNFG VwWjKJzIB+1BH7VuCQMYi0IxsoDlZbA7SAtzyoTupVDlBTLS4LuGn3YpBrIrLdt+MKAzXGXMhGE uhMDRwCC0JKGGgKFj0WwbIu7msSIGOsC9kyBMRKz5pgEzrL03W9Ged9ijag1bcnI7dR3U9wtDCw W7oIvn46z1lUxUYTnoMQWCQeZdbhSYnGx6Z7dvt2y2P9p5GQVyxiumyBcYvXXQ+AWex5R7waArC /6KnUtEYaMIsZNR/xF8U5PSnR3MYwA900gEG+bxPFNSot6tedMODyoaVe6PuFAobO08/vdNr6Lx /LMy0lz6kXRT1b7QxayX+ydT3zJeYvCQCo20wLPWPU0JMdtUUML7vIftk= X-Received: by 2002:a05:6102:5f04:b0:5ff:17bd:9e83 with SMTP id ada2fe7eead31-62ad384ad88mr286733137.14.1777504001651; Wed, 29 Apr 2026 16:06:41 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id a1e0cc1a2514c-95cc4f4d418sm807373241.9.2026.04.29.16.06.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:41 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 35/37] GDB: testsuite: TUI: Don't return -1 from top-level (sed) Date: Wed, 29 Apr 2026 20:04:26 -0300 Message-ID: <20260429230432.60487-36-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch is purely the result of running: $ sed -i 's/^ return -1/ return/' *.exp* inside gdb/testsuite/gdb.tui. --- gdb/testsuite/gdb.tui/basic.exp | 2 +- gdb/testsuite/gdb.tui/break.exp | 2 +- gdb/testsuite/gdb.tui/compact-source.exp | 2 +- gdb/testsuite/gdb.tui/corefile-run.exp | 6 +++--- gdb/testsuite/gdb.tui/flush-after-run.exp | 2 +- gdb/testsuite/gdb.tui/list-before.exp | 2 +- gdb/testsuite/gdb.tui/list.exp | 2 +- gdb/testsuite/gdb.tui/main-2.exp | 2 +- gdb/testsuite/gdb.tui/main.exp | 2 +- gdb/testsuite/gdb.tui/new-layout.exp | 2 +- gdb/testsuite/gdb.tui/regs.exp | 2 +- gdb/testsuite/gdb.tui/reread.exp | 2 +- gdb/testsuite/gdb.tui/resize-3.exp | 2 +- gdb/testsuite/gdb.tui/resize-one-line.exp | 2 +- gdb/testsuite/gdb.tui/resize.exp | 2 +- gdb/testsuite/gdb.tui/scroll.exp | 2 +- gdb/testsuite/gdb.tui/tui-focus.exp | 2 +- gdb/testsuite/gdb.tui/tui-init-source.exp | 2 +- gdb/testsuite/gdb.tui/tui-layout-asm-short-prog.exp | 2 +- gdb/testsuite/gdb.tui/tui-layout-asm.exp | 2 +- gdb/testsuite/gdb.tui/tui-layout.exp | 2 +- gdb/testsuite/gdb.tui/winheight.exp | 2 +- gdb/testsuite/gdb.tui/winwidth.exp | 2 +- 23 files changed, 25 insertions(+), 25 deletions(-) diff --git a/gdb/testsuite/gdb.tui/basic.exp b/gdb/testsuite/gdb.tui/basic.exp index 7909cea674d6..26264082a163 100644 --- a/gdb/testsuite/gdb.tui/basic.exp +++ b/gdb/testsuite/gdb.tui/basic.exp @@ -22,11 +22,11 @@ tuiterm_env standard_testfile main-one-line.c set main_line [gdb_get_line_number "int main"] if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { unsupported "TUI not supported" diff --git a/gdb/testsuite/gdb.tui/break.exp b/gdb/testsuite/gdb.tui/break.exp index 4e07a0c0b691..154ca40b69fa 100644 --- a/gdb/testsuite/gdb.tui/break.exp +++ b/gdb/testsuite/gdb.tui/break.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { unsupported "TUI not supported" diff --git a/gdb/testsuite/gdb.tui/compact-source.exp b/gdb/testsuite/gdb.tui/compact-source.exp index 9f41a160b3f4..e9478bbeb863 100644 --- a/gdb/testsuite/gdb.tui/compact-source.exp +++ b/gdb/testsuite/gdb.tui/compact-source.exp @@ -36,11 +36,11 @@ set srcfile [standard_output_file $srcfile] set fd [open $srcfile w] puts $fd $src_txt close $fd if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile gdb_test_no_output "maint set tui-left-margin-verbose on" diff --git a/gdb/testsuite/gdb.tui/corefile-run.exp b/gdb/testsuite/gdb.tui/corefile-run.exp index 7e1184ecf040..1361e4a7f6de 100644 --- a/gdb/testsuite/gdb.tui/corefile-run.exp +++ b/gdb/testsuite/gdb.tui/corefile-run.exp @@ -25,23 +25,23 @@ tuiterm_env standard_testfile tui-layout.c set core [standard_output_file "${testfile}.core"] if { [prepare_for_testing "failed to prepare" $testfile $srcfile debug] } { - return -1 + return } # Only run on native boards. require {target_can_use_run_cmd core} if { ![runto_main] } { - return -1 + return } if { ![gdb_gcore_cmd "$core" "save a corefile"] } { untested "could not generate a corefile" - return -1 + return } set src_line "return 0;" set src_line_nr [gdb_get_line_number $src_line] diff --git a/gdb/testsuite/gdb.tui/flush-after-run.exp b/gdb/testsuite/gdb.tui/flush-after-run.exp index ecc2caafc33d..db20b8cee80b 100644 --- a/gdb/testsuite/gdb.tui/flush-after-run.exp +++ b/gdb/testsuite/gdb.tui/flush-after-run.exp @@ -22,11 +22,11 @@ require target_can_use_run_cmd tuiterm_env standard_testfile if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { diff --git a/gdb/testsuite/gdb.tui/list-before.exp b/gdb/testsuite/gdb.tui/list-before.exp index 55485aa5629c..5d3cef954d49 100644 --- a/gdb/testsuite/gdb.tui/list-before.exp +++ b/gdb/testsuite/gdb.tui/list-before.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile gdb_test "list -q main" diff --git a/gdb/testsuite/gdb.tui/list.exp b/gdb/testsuite/gdb.tui/list.exp index de58afa53e1a..5cefebc7e016 100644 --- a/gdb/testsuite/gdb.tui/list.exp +++ b/gdb/testsuite/gdb.tui/list.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { unsupported "TUI not supported" diff --git a/gdb/testsuite/gdb.tui/main-2.exp b/gdb/testsuite/gdb.tui/main-2.exp index 1b8068e3a361..9b3b38645b0f 100644 --- a/gdb/testsuite/gdb.tui/main-2.exp +++ b/gdb/testsuite/gdb.tui/main-2.exp @@ -21,11 +21,11 @@ require allow_tui_tests tuiterm_env standard_testfile tui-layout.c if { [build_executable "failed to prepare" $testfile $srcfile ] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.tui/main.exp b/gdb/testsuite/gdb.tui/main.exp index 5bc6b91cdee4..d8a9c8eebe85 100644 --- a/gdb/testsuite/gdb.tui/main.exp +++ b/gdb/testsuite/gdb.tui/main.exp @@ -20,11 +20,11 @@ require allow_tui_tests tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } # Note: don't pass the executable here Term::clean_restart 24 80 diff --git a/gdb/testsuite/gdb.tui/new-layout.exp b/gdb/testsuite/gdb.tui/new-layout.exp index f293773f9d15..e544ef6fd90a 100644 --- a/gdb/testsuite/gdb.tui/new-layout.exp +++ b/gdb/testsuite/gdb.tui/new-layout.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } # Make sure TUI is supported before continuing. with_test_prefix "initial check" { Term::clean_restart 24 80 $testfile diff --git a/gdb/testsuite/gdb.tui/regs.exp b/gdb/testsuite/gdb.tui/regs.exp index 3c524ad49a70..8169538da85c 100644 --- a/gdb/testsuite/gdb.tui/regs.exp +++ b/gdb/testsuite/gdb.tui/regs.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.tui/reread.exp b/gdb/testsuite/gdb.tui/reread.exp index de35fef744cd..3ed0839e1c83 100644 --- a/gdb/testsuite/gdb.tui/reread.exp +++ b/gdb/testsuite/gdb.tui/reread.exp @@ -21,11 +21,11 @@ tuiterm_env # Use main-one-line.c to get the line info at a predictable location without # resorting to a dwarf assembly test-case. standard_testfile main-one-line.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { diff --git a/gdb/testsuite/gdb.tui/resize-3.exp b/gdb/testsuite/gdb.tui/resize-3.exp index d9e0948a9a80..fdaffe006419 100644 --- a/gdb/testsuite/gdb.tui/resize-3.exp +++ b/gdb/testsuite/gdb.tui/resize-3.exp @@ -21,11 +21,11 @@ standard_testfile -main.c -foo.c if { [build_executable_from_specs "failed to prepare" \ $testfile {debug} \ $srcfile {debug} \ $srcfile2 {nodebug}] == -1 } { - return -1 + return } tuiterm_env Term::clean_restart 24 80 $testfile diff --git a/gdb/testsuite/gdb.tui/resize-one-line.exp b/gdb/testsuite/gdb.tui/resize-one-line.exp index f5e2858b05d2..0a47dcf0e7f8 100644 --- a/gdb/testsuite/gdb.tui/resize-one-line.exp +++ b/gdb/testsuite/gdb.tui/resize-one-line.exp @@ -20,11 +20,11 @@ tuiterm_env standard_testfile main-one-line.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { diff --git a/gdb/testsuite/gdb.tui/resize.exp b/gdb/testsuite/gdb.tui/resize.exp index 93918f3b3560..25f52c6a5b8e 100644 --- a/gdb/testsuite/gdb.tui/resize.exp +++ b/gdb/testsuite/gdb.tui/resize.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![runto_main]} { diff --git a/gdb/testsuite/gdb.tui/scroll.exp b/gdb/testsuite/gdb.tui/scroll.exp index e9fa829f40ec..0162cfd8db7b 100644 --- a/gdb/testsuite/gdb.tui/scroll.exp +++ b/gdb/testsuite/gdb.tui/scroll.exp @@ -22,11 +22,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { unsupported "TUI not supported" diff --git a/gdb/testsuite/gdb.tui/tui-focus.exp b/gdb/testsuite/gdb.tui/tui-focus.exp index 5df76b59b864..310b3a473206 100644 --- a/gdb/testsuite/gdb.tui/tui-focus.exp +++ b/gdb/testsuite/gdb.tui/tui-focus.exp @@ -21,11 +21,11 @@ tuiterm_env load_lib gdb-python.exp standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Run a series of tests based on various test specifications. # # Each test specification is a tuple where the first item is the name of a diff --git a/gdb/testsuite/gdb.tui/tui-init-source.exp b/gdb/testsuite/gdb.tui/tui-init-source.exp index edd364e05b12..f49b0ecdcbdb 100644 --- a/gdb/testsuite/gdb.tui/tui-init-source.exp +++ b/gdb/testsuite/gdb.tui/tui-init-source.exp @@ -21,11 +21,11 @@ require allow_tui_tests tuiterm_env standard_testfile if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { diff --git a/gdb/testsuite/gdb.tui/tui-layout-asm-short-prog.exp b/gdb/testsuite/gdb.tui/tui-layout-asm-short-prog.exp index e54ae69997ed..b3dd72ce1ceb 100644 --- a/gdb/testsuite/gdb.tui/tui-layout-asm-short-prog.exp +++ b/gdb/testsuite/gdb.tui/tui-layout-asm-short-prog.exp @@ -25,11 +25,11 @@ lappend opts debug lappend opts additional_flags=-static lappend opts additional_flags=-nostdlib lappend opts ldflags=-nostartfiles if { [build_executable "failed to prepare" $testfile $srcfile $opts] == -1 } { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::prepare_for_tui]} { unsupported "TUI not supported" diff --git a/gdb/testsuite/gdb.tui/tui-layout-asm.exp b/gdb/testsuite/gdb.tui/tui-layout-asm.exp index bbaa4f9b846f..01193b6fb44b 100644 --- a/gdb/testsuite/gdb.tui/tui-layout-asm.exp +++ b/gdb/testsuite/gdb.tui/tui-layout-asm.exp @@ -19,11 +19,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } # The wider the window is, the less line truncation happens, so matching # pre-scroll to post-scroll lines is more accurate. But 100% accurate line # matching isn't a goal of the test-case. diff --git a/gdb/testsuite/gdb.tui/tui-layout.exp b/gdb/testsuite/gdb.tui/tui-layout.exp index 05ca3b450290..1cb70504e3f8 100644 --- a/gdb/testsuite/gdb.tui/tui-layout.exp +++ b/gdb/testsuite/gdb.tui/tui-layout.exp @@ -21,11 +21,11 @@ require allow_tui_tests tuiterm_env standard_testfile if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} { - return -1 + return } # Run one test of the 'layout' command, selecting LAYOUT_NAME. # # TERMINAL should be either 'dumb' or 'ansi'. When TERMINAL is 'dumb' diff --git a/gdb/testsuite/gdb.tui/winheight.exp b/gdb/testsuite/gdb.tui/winheight.exp index 758f23d8f723..9daf08916af8 100644 --- a/gdb/testsuite/gdb.tui/winheight.exp +++ b/gdb/testsuite/gdb.tui/winheight.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { unsupported "TUI not supported" diff --git a/gdb/testsuite/gdb.tui/winwidth.exp b/gdb/testsuite/gdb.tui/winwidth.exp index a18ff4edba1f..cc6c7dcd1536 100644 --- a/gdb/testsuite/gdb.tui/winwidth.exp +++ b/gdb/testsuite/gdb.tui/winwidth.exp @@ -18,11 +18,11 @@ tuiterm_env standard_testfile tui-layout.c if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} { - return -1 + return } Term::clean_restart 24 80 $testfile if {![Term::enter_tui]} { unsupported "TUI not supported" From patchwork Wed Apr 29 23:04:27 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134219 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id 6903B4358A43 for ; Wed, 29 Apr 2026 23:10:03 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6903B4358A43 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=Qs38yEBu X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2c.google.com (mail-vk1-xa2c.google.com [IPv6:2607:f8b0:4864:20::a2c]) by sourceware.org (Postfix) with ESMTPS id B1E324BB3BD2 for ; Wed, 29 Apr 2026 23:06:45 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B1E324BB3BD2 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B1E324BB3BD2 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2c ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777504005; cv=none; b=jGLNHuAHDviHm9x1RLdqciVdFw5tJI1IZ+vRNbRwZQTmIezJvIQWv69/7Inz1w+CAL6iiGDKnurhGHqXITkMbLgm/gTNV2KcOd1QoAtDU1XkrzTA7c3YmCLVIhBnbYfSmUp5YzBFEl3EsSPc2+Kv0wOHXPt9CSFBU9CcR5q+2fU= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777504005; c=relaxed/simple; bh=vNDn4GuUVKCIIH4zCm7fzLrW5zaO30MhA22woT1WYMc=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=FkF/4u71sAdwJaftCO/d92V8n00/oswl2LRTD/54y+l8A2vEUV+AszkbGmWCUpic1LQjfmH2MTxi21RHte+/GsGtiDqSeeFYSQnboXdhZGfh825Royxslu5Lc4UJN8yAYi0gnrwCSDTUGUY7WNFrBf1qqkXoIvCwwZISxUTCMG0= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B1E324BB3BD2 Received: by mail-vk1-xa2c.google.com with SMTP id 71dfb90a1353d-56d933b555cso92748e0c.0 for ; Wed, 29 Apr 2026 16:06:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777504005; x=1778108805; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=aBYKAQar8/tSECA//E1n/qAmbI1oe7i1J3llcoplrg4=; b=Qs38yEBuj/qkXLloGfuTQlI8x1Hk6NyDDcWP1MHIQYkVSlaoqb7WDkcCad4t0ibyON bt3YiKvAEn3dwB5ftPextSa63NuaJ2EumkoPEtw7BDJ/IsAJGVq8DXLw2HAfrU7EF+uu lZ1Cfu+z0YLRtK2+64ahJMeJn+gkAHbs/GFkkW6+IeChUrUr66Vfam/OBYtUjs7CMrsi o2mkfr/Bv2S4gjLXLocIQpplWBD3puZRTj5yhnl0KZ3Ft6h4n12OBVZf8kvsBGdIDXmc 8RaTHmme4OFtnHUDxQ0B081bkbqpxlpI1PsBcn/WXf1va+xgzHh0mQVQ0emPJ7QVTQ1T u+0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777504005; x=1778108805; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=aBYKAQar8/tSECA//E1n/qAmbI1oe7i1J3llcoplrg4=; b=N0Sf4y5erhAko+yoFYCIhHW/LcdX2abLJx39jZSy7DUyZhvoMsCCorheUbQzNwwm34 +MkSJF6JzgxZymuZT/YH3OAMKXjzJss6n7SaAs7n051wtVOyA+8jWVrjwndFW1beAUNS l3s9L3TTkG+6Vg9tyLWQJmQsYKjlW3DX+tJILxeQQVEw7iqKRxL+JnjYj0z9787xUezR zcaBBGy9OZgpmBKU8CXBqvNunG7POEC1o7oE6eaokXlVIRlotTluk+V05o2fX2EUcWzy P0WJlgweBTM6b9t3BfnjvP/C+WZN3q7o7GSLqijdLdDKhO9lWgmpYHbbE5x1LAexZcmO acmg== X-Gm-Message-State: AOJu0YxFUW/d9AJKO5xZyRR/rR9774XhJHbD2S39vN9frdAWpObg1y2m Ylcb02CVRHZ19lhcGamESS/Q4z35U4MfeoUgn75U76FM288+d8NW6Q8c7A1s2CiRQPRWyrv6yw9 WlmCC X-Gm-Gg: AeBDiev/AOrgcVsmP7y1hh9799h8XjUKw89wKauSODYmPxrKTm83R6auCleUfchcEaW xWK5lsOy9qOA61IoE5UlcyxUA0MUcU+DrRwFpaDr9b71kmaZdC7b354nRStX4pNDpPbUZVaQAPq IIFFsL/OE7D0UT0wKXCv/zxheHmbZGXHzwA3xruJLASnh/UCnZQBtqT5LL/tqgHC95iYdXbzcqC jIKeLuWdfhizW44ZAAT2pbuwpkUThxPWhKGehWPe33Gpfq2zVuEwST/V5utw5zOtJlPdbIoRWeI hYpFBoNO4f6ESg8/R+0OqAAQDPRbdOE/WQZfKBls3wo0ePztsnQwVpngwTKJIqqL5S93hMzYBHH 2BqtjplJDW5YevDzIvmyA5S5zPlQ09RQvsf2x09ReRqPfwhNZwV4TIHEgKN4s2oX4uIyr+ILltM uSdnAOfW/3kLbHeHLLJiSiL44ns9/KDNOHI7cHFr1oVPG3GRrJYjg4Aek= X-Received: by 2002:a05:6122:8b8b:b0:573:a779:62cf with SMTP id 71dfb90a1353d-573c969445amr88410e0c.7.1777504005104; Wed, 29 Apr 2026 16:06:45 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6bbace7sm2073590e0c.5.2026.04.29.16.06.43 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:44 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 36/37] GDB: testsuite: TUI: Don't return 0 from top-level (manual) Date: Wed, 29 Apr 2026 20:04:27 -0300 Message-ID: <20260429230432.60487-37-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_SHORT, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch changes statements that return 0 from the top level, and also one "return -1" statement that wasn't caught by sed. --- gdb/testsuite/gdb.tui/basic.exp | 2 +- gdb/testsuite/gdb.tui/resize-2.exp | 2 +- gdb/testsuite/gdb.tui/tui-disasm-long-lines.exp | 2 +- gdb/testsuite/gdb.tui/tui-mode-switch.exp | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gdb/testsuite/gdb.tui/basic.exp b/gdb/testsuite/gdb.tui/basic.exp index 26264082a163..45fdf3a7a76f 100644 --- a/gdb/testsuite/gdb.tui/basic.exp +++ b/gdb/testsuite/gdb.tui/basic.exp @@ -68,11 +68,11 @@ for { set i 1 } { $i <= $Term::_cols } { incr i } { # current way we position source code on the screen, which might change in # the future. gdb_assert { $main_screen_line == 7 } \ "check main is where we expect on the screen" if { $main_screen_line == -1 } { - return 0 + return } # Check the horizontal scrolling. set shifted_main_re [string range $main_re 1 end] set regexp "$main_line\[\\t \]+$shifted_main_re" diff --git a/gdb/testsuite/gdb.tui/resize-2.exp b/gdb/testsuite/gdb.tui/resize-2.exp index 69578cc4a22e..b7eb38f3c046 100644 --- a/gdb/testsuite/gdb.tui/resize-2.exp +++ b/gdb/testsuite/gdb.tui/resize-2.exp @@ -25,11 +25,11 @@ set screen_dim { 0 0 80 24 } # Use a layout with just a command window. gdb_test "tui new-layout command-layout cmd 1" if {![Term::prepare_for_tui]} { unsupported "TUI not supported" - return 0 + return } # Enter TUI. Term::command_no_prompt_prefix "layout command-layout" diff --git a/gdb/testsuite/gdb.tui/tui-disasm-long-lines.exp b/gdb/testsuite/gdb.tui/tui-disasm-long-lines.exp index 58add6dc3291..00f52c7cdfb6 100644 --- a/gdb/testsuite/gdb.tui/tui-disasm-long-lines.exp +++ b/gdb/testsuite/gdb.tui/tui-disasm-long-lines.exp @@ -29,11 +29,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "$binfile" \ # Try with a shorter version. lappend ccopts "additional_flags=-DSHORT_IDENTIFIERS" if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "$binfile" \ executable $ccopts] != "" } { untested "compile" - return -1 + return } } Term::clean_restart 24 80 $testfile if {![Term::prepare_for_tui]} { diff --git a/gdb/testsuite/gdb.tui/tui-mode-switch.exp b/gdb/testsuite/gdb.tui/tui-mode-switch.exp index c60596213b85..250b557125ec 100644 --- a/gdb/testsuite/gdb.tui/tui-mode-switch.exp +++ b/gdb/testsuite/gdb.tui/tui-mode-switch.exp @@ -13,11 +13,11 @@ Term::with_term $term { Term::clean_restart 12 40 } if {![Term::prepare_for_tui]} { unsupported "TUI not supported" - return 0 + return } # Generate prompt. Term::gen_prompt From patchwork Wed Apr 29 23:04:28 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 134218 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [127.0.0.1]) by sourceware.org (Postfix) with ESMTP id E2B2F4BB589A for ; Wed, 29 Apr 2026 23:09:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E2B2F4BB589A Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=He/PwXRI X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from mail-vk1-xa2d.google.com (mail-vk1-xa2d.google.com [IPv6:2607:f8b0:4864:20::a2d]) by sourceware.org (Postfix) with ESMTPS id 3D0404BAE7C9 for ; Wed, 29 Apr 2026 23:06:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 3D0404BAE7C9 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 3D0404BAE7C9 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::a2d ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777504009; cv=none; b=YZ4XTekWiisgGYFH20+g6NRbAtgzWixadAwqYG4gPjWutzrtdrNj0MCi+R/ZNX8PM41QrArGUgfsCzpkCkHyjZNecbSx5A73Jixh0rCwzJN/7/l+Pl0TlNwCGXV6qh1UFAKFXSOOMOGIOA/b7gxgLF+Cu8tqILdbWhjGv7AvIsI= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777504009; c=relaxed/simple; bh=qAtRKzt1fgk58aY7AuNtk5zKF9QbGpULuXI+qzK48uI=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=shUcCEyrNiVhbRqyaKbyZdVmXuzMPhbmA3pp1/ontnYG6XtLRx8spk7L21pastYbGfk4Yan+uDlcKxFQtPFgn39lbGlRcLCxBO+qLKL11Kj5Kt9B6kWokO8lEuA65yv26uKcrdY5YTXOY0FMziuVS1yZObSvjFVcwy6YlvxFByA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3D0404BAE7C9 Received: by mail-vk1-xa2d.google.com with SMTP id 71dfb90a1353d-56a86f0a23bso302709e0c.0 for ; Wed, 29 Apr 2026 16:06:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777504009; x=1778108809; darn=sourceware.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=bep0wYpCwLzhOCW//4XYL10afxPDLPCpv74YKPizFb8=; b=He/PwXRIAZVGo8WJmD5YhyYomesOq85F5EGrV6NEk+B9vDc1rkzSWK2WA/JBtEyVC9 JkklJw+ewRpLLpL0717RCH1NmMxYfq1WRa5hOyNAPXM9ZJ3sFeWB4PwxcpJKWHk4yj+K fvVCkR7CQPKP1+e2r0UfcXhZDfTgdYEwyU9/KglkqNnReh21BdS36iProoG2Z+68sZHV 9Tos6qMn09PAaHkzJ2C0RJFUPFGCIv/qRMCyADIg5JVZaxQI143OB65x25At5RKgm2bf NpT2Xb83n0MIvmxrm/N0lH1cQbSvs+6Azk+/dKaSfxvABldciFjyHwh7/HAZaCT7Xl7C lsAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777504009; x=1778108809; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=bep0wYpCwLzhOCW//4XYL10afxPDLPCpv74YKPizFb8=; b=oS+CbTKnA97pEWmQY1qaMY53YWnJ3k27cHbjsmtGLSQDxlZMgWy9DdFmnUcxgxGOst Hhvh0QNkLaOwiY7ZkfNXfifEa9AWwR42+o/0D8U2xGXPrvOMulMdAixUlIxIk1eyi2ms flrDLvPoIPosBcyO0Gm0U2t8GmXw+RQnxC9iFpVRLOvg2Ui6wMNdhZNHfmRXJhXAn/7C 375DhxJcFuacFBXb5z6HF1ov3W4NO5EQyzw9WvSmljRaDhf2+JQK9oRdC9uosM1OGDmo HuSEKhvsVxzPDWFfZWks5ajjlo02nu2CnPKOgQyiudsb16+yH2w/bWkuSYH2lapeZE3j etzA== X-Gm-Message-State: AOJu0Yxb9ayxnJ68h8dte0PeKVl66/pZSaPQ4Kb5U0ngkTkaDF/OLeLK wAQFPWz1D41tx2wWX0h2GCOF43Jkjze9/tsSOdFHe6xOk836ZXVfYAMMfEvEZMS66orW5VTN4P8 QM+5U X-Gm-Gg: AeBDieu9Bl7wCVCn23hElm1WIXtAfhToRbwHiEtXdyMlqsC8gN9mWYO8LcOPE7eZoRJ 4rLdqcLaCawyl6jwwV5EADup85iiCdF900bvIirXMP1Xm4rRpzDMFhbyFzYTjTa0ETRVmbndzud HbdCXdyyEW5CPmE15K0vUGqveZVUHQzlToq320ctOexyJF8W5mAsZVG3xOj2McLwxQWx6J4XNJY BZiHkTAGQ3ahUq7QQZMVYGcl9NL4t4QKmPBXG0weCXKo+o9+toCrw/o+zPnrdgM/FS5e9gmJdZn wjvIn9zuTgGPldgI0Z6oJVCzNL11eaV9m6k4o2JMuhZRyN1eEkSqqWIqkgTIP7ZhUJGk3Bj1xTA ETPdgwVz/kmyVqbkZ1j4JgkymfZe1U/pq6ISZqWsE+YyHdGc7Xpufy2jLfFK1unVTkkgbg9DEoT 7NeBprvTKr+awK+F4yQZLC2EfkehPSla9m/9ZwEXJB84wdOMeB9zfEsAk= X-Received: by 2002:a05:6122:e266:b0:56f:1bbb:83d6 with SMTP id 71dfb90a1353d-573c966b5a9mr88927e0c.10.1777504008662; Wed, 29 Apr 2026 16:06:48 -0700 (PDT) Received: from localhost ([2804:14d:7e39:8083:f04c:42e3:5943:38f6]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-573b6b7d4eesm2098245e0c.2.2026.04.29.16.06.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2026 16:06:47 -0700 (PDT) From: Thiago Jung Bauermann To: gdb-patches@sourceware.org Subject: [PATCH v2 37/37] GDB: testsuite: XML: Don't return -1 nor 0 from top-level Date: Wed, 29 Apr 2026 20:04:28 -0300 Message-ID: <20260429230432.60487-38-thiago.bauermann@linaro.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260429230432.60487-1-thiago.bauermann@linaro.org> References: <20260429230432.60487-1-thiago.bauermann@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-11.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, 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 sourceware.org 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~patchwork=sourceware.org@sourceware.org This patch changes statements that return -1 or 0 from the top level. --- gdb/testsuite/gdb.xml/tdesc-arch.exp | 4 ++-- gdb/testsuite/gdb.xml/tdesc-regs.exp | 2 +- gdb/testsuite/gdb.xml/tdesc-reload.exp | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/gdb.xml/tdesc-arch.exp b/gdb/testsuite/gdb.xml/tdesc-arch.exp index f3bb9ba26523..1f9b3c200571 100644 --- a/gdb/testsuite/gdb.xml/tdesc-arch.exp +++ b/gdb/testsuite/gdb.xml/tdesc-arch.exp @@ -29,11 +29,11 @@ gdb_test_multiple "set architecture" $msg { pass $msg } -re "Requires an argument. Valid arguments are (\[^ \]*), auto\\.\r\n$gdb_prompt $" { # If there is just one supported architecture, we can't do this test. unsupported "tdesc-arch.exp" - return -1 + return } } set default_arch "" set msg "read default architecture" @@ -45,11 +45,11 @@ gdb_test_multiple "show architecture" $msg { } # If that did not work, no point running further tests. if { "$arch1" == "" || "$arch2" == "" || "$default_arch" == "" } { unresolved "architecture XML tests" - return -1 + return } # Run these tests twice, once for $arch1 and once for $arch2, to # make sure that the tdesc file overrides the global default. # TRANS_MODE indicates how newlines should be represented; it should diff --git a/gdb/testsuite/gdb.xml/tdesc-regs.exp b/gdb/testsuite/gdb.xml/tdesc-regs.exp index 96f0fe089aa5..092355020b2c 100644 --- a/gdb/testsuite/gdb.xml/tdesc-regs.exp +++ b/gdb/testsuite/gdb.xml/tdesc-regs.exp @@ -107,11 +107,11 @@ if {[string equal ${core-regs} ""]} { } elseif { $feature_test_unsupported } { # Remind maintainers to add test support. unsupported "register tests (missing architecture-specific core-regs setting)" } - return 0 + return } # Otherwise, we support both XML and target defined registers. # Make sure we reject a description missing standard registers, diff --git a/gdb/testsuite/gdb.xml/tdesc-reload.exp b/gdb/testsuite/gdb.xml/tdesc-reload.exp index cdd075de099d..41dc30a7a5a1 100644 --- a/gdb/testsuite/gdb.xml/tdesc-reload.exp +++ b/gdb/testsuite/gdb.xml/tdesc-reload.exp @@ -19,15 +19,15 @@ require allow_xml_test standard_testfile if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} { - return -1 + return } if {![runto_main]} { - return 0 + return } # Three files we're going to write out to. set xml_file_1 [host_standard_output_file outfile1.xml] set xml_file_2 [host_standard_output_file outfile2.xml] @@ -58,11 +58,11 @@ gdb_test_no_output "set tdesc filename $xml_file_1" \ # Load the executable. gdb_load ${binfile} # Run to `main' where we begin our tests. if {![runto_main]} { - return -1 + return } # Run info registers just to check this appears to run fine with the # new target description. gdb_test -lbl "info all-registers" "" "Run info registers"