Merge pull request #1510 from Kangz/complete_lib
BUILD.gn: make the static_lib complete to fix the build on OSX
diff --git a/SPIRV/SpvBuilder.h b/SPIRV/SpvBuilder.h
index 0836fff..7c1d421 100644
--- a/SPIRV/SpvBuilder.h
+++ b/SPIRV/SpvBuilder.h
@@ -131,10 +131,8 @@
Id makeSamplerType();
Id makeSampledImageType(Id imageType);
-#ifdef NV_EXTENSIONS
// accelerationStructureNV type
Id makeAccelerationStructureNVType();
-#endif
// For querying about types.
Id getTypeId(Id resultId) const { return module.getTypeId(resultId); }
@@ -371,10 +369,8 @@
Id component;
Id texelOut;
Id lodClamp;
-#ifdef NV_EXTENSIONS
Id granularity;
Id coarse;
-#endif
bool nonprivate;
bool volatil;
};
diff --git a/StandAlone/ResourceLimits.cpp b/StandAlone/ResourceLimits.cpp
index 0765ed1..66e79af 100644
--- a/StandAlone/ResourceLimits.cpp
+++ b/StandAlone/ResourceLimits.cpp
@@ -125,7 +125,6 @@
/* .MaxCullDistances = */ 8,
/* .MaxCombinedClipAndCullDistances = */ 8,
/* .MaxSamples = */ 4,
-#ifdef NV_EXTENSIONS
/* .maxMeshOutputVerticesNV = */ 256,
/* .maxMeshOutputPrimitivesNV = */ 512,
/* .maxMeshWorkGroupSizeX_NV = */ 32,
@@ -135,7 +134,6 @@
/* .maxTaskWorkGroupSizeY_NV = */ 1,
/* .maxTaskWorkGroupSizeZ_NV = */ 1,
/* .maxMeshViewCountNV = */ 4,
-#endif
/* .limits = */ {
/* .nonInductiveForLoops = */ 1,
diff --git a/glslang/Include/ResourceLimits.h b/glslang/Include/ResourceLimits.h
index 89163ac..106b21d 100644
--- a/glslang/Include/ResourceLimits.h
+++ b/glslang/Include/ResourceLimits.h
@@ -133,7 +133,6 @@
int maxCullDistances;
int maxCombinedClipAndCullDistances;
int maxSamples;
-#ifdef NV_EXTENSIONS
int maxMeshOutputVerticesNV;
int maxMeshOutputPrimitivesNV;
int maxMeshWorkGroupSizeX_NV;
@@ -143,7 +142,6 @@
int maxTaskWorkGroupSizeY_NV;
int maxTaskWorkGroupSizeZ_NV;
int maxMeshViewCountNV;
-#endif
TLimits limits;
};
diff --git a/glslang/MachineIndependent/Intermediate.cpp b/glslang/MachineIndependent/Intermediate.cpp
index 67bc42d..769dad0 100644
--- a/glslang/MachineIndependent/Intermediate.cpp
+++ b/glslang/MachineIndependent/Intermediate.cpp
@@ -1576,27 +1576,29 @@
return false;
}
case EbtFloat16:
- switch (from) {
#ifdef AMD_EXTENSIONS
+ switch (from) {
case EbtInt16:
case EbtUint16:
return extensionRequested(E_GL_AMD_gpu_shader_int16);
case EbtFloat16:
return extensionRequested(E_GL_AMD_gpu_shader_half_float);
-#endif
default:
- return false;
- }
+ break;
+ }
+#endif
+ return false;
case EbtUint16:
- switch (from) {
#ifdef AMD_EXTENSIONS
+ switch (from) {
case EbtInt16:
case EbtUint16:
return extensionRequested(E_GL_AMD_gpu_shader_int16);
-#endif
default:
- return false;
- }
+ break;
+ }
+#endif
+ return false;
default:
return false;
}
diff --git a/glslang/MachineIndependent/ParseHelper.h b/glslang/MachineIndependent/ParseHelper.h
index 0c6b284..b513f49 100644
--- a/glslang/MachineIndependent/ParseHelper.h
+++ b/glslang/MachineIndependent/ParseHelper.h
@@ -348,9 +348,7 @@
void boolCheck(const TSourceLoc&, const TPublicType&);
void samplerCheck(const TSourceLoc&, const TType&, const TString& identifier, TIntermTyped* initializer);
void atomicUintCheck(const TSourceLoc&, const TType&, const TString& identifier);
-#ifdef NV_EXTENSIONS
void accStructNVCheck(const TSourceLoc & loc, const TType & type, const TString & identifier);
-#endif
void transparentOpaqueCheck(const TSourceLoc&, const TType&, const TString& identifier);
void memberQualifierCheck(glslang::TPublicType&);
void globalQualifierFixCheck(const TSourceLoc&, TQualifier&);
@@ -426,9 +424,8 @@
// Determine loop control from attributes
void handleLoopAttributes(const TAttributes& attributes, TIntermNode*);
-#ifdef NV_EXTENSIONS
void resizeMeshViewDimension(const TSourceLoc&, TType&);
-#endif
+
protected:
void nonInitConstCheck(const TSourceLoc&, TString& identifier, TType& type);
void inheritGlobalDefaults(TQualifier& dst) const;
diff --git a/glslang/MachineIndependent/ShaderLang.cpp b/glslang/MachineIndependent/ShaderLang.cpp
index 7039ac2..901b1fd 100755
--- a/glslang/MachineIndependent/ShaderLang.cpp
+++ b/glslang/MachineIndependent/ShaderLang.cpp
@@ -600,6 +600,7 @@
case EShLangIntersectNV:
case EShLangAnyHitNV:
case EShLangClosestHitNV:
+ case EShLangMissNV:
case EShLangCallableNV:
if (profile == EEsProfile || version < 460) {
correct = false;
diff --git a/glslang/Public/ShaderLang.h b/glslang/Public/ShaderLang.h
old mode 100755
new mode 100644
index 21800aa..4ba1976
--- a/glslang/Public/ShaderLang.h
+++ b/glslang/Public/ShaderLang.h
@@ -94,7 +94,6 @@
EShLangGeometry,
EShLangFragment,
EShLangCompute,
-#ifdef NV_EXTENSIONS
EShLangRayGenNV,
EShLangIntersectNV,
EShLangAnyHitNV,
@@ -103,7 +102,6 @@
EShLangCallableNV,
EShLangTaskNV,
EShLangMeshNV,
-#endif
EShLangCount,
} EShLanguage; // would be better as stage, but this is ancient now
@@ -114,7 +112,6 @@
EShLangGeometryMask = (1 << EShLangGeometry),
EShLangFragmentMask = (1 << EShLangFragment),
EShLangComputeMask = (1 << EShLangCompute),
-#ifdef NV_EXTENSIONS
EShLangRayGenNVMask = (1 << EShLangRayGenNV),
EShLangIntersectNVMask = (1 << EShLangIntersectNV),
EShLangAnyHitNVMask = (1 << EShLangAnyHitNV),
@@ -123,7 +120,6 @@
EShLangCallableNVMask = (1 << EShLangCallableNV),
EShLangTaskNVMask = (1 << EShLangTaskNV),
EShLangMeshNVMask = (1 << EShLangMeshNV),
-#endif
} EShLanguageMask;
namespace glslang {