handle clusters - #206
Conversation
5b5bb47 to
5af76b9
Compare
|
Here is a sample output of "info threads" with clusters: And "info dispatches": |
5af76b9 to
4c9d135
Compare
|
Test is updated. It now includes synchronization and checks blockIdx dimensions as obtained from the program to those calculated based on cluster&wg coordinates. |
lancesix
left a comment
There was a problem hiding this comment.
also, shouldn't we have some configury stuff to check dbgapi's version to be sure AMD_DBGAPI_DISPATCH_INFO_CLUSTER_SIZES is provided?
In nowhere else we have a similar check. I thought we'd first merge dbgapi PR, which bumps the version, and then build ROCgdb with that version, which brings us the guard here: |
We have https://github.com/ROCm/ROCgdb/blob/amd-staging/gdb/configure.ac#L330-L331 which currently guards building GDB with 0.80 or more. Either we wait for dbgapi to land, and when we have the right version bump configure.ac in this PR, or have something more dynamic (we do not have this yet) where configure can test dbgapi for this feature (use |
Ok, gotcha. I'll go with incrementing the configure version in this PR and leave the dynamic detection to a separate feature task. |
4c9d135 to
2d1a559
Compare
|
The last push updates the document, removes |
2d1a559 to
1c0dea6
Compare
|
The last push converts in-grid group ids to in-cluster group ids. |
The function 'amdgpu_used_lanes_count' in amdgpu-tdep.c and the function 'lane_workgroup_pos' in amd-dbgapi-target.c both compute partial workgroup sizes the same way. Extract the common code into a function named 'partial_workgroup_sizes' and reuse. This is a refactoring with no behavioral change.
1c0dea6 to
6abe945
Compare
|
The force-push above is a rebase. |
6abe945 to
5afc339
Compare
|
The force-push above uses |
Starting with gfx1250, workgroups may be organized into clusters, giving a workitem -> wave -> workgroup -> cluster -> grid hierarchy. Handle clusters by taking them into account when calculating workitem/lane coordinates, when showing wave target ids, and in the "info dispatches" command.
5afc339 to
b56c366
Compare
|
The update above adds a new test that uses barrier arrive/wait. |
Motivation
New feature: workgroup clusters
Technical Details
Workgroups can be organized in clusters. dbgapi provides new query functions. Use these queries to show cluster information.
Test Plan
A basic test is included.