[libclc] [libclc] Use custom CMake handling to overhaul libclc compilation (PR #185247)

Wenju He via cfe-commits cfe-commits at lists.llvm.org
Sat Mar 7 21:05:11 PST 2026


================
@@ -0,0 +1,18 @@
+set(CLC_AMDGCN_SOURCES
+  address_space/qualifier.cl
+  math/clc_ldexp.cl
+  mem_fence/clc_mem_fence.cl
+  subgroup/sub_group_broadcast.cl
+  synchronization/clc_work_group_barrier.cl
+  workitem/clc_get_enqueued_local_size.cl
+  workitem/clc_get_global_offset.cl
+  workitem/clc_get_global_size.cl
+  workitem/clc_get_group_id.cl
+  workitem/clc_get_local_id.cl
+  workitem/clc_get_local_size.cl
+  workitem/clc_get_max_sub_group_size.cl
+  workitem/clc_get_num_groups.cl
+  workitem/clc_get_work_dim.cl
+)
+list(TRANSFORM CLC_AMDGCN_SOURCES PREPEND "${CMAKE_CURRENT_SOURCE_DIR}/")
+set(CLC_AMDGCN_SOURCES ${CLC_AMDGCN_SOURCES} PARENT_SCOPE)
----------------
wenju-he wrote:

can probably create a new macro for the above 3 commands to avoid duplication of "set + list + set" in other files.

https://github.com/llvm/llvm-project/pull/185247


More information about the cfe-commits mailing list