Bug 97331 - [nvptx] Provide GCN_NUM_TEAMS/GCN_NUM_THREADS equivalent
Summary: [nvptx] Provide GCN_NUM_TEAMS/GCN_NUM_THREADS equivalent
Status: UNCONFIRMED
Alias: None
Product: gcc
Classification: Unclassified
Component: libgomp (show other bugs)
Version: 11.0
: P3 enhancement
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-08 08:40 UTC by Tom de Vries
Modified: 2020-10-08 08:50 UTC (History)
1 user (show)

See Also:
Host:
Target: nvptx
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom de Vries 2020-10-08 08:40:42 UTC
When looking at the gcn plugin, there are a number of environment variables that set/limit launch dimensions:
...
$ grep getenv libgomp/plugin/plugin-gcn.c | grep NUM
  const char *x = secure_getenv ("GCN_NUM_TEAMS");
    x = secure_getenv ("GCN_NUM_GANGS");
  const char *z = secure_getenv ("GCN_NUM_THREADS");
    z = secure_getenv ("GCN_NUM_WORKERS");
...

It would be nice to have similar ones for nvptx.
Comment 1 Jakub Jelinek 2020-10-08 08:50:53 UTC
The OpenMP 5.1 way is OMP_{NUM_THREADS,...}_DEV_{0,1,2,...} etc., but we aren't there yet.