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 28F353842405 for ; Sun, 29 May 2022 02:30:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 28F353842405 Received: from pps.filterd (m0098396.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 24SN4I8v019679; Sun, 29 May 2022 02:30:21 GMT Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3gbw36j4r8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 29 May 2022 02:30:21 +0000 Received: from m0098396.ppops.net (m0098396.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 24T2ULcu008267; Sun, 29 May 2022 02:30:21 GMT Received: from ppma02wdc.us.ibm.com (aa.5b.37a9.ip4.static.sl-reverse.com [169.55.91.170]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3gbw36j4qw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 29 May 2022 02:30:21 +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 24T2JhQn004145; Sun, 29 May 2022 02:30:19 GMT Received: from b01cxnp22035.gho.pok.ibm.com (b01cxnp22035.gho.pok.ibm.com [9.57.198.25]) by ppma02wdc.us.ibm.com with ESMTP id 3gbc9255d1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 29 May 2022 02:30:19 +0000 Received: from b01ledav002.gho.pok.ibm.com (b01ledav002.gho.pok.ibm.com [9.57.199.107]) by b01cxnp22035.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 24T2UJKP25428268 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 29 May 2022 02:30:19 GMT Received: from b01ledav002.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5FBE612405A; Sun, 29 May 2022 02:30:19 +0000 (GMT) Received: from b01ledav002.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CB173124054; Sun, 29 May 2022 02:30:18 +0000 (GMT) Received: from [9.160.72.217] (unknown [9.160.72.217]) by b01ledav002.gho.pok.ibm.com (Postfix) with ESMTP; Sun, 29 May 2022 02:30:18 +0000 (GMT) Message-ID: <17f6beb2-db1a-0bec-b022-168373c3921b@linux.ibm.com> Date: Sat, 28 May 2022 21:30:18 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: Plugin-based opcode table Content-Language: en-US To: Dmitry Selyutin , Alan Modra Cc: Luke Kenneth Casson Leighton , lkcl , binutils@sourceware.org References: From: Peter Bergner In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: kxUHrlPcxEJ_4UjwxwYmF6gsqumlHaIu X-Proofpoint-GUID: mQgGb7tbDrtqYv8PbRX4otdcpfxQ6sGj X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.874,Hydra:6.0.486,FMLib:17.11.64.514 definitions=2022-05-28_10,2022-05-27_01,2022-02-23_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 phishscore=0 malwarescore=0 spamscore=0 lowpriorityscore=0 bulkscore=0 priorityscore=1501 impostorscore=0 mlxlogscore=990 suspectscore=0 clxscore=1015 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2204290000 definitions=main-2205290012 X-Spam-Status: No, score=-3.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_EF, LIKELY_SPAM_BODY, NICE_REPLY_A, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) 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: Sun, 29 May 2022 02:30:28 -0000 On 5/23/22 8:06 AM, Dmitry Selyutin via Binutils wrote: > On Mon, May 23, 2022 at 3:59 PM Alan Modra wrote: >> I don't see any need for the artificial boundaries you might get with >> a plugin, whatever that might look like. ppc-opc.c already supports >> multiple incompatible powerpc cpu implementations, including ones that >> depart significantly from current powerpc ISA documentation. > > Alan, please, correct me if I'm wrong: does it mean that we can just > stick to marking new instructions and facilities with a custom per-CPU > flag? For now I introduced the -mlibresoc CPU which enabled the > PPC_OPCODE_SVP64 flag, and marked some new instructions appropriately > with this flag. Would that be OK if we follow this approach? I'm just catching up on my email backlog after being on vacation last week, but I agree with everything Alan said and also agree with how you're going about things. That said, I assume your -mlibresoc flag enables more than just the PPC_OPCODE_SVP64 flag, since there is a lot of "base" POWER instructions like addi, etc. that I'm sure your cpu implements. If for some reason, one of those "base" instructions enabled by -mlibresoc isn't implemented by your cpu or conflicts in some way with your new instructions, you can add the PPC_OPCODE_SVP64 to the deprecated field for the problematic instruction to disable it when using -mlibresoc. For example, POWER9 uses all the flags POWER8 enables plus PPC_OPCODE_POWER9. However, the "lxvx" instruction changed between POWER8 (where it was an extended mnemonic for lxvd2x) and POWER9 where is became a real instruction with a different opcode than lxvd2x (I'm ignoring that doing that was a very bad idea!). How that was solved, was adding PPC_OPCODE_POWER9 to the old lxvx instruction's deprecated field to disable that on POWER9 and later cpus. POWER9 and later cpus get the new lxvx instruction, because we enable it with the PPC_OPCODE_POWER9. Peter