Mar. 25th, 2009

fivemack: (Default)
Intel has announced the instruction set for its new vector-supercomputer-disguised-as-a-graphics-card 'Larrabee'.

http://software.intel.com/en-us/articles/prototype-primitives-guide/ has a C++ implementation using the data types and intrinsic names which the real thing will use.

It has a full set of the instructions you would expect, including count-set-bits and find-first-set-bit; it has vector gather and scatter (finally!), it has the normal-for-Intel irritating omissions (add-with-carry for 32-bit numbers only?), and it has one or two really quite surprising instructions:


BITINTERLEAVE21_PI - 2:1 Bit-Interleave Int32 Vectors

Performs an element-by-element bitwise interleave, using a 2:1 pattern, between int32 vector v2 and int32 vector v3. The low 21 bits from elements in v2 are interleaved with the low 11 bits from elements in v3 to form a vector of 32-bit values. Bits alternate 2:1, so that source elements A and B combine bitwise this way (high to low):
A20 B10 A19 A18 B9 A17 A16 B8 … A5 A4 B2 A3 A2 B1 A1 A0 B0


I will buy a chocolate pudding at the Carlton next Thursday for the person to give the least ludicrously contrived example in which this instruction might be useful. There is also a BITINTERLEAVE11_PI which takes alternate bits from the two source elements.

March 2024

S M T W T F S
     12
3456789
10111213141516
17181920212223
24 252627282930
31      

Most Popular Tags

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated Jul. 14th, 2025 11:51 am
Powered by Dreamwidth Studios