Detect OpenCL 3.0 __opencl_c_subgroups in CLAccelerator and guard cl_khr_subgroups pragma

Abierto
#312 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
35/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
cpp
Área
backend

Línea de trabajo

Start with src/opencl/cl_accelerator.cpp and inspect how CLAccelerator::set_device detects OpenCL C versions and subgroup support, keeping the stated OpenCL C++ 1.2 compatibility in mind. Then review the three named .cl files and their generated headers under src/opencl/generated/auto_*.hpp. Done means the OpenCL 3.0 subgroup feature is detected, the extension pragmas are guarded, and the named tests compile and pass on an OpenCL 3.0 device.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

task

Problem: CLAccelerator::set_device in src/opencl/cl_accelerator.cpp only checks CL_DEVICE_OPENCL_C_VERSION (>= 2.0) and cl_khr_subgroups in CL_DEVICE_EXTENSIONS, which fails on OpenCL 3.0 devices like Intel UHD Graphics (NEO) where CL_DEVICE_OPENCL_C_VERSION reports OpenCL C 1.2 and subgroups are exposed as the OpenCL 3.0 feature __opencl_c_subgroups (CL_DEVICE_OPENCL_C_ALL_VERSIONS / CL_DEVICE_OPENCL_C_FEATURES / CL_DEVICE_MAX_NUM_SUB_GROUPS), leaving SPLA_HAS_SUBGROUPS == 0 everywhere including tests. Update CLAccelerator::set_device (compatible with CL_HPP_TARGET_OPENCL_VERSION 120) to detect OpenCL 3.0 C support and __opencl_c_subgroups alongside the OpenCL 2.x cl_khr_subgroups check, guard #pragma OPENCL EXTENSION cl_khr_subgroups : enable with #ifdef cl_khr_subgroups in block_scan.cl, mxm_compute_spgemm_part.cl, and sort_and_combine_device.cl (regenerating src/opencl/generated/auto_*.hpp), and verify in tests/test_opencl_block_scan.cpp / test_opencl_sort_and_combine.cpp / test_opencl_compute_spgemm_part.cpp that SPLA_HAS_SUBGROUPS == 1 compiles and passes on OpenCL 3.0 devices.

Lenguaje dominante
C++
Estrellas
37
Forks
21
Merge medio
11 h 3 min
PR fusionados (30 d)
13

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de SparseLinearAlgebra/spla

Todos los issues de SparseLinearAlgebra/spla

Issues similares

Más issues de C++

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.