From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR03-DBA-obe.outbound.protection.outlook.com (mail-dbaeur03on2040.outbound.protection.outlook.com [40.107.104.40]) by sourceware.org (Postfix) with ESMTPS id CA6AC3858D39 for ; Wed, 19 Oct 2022 06:08:09 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org CA6AC3858D39 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=J7Qp6Pa3jetdssFwU/KnBrvIFotZS7O1UXg9asE3xkrHmzSzesC8+KL1ai+KEuHQqt+Ven9o5ysSkLvAUqXmpzTHL9ZW8M1APN5gO8+Wc6P2kKXk6O3jAHA2hGLXpOVUwFoR2hSToiNBEY8GZH07t7gdkLVekHkB9Y+PffpthDZ4VDhFzd/HDLOIO8/nvk0X95urGH4gIvO+j02eq5b0gROlk3knCYIzZSz6yjy2jsmG8q54NG6NrrqJCVSSUVHOMk6dMp85vyaSBK5Xl4EqmTltK8WR71pAvwo4FiTYUnDsVMTVlzADoEjLFdicBUpoOZX+0zxQwkAUziLIQIG7aw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=kc6+1JBBnnWaROBylY2nnbZRfggfIMtXiFmJIrGj0wE=; b=lbPtgU6OwNUsWzO1hdvZtCxU/IwrUocgy2QKF8qR751h7VH/Fh0yexXPbxbTgmcbVGlL9sn1r9i3n+CiXxpKGLNTbpnQhjuU14oPmmzAAMlrVZpbWxZg5k3jeFyEeFWtfd0npIn2so4xLwdwH1ClJwCgghu7n27N/eQsbsbIK6kkon71pNhD8DxSXBqpL6w+X2ksmZdOeoyDB3s8S1kMhVHn4FdqQzCrZ3qVo/wGn/VP9hFK3E0Kz3O7xeQuIrFDpMESmSl/uvE/RwFMmiJt+Ih9dT2V/iPqFbx9tOlar8MVyj2JIdYc3wTSUNHmHSiaVGedMjtSNoCZ7hydD3ra4A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=kc6+1JBBnnWaROBylY2nnbZRfggfIMtXiFmJIrGj0wE=; b=a+gBUa0eT7Bx1oi79BA+b5qfwWMo5RE+LGM7QzWKNff1geKRTBFMf5aWULirOGowz+GLmh9OH7AvUSUuD3MDIm8pFnH1GTcmFuapOVmB3d8ADLogOQtbQZbZeZHsPTHwz4MNbV+hVW89RPYc9/08Vs+TU7w1frTfQOYzrsk4uwBKCqL7ABBNOtvPea/9SngEt3wKw1Ly/cfHGnr6gWGz+ImnLIXRE3t87la5j3GmTaqwfEuopjAgRbAEBUQUZHeaqf/dIydw9MSaGJLntE57GfAXCNqws8YhAbWQR4z2EaNCPwo8r+a/czPdZVOKIpW2eiKc7Mb+Vqi2CyTvSewm4g== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from VE1PR04MB6560.eurprd04.prod.outlook.com (2603:10a6:803:122::25) by AM9PR04MB8555.eurprd04.prod.outlook.com (2603:10a6:20b:436::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5709.15; Wed, 19 Oct 2022 06:08:07 +0000 Received: from VE1PR04MB6560.eurprd04.prod.outlook.com ([fe80::2459:15ae:e6cb:218a]) by VE1PR04MB6560.eurprd04.prod.outlook.com ([fe80::2459:15ae:e6cb:218a%7]) with mapi id 15.20.5723.034; Wed, 19 Oct 2022 06:08:07 +0000 Message-ID: <8c7a9008-64cc-54a6-6124-4517f31d8d5c@suse.com> Date: Wed, 19 Oct 2022 08:08:06 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.3.3 Subject: Re: [PATCH v3 4/7] x86-64: further re-work insn/suffix recognition to also cover MOVSL Content-Language: en-US To: "H.J. Lu" Cc: Binutils References: <20e2773a-2e47-869b-1900-709f8ad4cd6b@suse.com> <2981100a-17bf-623c-27fc-0da08279c3ff@suse.com> <32052f49-9789-36c6-fc26-a7e24f248435@suse.com> <8a1fe0ad-d5a3-cdb6-780b-6ac69123a51d@suse.com> From: Jan Beulich In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: FR3P281CA0008.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:1d::14) To VE1PR04MB6560.eurprd04.prod.outlook.com (2603:10a6:803:122::25) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: VE1PR04MB6560:EE_|AM9PR04MB8555:EE_ X-MS-Office365-Filtering-Correlation-Id: 3b0c81c4-a483-44c1-c512-08dab1984ad5 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: icXALEIxWLGUnheALislZnDO/bNlGR6clrr1l7A8SCly+siDrL2kri6X11wbkmgufz4o7DUmqUxEdiUXyfzkA4ckhJovlN80uybitqOdVSoT9gVyURXAlzf1rwPbE6tmz6SFlp4y2f66CVwXqjxKYePi1GPP4u0hshB5WV9NQfV7T7OVIo596uDGrcMPtkWbD0Ow6qNqZbut21rmP3sth3Mg1Zq6CyYr8HzXcRkU+KaJ/qUrfCPN2NXoXYmYhAc6JzEOYoiBAjWpREjUe7cMb22pta5UDeHwfRvvLOrN6aAlusit1kMX7TL5+3LmMG9Je1mOmsj+UIu2Q+UW4GzGLK361/ToHRBdzE4xaVBzbkbQJx1Z+st16aHrNuLxYCFFTk5favx6wzefSst8YJCNddZ2RwdgnZmPSGRU8bnu6ksH9h0EUdJZdpaTEd4Tg8N1NFlP2VxW79NzgYv8a0ENltikVgQH+qQ3zykW8DDbvXr2bw5TW6MhfJx3LPFoRQL22nhNigRxuAOB6CpAWmM1Q0xn3zUiioh++TNNQZxJVFxkLmomNDRWDlf2xQlK0jphsP1JRn/7IaRLLrZJ2ReIP68Mtq7P5kWnWxYF5/mIEZfsyVMskCMqAm8B8ohkhayfS/xwUtPhqlcFwXWGGDbLnD3yGByK9F7a0/cFlXdaLpwFa1R6NDaOzB/VsxDB+ihdq37nYiEakZAZccGk3z7zT4epTttSHCbDFgExE290qKVU+vsS2z1BSmaH50IcEbnDns+08DLrR9e1YcB/80cjZwvImFRuYHz0ygXfkzYhrAA= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VE1PR04MB6560.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(346002)(136003)(396003)(366004)(376002)(39860400002)(451199015)(36756003)(66899015)(31686004)(41300700001)(316002)(6506007)(66476007)(6486002)(66556008)(31696002)(4326008)(478600001)(6916009)(26005)(186003)(38100700002)(53546011)(86362001)(8676002)(8936002)(5660300002)(2616005)(66946007)(6512007)(83380400001)(2906002)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?SlNLbVNuSnIwUSt2T3B0Tnh2ZEpXRmVMNGZDaDk2SVdZTkdKT0dmRTBJcFJo?= =?utf-8?B?ZVhEOVlkWTA1SCtOSkJUNzlqcUxIUVVCRDA0dnhwZVNZZU5FVllmaGlrUVBD?= =?utf-8?B?cFIyREUrdkZwemJBRU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WNIYW92?= =?utf-8?B?YklrVWx4c045L1lNYmJyZGZBMmRmUkQ5ZVEzeE5PbkhJWFYzZjI3eENETWFs?= =?utf-8?B?S2tSRlhIVWJmNURwb2NPTVorS1FVTUlZdjhLQVZydUNQWEpLOStETkxVTm55?= =?utf-8?B?REMwQzNPdFJLNTg1NWhRaStNR1RGYkJBVUgyc3lHdnk0TElVS3hmMTlSUFFJ?= =?utf-8?Q?I9a6e8YG9BT7y48XkArt8gQa5?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3b0c81c4-a483-44c1-c512-08dab1984ad5 X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6560.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Oct 2022 06:08:07.6421 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 0dhuVygQZYy0rSImZfmybMpszdq4a2+pc+mtbUrUyMByjqNyx21W0L6Taa8F9DPWtLjWm51GfCHul6U9QDSuag== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR04MB8555 X-Spam-Status: No, score=-3029.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,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: On 18.10.2022 23:48, H.J. Lu wrote: > On Mon, Oct 17, 2022 at 11:31 PM Jan Beulich wrote: >> >> On 18.10.2022 00:36, H.J. Lu wrote: >>> On Mon, Oct 17, 2022 at 12:02 AM Jan Beulich wrote: >>>> >>>> On 14.10.2022 19:07, H.J. Lu wrote: >>>>> On Fri, Oct 14, 2022 at 12:03 AM Jan Beulich wrote: >>>>>> >>>>>> On 13.10.2022 19:00, H.J. Lu wrote: >>>>>>> On Wed, Oct 12, 2022 at 11:08 PM Jan Beulich wrote: >>>>>>>> >>>>>>>> On 12.10.2022 19:10, H.J. Lu wrote: >>>>>>>>> On Wed, Oct 12, 2022 at 12:08 AM Jan Beulich wrote: >>>>>>>>>> >>>>>>>>>> On 11.10.2022 19:44, H.J. Lu wrote: >>>>>>>>>>> On Wed, Oct 5, 2022 at 12:24 AM Jan Beulich wrote: >>>>>>>>>>>> >>>>>>>>>>>> PR gas/29524 >>>>>>>>>>>> In order to make MOVSL{,Q} behave similarly to MOVSB{W,L,Q} and >>>>>>>>>>>> MOVSW{L,Q} we need to defer parse_insn()'s emitting of errors unrelated >>>>>>>>>>>> to prefix parsing. Utilize i.error just like match_template() does. >>>>>>>>>>> >>>>>>>>>>> Since movs{b,w,l,q} are string instructions, integer sign extensions >>>>>>>>>>> require a suffix to specify the destination size. This is different from other >>>>>>>>>>> integer instructions. Since only the new assembler allows the implicit suffix, >>>>>>>>>>> it won't be easy to use. We should improve error messages, but allowing >>>>>>>>>>> new syntax doesn't help much. >>>>>>>>>> >>>>>>>>>> It is an earlier change making most of this consistent with MOVZ*; it is >>>>>>>>> >>>>>>>>> MOVZ is different. There are no MOVZ string instructions. MOVS has >>>>>>>>> different meanings in ISA. MOVS difference from MOVZ in assembly >>>>>>>>> syntax should be expected. >>>>>>>> >>>>>>>> You've said so before, yes, but I continue to disagree. And as we can see >>>>>>>> from the series things can be made work consistently (and imo nothing else >>>>>>>> should have been done right from the beginning). >>>>>>>> >>>>>>> >>>>>>> There are inconsistencies in ISA. >>>>>> >>>>>> Sure. But we shouldn't add further ones in the assembler. >>>>> >>>>> Assembler just follows ISA. Programmers should learn to >>>>> deal with it or use a compiler. >>>> >>>> This is entirely non-constructive. Assembler writers should get things into >>>> usable (read: consistent) shape. Plus what ISA are you talking about here? >>> >>> GNU assembler has been this way for a long time and the current GNU >>> assembler will still be in use for the next few years. Assembler writers >>> should know about all these. >> >> Hmm, so after all not any ISA to follow? Plus do you suggest there's >> only people having written x86 assembler code for many years? And >> there's no people who would prefer to get their code into more >> consistent shape, but who are limited by assembler shortcomings? > > I prefer consistency with existing assemblers and ISA specs. > For new instructions, suffixes should be used only when there is > an ambiguity. For existing instructions, to support existing assembly > codes, suffixes may be optional even when there is an ambiguity. > But for integer MOVS instructions, suffixes have always been required. > I don't think we should change them now. We can improve documentation > if needed. > >> In any event, ... >> >>>> We're talking of mnemonics which aren't spelled out in any ISA document >>>> anyway. The only halfway official AT&T doc I'm aware of doesn't provide >>>> room for omitting size suffixes [1]. Yet that's a fundamental feature of gas, >>>> and elsewhere (recently: CMPccXADD) you're even suggesting to force people >>>> to omit suffixes (plus you've previously objected to the disassembler to >>>> consistently emit them in suffix-always mode). >>>> >>>> That same document was also only updated to cover 64-bit code in a half- >>>> hearted way, so can't necessarily be used for 64-bit only insns (it doesn't >>>> list any form of MOVSXD at all afaics, for example). Where not explicitly >>>> mentioned, their intended handling can only be inferred by using analogies. >>>> Nor do we support some of the odd (quirky I would say) mnemonics that are >>>> listed there, like xchglA or movabsbA (which is even wrongly described as >>>> moving an immediate value into the register). >>>> >>>> Bottom line: May I please ask that you take another (constructive) look at >>>> the v4 submission? >> >> ... this request continues to stand. > > I think we should improve diagnostics and documentation, not add new > syntaxes to existing instructions. I continue to disagree, but to make at least some forward progress: Which parts of this series can I expect an okay for (patches 5-7 already have one, but can't go in ahead)? I would try to re-order the series then to put the controversial patch(es) at the end, such that at least parts can go in and I can make further progress with other work. But there's no promise this re-ordering actually is going to work out if it's more than just this one patch which you continue to object to. Jan