Subject: port-i386/4625: as doesn't accept sh[lr]d with only two operands
To: None <gnats-bugs@gnats.netbsd.org>
From: Michael Eriksson T/D <Michael.Eriksson@era-t.ericsson.se>
List: netbsd-bugs
Date: 12/02/1997 16:16:34
>Number: 4625
>Category: port-i386
>Synopsis: as doesn't accept sh[lr]d with only two operands
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: gnats-admin (GNATS administrator)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Dec 2 07:20:00 1997
>Last-Modified:
>Originator: Michael Eriksson
>Organization:
Ericsson Radio Systems AB
>Release: NetBSD 1.3_BETA from 971129
>Environment:
System: NetBSD abro 1.3_BETA NetBSD 1.3_BETA (ABRO) #0: Sun Nov 30 04:44:58 MET 1997 eramer@abro:/usr/src/sys/arch/sparc/compile/ABRO sparc
>Description:
The assembler doesn't accept the sh[lr]d instructions with only two
operands.
>How-To-Repeat:
Try to assemble a file with this or similar lines:
shrdl %ebx, %edx
>Fix:
--- gnu/usr.bin/gas/opcode/i386.h.orig Sat Sep 6 13:09:17 1997
+++ gnu/usr.bin/gas/opcode/i386.h Sat Nov 29 23:17:58 1997
@@ -245,6 +245,7 @@
{"shld", 3, 0x0fa4, _, Modrm, Imm8, WordReg, WordReg|Mem},
{"shld", 3, 0x0fa5, _, Modrm, ShiftCount, WordReg, WordReg|Mem},
+{"shld", 2, 0x0fa5, _, Modrm, WordReg, WordReg|Mem, 0},
{"shr", 2, 0xd0, 5, W|Modrm, Imm1, Reg|Mem, 0},
{"shr", 2, 0xc0, 5, W|Modrm, Imm8, Reg|Mem, 0},
@@ -253,6 +254,7 @@
{"shrd", 3, 0x0fac, _, Modrm, Imm8, WordReg, WordReg|Mem},
{"shrd", 3, 0x0fad, _, Modrm, ShiftCount, WordReg, WordReg|Mem},
+{"shrd", 2, 0x0fad, _, Modrm, WordReg, WordReg|Mem, 0},
{"sar", 2, 0xd0, 7, W|Modrm, Imm1, Reg|Mem, 0},
{"sar", 2, 0xc0, 7, W|Modrm, Imm8, Reg|Mem, 0},
>Audit-Trail:
>Unformatted: