qemu-system-m68k does not accept "notw %d" instruction

Bug #547227 reported by Peter B. Jørgensen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QEMU
Invalid
Undecided
Unassigned

Bug Description

The notw and notb instructions does not work with latest version of qemu-system-m68k. I've tried both 0.12.3 and the latest git version compiled about an hour ago, both running on Arch Linux. The executable fails with the following output:
> qemu-system-m68k -nographic -M an5206 -kernel test.elf
qemu: fatal: Illegal instruction: 4640 @ 00000006
D0 = 00000000 A0 = 00000000 F0 = 0000000000000000 ( 0)
D1 = 00000000 A1 = 00000000 F1 = 0000000000000000 ( 0)
D2 = 00000000 A2 = 00000000 F2 = 0000000000000000 ( 0)
D3 = 00000000 A3 = 00000000 F3 = 0000000000000000 ( 0)
D4 = 00000000 A4 = 00000000 F4 = 0000000000000000 ( 0)
D5 = 00000000 A5 = 00000000 F5 = 0000000000000000 ( 0)
D6 = 00000000 A6 = 00000000 F6 = 0000000000000000 ( 0)
D7 = 00000000 A7 = 00000000 F7 = 0000000000000000 ( 0)
PC = 00000000 SR = 2700 ----- FPRESULT = 0
zsh: abort qemu-system-m68k -nographic -M an5206 -kernel test.elf

I've attached the test.elf file, which produces the bug. It contains the following:
> m68k-elf-objdump -m 68000 -D test.elf
test.elf: file format elf32-m68k
Disassembly of section .text:
00000000 <start>:
   0: 4e71 nop
   2: 4e71 nop
   4: 4e71 nop
   6: 4640 notw %d0
00000008 <loop>:
   8: 6000 fffe braw 8 <loop>

It works when removing the not instruction. There might be other non-working instructions, I've only tested a few.
Hope you'll get the bug fixed. Thanks.

Tags: m68k
Revision history for this message
Peter B. Jørgensen (peterbjorgensen) wrote :
Revision history for this message
Natalia Portillo (claunia) wrote :

As of QEMU 0.12.3, it only emulates ColdFire processors.

Coldfire no longer implement notw, only notl instruction, so this behaviour is expected.

Changed in qemu:
status: New → Invalid
Revision history for this message
Peter B. Jørgensen (peterbjorgensen) wrote :

Didn't know you are not targeting the original M68000. Must have missed that somewhere.

Revision history for this message
Andreas Färber (afaerber) wrote :

See `qemu-system-m68k -cpu ?`.

QEMU is not targeting it yet, but there's a project:
http://www.gitorious.org/qemu-m68k

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.