opencl: fix two issues on flash attention for Adreno a7x (#25697)
* opencl: route `sub_group_shuffle_xor` to qcom ext when KHR ext is unavailable KHR `sub_group_shuffle_xor` is not defined by compiler when `cl_qcom_subgroup_shuffle` is present, causing certain FA kernels fail to build. Define the KHR shuffle_xor using the qcom extension. * opencl: skip FA kernels with mixed and quant types for A7x to avoid compiler crash
This commit is contained in:
@@ -30,6 +30,10 @@
|
||||
#elif defined(cl_qcom_subgroup_shuffle)
|
||||
#pragma OPENCL EXTENSION cl_qcom_subgroup_shuffle : enable
|
||||
#define HAS_SUBGROUP_SHUFFLE 1
|
||||
// Adreno compilers that expose only cl_qcom_subgroup_shuffle do not declare the KHR
|
||||
// name, so calling it is an implicit declaration and the program fails to build.
|
||||
// Route it to the qcom builtin.
|
||||
#define sub_group_shuffle_xor(val, mask) qcom_sub_group_shuffle_xor((val), (mask), CLK_SUB_GROUP_SHUFFLE_WIDTH_WAVE_SIZE_QCOM, 0.0f)
|
||||
#endif
|
||||
|
||||
#define ACC_TYPE float
|
||||
|
||||
Reference in New Issue
Block a user