Changes between Version 6 and Version 7 of ParabixTransform
 Timestamp:
 Apr 22, 2014, 4:44:26 PM (4 years ago)
Legend:
 Unmodified
 Added
 Removed
 Modified

ParabixTransform
v6 v7 89 89 Unfortunately, the {{{hsimd<{2,4,8}>::pack{h,l}(e1, e2)}}} family of operations for 90 90 ideal transposition are not to be found within the SIMD instruction set of current 91 commodity processors. However, if *bit shuffle*operations are to be found instead,91 commodity processors. However, if ''bit shuffle'' operations are to be found instead, 92 92 then the pack operations can be expressed directly in terms of equivalent 93 93 bit shuffles. Bit shuffles can be found both at the intermediate representation … … 142 142 }}} 143 143 144 Alternatively, we may implement {{{hsimd<{4,8}>::pack{h,l}(e1, e2)}}} using 145 {{{shufflevector}}} with {{{i2}}} and {{{i4}}} vectors. 144 146 147 {{{ 148 define <4 x i2> @hsimd_packh_4(<4 x i2> %x, <4 x i2> %y) { 149 %result = shufflevector <4 x i2> %x, <4 x i2> %y, 150 <4 x i32> <i32 1, i32 3, i32 5, i32 7> 151 return <4 x i2> result 152 } 153 define <4 x i2> @hsimd_packl_4(<4 x i2> %x, <4 x i2> %y) { 154 %result = shufflevector <4 x i2> %x, <4 x i2> %y, 155 <4 x i32> <i32 0, i32 2, i32 4, i32 6> 156 return <4 x i2> result 157 } 158 159 define <2 x i4> @hsimd_packh_8(<2 x i4> %x, <2 x i4> %y) { 160 %result = shufflevector <2 x i4> %x, <2 x i4> %y, 161 <2 x i32> <i32 1, i32 3> 162 return <2 x i4> result 163 } 164 define <2 x i4> @hsimd_packl_8(<2 x i4> %x, <2 x i4> %y) { 165 %result = shufflevector <2 x i4> %x, <2 x i4> %y, 166 <2 x i32> <i32 0, i32 2> 167 return <2 x i4> result 168 } 169 }}}