From: mike7411 on
I noticed that the following doesn't compile in NASM:

pshufb xmm0, xmm1

It says:

error: parser: instruction expected

However, this does work:

pshufd xmm0, xmm1, 99

Any ideas why pshufd works but not pshufb?

From: SpooK on


On Nov 16, 10:32 am, mike7...(a)gmail.com wrote:
> I noticed that the following doesn't compile in NASM:
>
> pshufb xmm0, xmm1
>
> It says:
>
> error: parser: instruction expected
>
> However, this does work:
>
> pshufd xmm0, xmm1, 99
>
> Any ideas why pshufd works but not pshufb?

PSHUFD is apart of SSE2, covered by NASM. PSHUFB came out with SSSE3,
so I have doubts that NASM has been modified to handle such "new"
instructions... yet.

You may wish to look at YASM, I believe that project is much more
active and may have that instruction covered. YASM is a spin-off of
NASM, so your source should assemble with it.

From: Phil Carmody on
mike7411(a)gmail.com writes:

> I noticed that the following doesn't compile in NASM:
>
> pshufb xmm0, xmm1
>
> It says:
>
> error: parser: instruction expected
>
> However, this does work:
>
> pshufd xmm0, xmm1, 99
>
> Any ideas why pshufd works but not pshufb?

Is it because the pshufd instruction is supported, and the
pshufb instruction isn't supported, being as they are from
different generations of the godforsaken x86 instruction set?

Just a guess.

Phil
--
"Home taping is killing big business profits. We left this side blank
so you can help." -- Dead Kennedys, written upon the B-side of tapes of
/In God We Trust, Inc./.