CUDA是否有等价于OpenCL的shuffle操作?

huangapple go评论48阅读模式
英文:

Is there a CUDA equivalent to the OpenCL shuffle operation?

问题

这个链接描述了如何使用掩码来对矢量类型的元素进行洗牌。CUDA 中是否有类似的功能?

英文:

http://man.opencl.org/shuffle.html

This shuffles the elements of a vector type, based on a mask. Is there an equivalent in CUDA ?

答案1

得分: 2

没有等同于CUDA的东西。

如已指出,一个可能的方法是将向量的元素放入一个数组中,然后以这种方式进行处理。

英文:

There isn't anything equivalent in CUDA.

As already indicated, one possible approach would be to put the elements of a vector into an array, and do your work that way.

huangapple
  • 本文由 发表于 2023年3月4日 09:39:43
  • 转载请务必保留本文链接:https://go.coder-hub.com/75633159.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定