[PATCH] D41747: [libcxx] implement <experimental/simd> simd_mask<> and operators.
Tim Shen via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 4 16:55:19 PST 2018
timshen created this revision.
timshen added reviewers: mclow.lists, EricWF.
Herald added a subscriber: sanjoy.
simd_mask<T, Abi> stores a simd<U, Abi>, where U has the same length of T, but is an unsigned integer. Then all functionality of simd_mask<T, Abi> can be implemented in terms of simd<U, Abi>.
For reference, Vc seems to store an int as a bitset. This results into inefficient code:
- https://godbolt.org/g/e4uDPM storing int is slow.
- https://godbolt.org/g/hT7SYT storing simd<U, Abi> has zero cost.
https://reviews.llvm.org/D41747
Files:
libcxx/include/experimental/simd
libcxx/test/std/experimental/simd/simd.elementwise/operators.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.access/a.out
libcxx/test/std/experimental/simd/simd.mask.access/default.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.cons/broadcast.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.cons/default.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.cons/fixed_size_conversion.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.cons/load.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.elementwise/operators.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.mem/load.pass.cpp
libcxx/test/std/experimental/simd/simd.mask.mem/store.pass.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D41747.128682.patch
Type: text/x-patch
Size: 32042 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180105/d2cadf75/attachment-0001.bin>
More information about the cfe-commits
mailing list