From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by sourceware.org (Postfix) with ESMTPS id DD3EC3858D3C for ; Wed, 8 Dec 2021 20:50:07 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org DD3EC3858D3C Received: from pps.filterd (m0098417.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 1B8KR5kl016517; Wed, 8 Dec 2021 20:49:53 GMT Received: from ppma03wdc.us.ibm.com (ba.79.3fa9.ip4.static.sl-reverse.com [169.63.121.186]) by mx0a-001b2d01.pphosted.com with ESMTP id 3cu20m2dym-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 08 Dec 2021 20:49:52 +0000 Received: from pps.filterd (ppma03wdc.us.ibm.com [127.0.0.1]) by ppma03wdc.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 1B8KXdDd024497; Wed, 8 Dec 2021 20:49:52 GMT Received: from b03cxnp08027.gho.boulder.ibm.com (b03cxnp08027.gho.boulder.ibm.com [9.17.130.19]) by ppma03wdc.us.ibm.com with ESMTP id 3cqyy8j635-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 08 Dec 2021 20:49:52 +0000 Received: from b03ledav002.gho.boulder.ibm.com (b03ledav002.gho.boulder.ibm.com [9.17.130.233]) by b03cxnp08027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 1B8KnoVY27722464 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 8 Dec 2021 20:49:50 GMT Received: from b03ledav002.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id BCFA9136055; Wed, 8 Dec 2021 20:49:50 +0000 (GMT) Received: from b03ledav002.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5EE1A136051; Wed, 8 Dec 2021 20:49:50 +0000 (GMT) Received: from li-e362e14c-2378-11b2-a85c-87d605f3c641.ibm.com (unknown [9.211.124.5]) by b03ledav002.gho.boulder.ibm.com (Postfix) with ESMTP; Wed, 8 Dec 2021 20:49:50 +0000 (GMT) Message-ID: Subject: Re: [PATCH ver3] gdb: Add PowerPC support to gdb.dwarf2/frame-inlined-in-outer-frame.exp From: Carl Love To: Ulrich Weigand , Simon Marchi , cel@us.ibm.com Cc: gdb-patches@sourceware.org, Rogerio Alves , Will Schmidt Date: Wed, 08 Dec 2021 12:49:44 -0800 In-Reply-To: References: <61a8f3c2be6a60ff211ca02469bf3ce4554a36b1.camel@us.ibm.com> <92b6daba-54d6-bb1f-4c99-10b3ec32d3ec@polymtl.ca> <73426fba8d9ce1eb5fc60ae64a2ecd57074c510a.camel@us.ibm.com> <6f99e11d-25a7-ceaa-0975-06ac1d9d5d05@polymtl.ca> X-Mailer: Evolution 3.28.5 (3.28.5-16.el8) Mime-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: Krh95mcR4Jq-s5ZzmBM5KQN4kszZnYZ3 X-Proofpoint-GUID: Krh95mcR4Jq-s5ZzmBM5KQN4kszZnYZ3 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.11.62.513 definitions=2021-12-08_08,2021-12-08_01,2021-12-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 impostorscore=0 bulkscore=0 adultscore=0 spamscore=0 mlxlogscore=999 lowpriorityscore=0 priorityscore=1501 mlxscore=0 suspectscore=0 clxscore=1015 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2110150000 definitions=main-2112080113 X-Spam-Status: No, score=-12.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_EF, GIT_PATCH_0, HTML_MESSAGE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.29 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: , X-List-Received-Date: Wed, 08 Dec 2021 20:50:09 -0000 Ulrich, Simon: It looks like I tested Simon's last patch suggestion on a Power 9LE machine not the Power 8BE machine as intended. I verified that the current mainline version of the frame-inlined-in-outer-frame does not work on Power 8 BE. I created the following patch to revert back to the version of the patch with the _start symbol in the the Power LE, BE and default #if clauses. The patch was then retested on Power 10 LE and Power 8BE to verify the updated patch is working correctly. Sorry for messing up the previous testing. Please let me know if you see any additional issues with this patch or the assembly code file. Thanks. Carl --------------------------------------------------------------------- ------------------------------- gdb fix elfv1 Powerpc gdb.dwarf2/frame-inlined-in-outer-frame.exp On ELFv1, the _start symbol must point to the *function descriptor* (in the .opd section), not to the function code (in the .text section) like with ELFv2 and other architectures. Patch retested on Power 10 LE and Power 8 BE systems. Test passes on both systems. --- gdb/testsuite/gdb.dwarf2/frame-inlined-in-outer-frame.S | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gdb/testsuite/gdb.dwarf2/frame-inlined-in-outer-frame.S b/gdb/testsuite/gdb.dwarf2/frame-inlined-in-outer-frame.S index 224b50b20a5..112788a3440 100644 --- a/gdb/testsuite/gdb.dwarf2/frame-inlined-in-outer-frame.S +++ b/gdb/testsuite/gdb.dwarf2/frame-inlined-in-outer-frame.S @@ -103,19 +103,24 @@ #if defined __powerpc64__ # if _CALL_ELF == 2 .abiversion 2 /* Tell gdb what ELF version to use. */ +.global _start +_start: # else .abiversion 1 /* Tell gdb what ELF version to use. */ .align 2 +.global _start .section ".opd", "aw" .align 3 +_start: .quad ._start,.TOC.@tocbase,0 .previous .type ._start,@function ._start: # endif -#endif +#else .global _start _start: +#endif .cfi_startproc /* State that the return address for this frame is undefined. */ -- 2.25.1