This generates 32 subtarget features for each possible multiple
of the wave size. The attribute is named +max-work-group-size=N.
The use of an equal sign might be weird because no other target
seems to do this, but it is prettier.
Details
- Reviewers
• tstellarAMD
Diff Detail
Event Timeline
This is a property of the runtime. There should be function attributes for related information, such as required workgroup size. There may also be an attribute for maximum to assume but not required, but the subtarget feature would still be needed to validate that it is not above the maximum supported by the runtime, and would also serve as the default if that attribute is missing.
Actually the higher workgroups might technically work with the runtime, they just aren't supported. I think the way it works in AMD OpenCL is the max 256 is rejected by default, but there is an environment variable to increase the limit for internal development.
How about just making it a normal string attribute similar to use-soft-float or something like that? Then you can just look it up on the function in the backend and won't need to configure a large set of subtarget features for it?
-eric