Skip to contentSkip to conversation

M68k for 3.0 patches

GIT PULL Applied Laurent Vivier 2 participants 3 messages Jul 2, 2018

lore
Share & tools
lore
#0 lore raw

The following changes since commit 281bd281222776229d5dbf84d1a5c6d8d9d2a34b:

Merge remote-tracking branch 'remotes/xtensa/tags/20180630-xtensa' into staging (2018-06-30 22:23:51 +0100)

are available in the Git repository at:

git://github.com/vivier/qemu-m68k.git tags/m68k-for-3.0-pull-request

for you to fetch changes up to d9345f1e1b1936b9ed7026b83091cf701f7ce07e:

target/m68k: correctly disassemble move16 (2018-07-02 12:02:00 +0200)

----------------------------------------------------------------
correctly disassemble move16

----------------------------------------------------------------

Laurent Vivier (1):
target/m68k: correctly disassemble move16

 disas/m68k.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
Signature · 1 line
2.14.4
#1 lore raw

[Qemu-devel] [PULL 1/1] target/m68k: correctly disassemble move16

"move16 %a0@+,%a1@" and "fmovel (cpid=3) %a0@-,%fpcr" share the same opcode.

To fix that, backport the fix from binutils:

2005-11-10 Andreas Schwab <[email protected]>

* m68k-dis.c (print_insn_m68k): Only match FPU insns with coprocessor ID 1.

Message-Id: <[email protected]>

---
 disas/m68k.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
disas/m68k.c +14 -0
index 61b689ef3e..a687df437c 100644
@@ -2017,6 +2017,20 @@ print_insn_m68k (bfd_vma memaddr, disassemble_info *info)
 		}
 	    }
 
+          /* Don't match FPU insns with non-default coprocessor ID.  */
+          if (*d == '\0')
+            {
+              for (d = opc->args; *d; d += 2)
+                {
+                  if (d[0] == 'I')
+                    {
+                      val = fetch_arg (buffer, 'd', 3, info);
+                      if (val != 1)
+                        break;
+                    }
+                }
+            }
+
 	  if (*d == '\0')
 	    if ((val = match_insn_m68k (memaddr, info, opc, & priv)))
 	      return val;
Signature · 1 line
2.14.4
#2 lore raw
In reply to Laurent Vivier
Quoted 8 lines · Laurent Vivier

The following changes since commit 281bd281222776229d5dbf84d1a5c6d8d9d2a34b:

Merge remote-tracking branch 'remotes/xtensa/tags/20180630-xtensa' into staging (2018-06-30 22:23:51 +0100)

are available in the Git repository at:

git://github.com/vivier/qemu-m68k.git tags/m68k-for-3.0-pull-request

Quoted 8 lines

for you to fetch changes up to d9345f1e1b1936b9ed7026b83091cf701f7ce07e:

target/m68k: correctly disassemble move16 (2018-07-02 12:02:00 +0200)

----------------------------------------------------------------
correctly disassemble move16

----------------------------------------------------------------

Applied, thanks.

-- PMM