|
|
@@ -153,6 +153,11 @@ EProfile EDesktopProfile = static_cast<EProfile>(ENoProfile | ECoreProfile | ECo
|
|
|
{ EBadProfile } };
|
|
|
const Versioning* Es300Desktop130 = &Es300Desktop130Version[0];
|
|
|
|
|
|
+ const Versioning Es310Desktop420Version[] = { { EEsProfile, 0, 310, 0, nullptr },
|
|
|
+ { EDesktopProfile, 0, 420, 0, nullptr },
|
|
|
+ { EBadProfile } };
|
|
|
+ const Versioning* Es310Desktop420 = &Es310Desktop420Version[0];
|
|
|
+
|
|
|
const Versioning Es310Desktop430Version[] = { { EEsProfile, 0, 310, 0, nullptr },
|
|
|
{ EDesktopProfile, 0, 430, 0, nullptr },
|
|
|
{ EBadProfile } };
|
|
|
@@ -256,14 +261,14 @@ const BuiltInFunction BaseFunctions[] = {
|
|
|
{ EOpGreaterThanEqual, "greaterThanEqual", 2, TypeU, ClassBNS, Es300Desktop130 },
|
|
|
{ EOpVectorEqual, "equal", 2, TypeU, ClassBNS, Es300Desktop130 },
|
|
|
{ EOpVectorNotEqual, "notEqual", 2, TypeU, ClassBNS, Es300Desktop130 },
|
|
|
- { EOpAtomicAdd, "atomicAdd", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicMin, "atomicMin", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicMax, "atomicMax", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicAnd, "atomicAnd", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicOr, "atomicOr", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicXor, "atomicXor", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicExchange, "atomicExchange", 2, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
- { EOpAtomicCompSwap, "atomicCompSwap", 3, TypeIU, ClassV1FIOCV, Es310Desktop430 },
|
|
|
+ { EOpAtomicAdd, "atomicAdd", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicMin, "atomicMin", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicMax, "atomicMax", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicAnd, "atomicAnd", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicOr, "atomicOr", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicXor, "atomicXor", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicExchange, "atomicExchange", 2, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
+ { EOpAtomicCompSwap, "atomicCompSwap", 3, TypeIU, ClassV1FIOCV, Es310Desktop420 },
|
|
|
#ifndef GLSLANG_WEB
|
|
|
{ EOpMix, "mix", 3, TypeB, ClassRegular, Es310Desktop450 },
|
|
|
{ EOpMix, "mix", 3, TypeIU, ClassLB, Es310Desktop450 },
|
|
|
@@ -5805,7 +5810,7 @@ void TBuiltIns::addQueryFunctions(TSampler sampler, const TString& typeName, int
|
|
|
return;
|
|
|
#endif
|
|
|
|
|
|
- if (sampler.isImage() && ((profile == EEsProfile && version < 310) || (profile != EEsProfile && version < 430)))
|
|
|
+ if (sampler.isImage() && ((profile == EEsProfile && version < 310) || (profile != EEsProfile && version < 420)))
|
|
|
return;
|
|
|
|
|
|
if (profile == EEsProfile)
|
|
|
@@ -7823,6 +7828,22 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, const SpvVersion
|
|
|
symbolTable.setFunctionExtensions("uintBitsToFloat", 1, &E_GL_ARB_shader_bit_encoding);
|
|
|
}
|
|
|
|
|
|
+ if (profile != EEsProfile && version < 430 ) {
|
|
|
+ symbolTable.setFunctionExtensions("imageSize", 1, &E_GL_ARB_shader_image_size);
|
|
|
+ }
|
|
|
+
|
|
|
+ // GL_ARB_shader_storage_buffer_object
|
|
|
+ if (profile != EEsProfile && version < 430 ) {
|
|
|
+ symbolTable.setFunctionExtensions("atomicAdd", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicMin", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicMax", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicAnd", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicOr", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicXor", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicExchange", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ symbolTable.setFunctionExtensions("atomicCompSwap", 1, &E_GL_ARB_shader_storage_buffer_object);
|
|
|
+ }
|
|
|
+
|
|
|
symbolTable.setVariableExtensions("gl_DeviceIndex", 1, &E_GL_EXT_device_group);
|
|
|
BuiltInVariable("gl_DeviceIndex", EbvDeviceIndex, symbolTable);
|
|
|
symbolTable.setVariableExtensions("gl_ViewIndex", 1, &E_GL_EXT_multiview);
|