KhronosGroup / KhronosGroup/OpenCL-Docs
OpenCL C lacking a unique identifier
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 421
- Forks
- 132
- Avg merge
- 5d 13h
- Merged PRs (30d)
- 11
Description
Consider adding to the specification, a function that will allow each work group (that is currently being executed on a compute unit) to get some kind of compute id or unique id("get_compute_id()" or "get_unique_id()") that no other work group can use until it has finished its execution and releases the ID to be reused.
e.g.
//be able to get the highest possible index in the host code
device.getInfo<CL_DEVICE_MAX_NUM_WORKGROUPS_THAT_CAN_BE_EXECUTED_AT_A_TIME>() == 19 //assuming the device has 20 compute units and ONLY ONE work group can be executed per compute unit at a time; otherwise it would be higher than num compute units
//in the kernel, be able to get the unique id for the current work group
int uniqueID = get_unique_id(); //return int ranging from 0 to CL_DEVICE_MAX_NUM_WORKGROUPS_THAT_CAN_BE_EXECUTED_AT_A_TIME
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the OpenCL C specification and the host device-info example described in the issue. Clarify the scope and semantics of a work-group identifier, including its lifetime, range, and interaction with concurrent work groups. Done would require an agreed specification change rather than only an implementation edit.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- api, compilers
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100