dsputil: x86: add SHUFFLE_MASK_W macro

Simplifies pshufb masks that operate on words.
This commit is contained in:
Jason Garrett-Glaser 2012-07-20 18:33:06 -04:00 committed by Justin Ruggles
parent b2704a65d5
commit 85a3c19ed1
2 changed files with 13 additions and 1 deletions

View file

@ -625,3 +625,15 @@
shufps %1, %1, 0
%endif
%endmacro
%macro SHUFFLE_MASK_W 8
%rep 8
%if %1>=0x80
db %1, %1
%else
db %1*2
db %1*2+1
%endif
%rotate 1
%endrep
%endmacro