Am I missing something? I have just coded a RIPEMD160 Function in MMX only to just notice that there is no PNOT instruction.

This would make the next best way around this that I can think of:

AllSet QWORD 0ffffffffffffffffh

pnot MACRO mmX:REQ
pxor mmX,AllSet

Cheers! :)
Posted on 2002-07-02 23:05:44 by huh
Here is a lazy version without memory access:
pnot MACRO mmA:REQ, mmB:REQ

pcmpeqd mmB,mmB ; set bits of scratch register
pxor mmA,mmB ; reverse bits of destination
; pandn mmA,mmB ; can replace pxor with this too
The PANDN instruction allows you to optimize the NOT out of the algo, or maybe you could already have a register set (FF) - it is very useful to +/-1 or change sign of number.
Posted on 2002-07-03 07:03:34 by bitRAKE