Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Watcom C Library Reference - <u>synopsis:</u> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
Synopsis:
    #include <mmintrin.h>
    __m64 _m_psrlwi(__m64 *m, int count);

Description:
    The 16-bit words in m are each independently shifted to the right by the
    scalar shift count in count.  The high-order bits of each element are
    filled with zeros.  The shift count is interpreted as unsigned.  Shift
    counts greater than 15 yield all zeros.

Returns:
    Shift right each 16-bit word in m by an amount specified in count while
    shifting in zeros.

Example:
    #include <stdio.h>
    #include <mmintrin.h>

    #define AS_WORDS "%4.4x %4.4x %4.4x %4.4x"

    __m64   a;
    __m64   b = { 0x3f04800300040001 };

    void main()
      {
        a = _m_psrlwi( b, 2 );
        printf( "m ="AS_WORDS"\n"
                "mm="AS_WORDS"\n",
            b._16[3], b._16[2], b._16[1], b._16[0],
            a._16[3], a._16[2], a._16[1], a._16[0] );
      }

    produces the following:

    m =3f04 8003 0004 0001
    mm=0fc1 2000 0001 0000

Classification:
    Intel

Systems:
    MACRO

See Also:
    _m_empty, _m_psrld, _m_psrldi, _m_psrlq, _m_psrlqi, _m_psrlw

See Also: _m_empty _m_psrld

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson