From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id Kv0INUhLdGIXiAQAWB0awg (envelope-from ) for ; Thu, 05 May 2022 18:10:16 -0400 Received: by simark.ca (Postfix, from userid 112) id CBAA31E058; Thu, 5 May 2022 18:10:16 -0400 (EDT) Authentication-Results: simark.ca; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=Zy2CQH9q; dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 600141E00D for ; Thu, 5 May 2022 18:10:16 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 91910385737E for ; Thu, 5 May 2022 22:10:15 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 91910385737E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1651788615; bh=Kqs6PO1ZqGM/c2xZqmtn6u7ODUp0q8iQCIhNbLaqaKM=; h=Subject:To:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=Zy2CQH9q06aOdtSPGB/LDn/yFwg3kIv5Qtd6UFmIq64QGF1G+t/03LXTuyT6tp/3p pSEaHGNI+jcPVmtoU0kJguF5GF37aMp3PV9hjTFsxiVeOK6fehTN9I9b+WRon9wvn3 0C9/61r2f+4Zwd+6so/kYc4+wSd2tIxjFTdgjx4w= Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by sourceware.org (Postfix) with ESMTPS id E03653858016 for ; Thu, 5 May 2022 22:09:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org E03653858016 Received: from pps.filterd (m0098413.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 245LEatW017291 for ; Thu, 5 May 2022 22:09:56 GMT Received: from ppma02wdc.us.ibm.com (aa.5b.37a9.ip4.static.sl-reverse.com [169.55.91.170]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3fvpasgrgg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 05 May 2022 22:09:56 +0000 Received: from pps.filterd (ppma02wdc.us.ibm.com [127.0.0.1]) by ppma02wdc.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 245M8GN2015752 for ; Thu, 5 May 2022 22:09:55 GMT Received: from b03cxnp08027.gho.boulder.ibm.com (b03cxnp08027.gho.boulder.ibm.com [9.17.130.19]) by ppma02wdc.us.ibm.com with ESMTP id 3frvra4dyb-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 05 May 2022 22:09:55 +0000 Received: from b03ledav004.gho.boulder.ibm.com (b03ledav004.gho.boulder.ibm.com [9.17.130.235]) by b03cxnp08027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 245M9tA012780196 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 5 May 2022 22:09:55 GMT Received: from b03ledav004.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 07F287806A; Thu, 5 May 2022 22:09:55 +0000 (GMT) Received: from b03ledav004.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B0C0378067; Thu, 5 May 2022 22:09:54 +0000 (GMT) Received: from li-e362e14c-2378-11b2-a85c-87d605f3c641.ibm.com (unknown [9.211.152.172]) by b03ledav004.gho.boulder.ibm.com (Postfix) with ESMTP; Thu, 5 May 2022 22:09:54 +0000 (GMT) Message-ID: Subject: [PATCH] PowerPC fix for gdb.server/sysroot.exp To: gdb-patches@sourceware.org Date: Thu, 05 May 2022 15:09:54 -0700 Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5 (3.28.5-18.el8) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: qTFqcDB3dsdTUqz7NY92Pp-IFZl_0Ifo X-Proofpoint-GUID: qTFqcDB3dsdTUqz7NY92Pp-IFZl_0Ifo X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.858,Hydra:6.0.486,FMLib:17.11.64.514 definitions=2022-05-05_09,2022-05-05_01,2022-02-23_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 priorityscore=1501 mlxlogscore=839 spamscore=0 bulkscore=0 lowpriorityscore=0 impostorscore=0 mlxscore=0 clxscore=1015 phishscore=0 suspectscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2202240000 definitions=main-2205050142 X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Carl Love via Gdb-patches Reply-To: Carl Love Cc: Rogerio Alves Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" GDB maintainers: The gdb.server/sysroot.exp test has one failure on PowerPC. When gdb stops at the printf in the test, the output on PowerPC is not identical to other systems. The output include a little more information on the version of GLIBC. The result is the current gdb test fails. The following patch makes a minor change to the test so that the output for PowerPC and other architectures both pass. Intel and PowerPC both pass this test now. Please let me know if this patch is acceptable for mainline. Thanks. Carl Love ----------------------------------------------- PowerPC fix for gdb.server/sysroot.exp On PowerPC, the stop in the printf function is of the form: Breakpoint 2, 0x00007ffff7c6ab08 in printf@@GLIBC_2.17 () from /lib64/libc.so.6 On other architectures the output looks like: Breakpoint 2, 0x0000007fb7ea29ac in printf () from /lib/aarch64-linux-gnu/libc.so.6 The following patch modifies the printf test by matchine any character starting immediately after the printf. The test now works for PowerPC output as well as the output from other architectures. The test has been run on a Power 10 system and and Intel x86_64 system. --- gdb/testsuite/gdb.server/sysroot.exp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gdb/testsuite/gdb.server/sysroot.exp b/gdb/testsuite/gdb.server/sysroot.exp index a319200e8d2..95679fc0849 100644 --- a/gdb/testsuite/gdb.server/sysroot.exp +++ b/gdb/testsuite/gdb.server/sysroot.exp @@ -78,7 +78,7 @@ foreach_with_prefix sysroot { "local" "remote" } { # Test that we can stop inside a library. gdb_breakpoint printf - gdb_test "continue" "Breakpoint $decimal.* (__)?printf .*" \ + gdb_test "continue" "Breakpoint $decimal.* (__)?printf.*" \ "continue to printf" } } -- 2.31.1