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 9D4663858403 for ; Sat, 25 Sep 2021 23:29:38 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 9D4663858403 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 18PMuTv5003421 for ; Sat, 25 Sep 2021 19:29:37 -0400 Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com with ESMTP id 3ba0rth9pw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sat, 25 Sep 2021 19:29:37 -0400 Received: from m0098399.ppops.net (m0098399.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.43/8.16.0.43) with SMTP id 18PNRueJ005893 for ; Sat, 25 Sep 2021 19:29:36 -0400 Received: from ppma02dal.us.ibm.com (a.bd.3ea9.ip4.static.sl-reverse.com [169.62.189.10]) by mx0a-001b2d01.pphosted.com with ESMTP id 3ba0rth9ps-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 25 Sep 2021 19:29:36 -0400 Received: from pps.filterd (ppma02dal.us.ibm.com [127.0.0.1]) by ppma02dal.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 18PNSq9Q031652; Sat, 25 Sep 2021 23:29:36 GMT Received: from b03cxnp08026.gho.boulder.ibm.com (b03cxnp08026.gho.boulder.ibm.com [9.17.130.18]) by ppma02dal.us.ibm.com with ESMTP id 3b9ud9amfu-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 25 Sep 2021 23:29:36 +0000 Received: from b03ledav004.gho.boulder.ibm.com (b03ledav004.gho.boulder.ibm.com [9.17.130.235]) by b03cxnp08026.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 18PNTY1P32113114 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 25 Sep 2021 23:29:34 GMT Received: from b03ledav004.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CEBF6789A3; Sat, 25 Sep 2021 23:29:34 +0000 (GMT) Received: from b03ledav004.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4646878997; Sat, 25 Sep 2021 23:29:34 +0000 (GMT) Received: from [9.160.55.172] (unknown [9.160.55.172]) by b03ledav004.gho.boulder.ibm.com (Postfix) with ESMTP; Sat, 25 Sep 2021 23:29:34 +0000 (GMT) To: Binutils Cc: Alan Modra , Paul Clarke From: Peter Bergner Subject: [PATCH][Committed] PowerPC: Enable mfppr mfppr32, mtppr and mtppr32 extended mnemonics on POWER5 Message-ID: <2c58f84f-0917-3c89-4fc0-404b109e8a68@linux.ibm.com> Date: Sat, 25 Sep 2021 18:29:33 -0500 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 X-Proofpoint-GUID: KjSmUAbA5oA7yTEtzweUSER8wdE1ToPV X-Proofpoint-ORIG-GUID: YJrBbjrpxWWfmVpwl-i_o16_M3w1NYZW X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.391,FMLib:17.0.607.475 definitions=2021-09-25_07,2021-09-24_02,2020-04-07_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 bulkscore=0 phishscore=0 mlxscore=0 lowpriorityscore=0 malwarescore=0 spamscore=0 mlxlogscore=999 suspectscore=0 adultscore=0 impostorscore=0 priorityscore=1501 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2109230001 definitions=main-2109250176 X-Spam-Status: No, score=-10.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_EF, GIT_PATCH_0, KAM_NUMSUBJECT, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, 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 X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Sep 2021 23:29:40 -0000 PowerPC: Enable mfppr mfppr32, mtppr and mtppr32 extended mnemonics on POWER5 SPR 896 and the mfppr mfppr32, mtppr and mtppr32 extended mnemonics were added in ISA 2.03, so enable them on POWER5 and later. Noticed and reported by Paul. Committed to trunk. Peter opcodes/ * ppc-opc.c (powerpc_opcodes) : Enable on POWER5 and later. gas/ * testsuite/gas/ppc/power5.s: New test. * testsuite/gas/ppc/power5.d: Likewise. * testsuite/gas/ppc/ppc.exp: Run it. * testsuite/gas/ppc/power7.s: Remove tests for mfppr, mfppr32, mtppr and mtppr32. * testsuite/gas/ppc/power7.d: Likewise. diff --git a/gas/testsuite/gas/ppc/power5.d b/gas/testsuite/gas/ppc/power5.d new file mode 100644 index 00000000000..e46cea456f9 --- /dev/null +++ b/gas/testsuite/gas/ppc/power5.d @@ -0,0 +1,14 @@ +#as: -mpower5 +#objdump: -dr -Mpower5 +#name: POWER5 tests + +.* + +Disassembly of section \.text: + +0+00 : +.*: (7d 40 e2 a6|a6 e2 40 7d) mfppr r10 +.*: (7d 62 e2 a6|a6 e2 62 7d) mfppr32 r11 +.*: (7d 80 e3 a6|a6 e3 80 7d) mtppr r12 +.*: (7d a2 e3 a6|a6 e3 a2 7d) mtppr32 r13 +#pass diff --git a/gas/testsuite/gas/ppc/power5.s b/gas/testsuite/gas/ppc/power5.s new file mode 100644 index 00000000000..8bf65ff2f16 --- /dev/null +++ b/gas/testsuite/gas/ppc/power5.s @@ -0,0 +1,6 @@ + .text +power5: + mfppr 10 + mfppr32 11 + mtppr 12 + mtppr32 13 diff --git a/gas/testsuite/gas/ppc/power7.d b/gas/testsuite/gas/ppc/power7.d index a2e6df44a57..bb8d87ff270 100644 --- a/gas/testsuite/gas/ppc/power7.d +++ b/gas/testsuite/gas/ppc/power7.d @@ -103,9 +103,5 @@ Disassembly of section \.text: .*: (7f bd eb 78|78 eb bd 7f) mdoio .*: (7f de f3 78|78 f3 de 7f) mdoom .*: (7f de f3 78|78 f3 de 7f) mdoom -.*: (7d 40 e2 a6|a6 e2 40 7d) mfppr r10 -.*: (7d 62 e2 a6|a6 e2 62 7d) mfppr32 r11 -.*: (7d 80 e3 a6|a6 e3 80 7d) mtppr r12 -.*: (7d a2 e3 a6|a6 e3 a2 7d) mtppr32 r13 .*: (7d 60 52 64|64 52 60 7d) tlbie r10,r11 #pass diff --git a/gas/testsuite/gas/ppc/power7.s b/gas/testsuite/gas/ppc/power7.s index b8111128d6f..4f767832c1d 100644 --- a/gas/testsuite/gas/ppc/power7.s +++ b/gas/testsuite/gas/ppc/power7.s @@ -94,8 +94,4 @@ power7: or 29,29,29 mdoom or 30,30,30 - mfppr 10 - mfppr32 11 - mtppr 12 - mtppr32 13 tlbie 10,11 diff --git a/gas/testsuite/gas/ppc/ppc.exp b/gas/testsuite/gas/ppc/ppc.exp index b5ce36da4d4..dcf4f74f54c 100644 --- a/gas/testsuite/gas/ppc/ppc.exp +++ b/gas/testsuite/gas/ppc/ppc.exp @@ -116,6 +116,7 @@ run_dump_test "e500mc64_nop" run_dump_test "e5500_nop" run_dump_test "e6500_nop" run_dump_test "power4_32" +run_dump_test "power5" run_dump_test "power6" run_dump_test "power7" run_dump_test "power8" diff --git a/opcodes/ppc-opc.c b/opcodes/ppc-opc.c index 13d8b6c3c07..a34df1700d0 100644 --- a/opcodes/ppc-opc.c +++ b/opcodes/ppc-opc.c @@ -7073,8 +7073,8 @@ const struct powerpc_opcode powerpc_opcodes[] = { {"mfdvlim", XSPR(31,339,883), XSPR_MASK, TITAN, EXT, {RT}}, {"mfclcsr", XSPR(31,339,884), XSPR_MASK, TITAN, EXT, {RT}}, {"mfccr1", XSPR(31,339,888), XSPR_MASK, TITAN, EXT, {RT}}, -{"mfppr", XSPR(31,339,896), XSPR_MASK, POWER7, EXT, {RT}}, -{"mfppr32", XSPR(31,339,898), XSPR_MASK, POWER7, EXT, {RT}}, +{"mfppr", XSPR(31,339,896), XSPR_MASK, POWER5, EXT, {RT}}, +{"mfppr32", XSPR(31,339,898), XSPR_MASK, POWER5, EXT, {RT}}, {"mfgqr", XSPR(31,339,912), XSPRGQR_MASK, PPCPS, EXT, {RT, SPRGQR}}, {"mfhid2", XSPR(31,339,920), XSPR_MASK, GEKKO, EXT, {RT}}, {"mfwpar", XSPR(31,339,921), XSPR_MASK, GEKKO, EXT, {RT}}, @@ -7514,8 +7514,8 @@ const struct powerpc_opcode powerpc_opcodes[] = { {"mtdvlim", XSPR(31,467,883), XSPR_MASK, TITAN, EXT, {RS}}, {"mtclcsr", XSPR(31,467,884), XSPR_MASK, TITAN, EXT, {RS}}, {"mtccr1", XSPR(31,467,888), XSPR_MASK, TITAN, EXT, {RS}}, -{"mtppr", XSPR(31,467,896), XSPR_MASK, POWER7, EXT, {RS}}, -{"mtppr32", XSPR(31,467,898), XSPR_MASK, POWER7, EXT, {RS}}, +{"mtppr", XSPR(31,467,896), XSPR_MASK, POWER5, EXT, {RS}}, +{"mtppr32", XSPR(31,467,898), XSPR_MASK, POWER5, EXT, {RS}}, {"mtgqr", XSPR(31,467,912), XSPRGQR_MASK, PPCPS, EXT, {SPRGQR, RS}}, {"mthid2", XSPR(31,467,920), XSPR_MASK, GEKKO, EXT, {RS}}, {"mtwpar", XSPR(31,467,921), XSPR_MASK, GEKKO, EXT, {RS}},