From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by sourceware.org (Postfix) with ESMTPS id 888253942012 for ; Mon, 28 Nov 2022 17:02:44 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 888253942012 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=us.ibm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=us.ibm.com Received: from pps.filterd (m0187473.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 2ASG0oSV035172; Mon, 28 Nov 2022 17:02:43 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=message-id : from : to : cc : date : in-reply-to : references : content-type : mime-version : content-transfer-encoding : subject; s=pp1; bh=u7ehWntqeA8Y0vyQC3BdCUqyXcyW5VXBwG42HZZuhfs=; b=SH8B2a2FTcraMSEwEdeyL8GUyf1Mzhd1WsWYLPEs18ltgr7refdEnM/+aMTVHxSU6k/s D3yTL5Nn58zaeI5GV5efhpyTD+qRXicEZDLdgdcWpJcqWpO+XaWbnzUVkTKtXw+ICNlE 2oEJ3iMZJ6mLzOpKMMebjK4+VxkHon8CnRnTb68WiCUS/zgGV6V1I3RqgXwmmzl4sEbN QkCANTe5oJ7XW3dXUdjAw1d9Zpv6uKHF819z8FG7SSNt/W6kCMI4rfJvjLkUvqnMFsNe 73wjWTeODxyhca7HnWMp5YYEiHrc8vwq4qvp0OQ+cN25zsZ6ciL/F3DrvHUoNkCmuQqW 3Q== Received: from ppma01dal.us.ibm.com (83.d6.3fa9.ip4.static.sl-reverse.com [169.63.214.131]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3m3vv9xr6g-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 28 Nov 2022 17:02:43 +0000 Received: from pps.filterd (ppma01dal.us.ibm.com [127.0.0.1]) by ppma01dal.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 2ASGpMZT006563; Mon, 28 Nov 2022 17:02:42 GMT Received: from b01cxnp22035.gho.pok.ibm.com (b01cxnp22035.gho.pok.ibm.com [9.57.198.25]) by ppma01dal.us.ibm.com with ESMTP id 3m3ae9thjd-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 28 Nov 2022 17:02:42 +0000 Received: from smtpav01.wdc07v.mail.ibm.com ([9.208.128.113]) by b01cxnp22035.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 2ASH2f3j10683086 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 28 Nov 2022 17:02:41 GMT Received: from smtpav01.wdc07v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id D237F58074; Mon, 28 Nov 2022 17:02:40 +0000 (GMT) Received: from smtpav01.wdc07v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4B15D5808D; Mon, 28 Nov 2022 17:02:40 +0000 (GMT) Received: from li-e362e14c-2378-11b2-a85c-87d605f3c641.ibm.com (unknown [9.163.52.7]) by smtpav01.wdc07v.mail.ibm.com (Postfix) with ESMTP; Mon, 28 Nov 2022 17:02:40 +0000 (GMT) Message-ID: <69ca80b6a0fd18f3fda900b8907588e30bb07eff.camel@us.ibm.com> From: Carl Love To: Tom de Vries , gdb-patches@sourceware.org Cc: Ulrich Weigand , cel@us.ibm.com Date: Mon, 28 Nov 2022 09:02:39 -0800 In-Reply-To: <20221128125751.1712-1-tdevries@suse.de> References: <20221128125751.1712-1-tdevries@suse.de> 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: gLAEII7l9B8nBcXEYKnVePCB0_GtgBF6 X-Proofpoint-GUID: gLAEII7l9B8nBcXEYKnVePCB0_GtgBF6 Subject: Re: [pushed] [gdb/testsuite] Fix gdb.arch/altivec-regs.exp with gcc 4.8.5 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-11-28_14,2022-11-28_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 impostorscore=0 suspectscore=0 bulkscore=0 phishscore=0 spamscore=0 priorityscore=1501 lowpriorityscore=0 adultscore=0 mlxlogscore=938 mlxscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2211280126 X-Spam-Status: No, score=-11.3 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,GIT_PATCH_0,KAM_NUMSUBJECT,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Tom: On Mon, 2022-11-28 at 13:57 +0100, Tom de Vries wrote: > On powerpc64le-linux, using gcc 4.8.5, I run into: > ... > (gdb) PASS: gdb.arch/altivec-regs.exp: next (1) > next^M > 11 c = vec_add (a, b);^M > (gdb) PASS: gdb.arch/altivec-regs.exp: next (2) > print/x a^M > $67 = {0xfefefefe, 0xfefefefe, 0xfefefefe, 0xfefefefe}^M > (gdb) FAIL: gdb.arch/altivec-regs.exp: print vector parameter a > ... > > Looking at the disassembly and the debug info, it's clear why there's > a FAIL. > > The debug info says that the variable can be found at some stack > location, but > the instructions don't seem to be writing there. > > We can work around this by marking variable a volatile. Likewise for > b. > > Note that marking the variables as volatile doesn't change the > location > information. > > Tested on power64le-linux. > --- > gdb/testsuite/gdb.arch/altivec-regs.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/gdb/testsuite/gdb.arch/altivec-regs.c > b/gdb/testsuite/gdb.arch/altivec-regs.c > index 4d4fe3f5dbb..8f3b729fe3f 100644 > --- a/gdb/testsuite/gdb.arch/altivec-regs.c > +++ b/gdb/testsuite/gdb.arch/altivec-regs.c > @@ -2,7 +2,7 @@ > #include > > vector unsigned int > -vector_fun (vector unsigned int a, vector unsigned int b) > +vector_fun (volatile vector unsigned int a, volatile vector unsigned > int b) > { > vector unsigned int c; > a = ((vector unsigned int) vec_splat_u8(2)); > > base-commit: 2650ea9730e31fc5c9111afc1a689dbca76707f5 I ran this test case before and after your commit on my Power 10 and my Power 9 box. I did not see a failure before or after the commit on either machine. The fix looks fine to me as it doesn't change the behavior on Power 9 or Power 10 that I can see. Carl