Skip to content

Commit f37dbcb

Browse files
committed
Clarify that num_threads does not set the OpenCL work-group size.
1 parent 0ebab4a commit f37dbcb

3 files changed

Lines changed: 6 additions & 3 deletions

File tree

‎src/loch/_platforms/__init__.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,8 @@ def create_backend(
112112
Total number of atoms in the system.
113113
114114
num_threads : int
115-
Number of threads per block/work-group.
115+
Number of threads per block (CUDA) or granularity of the global
116+
work size (OpenCL, where the runtime picks the work-group size).
116117
117118
nvcc : str, optional
118119
Path to NVCC compiler (CUDA only).

‎src/loch/_platforms/_base.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@ def __init__(
7272
Total number of atoms in the system.
7373
7474
num_threads : int
75-
Number of threads per block (CUDA) or work-group size (OpenCL).
75+
Number of threads per block (CUDA) or granularity of the global
76+
work size (OpenCL, where the runtime picks the work-group size).
7677
7778
nvcc : str, optional
7879
Path to NVCC compiler (CUDA only). If None, uses default.

‎src/loch/_platforms/_opencl.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ def __init__(
8181
Total number of atoms in the system.
8282
8383
num_threads : int
84-
Work-group size (threads per work-group).
84+
Granularity of the global work size. The work-group size is
85+
chosen by the OpenCL runtime.
8586
8687
nvcc : str, optional
8788
Ignored for OpenCL (included for API compatibility).

0 commit comments

Comments
 (0)