diff options
author | gnl21 <gleese@broadcom.com> | 2021-08-26 21:33:19 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-08-26 21:33:19 +0300 |
commit | ee30773650eca50b1cd3c913babcc2b50d7b91fd (patch) | |
tree | 691333499c750e9932181a7c9d7280ef0208041d /tools | |
parent | 2a5cc342fb5a8166ec218963bbe5c2e5c4045c2c (diff) |
Add a feature for allowing LocalSizeId (#4492)
Allow LocalSizeId as a way of sizing compute workgroups where the
environment allows it. A command-line switch is also added to force
acceptance even where the environment would not otherwise allow it.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/val/val.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/val/val.cpp b/tools/val/val.cpp index 21a7d8f43..55321dab2 100644 --- a/tools/val/val.cpp +++ b/tools/val/val.cpp @@ -64,6 +64,8 @@ Options: --relax-struct-store Allow store from one struct type to a different type with compatible layout and members. + --allow-localsizeid Allow use of the LocalSizeId decoration where it would otherwise not + be allowed by the target environment. --before-hlsl-legalization Allows code patterns that are intended to be fixed by spirv-opt's legalization passes. --version Display validator version information. @@ -153,6 +155,8 @@ int main(int argc, char** argv) { options.SetWorkgroupScalarBlockLayout(true); } else if (0 == strcmp(cur_arg, "--skip-block-layout")) { options.SetSkipBlockLayout(true); + } else if (0 == strcmp(cur_arg, "--allow-localsizeid")) { + options.SetAllowLocalSizeId(true); } else if (0 == strcmp(cur_arg, "--relax-struct-store")) { options.SetRelaxStructStore(true); } else if (0 == cur_arg[1]) { |