From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-sender-0.a4lg.com (mail-sender.a4lg.com [153.120.152.154]) by sourceware.org (Postfix) with ESMTPS id D0C80385220B for ; Wed, 23 Nov 2022 08:20:14 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D0C80385220B Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=irq.a4lg.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=irq.a4lg.com Received: from [127.0.0.1] (localhost [127.0.0.1]) by mail-sender-0.a4lg.com (Postfix) with ESMTPSA id 27D2B300089; Wed, 23 Nov 2022 08:20:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=irq.a4lg.com; s=2017s01; t=1669191611; bh=P15xxqb6zZA0avf1+yMRMTtFCNuzo8rlxNMstNRgU/E=; h=Message-ID:Date:Mime-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type:Content-Transfer-Encoding; b=FVy8VYDCgCEWynHjDObYiqbTlVMKk1aSCLryCRZk8E7FcrQKoeAYRh6rpImAckfL/ RnpN2yJRs4+Pw9Xhu3EnNmJ6HhzEm1IVHHG5P9Fh6GVW3yiAg9YHOkSznKKORY42i0 sq5/jNHU4W7i2EWG6tLFLSWddHHVMWYcxHmc0f34= Message-ID: <5ae888a2-70d6-707b-7e3d-b6e055004479@irq.a4lg.com> Date: Wed, 23 Nov 2022 17:20:08 +0900 Mime-Version: 1.0 Subject: Re: [PATCH 1/2] RISC-V: Make .insn tests stricter Content-Language: en-US To: Jan Beulich Cc: binutils@sourceware.org, Nelson Chu References: <2e469b6dd7d8b93ffd3cac333dd58d172a8f28d6.1668841829.git.research_trasio@irq.a4lg.com> <6a9c59f1-ff0b-45b9-c4cc-d795b93a5c9f@suse.com> From: Tsukasa OI In-Reply-To: <6a9c59f1-ff0b-45b9-c4cc-d795b93a5c9f@suse.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,GIT_PATCH_0,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 2022/11/21 16:32, Jan Beulich wrote: > On 19.11.2022 08:10, Tsukasa OI wrote: >> To make sure that all instruction bits are dumped through ".byte", this >> commit makes matching patterns stricter (to cover all instruction bits). > > Hmm, it was deliberate to omit the .byte part of the disassembly, > very specifically because of the inconsistency of using only in > some cases. Personally I would agree with such tightening of the > expectations only if the disassembler was first improved. But of > course it's the maintainers judgement ... > > Jan Hi, I can agree most of your opinion except... even if we fix this inconsistency later (I won't, though), I think we can change the tests once we have changed the disassembler. So I don't find any problems making tests tighter. Nelson assigned you as the person who makes the final judgement and I want to hear your thoughts/decision about PATCH 1/2. p.s. I made a small change to PATCH 2/2 and I'll reply your feedback to PATCH 2/2 after PATCH v2 is submitted (PATCH v2 1/2 is unchanged from v1). Thanks, Tsukasa > >> --- a/gas/testsuite/gas/riscv/insn-na.d >> +++ b/gas/testsuite/gas/riscv/insn-na.d >> @@ -61,15 +61,15 @@ Disassembly of section .text: >> [^:]+:[ ]+022180d7[ ]+vadd\.vv[ ]+v1,v2,v3 >> [^:]+:[ ]+0001[ ]+c\.addi[ ]+zero,0 >> [^:]+:[ ]+00000013[ ]+addi[ ]+zero,zero,0 >> -[^:]+:[ ]+001f 0000 0000[ ].* >> -[^:]+:[ ]+0000003f 00000000[ ].* >> -[^:]+:[ ]+007f 0000 0000 0000 0000[ ]+[._a-z].* >> -[^:]+:[ ]+0000107f 00000000 00000000[ ]+[._a-z].* >> -[^:]+:[ ]+607f 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000[ ]+[._a-z].* >> +[^:]+:[ ]+001f 0000 0000[ ]+\.byte[ ]+0x1f, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+0000003f 00000000[ ]+\.8byte[ ]+0x3f >> +[^:]+:[ ]+007f 0000 0000 0000 0000[ ]+\.byte[ ]+0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+0000107f 00000000 00000000[ ]+\.byte[ ]+0x7f, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+607f 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000[ ]+\.byte[ ]+0x7f, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> [^:]+:[ ]+0001[ ]+c\.addi[ ]+zero,0 >> [^:]+:[ ]+00000013[ ]+addi[ ]+zero,zero,0 >> -[^:]+:[ ]+001f 0000 0000[ ].* >> -[^:]+:[ ]+0000003f 00000000[ ].* >> -[^:]+:[ ]+007f 0000 0000 0000 0000[ ]+[._a-z].* >> -[^:]+:[ ]+0000107f 00000000 00000000[ ]+[._a-z].* >> -[^:]+:[ ]+607f 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000[ ]+[._a-z].* >> +[^:]+:[ ]+001f 0000 0000[ ]+\.byte[ ]+0x1f, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+0000003f 00000000[ ]+\.8byte[ ]+0x3f >> +[^:]+:[ ]+007f 0000 0000 0000 0000[ ]+\.byte[ ]+0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+0000107f 00000000 00000000[ ]+\.byte[ ]+0x7f, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+607f 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000[ ]+\.byte[ ]+0x7f, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> diff --git a/gas/testsuite/gas/riscv/insn.d b/gas/testsuite/gas/riscv/insn.d >> index 2e5d35b39702..cf84f177af39 100644 >> --- a/gas/testsuite/gas/riscv/insn.d >> +++ b/gas/testsuite/gas/riscv/insn.d >> @@ -83,12 +83,12 @@ Disassembly of section .text: >> [^:]+:[ ]+0000 0000 0000 ? >> [^:]+:[ ]+0001[ ]+nop >> [^:]+:[ ]+00000013[ ]+nop >> -[^:]+:[ ]+001f 0000 0000[ ].* >> -[^:]+:[ ]+0000003f 00000000[ ].* >> -[^:]+:[ ]+007f 0000 0000 0000[ ]+[._a-z].* >> +[^:]+:[ ]+001f 0000 0000[ ]+\.byte[ ]+0x1f, 0x00, 0x00, 0x00, 0x00, 0x00 >> +[^:]+:[ ]+0000003f 00000000[ ]+\.8byte[ ]+0x3f >> +[^:]+:[ ]+007f 0000 0000 0000[ ]+\.byte[ ]+0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> [^:]+:[ ]+0000 ? >> -[^:]+:[ ]+0000107f 00000000[ ]+[._a-z].* >> +[^:]+:[ ]+0000107f 00000000[ ]+\.byte[ ]+0x7f, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> [^:]+:[ ]+00000000 ? >> -[^:]+:[ ]+607f 0000 0000 0000[ ]+[._a-z].* >> +[^:]+:[ ]+607f 0000 0000 0000[ ]+\.byte[ ]+0x7f, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 >> [^:]+:[ ]+0000 0000 0000 0000 ? >> [^:]+:[ ]+0000 0000 0000 ? >