public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] Fix gdb.arch/powerpc-power7.exp isel dis-assembly output.
@ 2022-06-08  0:02 Carl Love
  2022-06-08 10:37 ` Ulrich Weigand
  0 siblings, 1 reply; 2+ messages in thread
From: Carl Love @ 2022-06-08  0:02 UTC (permalink / raw)
  To: gdb-patches, Ulrich Weigand, Will Schmidt, cel

GDB maintainers:

The following patch updates the expected output for the isel
instruction following a recent change to the gdb dis-assembly output
for the isel instruction.  The change broke the test on Power 7, Power
8, Power 9 and Power 10.  

The patch has been tested and verified on Power 7 and Power 8. 

Please let me know if the patch is acceptable for mainline.

                  Carl Love


----------------------------------------------------------
Fix gdb.arch/powerpc-power7.exp isel dis-assembly output.

The following commit changes the output format for the dis-assembly instruction on
PowerPC.

   commit dd4832bf3efc1bd1797a6b9188260692b8b0db52     Introduces error in test
   Author: Dmitry Selyutin <ghostmansd@gmail.com>
   Date:   Tue May 24 13:46:35 2022 +0000

       opcodes: introduce BC field; fix isel

       Per Power ISA Version 3.1B 3.3.12, isel uses BC field rather than CRB
       field present in binutils sources. Also, per 1.6.2, BC has the same
       semantics as BA and BB fields, so this should keep the same flags and
       mask, only with the different offset.

       opcodes/
               * ppc-opc.c
               (BC): Define new field, with the same definition as CRB field,
               but with the PPC_OPERAND_CR_BIT flag present.
       gas/
               * testsuite/gas/ppc/476.d: Update.
               * testsuite/gas/ppc/a2.d: Update.
               * testsuite/gas/ppc/e500.d: Update.
               * testsuite/gas/ppc/power7.d: Update.
  <snip>
   --- a/gas/testsuite/gas/ppc/476.d
   +++ b/gas/testsuite/gas/ppc/476.d
   @@ -209,7 +209,7 @@ dis-assembly of section \.text:
    .*:    (7c 20 07 8c|8c 07 20 7c)       ici     1
    .*:    (7c 03 27 cc|cc 27 03 7c)       icread  r3,r4
    .*:    (50 83 65 36|36 65 83 50)       rlwimi  r3,r4,12,20,27
    -.*:    (7c 43 27 1e|1e 27 43 7c)       isel    r2,r3,r4,28
    +.*:    (7c 43 27 1e|1e 27 43 7c)       isel    r2,r3,r4,4\*cr7\+lt

The above change breaks the gdb regression test gdb.arch/powerpc-power7.exp
on Power 7, Power 8, Power 9 and Power 10.

This patch updates the regression test gdb.arch/powerpc-power7.exp with
the new expected output for the isel instruction.

The patch has been tested on Power 7 and Power 10 to verify the patch fixes
the test.
---
 gdb/testsuite/gdb.arch/powerpc-power7.exp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gdb/testsuite/gdb.arch/powerpc-power7.exp b/gdb/testsuite/gdb.arch/powerpc-power7.exp
index f2f4525cd6e..10f7eebefc9 100644
--- a/gdb/testsuite/gdb.arch/powerpc-power7.exp
+++ b/gdb/testsuite/gdb.arch/powerpc-power7.exp
@@ -140,7 +140,7 @@ func_check "frsqrte f14,f15"
 func_check "frsqrte. f14,f15"
 func_check "frsqrtes f14,f15"
 func_check "frsqrtes. f14,f15"
-func_check "isel    r2,r3,r4,28"
+func_check "isel    r2,r3,r4,4*cr7+lt"
 func_check "yield"
 func_check "ori     r2,r2,0"
 func_check "nop"
-- 
2.31.1



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] Fix gdb.arch/powerpc-power7.exp isel dis-assembly output.
  2022-06-08  0:02 [PATCH] Fix gdb.arch/powerpc-power7.exp isel dis-assembly output Carl Love
@ 2022-06-08 10:37 ` Ulrich Weigand
  0 siblings, 0 replies; 2+ messages in thread
From: Ulrich Weigand @ 2022-06-08 10:37 UTC (permalink / raw)
  To: gdb-patches, will_schmidt, cel

Carl Love <cel@us.ibm.com> wrote:

>Fix gdb.arch/powerpc-power7.exp isel dis-assembly output.

This is OK.

Thanks,
Ulrich


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-06-08 10:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-08  0:02 [PATCH] Fix gdb.arch/powerpc-power7.exp isel dis-assembly output Carl Love
2022-06-08 10:37 ` Ulrich Weigand

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).