Re: Linux-2.1.4..

Hans Lermen (lermen@elserv.ffm.fgan.de)
Tue, 15 Oct 1996 23:15:11 +0200 (MET DST)

On Tue, 15 Oct 1996, Michael Stiller wrote:

> {standard input}:80: Error: register does not match opcode suffix
> ---
> The offending code looks like: (snippet from info.S)
>

which is the macro __copy_user(to,from,size) in include/asm-i386/segment.h

> #APP
> movl $3f,%edx
> incl 984(%eax)
> rep; movsl
> testb $2,%bp
> ^^^^^
^^^
The original instruction is

"testb $2,%b3\n\t"
^^^
This wants the low-byte register of eax, ... ,edx, == al, .. , dl.
unfortunately GCC selected 'ebp', which doesn't have it.

> The ^marked^ Mnemonics should be word-wide i.e. testw i guess.
^^^^^
no, testb is correct, %bp isn't.

> What ist wrong here ?

The constraints are wrong:

:"=d" (size) \
:"c" (size >> 2), "m" (current->tss.ex), "r" (size & 3), \
^^^
This is _any_ general purpose register.
The correct constraints should be:

:"=d" (size) \
:"c" (size >> 2), "m" (current->tss.ex), "a,b" (size & 3), \
^^^

Hans
<lermen@fgan.de>

--
To unsubscribe: mail -s unsubscribe axp-list-request@redhat.com < /dev/null



Feedback | Store | News | Support | Product Errata | About Us | Linux Info | Search | JumpWords
No Frames | Show Frames

Copyright © 1995-1997 Red Hat Software. Legal notices