Commit 033ae528 by John Kessenich

GLSL: Implement nonuniformEXT keyword, declarations, and constructor.

parent a3bf9121
......@@ -393,6 +393,7 @@ enum Decoration {
DecorationPassthroughNV = 5250,
DecorationViewportRelativeNV = 5252,
DecorationSecondaryViewportRelativeNV = 5256,
DecorationNonUniformEXT = 5300,
DecorationHlslCounterBufferGOOGLE = 5634,
DecorationHlslSemanticGOOGLE = 5635,
DecorationMax = 0x7fffffff,
......@@ -688,6 +689,18 @@ enum Capability {
CapabilityShaderStereoViewNV = 5259,
CapabilityPerViewAttributesNV = 5260,
CapabilityFragmentFullyCoveredEXT = 5265,
CapabilityShaderNonUniformEXT = 5301,
CapabilityRuntimeDescriptorArrayEXT = 5302,
CapabilityInputAttachmentArrayDynamicIndexingEXT = 5303,
CapabilityUniformTexelBufferArrayDynamicIndexingEXT = 5304,
CapabilityStorageTexelBufferArrayDynamicIndexingEXT = 5305,
CapabilityUniformBufferArrayNonUniformIndexingEXT = 5306,
CapabilitySampledImageArrayNonUniformIndexingEXT = 5307,
CapabilityStorageBufferArrayNonUniformIndexingEXT = 5308,
CapabilityStorageImageArrayNonUniformIndexingEXT = 5309,
CapabilityInputAttachmentArrayNonUniformIndexingEXT = 5310,
CapabilityUniformTexelBufferArrayNonUniformIndexingEXT = 5311,
CapabilityStorageTexelBufferArrayNonUniformIndexingEXT = 5312,
CapabilitySubgroupShuffleINTEL = 5568,
CapabilitySubgroupBufferBlockIOINTEL = 5569,
CapabilitySubgroupImageBlockIOINTEL = 5570,
......
nonuniform.frag
ERROR: 0:6: 'nonuniformEXT' : for non-parameter, can only apply to 'in' or no storage qualifier
ERROR: 0:7: 'nonuniformEXT' : for non-parameter, can only apply to 'in' or no storage qualifier
ERROR: 0:8: 'nonuniformEXT' : for non-parameter, can only apply to 'in' or no storage qualifier
ERROR: 0:17: 'nonuniformEXT' : for non-parameter, can only apply to 'in' or no storage qualifier
ERROR: 0:23: 'constructor' : too many arguments
ERROR: 0:23: 'assign' : cannot convert from ' const float' to ' nonuniform temp int'
ERROR: 0:24: 'constructor' : not enough data provided for construction
ERROR: 0:24: 'assign' : cannot convert from ' const float' to ' nonuniform temp int'
ERROR: 8 compilation errors. No code generated.
Shader version: 450
ERROR: node is still EOpNull!
0:10 Function Definition: foo(i1; ( global void)
0:10 Function Parameters:
0:10 'nupi' ( nonuniform in int)
0:14 Function Definition: main( ( global void)
0:14 Function Parameters:
0:? Sequence
0:19 Function Call: foo(i1; ( global void)
0:19 'nu_li' ( nonuniform temp int)
0:22 move second child to first child ( temp int)
0:22 'nu_li' ( nonuniform temp int)
0:22 add ( temp int)
0:22 'a' ( nonuniform temp int)
0:22 component-wise multiply ( nonuniform temp int)
0:22 'a' ( temp int)
0:22 Constant:
0:22 2 (const int)
0:23 'nu_li' ( nonuniform temp int)
0:24 'nu_li' ( nonuniform temp int)
0:? Linker Objects
0:? 'nu_inv4' ( smooth nonuniform in 4-component vector of float)
0:? 'nu_gf' ( nonuniform temp float)
0:? 'nu_outv4' ( nonuniform out 4-component vector of float)
0:? 'nu_uv4' ( nonuniform uniform 4-component vector of float)
0:? 'nu_constf' ( nonuniform const float)
0:? 1.000000
Linked fragment stage:
Shader version: 450
ERROR: node is still EOpNull!
0:10 Function Definition: foo(i1; ( global void)
0:10 Function Parameters:
0:10 'nupi' ( nonuniform in int)
0:14 Function Definition: main( ( global void)
0:14 Function Parameters:
0:? Sequence
0:19 Function Call: foo(i1; ( global void)
0:19 'nu_li' ( nonuniform temp int)
0:22 move second child to first child ( temp int)
0:22 'nu_li' ( nonuniform temp int)
0:22 add ( temp int)
0:22 'a' ( nonuniform temp int)
0:22 component-wise multiply ( nonuniform temp int)
0:22 'a' ( temp int)
0:22 Constant:
0:22 2 (const int)
0:23 'nu_li' ( nonuniform temp int)
0:24 'nu_li' ( nonuniform temp int)
0:? Linker Objects
0:? 'nu_inv4' ( smooth nonuniform in 4-component vector of float)
0:? 'nu_gf' ( nonuniform temp float)
0:? 'nu_outv4' ( nonuniform out 4-component vector of float)
0:? 'nu_uv4' ( nonuniform uniform 4-component vector of float)
0:? 'nu_constf' ( nonuniform const float)
0:? 1.000000
#version 450
nonuniformEXT in vec4 nu_inv4;
nonuniformEXT float nu_gf;
nonuniformEXT out vec4 nu_outv4; // ERROR, out
nonuniformEXT uniform vec4 nu_uv4; // ERROR, uniform
nonuniformEXT const float nu_constf = 1.0; // ERROR, const
void foo(nonuniformEXT int nupi)
{
}
void main()
{
nonuniformEXT int nu_li;
nonuniformEXT const int nu_ci = 2; // ERROR, const
foo(nu_li);
int a;
nu_li = nonuniformEXT(a) + nonuniformEXT(a * 2);
nu_li = nonuniformEXT(a, a); // ERROR, too many arguments
nu_li = nonuniformEXT(); // ERROR, no arguments
}
\ No newline at end of file
......@@ -437,6 +437,7 @@ public:
clearInterstage();
clearMemory();
specConstant = false;
nonUniform = false;
clearLayout();
}
......@@ -470,7 +471,7 @@ public:
// Drop just the storage qualification, which perhaps should
// never be done, as it is fundamentally inconsistent, but need to
// explore what downstream consumers need.
// E.g., in a deference, it is an inconsistency between:
// E.g., in a dereference, it is an inconsistency between:
// A) partially dereferenced resource is still in the storage class it started in
// B) partially dereferenced resource is a new temporary object
// If A, then nothing should change, if B, then everything should change, but this is half way.
......@@ -478,6 +479,7 @@ public:
{
storage = EvqTemporary;
specConstant = false;
nonUniform = false;
}
const char* semanticName;
......@@ -502,6 +504,7 @@ public:
bool readonly : 1;
bool writeonly : 1;
bool specConstant : 1; // having a constant_id is not sufficient: expressions have no id, but are still specConstant
bool nonUniform : 1;
bool isMemory() const
{
......@@ -833,6 +836,10 @@ public:
// true front-end constant.
return specConstant;
}
bool isNonUniform() const
{
return nonUniform;
}
bool isFrontEndConstant() const
{
// True if the front-end knows the final constant value.
......@@ -1692,6 +1699,8 @@ public:
appendStr(" writeonly");
if (qualifier.specConstant)
appendStr(" specialization-constant");
if (qualifier.nonUniform)
appendStr(" nonuniform");
appendStr(" ");
appendStr(getStorageQualifierString());
if (isArray()) {
......
......@@ -703,6 +703,7 @@ enum TOperator {
EOpConstructF16Mat4x4,
EOpConstructStruct,
EOpConstructTextureSampler,
EOpConstructNonuniform, // expected to be transformed away, not present in final AST
EOpConstructGuardEnd,
//
......
......@@ -1816,6 +1816,9 @@ TOperator TIntermediate::mapTypeToConstructorOp(const TType& type) const
{
TOperator op = EOpNull;
if (type.getQualifier().nonUniform)
return EOpConstructNonuniform;
switch (type.getBasicType()) {
case EbtStruct:
op = EOpConstructStruct;
......
......@@ -2579,12 +2579,15 @@ void TParseContext::transparentOpaqueCheck(const TSourceLoc& loc, const TType& t
//
void TParseContext::globalQualifierFixCheck(const TSourceLoc& loc, TQualifier& qualifier)
{
bool nonuniformOkay = false;
// move from parameter/unknown qualifiers to pipeline in/out qualifiers
switch (qualifier.storage) {
case EvqIn:
profileRequires(loc, ENoProfile, 130, nullptr, "in for stage inputs");
profileRequires(loc, EEsProfile, 300, nullptr, "in for stage inputs");
qualifier.storage = EvqVaryingIn;
nonuniformOkay = true;
break;
case EvqOut:
profileRequires(loc, ENoProfile, 130, nullptr, "out for stage outputs");
......@@ -2595,10 +2598,17 @@ void TParseContext::globalQualifierFixCheck(const TSourceLoc& loc, TQualifier& q
qualifier.storage = EvqVaryingIn;
error(loc, "cannot use 'inout' at global scope", "", "");
break;
case EvqGlobal:
case EvqTemporary:
nonuniformOkay = true;
break;
default:
break;
}
if (!nonuniformOkay && qualifier.nonUniform)
error(loc, "for non-parameter, can only apply to 'in' or no storage qualifier", "nonuniformEXT", "");
invariantCheck(loc, qualifier);
}
......@@ -2847,6 +2857,7 @@ void TParseContext::mergeQualifiers(const TSourceLoc& loc, TQualifier& dst, cons
MERGE_SINGLETON(readonly);
MERGE_SINGLETON(writeonly);
MERGE_SINGLETON(specConstant);
MERGE_SINGLETON(nonUniform);
if (repeated)
error(loc, "replicated qualifiers", "", "");
......@@ -3669,7 +3680,7 @@ void TParseContext::redeclareBuiltinBlock(const TSourceLoc& loc, TTypeList& newT
trackLinkage(*block);
}
void TParseContext::paramCheckFix(const TSourceLoc& loc, const TStorageQualifier& qualifier, TType& type)
void TParseContext::paramCheckFixStorage(const TSourceLoc& loc, const TStorageQualifier& qualifier, TType& type)
{
switch (qualifier) {
case EvqConst:
......@@ -3715,8 +3726,10 @@ void TParseContext::paramCheckFix(const TSourceLoc& loc, const TQualifier& quali
else
warn(loc, "qualifier has no effect on non-output parameters", "precise", "");
}
if (qualifier.isNonUniform())
type.getQualifier().nonUniform = qualifier.nonUniform;
paramCheckFix(loc, qualifier.storage, type);
paramCheckFixStorage(loc, qualifier.storage, type);
}
void TParseContext::nestedBlockCheck(const TSourceLoc& loc)
......@@ -5867,6 +5880,11 @@ TIntermTyped* TParseContext::constructBuiltIn(const TType& type, TOperator op, T
basicOp = EOpConstructBool;
break;
case EOpConstructNonuniform:
node->getWritableType().getQualifier().nonUniform = true;
return node;
break;
default:
error(loc, "unsupported construction", "", "");
......
......@@ -363,7 +363,7 @@ public:
bool containsFieldWithBasicType(const TType& type ,TBasicType basicType);
TSymbol* redeclareBuiltinVariable(const TSourceLoc&, const TString&, const TQualifier&, const TShaderQualifiers&);
void redeclareBuiltinBlock(const TSourceLoc&, TTypeList& typeList, const TString& blockName, const TString* instanceName, TArraySizes* arraySizes);
void paramCheckFix(const TSourceLoc&, const TStorageQualifier&, TType& type);
void paramCheckFixStorage(const TSourceLoc&, const TStorageQualifier&, TType& type);
void paramCheckFix(const TSourceLoc&, const TQualifier&, TType& type);
void nestedBlockCheck(const TSourceLoc&);
void nestedStructCheck(const TSourceLoc&);
......
......@@ -341,6 +341,7 @@ void TScanContext::fillInKeywordMap()
(*KeywordMap)["const"] = CONST;
(*KeywordMap)["uniform"] = UNIFORM;
(*KeywordMap)["nonuniformEXT"] = NONUNIFORM;
(*KeywordMap)["in"] = IN;
(*KeywordMap)["out"] = OUT;
(*KeywordMap)["inout"] = INOUT;
......@@ -857,6 +858,7 @@ int TScanContext::tokenizeIdentifier()
switch (keyword) {
case CONST:
case UNIFORM:
case NONUNIFORM:
case IN:
case OUT:
case INOUT:
......
......@@ -199,6 +199,7 @@ void TParseVersions::initializeExtensionBehavior()
extensionBehavior[E_GL_EXT_shader_image_load_formatted] = EBhDisable;
extensionBehavior[E_GL_EXT_post_depth_coverage] = EBhDisable;
extensionBehavior[E_GL_EXT_control_flow_attributes] = EBhDisable;
extensionBehavior[E_GL_EXT_nonuniform_qualifier] = EBhDisable;
// #line and #include
extensionBehavior[E_GL_GOOGLE_cpp_style_line_directive] = EBhDisable;
......@@ -351,6 +352,7 @@ void TParseVersions::getPreamble(std::string& preamble)
"#define GL_EXT_shader_image_load_formatted 1\n"
"#define GL_EXT_post_depth_coverage 1\n"
"#define GL_EXT_control_flow_attributes 1\n"
"#define GL_EXT_nonuniform_qualifier 1\n"
// GL_KHR_shader_subgroup
"#define GL_KHR_shader_subgroup_basic 1\n"
......
......@@ -157,6 +157,7 @@ const char* const E_GL_EXT_device_group = "GL_EXT_device_group";
const char* const E_GL_EXT_multiview = "GL_EXT_multiview";
const char* const E_GL_EXT_post_depth_coverage = "GL_EXT_post_depth_coverage";
const char* const E_GL_EXT_control_flow_attributes = "GL_EXT_control_flow_attributes";
const char* const E_GL_EXT_nonuniform_qualifier = "GL_EXT_nonuniform_qualifier";
// Arrays of extensions for the above viewportEXTs duplications
......
......@@ -140,7 +140,7 @@ extern int yylex(YYSTYPE*, TParseContext&);
%token <lex> U8VEC2 U8VEC3 U8VEC4
%token <lex> VEC2 VEC3 VEC4
%token <lex> MAT2 MAT3 MAT4 CENTROID IN OUT INOUT
%token <lex> UNIFORM PATCH SAMPLE BUFFER SHARED
%token <lex> UNIFORM PATCH SAMPLE BUFFER SHARED NONUNIFORM
%token <lex> COHERENT VOLATILE RESTRICT READONLY WRITEONLY
%token <lex> DVEC2 DVEC3 DVEC4 DMAT2 DMAT3 DMAT4
%token <lex> F16VEC2 F16VEC3 F16VEC4 F16MAT2 F16MAT3 F16MAT4
......@@ -268,6 +268,7 @@ extern int yylex(YYSTYPE*, TParseContext&);
%type <interm> array_specifier
%type <interm.type> precise_qualifier invariant_qualifier interpolation_qualifier storage_qualifier precision_qualifier
%type <interm.type> layout_qualifier layout_qualifier_id_list layout_qualifier_id
%type <interm.type> non_uniform_qualifier
%type <interm.type> type_qualifier fully_specified_type type_specifier
%type <interm.type> single_type_qualifier
......@@ -473,6 +474,11 @@ function_identifier
$$.function = new TFunction(&empty, TType(EbtVoid), EOpNull);
}
}
| non_uniform_qualifier {
// Constructor
$$.intermNode = 0;
$$.function = parseContext.handleConstructorCall($1.loc, $1);
}
;
unary_expression
......@@ -966,7 +972,7 @@ parameter_declaration
$$ = $1;
parseContext.parameterTypeCheck($1.loc, EvqIn, *$1.param.type);
parseContext.paramCheckFix($1.loc, EvqTemporary, *$$.param.type);
parseContext.paramCheckFixStorage($1.loc, EvqTemporary, *$$.param.type);
parseContext.precisionQualifierCheck($$.loc, $$.param.type->getBasicType(), $$.param.type->getQualifier());
}
//
......@@ -986,7 +992,7 @@ parameter_declaration
$$ = $1;
parseContext.parameterTypeCheck($1.loc, EvqIn, *$1.param.type);
parseContext.paramCheckFix($1.loc, EvqTemporary, *$$.param.type);
parseContext.paramCheckFixStorage($1.loc, EvqTemporary, *$$.param.type);
parseContext.precisionQualifierCheck($$.loc, $$.param.type->getBasicType(), $$.param.type->getQualifier());
}
;
......@@ -1211,6 +1217,9 @@ single_type_qualifier
// allow inheritance of storage qualifier from block declaration
$$ = $1;
}
| non_uniform_qualifier {
$$ = $1;
}
;
storage_qualifier
......@@ -1331,6 +1340,13 @@ storage_qualifier
}
;
non_uniform_qualifier
: NONUNIFORM {
$$.init($1.loc);
$$.qualifier.nonUniform = true;
}
;
type_name_list
: IDENTIFIER {
// TODO
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -124,314 +124,315 @@ extern int yydebug;
SAMPLE = 334,
BUFFER = 335,
SHARED = 336,
COHERENT = 337,
VOLATILE = 338,
RESTRICT = 339,
READONLY = 340,
WRITEONLY = 341,
DVEC2 = 342,
DVEC3 = 343,
DVEC4 = 344,
DMAT2 = 345,
DMAT3 = 346,
DMAT4 = 347,
F16VEC2 = 348,
F16VEC3 = 349,
F16VEC4 = 350,
F16MAT2 = 351,
F16MAT3 = 352,
F16MAT4 = 353,
F32VEC2 = 354,
F32VEC3 = 355,
F32VEC4 = 356,
F32MAT2 = 357,
F32MAT3 = 358,
F32MAT4 = 359,
F64VEC2 = 360,
F64VEC3 = 361,
F64VEC4 = 362,
F64MAT2 = 363,
F64MAT3 = 364,
F64MAT4 = 365,
NOPERSPECTIVE = 366,
FLAT = 367,
SMOOTH = 368,
LAYOUT = 369,
__EXPLICITINTERPAMD = 370,
MAT2X2 = 371,
MAT2X3 = 372,
MAT2X4 = 373,
MAT3X2 = 374,
MAT3X3 = 375,
MAT3X4 = 376,
MAT4X2 = 377,
MAT4X3 = 378,
MAT4X4 = 379,
DMAT2X2 = 380,
DMAT2X3 = 381,
DMAT2X4 = 382,
DMAT3X2 = 383,
DMAT3X3 = 384,
DMAT3X4 = 385,
DMAT4X2 = 386,
DMAT4X3 = 387,
DMAT4X4 = 388,
F16MAT2X2 = 389,
F16MAT2X3 = 390,
F16MAT2X4 = 391,
F16MAT3X2 = 392,
F16MAT3X3 = 393,
F16MAT3X4 = 394,
F16MAT4X2 = 395,
F16MAT4X3 = 396,
F16MAT4X4 = 397,
F32MAT2X2 = 398,
F32MAT2X3 = 399,
F32MAT2X4 = 400,
F32MAT3X2 = 401,
F32MAT3X3 = 402,
F32MAT3X4 = 403,
F32MAT4X2 = 404,
F32MAT4X3 = 405,
F32MAT4X4 = 406,
F64MAT2X2 = 407,
F64MAT2X3 = 408,
F64MAT2X4 = 409,
F64MAT3X2 = 410,
F64MAT3X3 = 411,
F64MAT3X4 = 412,
F64MAT4X2 = 413,
F64MAT4X3 = 414,
F64MAT4X4 = 415,
ATOMIC_UINT = 416,
SAMPLER1D = 417,
SAMPLER2D = 418,
SAMPLER3D = 419,
SAMPLERCUBE = 420,
SAMPLER1DSHADOW = 421,
SAMPLER2DSHADOW = 422,
SAMPLERCUBESHADOW = 423,
SAMPLER1DARRAY = 424,
SAMPLER2DARRAY = 425,
SAMPLER1DARRAYSHADOW = 426,
SAMPLER2DARRAYSHADOW = 427,
ISAMPLER1D = 428,
ISAMPLER2D = 429,
ISAMPLER3D = 430,
ISAMPLERCUBE = 431,
ISAMPLER1DARRAY = 432,
ISAMPLER2DARRAY = 433,
USAMPLER1D = 434,
USAMPLER2D = 435,
USAMPLER3D = 436,
USAMPLERCUBE = 437,
USAMPLER1DARRAY = 438,
USAMPLER2DARRAY = 439,
SAMPLER2DRECT = 440,
SAMPLER2DRECTSHADOW = 441,
ISAMPLER2DRECT = 442,
USAMPLER2DRECT = 443,
SAMPLERBUFFER = 444,
ISAMPLERBUFFER = 445,
USAMPLERBUFFER = 446,
SAMPLERCUBEARRAY = 447,
SAMPLERCUBEARRAYSHADOW = 448,
ISAMPLERCUBEARRAY = 449,
USAMPLERCUBEARRAY = 450,
SAMPLER2DMS = 451,
ISAMPLER2DMS = 452,
USAMPLER2DMS = 453,
SAMPLER2DMSARRAY = 454,
ISAMPLER2DMSARRAY = 455,
USAMPLER2DMSARRAY = 456,
SAMPLEREXTERNALOES = 457,
F16SAMPLER1D = 458,
F16SAMPLER2D = 459,
F16SAMPLER3D = 460,
F16SAMPLER2DRECT = 461,
F16SAMPLERCUBE = 462,
F16SAMPLER1DARRAY = 463,
F16SAMPLER2DARRAY = 464,
F16SAMPLERCUBEARRAY = 465,
F16SAMPLERBUFFER = 466,
F16SAMPLER2DMS = 467,
F16SAMPLER2DMSARRAY = 468,
F16SAMPLER1DSHADOW = 469,
F16SAMPLER2DSHADOW = 470,
F16SAMPLER1DARRAYSHADOW = 471,
F16SAMPLER2DARRAYSHADOW = 472,
F16SAMPLER2DRECTSHADOW = 473,
F16SAMPLERCUBESHADOW = 474,
F16SAMPLERCUBEARRAYSHADOW = 475,
SAMPLER = 476,
SAMPLERSHADOW = 477,
TEXTURE1D = 478,
TEXTURE2D = 479,
TEXTURE3D = 480,
TEXTURECUBE = 481,
TEXTURE1DARRAY = 482,
TEXTURE2DARRAY = 483,
ITEXTURE1D = 484,
ITEXTURE2D = 485,
ITEXTURE3D = 486,
ITEXTURECUBE = 487,
ITEXTURE1DARRAY = 488,
ITEXTURE2DARRAY = 489,
UTEXTURE1D = 490,
UTEXTURE2D = 491,
UTEXTURE3D = 492,
UTEXTURECUBE = 493,
UTEXTURE1DARRAY = 494,
UTEXTURE2DARRAY = 495,
TEXTURE2DRECT = 496,
ITEXTURE2DRECT = 497,
UTEXTURE2DRECT = 498,
TEXTUREBUFFER = 499,
ITEXTUREBUFFER = 500,
UTEXTUREBUFFER = 501,
TEXTURECUBEARRAY = 502,
ITEXTURECUBEARRAY = 503,
UTEXTURECUBEARRAY = 504,
TEXTURE2DMS = 505,
ITEXTURE2DMS = 506,
UTEXTURE2DMS = 507,
TEXTURE2DMSARRAY = 508,
ITEXTURE2DMSARRAY = 509,
UTEXTURE2DMSARRAY = 510,
F16TEXTURE1D = 511,
F16TEXTURE2D = 512,
F16TEXTURE3D = 513,
F16TEXTURE2DRECT = 514,
F16TEXTURECUBE = 515,
F16TEXTURE1DARRAY = 516,
F16TEXTURE2DARRAY = 517,
F16TEXTURECUBEARRAY = 518,
F16TEXTUREBUFFER = 519,
F16TEXTURE2DMS = 520,
F16TEXTURE2DMSARRAY = 521,
SUBPASSINPUT = 522,
SUBPASSINPUTMS = 523,
ISUBPASSINPUT = 524,
ISUBPASSINPUTMS = 525,
USUBPASSINPUT = 526,
USUBPASSINPUTMS = 527,
F16SUBPASSINPUT = 528,
F16SUBPASSINPUTMS = 529,
IMAGE1D = 530,
IIMAGE1D = 531,
UIMAGE1D = 532,
IMAGE2D = 533,
IIMAGE2D = 534,
UIMAGE2D = 535,
IMAGE3D = 536,
IIMAGE3D = 537,
UIMAGE3D = 538,
IMAGE2DRECT = 539,
IIMAGE2DRECT = 540,
UIMAGE2DRECT = 541,
IMAGECUBE = 542,
IIMAGECUBE = 543,
UIMAGECUBE = 544,
IMAGEBUFFER = 545,
IIMAGEBUFFER = 546,
UIMAGEBUFFER = 547,
IMAGE1DARRAY = 548,
IIMAGE1DARRAY = 549,
UIMAGE1DARRAY = 550,
IMAGE2DARRAY = 551,
IIMAGE2DARRAY = 552,
UIMAGE2DARRAY = 553,
IMAGECUBEARRAY = 554,
IIMAGECUBEARRAY = 555,
UIMAGECUBEARRAY = 556,
IMAGE2DMS = 557,
IIMAGE2DMS = 558,
UIMAGE2DMS = 559,
IMAGE2DMSARRAY = 560,
IIMAGE2DMSARRAY = 561,
UIMAGE2DMSARRAY = 562,
F16IMAGE1D = 563,
F16IMAGE2D = 564,
F16IMAGE3D = 565,
F16IMAGE2DRECT = 566,
F16IMAGECUBE = 567,
F16IMAGE1DARRAY = 568,
F16IMAGE2DARRAY = 569,
F16IMAGECUBEARRAY = 570,
F16IMAGEBUFFER = 571,
F16IMAGE2DMS = 572,
F16IMAGE2DMSARRAY = 573,
STRUCT = 574,
VOID = 575,
WHILE = 576,
IDENTIFIER = 577,
TYPE_NAME = 578,
FLOATCONSTANT = 579,
DOUBLECONSTANT = 580,
INT16CONSTANT = 581,
UINT16CONSTANT = 582,
INT32CONSTANT = 583,
UINT32CONSTANT = 584,
INTCONSTANT = 585,
UINTCONSTANT = 586,
INT64CONSTANT = 587,
UINT64CONSTANT = 588,
BOOLCONSTANT = 589,
FLOAT16CONSTANT = 590,
LEFT_OP = 591,
RIGHT_OP = 592,
INC_OP = 593,
DEC_OP = 594,
LE_OP = 595,
GE_OP = 596,
EQ_OP = 597,
NE_OP = 598,
AND_OP = 599,
OR_OP = 600,
XOR_OP = 601,
MUL_ASSIGN = 602,
DIV_ASSIGN = 603,
ADD_ASSIGN = 604,
MOD_ASSIGN = 605,
LEFT_ASSIGN = 606,
RIGHT_ASSIGN = 607,
AND_ASSIGN = 608,
XOR_ASSIGN = 609,
OR_ASSIGN = 610,
SUB_ASSIGN = 611,
LEFT_PAREN = 612,
RIGHT_PAREN = 613,
LEFT_BRACKET = 614,
RIGHT_BRACKET = 615,
LEFT_BRACE = 616,
RIGHT_BRACE = 617,
DOT = 618,
COMMA = 619,
COLON = 620,
EQUAL = 621,
SEMICOLON = 622,
BANG = 623,
DASH = 624,
TILDE = 625,
PLUS = 626,
STAR = 627,
SLASH = 628,
PERCENT = 629,
LEFT_ANGLE = 630,
RIGHT_ANGLE = 631,
VERTICAL_BAR = 632,
CARET = 633,
AMPERSAND = 634,
QUESTION = 635,
INVARIANT = 636,
PRECISE = 637,
HIGH_PRECISION = 638,
MEDIUM_PRECISION = 639,
LOW_PRECISION = 640,
PRECISION = 641,
PACKED = 642,
RESOURCE = 643,
SUPERP = 644
NONUNIFORM = 337,
COHERENT = 338,
VOLATILE = 339,
RESTRICT = 340,
READONLY = 341,
WRITEONLY = 342,
DVEC2 = 343,
DVEC3 = 344,
DVEC4 = 345,
DMAT2 = 346,
DMAT3 = 347,
DMAT4 = 348,
F16VEC2 = 349,
F16VEC3 = 350,
F16VEC4 = 351,
F16MAT2 = 352,
F16MAT3 = 353,
F16MAT4 = 354,
F32VEC2 = 355,
F32VEC3 = 356,
F32VEC4 = 357,
F32MAT2 = 358,
F32MAT3 = 359,
F32MAT4 = 360,
F64VEC2 = 361,
F64VEC3 = 362,
F64VEC4 = 363,
F64MAT2 = 364,
F64MAT3 = 365,
F64MAT4 = 366,
NOPERSPECTIVE = 367,
FLAT = 368,
SMOOTH = 369,
LAYOUT = 370,
__EXPLICITINTERPAMD = 371,
MAT2X2 = 372,
MAT2X3 = 373,
MAT2X4 = 374,
MAT3X2 = 375,
MAT3X3 = 376,
MAT3X4 = 377,
MAT4X2 = 378,
MAT4X3 = 379,
MAT4X4 = 380,
DMAT2X2 = 381,
DMAT2X3 = 382,
DMAT2X4 = 383,
DMAT3X2 = 384,
DMAT3X3 = 385,
DMAT3X4 = 386,
DMAT4X2 = 387,
DMAT4X3 = 388,
DMAT4X4 = 389,
F16MAT2X2 = 390,
F16MAT2X3 = 391,
F16MAT2X4 = 392,
F16MAT3X2 = 393,
F16MAT3X3 = 394,
F16MAT3X4 = 395,
F16MAT4X2 = 396,
F16MAT4X3 = 397,
F16MAT4X4 = 398,
F32MAT2X2 = 399,
F32MAT2X3 = 400,
F32MAT2X4 = 401,
F32MAT3X2 = 402,
F32MAT3X3 = 403,
F32MAT3X4 = 404,
F32MAT4X2 = 405,
F32MAT4X3 = 406,
F32MAT4X4 = 407,
F64MAT2X2 = 408,
F64MAT2X3 = 409,
F64MAT2X4 = 410,
F64MAT3X2 = 411,
F64MAT3X3 = 412,
F64MAT3X4 = 413,
F64MAT4X2 = 414,
F64MAT4X3 = 415,
F64MAT4X4 = 416,
ATOMIC_UINT = 417,
SAMPLER1D = 418,
SAMPLER2D = 419,
SAMPLER3D = 420,
SAMPLERCUBE = 421,
SAMPLER1DSHADOW = 422,
SAMPLER2DSHADOW = 423,
SAMPLERCUBESHADOW = 424,
SAMPLER1DARRAY = 425,
SAMPLER2DARRAY = 426,
SAMPLER1DARRAYSHADOW = 427,
SAMPLER2DARRAYSHADOW = 428,
ISAMPLER1D = 429,
ISAMPLER2D = 430,
ISAMPLER3D = 431,
ISAMPLERCUBE = 432,
ISAMPLER1DARRAY = 433,
ISAMPLER2DARRAY = 434,
USAMPLER1D = 435,
USAMPLER2D = 436,
USAMPLER3D = 437,
USAMPLERCUBE = 438,
USAMPLER1DARRAY = 439,
USAMPLER2DARRAY = 440,
SAMPLER2DRECT = 441,
SAMPLER2DRECTSHADOW = 442,
ISAMPLER2DRECT = 443,
USAMPLER2DRECT = 444,
SAMPLERBUFFER = 445,
ISAMPLERBUFFER = 446,
USAMPLERBUFFER = 447,
SAMPLERCUBEARRAY = 448,
SAMPLERCUBEARRAYSHADOW = 449,
ISAMPLERCUBEARRAY = 450,
USAMPLERCUBEARRAY = 451,
SAMPLER2DMS = 452,
ISAMPLER2DMS = 453,
USAMPLER2DMS = 454,
SAMPLER2DMSARRAY = 455,
ISAMPLER2DMSARRAY = 456,
USAMPLER2DMSARRAY = 457,
SAMPLEREXTERNALOES = 458,
F16SAMPLER1D = 459,
F16SAMPLER2D = 460,
F16SAMPLER3D = 461,
F16SAMPLER2DRECT = 462,
F16SAMPLERCUBE = 463,
F16SAMPLER1DARRAY = 464,
F16SAMPLER2DARRAY = 465,
F16SAMPLERCUBEARRAY = 466,
F16SAMPLERBUFFER = 467,
F16SAMPLER2DMS = 468,
F16SAMPLER2DMSARRAY = 469,
F16SAMPLER1DSHADOW = 470,
F16SAMPLER2DSHADOW = 471,
F16SAMPLER1DARRAYSHADOW = 472,
F16SAMPLER2DARRAYSHADOW = 473,
F16SAMPLER2DRECTSHADOW = 474,
F16SAMPLERCUBESHADOW = 475,
F16SAMPLERCUBEARRAYSHADOW = 476,
SAMPLER = 477,
SAMPLERSHADOW = 478,
TEXTURE1D = 479,
TEXTURE2D = 480,
TEXTURE3D = 481,
TEXTURECUBE = 482,
TEXTURE1DARRAY = 483,
TEXTURE2DARRAY = 484,
ITEXTURE1D = 485,
ITEXTURE2D = 486,
ITEXTURE3D = 487,
ITEXTURECUBE = 488,
ITEXTURE1DARRAY = 489,
ITEXTURE2DARRAY = 490,
UTEXTURE1D = 491,
UTEXTURE2D = 492,
UTEXTURE3D = 493,
UTEXTURECUBE = 494,
UTEXTURE1DARRAY = 495,
UTEXTURE2DARRAY = 496,
TEXTURE2DRECT = 497,
ITEXTURE2DRECT = 498,
UTEXTURE2DRECT = 499,
TEXTUREBUFFER = 500,
ITEXTUREBUFFER = 501,
UTEXTUREBUFFER = 502,
TEXTURECUBEARRAY = 503,
ITEXTURECUBEARRAY = 504,
UTEXTURECUBEARRAY = 505,
TEXTURE2DMS = 506,
ITEXTURE2DMS = 507,
UTEXTURE2DMS = 508,
TEXTURE2DMSARRAY = 509,
ITEXTURE2DMSARRAY = 510,
UTEXTURE2DMSARRAY = 511,
F16TEXTURE1D = 512,
F16TEXTURE2D = 513,
F16TEXTURE3D = 514,
F16TEXTURE2DRECT = 515,
F16TEXTURECUBE = 516,
F16TEXTURE1DARRAY = 517,
F16TEXTURE2DARRAY = 518,
F16TEXTURECUBEARRAY = 519,
F16TEXTUREBUFFER = 520,
F16TEXTURE2DMS = 521,
F16TEXTURE2DMSARRAY = 522,
SUBPASSINPUT = 523,
SUBPASSINPUTMS = 524,
ISUBPASSINPUT = 525,
ISUBPASSINPUTMS = 526,
USUBPASSINPUT = 527,
USUBPASSINPUTMS = 528,
F16SUBPASSINPUT = 529,
F16SUBPASSINPUTMS = 530,
IMAGE1D = 531,
IIMAGE1D = 532,
UIMAGE1D = 533,
IMAGE2D = 534,
IIMAGE2D = 535,
UIMAGE2D = 536,
IMAGE3D = 537,
IIMAGE3D = 538,
UIMAGE3D = 539,
IMAGE2DRECT = 540,
IIMAGE2DRECT = 541,
UIMAGE2DRECT = 542,
IMAGECUBE = 543,
IIMAGECUBE = 544,
UIMAGECUBE = 545,
IMAGEBUFFER = 546,
IIMAGEBUFFER = 547,
UIMAGEBUFFER = 548,
IMAGE1DARRAY = 549,
IIMAGE1DARRAY = 550,
UIMAGE1DARRAY = 551,
IMAGE2DARRAY = 552,
IIMAGE2DARRAY = 553,
UIMAGE2DARRAY = 554,
IMAGECUBEARRAY = 555,
IIMAGECUBEARRAY = 556,
UIMAGECUBEARRAY = 557,
IMAGE2DMS = 558,
IIMAGE2DMS = 559,
UIMAGE2DMS = 560,
IMAGE2DMSARRAY = 561,
IIMAGE2DMSARRAY = 562,
UIMAGE2DMSARRAY = 563,
F16IMAGE1D = 564,
F16IMAGE2D = 565,
F16IMAGE3D = 566,
F16IMAGE2DRECT = 567,
F16IMAGECUBE = 568,
F16IMAGE1DARRAY = 569,
F16IMAGE2DARRAY = 570,
F16IMAGECUBEARRAY = 571,
F16IMAGEBUFFER = 572,
F16IMAGE2DMS = 573,
F16IMAGE2DMSARRAY = 574,
STRUCT = 575,
VOID = 576,
WHILE = 577,
IDENTIFIER = 578,
TYPE_NAME = 579,
FLOATCONSTANT = 580,
DOUBLECONSTANT = 581,
INT16CONSTANT = 582,
UINT16CONSTANT = 583,
INT32CONSTANT = 584,
UINT32CONSTANT = 585,
INTCONSTANT = 586,
UINTCONSTANT = 587,
INT64CONSTANT = 588,
UINT64CONSTANT = 589,
BOOLCONSTANT = 590,
FLOAT16CONSTANT = 591,
LEFT_OP = 592,
RIGHT_OP = 593,
INC_OP = 594,
DEC_OP = 595,
LE_OP = 596,
GE_OP = 597,
EQ_OP = 598,
NE_OP = 599,
AND_OP = 600,
OR_OP = 601,
XOR_OP = 602,
MUL_ASSIGN = 603,
DIV_ASSIGN = 604,
ADD_ASSIGN = 605,
MOD_ASSIGN = 606,
LEFT_ASSIGN = 607,
RIGHT_ASSIGN = 608,
AND_ASSIGN = 609,
XOR_ASSIGN = 610,
OR_ASSIGN = 611,
SUB_ASSIGN = 612,
LEFT_PAREN = 613,
RIGHT_PAREN = 614,
LEFT_BRACKET = 615,
RIGHT_BRACKET = 616,
LEFT_BRACE = 617,
RIGHT_BRACE = 618,
DOT = 619,
COMMA = 620,
COLON = 621,
EQUAL = 622,
SEMICOLON = 623,
BANG = 624,
DASH = 625,
TILDE = 626,
PLUS = 627,
STAR = 628,
SLASH = 629,
PERCENT = 630,
LEFT_ANGLE = 631,
RIGHT_ANGLE = 632,
VERTICAL_BAR = 633,
CARET = 634,
AMPERSAND = 635,
QUESTION = 636,
INVARIANT = 637,
PRECISE = 638,
HIGH_PRECISION = 639,
MEDIUM_PRECISION = 640,
LOW_PRECISION = 641,
PRECISION = 642,
PACKED = 643,
RESOURCE = 644,
SUPERP = 645
};
#endif
......@@ -475,7 +476,7 @@ union YYSTYPE
};
} interm;
#line 479 "MachineIndependent/glslang_tab.cpp.h" /* yacc.c:1909 */
#line 480 "MachineIndependent/glslang_tab.cpp.h" /* yacc.c:1909 */
};
# define YYSTYPE_IS_TRIVIAL 1
# define YYSTYPE_IS_DECLARED 1
......
......@@ -184,6 +184,7 @@ INSTANTIATE_TEST_CASE_P(
"loopsArtificial.frag",
"matrix.frag",
"matrix2.frag",
"nonuniform.frag",
"newTexture.frag",
"Operations.frag",
"overlongLiteral.frag",
......
......@@ -6560,6 +6560,7 @@ void HlslParseContext::mergeQualifiers(TQualifier& dst, const TQualifier& src)
MERGE_SINGLETON(readonly);
MERGE_SINGLETON(writeonly);
MERGE_SINGLETON(specConstant);
MERGE_SINGLETON(nonUniform);
}
// used to flatten the sampler type space into a single dimension
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment