Merge vk-gl-cts/opengl-es-cts-3.2.6 into vk-gl-cts/opengl-es-cts-3.2.7

Change-Id: I5eee40dacbbc0fd7b95c06a9e6f434f45ca8ecf9
diff --git a/modules/gles31/functional/es31fShaderFramebufferFetchTests.cpp b/modules/gles31/functional/es31fShaderFramebufferFetchTests.cpp
index 226b05a..c0efc27 100644
--- a/modules/gles31/functional/es31fShaderFramebufferFetchTests.cpp
+++ b/modules/gles31/functional/es31fShaderFramebufferFetchTests.cpp
@@ -599,7 +599,13 @@
 	}
 	else if (textureChannelClass == tcu::TEXTURECHANNELCLASS_SIGNED_INTEGER)
 	{
-		tcu::clear(reference.getAccess(), tcu::clamp(fbColor.asInt() + uniformColor.asInt(), formatMinValue.asInt(), formatMaxValue.asInt()));
+		tcu::IVec4 clearColor;
+
+		// Calculate using 64 bits to avoid signed integer overflow.
+		for (int i = 0; i < 4; i++)
+			clearColor[i] = static_cast<int>((static_cast<deInt64>(fbColor.asInt()[i]) + static_cast<deInt64>(uniformColor.asInt()[i])) & 0xffffffff);
+
+		tcu::clear(reference.getAccess(), clearColor);
 	}
 	else
 	{