Intel® oneAPI DPC++/C++ Compiler
Talk to fellow users of Intel® oneAPI DPC++/C++ Compiler and companion tools like Intel® oneAPI DPC++ Library, Intel® DPC++ Compatibility Tool, and Intel® Distribution for GDB*

DCP++ subgroup

RitaChu
Сотрудник
1 816Просмотр.

Hi, 

What is the difference between subgroup shuffle and group_broadcast.  To me they seem to generate same results if you give the same index to shuffle/broadcast.

Thanks

0 баллов
5 Ответы
SantoshY_Intel
Модератор
1 785Просмотр.

Hi,


Thanks for reaching out to us.


The sub-group broadcast function can be thought of as a specialized version of the general-purpose shuffle function, where the shuffle index is the same for all work-items in the sub-group.


>>"To me they seem to generate same results if you give the same index to shuffle/broadcast."

When the shuffle index is known to be the same for all work-items in the sub-group, then we will get the same results for both shuffle and broadcast.

But, using broadcast instead of shuffle provides the compiler additional information and may increase performance on some implementations. 


Thanks & Regards,

Santosh


RitaChu
Сотрудник
1 767Просмотр.
SantoshY_Intel
Модератор
1 744Просмотр.

Hi,

 

Could you please let us know whether you have any other issues? If not, could you please confirm whether we can close this thread from our end?

 

Thanks & Regards,

Santosh

 

RitaChu
Сотрудник
1 736Просмотр.

@SantoshY_Intel I have no more issue, please close the thread.  Thank you very much

SantoshY_Intel
Модератор
1 723Просмотр.

Hi,


As your issue is resolved, we are closing this thread. If you need any additional information, please post a new question as this thread will no longer be monitored by Intel.


Thanks & Regards,

Santosh


Ответить