Enable HLSL legalization

Also added known-good mechanism to fetch latest validated spirv-tools.
Also added -Od and -Os to disable optimizer and optimize for size.

Fetching spirv-tools is optional for both glsl and hlsl. Legalization
of hlsl is done by default if spirv-opt is present at cmake time.
Optimization for glsl is currently done through the option -Os.

Legalization testing is currently only done on four existing shaders.
A separate baseLegalResults directory holds those results. All previous
testing is done with the optimizer disabled.
This commit is contained in:
GregF 2017-09-21 18:40:22 -06:00
parent 44dd6a00c3
commit cd1f169c6a
16 changed files with 536 additions and 23 deletions

18
known_good.json Normal file
View file

@ -0,0 +1,18 @@
{
"commits" : [
{
"name" : "spirv-tools",
"site" : "github",
"subrepo" : "KhronosGroup/SPIRV-Tools",
"subdir" : "External/spirv-tools",
"commit" : "cf85ad1429de560eb1569cf6b36ba5a4ae5ff4be"
},
{
"name" : "spirv-tools/external/spirv-headers",
"site" : "github",
"subrepo" : "KhronosGroup/SPIRV-Headers",
"subdir" : "External/spirv-tools/external/spirv-headers",
"commit" : "2bb92e6fe2c6aa410152fc6c63443f452acb1a65"
}
]
}