src/tests


Log

Author Commit Date CI Message
Jamie Madill e2cd53d6 2015-10-27T11:15:46 Implement primitive restart boolean query. We have support for primitive restart in the GL renderer, but we didn't complete support for the state query. BUG=angleproject:1101 Change-Id: I4c6ad10642f7de1d09718c4582f1037782cced58 Reviewed-on: https://chromium-review.googlesource.com/309151 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@google.com> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 362df97f 2015-10-27T11:15:45 Update WebGL test expectations. BUG=None Change-Id: Id2a88bcfd9ebf8152704ca9fc66d8401d5db43e2 Reviewed-on: https://chromium-review.googlesource.com/309150 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 839ce0b4 2015-10-23T13:13:12 Validate that compressed image formats are supported by the context. This validation was previously acceptable because all renderers supported all compressed formats in the format tables. Adding new formats that are not universally supported would have caused failures in the dEQP negative API tests. BUG=angleproject:1185 Change-Id: I102a3286a351a7c8936527963a382d9673341fc0 Reviewed-on: https://chromium-review.googlesource.com/308490 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 7535b761 2015-06-18T15:47:46 Remove dynamic indexing of matrices and vectors in HLSL Re-re-landing with fix to setting qualifiers on generated nodes. The previous version failed when a uniform was indexed, because it would set the uniform qualifier on some of the generated nodes and that interfered with the operation of UniformsHLSL. Re-landing after fixing D3D9 specific issues. HLSL doesn't support dynamic indexing of matrices and vectors, so replace that with helper functions that unroll dynamic indexing into switch/case and static indexing. Both the indexed vector/matrix expression and the index may have side effects, and these will be evaluated correctly. If necessary, index expressions that have side effects will be written to a temporary variable that will replace the index. Besides dEQP tests, this change is tested by a WebGL 2 conformance test. In the case that a dynamic index is out-of-range, the base ESSL 3.00 spec allows undefined behavior. KHR_robust_buffer_access_behavior adds the requirement that program termination should not occur and that out-of-range reads must return either a value from the active program's memory or zero, and out-of-range writes should only affect the active program's memory or do nothing. This patch clamps out-of-range indices so that either the first or last item of the matrix/vector is accessed. The code is not transformed in case the it fits within the limited subset of ESSL 1.00 given in Appendix A of the spec. If the code isn't within the restricted subset, even ESSL 1.00 shaders may require this workaround. BUG=angleproject:1116 TEST=dEQP-GLES3.functional.shaders.indexing.* (all pass after change) WebGL 2 conformance tests (glsl3/vector-dynamic-indexing.html) Change-Id: I16119f9092360fb72798f9550a6f4d3cfffdc92f Reviewed-on: https://chromium-review.googlesource.com/308790 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Zhenyao Mo <zmo@chromium.org>
Jamie Madill a33475b3 2015-10-26T13:08:58 Suppress failing textures tests in Linux dEQP. BUG=angleproject:1020 Change-Id: Ia074186c2f80b41c5a02523b3b3f564cd09ec557 Reviewed-on: https://chromium-review.googlesource.com/308920 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill f71e6618 2015-10-23T10:28:24 Update dEQP-GLES2 expectations. Some texture.mipmap.2d.projected are passing and fbo.api.valid_texcube_attachments seems to pass. BUG=angleproject:1026 BUG=angleproject:1020 Change-Id: I46ada896978cbb0a3bcbfb3985a5a50e4095ab98 Reviewed-on: https://chromium-review.googlesource.com/308391 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill b066669d 2015-10-26T10:38:18 Revert "Remove dynamic indexing of matrices and vectors in HLSL" This reverts commit 3766a40d6fda7e7190514ab7838a3f37169d863f. This CL was causing crashes in UniformHLSL.cpp, where an internal uniform "base" was attempted to be declared in HLSL. Was crashing on an external WebGL 3D canvas page (http://www.taccgl.org/?dbg=t). BUG=546686 Original commit message: Re-landing after fixing D3D9 specific issues. HLSL doesn't support dynamic indexing of matrices and vectors, so replace that with helper functions that unroll dynamic indexing into switch/case and static indexing. Both the indexed vector/matrix expression and the index may have side effects, and these will be evaluated correctly. If necessary, index expressions that have side effects will be written to a temporary variable that will replace the index. Besides dEQP tests, this change is tested by a WebGL 2 conformance test. In the case that a dynamic index is out-of-range, the base ESSL 3.00 spec allows undefined behavior. KHR_robust_buffer_access_behavior adds the requirement that program termination should not occur and that out-of-range reads must return either a value from the active program's memory or zero, and out-of-range writes should only affect the active program's memory or do nothing. This patch clamps out-of-range indices so that either the first or last item of the matrix/vector is accessed. The code is not transformed in case the it fits within the limited subset of ESSL 1.00 given in Appendix A of the spec. If the code isn't within the restricted subset, even ESSL 1.00 shaders may require this workaround. BUG=angleproject:1116 TEST=dEQP-GLES3.functional.shaders.indexing.* (all pass after change) WebGL 2 conformance tests (glsl3/vector-dynamic-indexing.html) Change-Id: I1d4b2e3888e91af7d5eebf743d12778698b6b903 Reviewed-on: https://chromium-review.googlesource.com/308770 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 334d615f 2015-10-22T14:00:28 Fix up the style in DynamicHLSL a bit. Use std::stringstream when possible, and use Context's caps instead of the Renderer's. BUG=angleproject:754 Change-Id: I2dc773709bbd612ab7ea372a358337c0a81869a3 Reviewed-on: https://chromium-review.googlesource.com/307872 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Austin Kinross d0925fd2 2015-10-23T10:22:01 Add "../../../third_party/deqp/src/data" to dEQP data directories Change-Id: I9bd4127d2eb24657e45b3a3b4668794d86b9d0e3 Reviewed-on: https://chromium-review.googlesource.com/308481 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Kenneth Russell e4bd0418 2015-10-21T17:00:06 Enable EXT_discard_framebuffer in ANGLE's D3D11 backend. This doesn't seem to cause the video-related WebGL test failures anymore that were previously seen. BUG=497445 Change-Id: I705ae8735823ab7f4b26cf7696cdb746936e4447 Reviewed-on: https://chromium-review.googlesource.com/308001 Tryjob-Request: Kenneth Russell <kbr@chromium.org> Tested-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 6c0b8dd6 2015-10-22T11:08:52 Skip the TransformFeedbackTest.MultiContext on OSX AMD too. BUG=angleproject:889 Change-Id: Idf8d00ac13382970aa8b16313a56db32a3fca05f Reviewed-on: https://chromium-review.googlesource.com/307891 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 1a683460 2015-09-29T15:09:59 Implement TransformFeedbackGL. Reland with supression for TransformFeedbackTest.MultiContext on Linux AMD. BUG=angleproject:889 Change-Id: I6f2a2e856dacf16308de222dd0936bedbb3b175c Reviewed-on: https://chromium-review.googlesource.com/307871 Tryjob-Request: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang a9ca8e20 2015-10-22T14:34:20 Revert "Implement TransformFeedbackGL." Failing on AMD Linux bots. This reverts commit a9c5288192f90ebf03b0d26d86964b4fbce74bcb. Change-Id: I2a2db8c3d96c4b927d7d784486c6df772ae63084 Reviewed-on: https://chromium-review.googlesource.com/308130 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang a9c52881 2015-09-29T15:09:59 Implement TransformFeedbackGL. BUG=angleproject:889 Change-Id: I347ac21cfd0a56654a75fb41ac24c6c67ede3a05 Reviewed-on: https://chromium-review.googlesource.com/302351 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tryjob-Request: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jinyoung Hur 85769f0d 2015-10-20T17:08:44 Re-land "Only require that the stencil masks are same as many effective bits set" It seems reasonable to validate the equality between stencilWriteMask and stencilBackWriteMask only by comparing the effective bits. An existing dEQP test[1] and a WebGL test[2] also use the max size of stencil bits for checking the stencil mask values. [1] StencilWriteMaskSeparateTestCase (gles3/functional/ es3fIntegerStateQueryTests.cpp) [2] https://www.khronos.org/registry/webgl/sdk/tests/conformance/state/ gl-get-calls.html (Search for "minimumRequiredStencilMask ") Re-land with fix for Clang warning. Change-Id: I4cadaffced04ca55fa6daf7ac6a462368e0cfeec Reviewed-on: https://chromium-review.googlesource.com/307530 Reviewed-by: Jinyoung Hur <hurims@gmail.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 1220bbbd 2015-10-20T21:04:11 Revert "Only require that the stencil masks are same as many effective bits set" Reverting temporarily, causes a compile warning with Clang: ..\..\third_party\angle\src\libANGLE\renderer\d3d\d3d11\Renderer11.cpp(242,7) : error: field 'mDebug' will be initialized after field 'mCurStencilSize' [-Werror,-Wreorder] mDebug(nullptr), ^ 1 error generated. ninja: build stopped: subcommand failed. http://build.chromium.org/p/tryserver.chromium.win/builders/win_clang_dbg/builds/98 This reverts commit 685aa4b87d2c6a3f13134c77af8690e5f3d6aa6d. Change-Id: I9dab08b26e2eddf508a7bcde7813c25be350bf31 Reviewed-on: https://chromium-review.googlesource.com/307520 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang de6144f1 2015-10-20T10:55:44 Add support for EAC and ETC2 texture formats with D3D11. Passes: * dEQP-GLES3.functional.implementation_limits.num_compressed_texture_formats * dEQP-GLES3.functional.implementation_limits.compressed_texture_formats * dEQP-GLES3.functional.texture.*eac* * dEQP-GLES3.functional.texture.*etc2* BUG=angleproject:598 Change-Id: Iaec1756b540f8f44c821fd8b9ba63f115ebe6de0 Reviewed-on: https://chromium-review.googlesource.com/305520 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Peter Kotwicz 27460dfc 2015-10-15T23:48:34 Do not attempt to compile angle_end2end_tests or angle_perftests on Android BUG=507294 Change-Id: Ied198a26f5eecab1dc608a06c2cc5e3be08cc28c Reviewed-on: https://chromium-review.googlesource.com/306460 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Peter Kotwicz <pkotwicz@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Peter Kotwicz <pkotwicz@chromium.org>
Jamie Madill d2c52e3b 2015-10-14T17:07:05 Fix debug annotations and shaders. The Program refactor inadvertantly broken Debug annotations. Fix this by correctly passing the path to the temporary shader source in the first "C" string argument to ShCompile, instead of as the first part of the source string. BUG=angleproject:1177 TEST=manual testing with MSVS Change-Id: Ie77bb11b51645a474b542ddd2ae0f391e019e341 Reviewed-on: https://chromium-review.googlesource.com/306210 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jinyoung Hur 685aa4b8 2015-09-29T00:58:02 Only require that the stencil masks are same as many effective bits set It seems reasonable to validate the equality between stencilWriteMask and stencilBackWriteMask only by comparing the effective bits. An existing dEQP test[1] and a WebGL test[2] also use the max size of stencil bits for checking the stencil mask values. [1] StencilWriteMaskSeparateTestCase (gles3/functional/ es3fIntegerStateQueryTests.cpp) [2] https://www.khronos.org/registry/webgl/sdk/tests/conformance/state/ gl-get-calls.html (Search for "minimumRequiredStencilMask ") Change-Id: I68cefbe8a9f69c5a9ebcb30027a05581e3024add Reviewed-on: https://chromium-review.googlesource.com/302703 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jinyoung Hur <hurims@gmail.com> Commit-Queue: Jinyoung Hur <hurims@gmail.com> Tryjob-Request: Jamie Madill <jmadill@chromium.org>
Austin Kinross 7a3e8e24 2015-10-08T15:50:06 Don't include samplers in uniform vector count validation Change-Id: Id2820643b70d3266c82eb10a5f05d3a5886e9323 Reviewed-on: https://chromium-review.googlesource.com/304871 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Austin Kinross 6655878f 2015-10-07T15:47:43 UniformTest.SamplerUniformsAppearOnce should check for VTF support Change-Id: If4b1602a5f706b5343fc1757962341602354b88e Reviewed-on: https://chromium-review.googlesource.com/304389 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Minmin Gong adff67b5 2015-10-14T10:34:45 Re-land "Implements more pack/unpack states." Pack: row length, skip rows, skip pixels. Unpack: image height, skip images, skip rows, skip pixels. Note that PBOs are not covered by this change. Re-land with fix for test expectations. BUG=angleproject:512 BUG=angleproject:1095 Change-Id: I71d8d3bd8fc1f2c75ca16ac2634d5eafcbd71f26 Reviewed-on: https://chromium-review.googlesource.com/305522 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill c7473924 2015-10-14T14:33:19 Revert "Implements more pack/unpack states. Pack: row length, skip rows, skip pixels. Unpack: image height, skip images, skip rows, skip pixels. Note that PBOs are not covered by this change." Expectations still not correct. This removes suppressions for two failing tests: functional.texture.specification.teximage3d_depth_pbo.depth_component32f_2d_array dEQP-GLES3.functional.texture.specification.teximage3d_depth_pbo.depth32f_stencil8_2d_array BUG=angleproject:512 BUG=angleproject:1095 This reverts commit 72e7013e68a24107b9082629fc52d59a78998eb2. Change-Id: Id81b6e616e61535b8504890ce57591813e22af69 Reviewed-on: https://chromium-review.googlesource.com/305521 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho a6996685 2015-10-12T14:32:30 Automatically enable highp in fragment shaders on ESSL3 Most code using the translator already enables highp with the resources flag when a shader spec that accepts ESSL3 is used, but for example the shader_translator utility doesn't. This fix makes sure that highp is always enabled when a fragment shader written in ESSL3 or newer is being compiled. This will make shader_translator easier to use for testing ESSL3 shaders. BUG=541550 TEST=angle_unittests Change-Id: Ia1911677c55f3c5d921829a8cbb808847ac8b636 Reviewed-on: https://chromium-review.googlesource.com/305190 Tryjob-Request: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Minmin Gong 72e7013e 2015-10-01T17:19:45 Implements more pack/unpack states. Pack: row length, skip rows, skip pixels. Unpack: image height, skip images, skip rows, skip pixels. Note that PBOs are not covered by this change. BUG=angleproject:512 BUG=angleproject:1095 Change-Id: Ia2fd7e52615d4aa08011dd615fcc20b79672d355 Reviewed-on: https://chromium-review.googlesource.com/304908 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 02f98029 2015-10-13T11:13:34 Use named value-parameterized tests for dEQP gtests This replace the non-descriptive digit at the end of the test name by the name of the dEQP test being run. Reland, enabling the named tests only in standalone. BUG=angleproject:1153 Change-Id: I1336d38425c19305fae8279a42d4931cc516215c Reviewed-on: https://chromium-review.googlesource.com/304171 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Austin Kinross 08528e17 2015-10-07T16:24:40 glTexSubImage2D should always allow non-power-of-two inputs If GL_OES_texture_npot isn't active then ANGLE currently prevents calls to glTexSubImage2D with: - level > 0 - width/height NPOT This isn't correct. It is legitimate to supply data to a NPOT subregion of a POT texture via glTexSubImage2D. Fixes these dEQP tests on 9_3: dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.a8_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.a8_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.l8_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.l8_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.la88_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.la88_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgb565_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgb565_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgb888_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgb888_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgba4444_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgba4444_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgba5551_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgba5551_cube dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgba8888_2d dEQP-GLES2.functional.texture.specification.basic_texsubimage2d.rgba8888_cube Change-Id: I5889a27edbfa807995fa20b16f36456f676b80fc Reviewed-on: https://chromium-review.googlesource.com/304612 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 2f6ddf31 2015-09-22T16:10:07 Allow double underscore in macro names Double underscore is allowed according to GLSL ES 3.10, and based on Khronos discussions the intent is that this should also apply to older specs. The dEQP tests also check this, and WebGL tests that check the opposite were recently removed. The error is changed into a warning. BUG=angleproject:989 TEST=angle_unittests dEQP-GLES3.functional.shaders.preprocessor.* (2 tests start passing) dEQP-GLES2.functional.shaders.preprocessor.* (2 tests start passing) Change-Id: I582c01b4adc8fc416354351e02b776f2cc602408 Reviewed-on: https://chromium-review.googlesource.com/300965 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tryjob-Request: Olli Etuaho <oetuaho@nvidia.com>
Brandon Jones 1048ea75 2015-10-06T15:34:52 Made program binaries cache information needed for getTransformFeedbackVarying BUG=angleproject:1173 Change-Id: Ib8883b32f54f5d38fb94e85decae2dcee108facf Reviewed-on: https://chromium-review.googlesource.com/304381 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Brandon Jones <bajones@chromium.org>
Jamie Madill 000b2f49 2015-10-09T15:33:14 Revert "Implements more pack/unpack states. Pack: row length, skip rows, skip pixels. Unpack: image height, skip images, skip rows, skip pixels." This is causing failures in dEQP-GLES3.functional.texture.specification.teximage3d_depth_pbo.depth_component24_2d_array First failing build on the bot: http://build.chromium.org/p/chromium.gpu.fyi/builders/Win7%20Release%20dEQP%20%28NVIDIA%29/builds/3635 Please fix the failure and re-land your CL with the fix. BUG=angleproject:512 BUG=angleproject:1095 This reverts commit f1bb3f0569d5ef41b17f8ad0add7308f9d0f0de1. Change-Id: I30f61db888b0adf73a1d98bbeeb2428068119627 Reviewed-on: https://chromium-review.googlesource.com/304990 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Minmin Gong f1bb3f05 2015-10-01T17:19:45 Implements more pack/unpack states. Pack: row length, skip rows, skip pixels. Unpack: image height, skip images, skip rows, skip pixels. BUG=angleproject:512 BUG=angleproject:1095 Change-Id: I11e3bc05d23419b72c92b96aabd3f0bacd983626 Reviewed-on: https://chromium-review.googlesource.com/304370 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 13473fae 2015-10-08T08:02:34 Suppress EGLSurfaceTest.MakeCurrentTwice on Mac chromium builds This is to remove a failure on the intel trybots were ANGLE is currently enable to create any context while this test expects creation to succeed. BUG=angleproject:891 Change-Id: I0450da3211fd958a17f6db0d7e2a85968d6e3a87 Reviewed-on: https://chromium-review.googlesource.com/304730 Tryjob-Request: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 1ea9aaad 2015-10-07T11:13:55 Add suppressions for several Intel failures. Also add a new test for UBOs to end2end_tests. BUG=540538 Change-Id: I6ffa6ba061a2c33811c65719deaa4302f1dbd704 Reviewed-on: https://chromium-review.googlesource.com/304521 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho b3fbd867 2015-09-30T17:55:02 Fix setting const qualifier on indexing expression Resubmitting now that separate fix for updating mangled names of types has been merged. A unit test is added to make sure that the same regression doesn't happen again. Previously, constness of indexing expressions did not take the index expression into account. Now constness correctly takes into account both the base expression and the index expression. Setting the type of expressions that index arrays is also simplified. BUG=angleproject:1170 TEST=angle_unittests Change-Id: Ie9b6aaee8185b945c03657b13d9513cc55cd2a9f Reviewed-on: https://chromium-review.googlesource.com/303601 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Geoff Lang f0aa8429 2015-09-29T15:08:34 Implement QueryGL. Passes all tests in: * dEQP-GLES3.functional.occlusion_query * angle_end2end_tests BUG=angleproject:887 Change-Id: I643ab4c28cb545de9e7b0e1740e3fd8e2aa9d3d9 Reviewed-on: https://chromium-review.googlesource.com/302338 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 90208e95 2015-10-05T15:40:36 Check for GL_OES_get_program_binary before running ProgramBinaryTest. BUG=angleproject:882 Change-Id: I2e5f4aeac6ff413d5f69097957718c52bd7828dd Reviewed-on: https://chromium-review.googlesource.com/304170 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
tmartino 7c10269d 2015-10-02T16:43:40 Correcting INVALID_ENUM issue for GLES3. Similar to prior fix for GLES2, validation now correctly returns INVALID_ENUM instead of shorting out. BUG=angleproject:1168 Change-Id: I8247b0b3520b0f116856049c85606bb44fa24021 Reviewed-on: https://chromium-review.googlesource.com/303472 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Tommy Martino <tmartino@chromium.org>
Geoff Lang 01306fc7 2015-10-05T16:53:10 Revert "Implement program binary in ProgramGL." Causing issues on AMD and Intel bots. This reverts commit 6d8926691a8ed59add7602af602af3e6f7a81ab6. Change-Id: Ifb395f78a6a44b874ac13da1f252f604a1a7b0bc Reviewed-on: https://chromium-review.googlesource.com/303439 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 5a85bee2 2015-10-02T14:06:06 Add angle_perftests to GN. Also clean up the formatting a bit with gn format. BUG=537008 Change-Id: I23337e634f20f611aaae7d17ef47b5784738bbe8 Reviewed-on: https://chromium-review.googlesource.com/303793 Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 6d892669 2015-10-02T09:57:30 Implement program binary in ProgramGL. Verified by end2end tests and manually checking that chrome can load and save program binaries. BUG=angleproject:882 Change-Id: Ic7e4b443365af6ea2d9ce5b0ecfb685eac85f479 Reviewed-on: https://chromium-review.googlesource.com/303828 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 36b73909 2015-10-05T11:58:50 Fix standalone ninja build on Linux Preprocessor conditions referring to undefined macros failed standalone build which uses the -Werror=undef setting. This same error has been in multiple patches, and reverting them would cause test breakage, so fixing the issue is simpler than reverting. Change-Id: I4a079ef5d823eed76ebdefa8be413f63d29a5f6a Reviewed-on: https://chromium-review.googlesource.com/304020 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill e623bd46 2015-10-02T19:14:15 Revert "Fix setting const qualifier on indexing expression" Failing to compile shaders which are used in some layout_tests, see http://crbug.com/538692 for logs and bad shaders. We should diagnose if the shaders are faulty or if there's a bug in this CL and take appropriate action, but first priority is to get the tests running again. BUG=538692 BUG=angleproject:1170 This reverts commit 16a79cd169420cdf0254964b1bac9dd9964a8119. Change-Id: Iea14c58d87041bcf5ba645b7076ba0936dea6b9d Reviewed-on: https://chromium-review.googlesource.com/303794 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 4e7196a1 2015-09-30T14:44:15 UniformTest.FloatUniformStateQuery do computations in doubles When using floats, when testing INT_MAX, the loss of precision causes an undefined behavior when casting from float to int. In this cause on clang 3.6 on Mac, the integer wrapped and became INT_MIN. Reland with warnings fixes for MSVC on standalone builds. BUG=angleproject:891 Change-Id: Ieed609840ae22e89f51c3a85cd5309c4d8bc52ea Reviewed-on: https://chromium-review.googlesource.com/303900 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang e746890e 2015-10-02T10:46:24 Return the correct value when querying GL_MAX_FRAGMENT_UNIFORM_VECTORS. BUG=angleproject:1087 Change-Id: Ibd0918f29b65c509e749953059d584ea83776a31 Reviewed-on: https://chromium-review.googlesource.com/303775 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
tmartino 0ccd5aee 2015-10-01T14:33:14 Correcting INVALID_OPERATION to INVALID_ENUM Should return INVALID_ENUM when uncompressed texture passed to compressed image constructor. BUG=angleproject:1168 Change-Id: If30f0407e7455d6e19432831883d33a1e8bfec9a Reviewed-on: https://chromium-review.googlesource.com/303750 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho ee0d4c52 2015-10-02T15:50:06 Revert "UniformTest.FloatUniformStateQuery do computations in doubles" This change broke standalone build on Windows. Two casts from double to GLfloat were missing. This reverts commit 7aa4cae26f755dc9e6646e669fc3222f9dd63b20. BUG=angleproject:891 Change-Id: I69cf773c940fd43b06f21c1ee86e60bac6825684 Reviewed-on: https://chromium-review.googlesource.com/303352 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez 7aa4cae2 2015-09-30T14:44:15 UniformTest.FloatUniformStateQuery do computations in doubles When using floats, when testing INT_MAX, the loss of precision causes an undefined behavior when casting from float to int. In this cause on clang 3.6 on Mac, the integer wrapped and became INT_MIN. BUG=angleproject:891 Change-Id: Ieb3199fd33c25e7da8d154f88658e06f01d53c0e Reviewed-on: https://chromium-review.googlesource.com/303338 Tryjob-Request: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 16a79cd1 2015-09-30T17:55:02 Fix setting const qualifier on indexing expression Previously, constness of indexing expressions did not take the index expression into account. Now constness correctly takes into account both the base expression and the index expression. Setting the type of expressions that index arrays is also simplified. BUG=angleproject:1170 TEST=angle_unittests Change-Id: Ie2d122020cc252655ab0eea96886b9f85931b80a Reviewed-on: https://chromium-review.googlesource.com/303350 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Corentin Wallez 7b43c9b0 2015-09-30T10:47:30 Add suppressions for failing end2end tests on Mac Intel BUG=angleproject:891 Change-Id: I88a8bcc4a6911c92bdb981aca34a0557ad451df7 Reviewed-on: https://chromium-review.googlesource.com/303390 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Kimmo Kinnunen 5f0246ca 2015-07-22T10:30:35 Implement gl_FragDepth for GLES SL 3.0 Makes it an error to access gl_FragDepthEXT in #version 300 es shader. TODO: Lacks the feature to make "#extension GL_EXT_frag_depth : require" an error for #version 300 es. Reland of: https://chromium-review.googlesource.com/#/c/287570 BUG=angleproject:1102 TEST=angle_unittest Change-Id: I064d918d65f37539cb1e14f12173ca5591a4ea3f Reviewed-on: https://chromium-review.googlesource.com/301711 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang ddf4d392 2015-09-29T13:00:14 Skip BlendMinMax test on Intel OpenGL due to driver flakyness. Change-Id: I72da31fa0bfbed578e20ff39b82d8c8e716fd276 Reviewed-on: https://chromium-review.googlesource.com/302337 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 947908f1 2015-09-22T10:42:08 Add dEQP GLES2 test expectations for Mac BUG=angleproject:891 Change-Id: Ib7d16a9266fe23fb9374cec94f3baa4ad135c0d3 Reviewed-on: https://chromium-review.googlesource.com/302333 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang afd7f0a8 2015-09-09T15:33:31 Explicitly enable framebuffer SRGB blending in StateManagerGL. In DesktopGL, SRGB blending must be enabled or linear blending will be used. reland: Work around issues on AMD drivers where SRGB blending would be used on clears of linear attachments. Passes all dEQP-GLES3.functional.fragment_ops.blend.fbo_srgb.* tests (1106 new passing tests). BUG=angleproject:883 BUG=angleproject:885 Change-Id: I974a55fe3acc77ac77e93f19c83ee3b76f784df2 Reviewed-on: https://chromium-review.googlesource.com/302336 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 543e7ff7 2015-09-29T14:15:15 Revert "Explicitly enable framebuffer SRGB blending in StateManagerGL." More compile errors on mac. This reverts commit 056fae4a01db306b8f9c1e57374e18ebffbdf8eb. Change-Id: I579b9e50ded7240be4f488a48588a89ecb4bea44 Reviewed-on: https://chromium-review.googlesource.com/302571 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 056fae4a 2015-09-09T15:33:31 Explicitly enable framebuffer SRGB blending in StateManagerGL. In DesktopGL, SRGB blending must be enabled or linear blending will be used. reland: Work around issues on AMD drivers where SRGB blending would be used on clears of linear attachments. Passes all dEQP-GLES3.functional.fragment_ops.blend.fbo_srgb.* tests (1106 new passing tests). BUG=angleproject:883 BUG=angleproject:885 Change-Id: I6c2b4552c571707a8d8d80d3573bcb38797c3929 Reviewed-on: https://chromium-review.googlesource.com/302791 Tryjob-Request: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang ec3123bb 2015-09-28T19:21:01 Revert "Explicitly enable framebuffer SRGB blending in StateManagerGL." Compilation failure on mac and linux. This reverts commit e19d7f90355f02ac7a7cd0a2ac130e0859cd3cc7. Change-Id: I638c3ffebb8c7ad0e3fe2e1e65d6212487bfc6ae Reviewed-on: https://chromium-review.googlesource.com/302790 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang e19d7f90 2015-09-09T15:33:31 Explicitly enable framebuffer SRGB blending in StateManagerGL. In DesktopGL, SRGB blending must be enabled or linear blending will be used. reland: Work around issues on AMD drivers where SRGB blending would be used on clears of linear attachments. Passes all dEQP-GLES3.functional.fragment_ops.blend.fbo_srgb.* tests (1106 new passing tests). BUG=angleproject:883 BUG=angleproject:885 Change-Id: I03fbb0910ce414552ba841099a177446d0ace7b6 Reviewed-on: https://chromium-review.googlesource.com/301702 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Dian Xiang db3dd083 2015-09-16T20:16:01 Refactoring TextureFormat and its helper functions to individual classes BUG=angleproject:1160 This is the first step to BUG=angleproject:1160, optimizing GetTextureFormatInfo to use static switching rather than building maps and using the find function. Also reordered the includes in alphabetical, src files first format The next step is to modify the GetTextureFormatInfo not to build a map but to use static switching. The step after that is to use a JSON generator to generate the switching, hence refactoring TextureFormat to be in its own class so we only need to generate what's necesary. The helper functions such as swizzle texture format can also be done using the same approach. Hence, they're also refactored into their own files. Change-Id: I753f437ca0df69ee5584d254fe0d2ea8b09a857e Reviewed-on: https://chromium-review.googlesource.com/300288 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Dian Xiang <dianx@google.com>
Geoff Lang 0af0b81d 2015-09-23T13:56:25 Add a SamplerImpl object and implement it for the GL backend. Passes all tests in dEQP-GLES3.functional.samplers BUG=angleproject:1162 Change-Id: I7713031a677aac2b41889a6b4297ab512e184863 Reviewed-on: https://chromium-review.googlesource.com/301582 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 68a9d748 2015-09-15T08:21:10 Compile the dEQP test targets on Mac BUG=angleproject:891 Change-Id: I4bc2817106c8170684a76972badd38c02c0abf0e Reviewed-on: https://chromium-review.googlesource.com/299852 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 247374cb 2015-09-09T15:07:24 Allow limited form of expressions in #line directives Reuse ExpressionParser that's also used for parsing preprocessor conditionals to parse line and file numbers in #line directives. According to recent Khronos discussions, the intent of the spec is that expressions in #line directives should be interpreted similarly to expressions in conditional directives, so reusing ExpressionParser is a natural way to implement this. This enables simple math operators operating on integers. There are a few unclear corner cases, but this approach is enough to support practical use cases and pass the dEQP tests. Valid line directives have one of the following forms: #line line-expression #line line-expression file-expression ExpressionParser is first run to parse the line-expression. In ambiguous cases the ExpressionParser consumes as much of the line as possible to form line-expression. Then, if end-of-line hasn't been reached, file-expression is parsed by running ExpressionParser again. As an example of an ambiguous case: #line 1 + 2 This could alternatively be interpreted to mean line-expression "1" and file-expression "+ 2" where + is the unary + operator, but ANGLE now interprets it to mean line-expression "1 + 2". Because of these ambiguous cases, a bison grammar that would parse multiple expressions on the same line couldn't be easily constructed, so this solution where ExpressionParser is run twice was chosen instead. The problematic corner cases are: - ExpressionParser uses 64-bit integers internally for evaluating the expression's value. It's possible to interpret the ESSL3 spec so that 32-bit integer wraparound behavior would be required also for #line directive expressions. - It's unclear whether the defined operator can be used in #line expressions. In this patch it is disabled. Hoping for further clarification from Khronos. - It's unclear how short-circuiting should affect the parsing of undefined identifiers in #line expressions. Now it's consistent with #if expressions (undefined identifiers are OK if they're short-circuited). dEQP expectations are updated for preprocessor tests, including ones not affected specifically by this change. BUG=angleproject:989 TEST=angle_unittests, dEQP-GLES3.functional.shaders.preprocessor.* (4 start passing), dEQP-GLES2.functional.shaders.preprocessor.* (4 start passing) Change-Id: I55c5bf75857da5de855cc600d3603ee19399f328 Reviewed-on: https://chromium-review.googlesource.com/300964 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 412f17da 2015-09-25T08:43:54 Suppress TextureLimitsTest.MaxCombinedTextures on Intel GL. This test probably triggers a driver bug. BUG=angleproject:1123 Change-Id: I81921e7faf51ac60f1175a04ee17e920a346059d Reviewed-on: https://chromium-review.googlesource.com/302461 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 006cbc5b 2015-09-23T16:47:54 Remove rx::ShaderSh and move the shared code to the GL. The GL layer can interact with the translator directly, to query all the active shader variables and call ShCompile. BUG=angleproject:1159 Change-Id: I334a9bef28f93cf85dd8cac0fb8542ac567cc3ec Reviewed-on: https://chromium-review.googlesource.com/299877 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 91445bce 2015-09-23T16:47:53 Make a shader Shader::Data state structure. This design follows the similar designs for Program, Framebuffer, etc. Because of the current design, share a mutable pointer with the Impl so the patch becomes a bit smaller and easier to review. In a follow- up patch we can move the shared code into the GL layer. BUG=angleproject:1159 Change-Id: Ib243e74779f23be51cdca80f1b5c6e5f3e36059d Reviewed-on: https://chromium-review.googlesource.com/299876 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3d3d2f20 2015-09-23T16:47:51 Re-re-land "Move sampler validation to the GL layer." This previously was D3D-only, but is required for every draw call. This completes the work of removing the D3D-specific Impl methods from ProgramImpl. Also add several regression tests to cover texture and sampler validation. Re-land with a fix for duplicate sampler active uniforms. Re-re-land with a fix for a test comparison warning on Linux. BUG=angleproject:1123 Change-Id: Iaf7b33861c07b9ceed4bd53ac2f010d35f05df45 Reviewed-on: https://chromium-review.googlesource.com/301712 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 6d246510 2015-09-23T18:04:10 Revert "Re-land "Move sampler validation to the GL layer."" Build failure on Linux: In file included from ../../third_party/angle/src/tests/gl_tests/UniformTest.cpp:7: In file included from ../../third_party/angle/src/tests/test_utils/ANGLETest.h:10: ../../testing/gtest/include/gtest/gtest.h:1392:16: error: comparison of integers of different signs: 'const int' and 'const unsigned int' [-Werror,-Wsign-compare] if (expected == actual) { ~~~~~~~~ ^ ~~~~~~ ../../testing/gtest/include/gtest/gtest.h:1422:12: note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<int, unsigned int>' requested here return CmpHelperEQ(expected_expression, actual_expression, expected, ^ ../../third_party/angle/src/tests/gl_tests/UniformTest.cpp:487:5: note: in instantiation of function template specialization 'testing::internal::EqHelper<false>::Compare<int, unsigned int>' requested here EXPECT_EQ(GL_SAMPLER_2D, type); ^ BUG=angleproject:1123 This reverts commit 6cbf4385280c4c1dd97f0882ecb18dbc4c341fd4. Change-Id: I95279b37d253e3ea78faa53f3773f2dc3d17df95 Reviewed-on: https://chromium-review.googlesource.com/302030 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Minmin Gong eb5ea077 2015-09-11T11:21:00 Implements GL_EXT_unpack_subimage and GL_NV_pack_subimage. Pack/unpack subimages is core features of GLES3. Those 2 extensions expose them to GLES2. BUG=angleproject:512 Change-Id: I6834cf5d4a91bc3430c60dcec29c449826fd6d93 Reviewed-on: https://chromium-review.googlesource.com/299790 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Minmin Gong <mgong@microsoft.com>
Jamie Madill 83f349ea 2015-09-23T09:50:36 Remove CompilerImpl and merge code to gl::Compiler. This class uses no Impl-specific code. We can also do a similar code relocation for the gl::Shader class, but in several steps because it is a bit more complex. BUG=angleproject:1159 Change-Id: I4d3ce3253df0a2bdee1d98e46cfd4b999d86be6e Reviewed-on: https://chromium-review.googlesource.com/299874 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 6cbf4385 2015-09-22T19:12:11 Re-land "Move sampler validation to the GL layer." This previously was D3D-only, but is required for every draw call. This completes the work of removing the D3D-specific Impl methods from ProgramImpl. Also add several regression tests to cover texture and sampler validation. Re-land with a fix for duplicate sampler active uniforms. BUG=angleproject:1123 Change-Id: Iefef06e7901873c98bf2ba7864efd16a4c6435d3 Reviewed-on: https://chromium-review.googlesource.com/301581 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 3187a38e 2015-09-09T12:00:12 Make preprocessor ExpressionParser only lex what it can parse This cleans up ExpressionParser so that the lexer only consumes one extra token in case the parser finishes. The parser will also finish with YYACCEPT once it has parsed a complete expression. This will make the preprocessor to generate a more informative unexpected token error instead of a syntax error if there are extra tokens after #if. This will also enable reusing ExpressionParser for parsing expressions in line directives. The format for a line directive that specifies both line and file numbers is as follows: #if line-expression file_expression ExpressionParser will need to be run twice for each line: first to parse line-expression and then to parse file-expression. For that reason, it is essential that ExpressionParser for line-expression stops before consuming more than one token of file-expression. BUG=angleproject:989 TEST=angle_unittests, dEQP-GLES3.functional.shaders.preprocessor.* Change-Id: I0bb92f733c18891eeddbc61e7c5bebdf1003559a Reviewed-on: https://chromium-review.googlesource.com/300962 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tryjob-Request: Olli Etuaho <oetuaho@nvidia.com>
Geoff Lang 3edfe034 2015-09-04T16:38:24 Support primitive restart in RendererGL. Store index ranges in a new struct that tracks how many real indices were seen. Update index caching to key on primitive restart being enabled and update index counting functions to skip primitive restart indicies when needed. Passes dEQP-GLES3.functional.primitive_restart.* Change-Id: Id1e25a5adcdcd4e998836e8ff6679c64be4c3066 Reviewed-on: https://chromium-review.googlesource.com/297770 Tryjob-Request: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 3aa23a7c 2015-09-22T19:03:33 Revert "Move sampler validation to the GL layer." Probably causing failures in the dEQP-GLES2 GL back-end tests: dEQP-GLES2.functional.uniform_api.info_query.basic.sampler2D_both BUG=angleproject:1123 This reverts commit 6fa156b66da2090c98f1a044a948694c7ac83324. Change-Id: I3cc993c34aae4a108037ce81709b71d16ece814e Reviewed-on: https://chromium-review.googlesource.com/301580 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 6fa156b6 2015-09-22T10:17:01 Move sampler validation to the GL layer. This previously was D3D-only, but is required for every draw call. This completes the work of removing the D3D-specific Impl methods from ProgramImpl. Also add several regression tests to cover texture and sampler validation. BUG=angleproject:1123 Change-Id: I167cbc8f47b4a397d2ae6cc507bdac35168bcacd Reviewed-on: https://chromium-review.googlesource.com/299400 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 261f5379 2015-09-18T10:34:31 Support parsing defined operator generated by macro expansion dEQP tests enforce that the defined operator should be parsed even when it is generated as a result of macro expansion, even though this is undefined according to the C++ preprocessor spec. Implement support for this by putting the parsing for the defined operator inside MacroExpander. The operator gets processed right after it is generated by macro expansion. Parsing the defined operator is toggled with a boolean according to the context where MacroExpander is used. BUG=angleproject:989 TEST=angle_unittests, dEQP-GLES3.functional.shaders.preprocessor.* - 2 tests start passing: dEQP-GLES3.functional.shaders.preprocessor.conditional_inclusion.basic_2* Change-Id: I780e63bd4558253657d898685d62339017564a06 Reviewed-on: https://chromium-review.googlesource.com/300970 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez a0928b94 2015-09-15T08:15:56 Port gpu_test_expectations to Mac BUG=angleproject:891 Change-Id: I06ad3b25914bc9ec4541b38a9b160983b7dcb720 Reviewed-on: https://chromium-review.googlesource.com/299850 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Austin Kinross cc54ab36 2015-09-02T10:27:28 Generate tests.sln for WinRT, and make it include dEQP projects Change-Id: I34284965f7b4f9d11aa7bab263292d4f41312d04 Reviewed-on: https://chromium-review.googlesource.com/297307 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang ee48376c 2015-09-15T13:12:07 Update to the latest versions of the GL and EGL headers. Add GLES 3.1 and 3.2 headers. Remove GLES 3.0 extension headers and entry point files. Re-land fixes double define from different style defines in libGLESv2.gypi and other projects. Re-land fixes missing defines in angle_util project in gn. Change-Id: I1952413cd4390e6f5450df809f8f5867bf6f49e2 Reviewed-on: https://chromium-review.googlesource.com/299771 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 0393310f 2015-09-15T16:59:59 Revert "Update to the latest versions of the GL and EGL headers." Issues with GN build. This reverts commit 8284436798dd184afe61cbb586185cb68e503d6f. Change-Id: I99d186019135bbbe250e95c9567854108d31c556 Reviewed-on: https://chromium-review.googlesource.com/299870 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez f0ca9a0c 2015-09-14T11:53:10 Remove the usage of some c++11 library features That were causing compilation error in Chromium Mac builds BUG=angleproject:891 Change-Id: I45777451b300928e8c8d232a5b7ecffa7f1c3cbe Reviewed-on: https://chromium-review.googlesource.com/299721 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 178e5974 2015-09-14T11:52:44 In Chromium Mac builds do not find cstdint, use stdint.h instead BUG=angleproject:891 Change-Id: Idf2a89ad26955df3579bb2c1883137589f68f573 Reviewed-on: https://chromium-review.googlesource.com/299720 Tryjob-Request: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 1b27199e 2015-09-14T11:57:03 IndexBufferOffsetTest: fix -Wnewline-eof for Mac BUG=angleproject:891 Change-Id: Ic36d549d1a5ae52c49185064c2fdf60bd0074c0d Reviewed-on: https://chromium-review.googlesource.com/299723 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 934cd2e5 2015-09-11T11:21:34 SixteenBppTextureTest: test the FBO are renderable before drawing It is valid for the implementation to return a GL_FRAMEBUFFER_UNSUPPORTED for framebuffer completeness. Check for that case and return early. This fixes the RGB5_A1 tests on Mac that doesn't support rendering to this format. BUG=angleproject:891 Change-Id: If37d8f82e994a93a470cbdc01d758fe60d54a5b2 Reviewed-on: https://chromium-review.googlesource.com/298863 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Geoff Lang <geofflang@chromium.org> Tryjob-Request: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 0baaca68 2015-09-14T07:38:00 EGLContextCompatTest: fix typo in WindowDifferentConfig It was incorrectly calling the pbuffer function. BUG=angleproject:891 Change-Id: I6959540262a8ef80886e41da795f9e4aff218535 Reviewed-on: https://chromium-review.googlesource.com/299441 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang 82844367 2015-09-11T13:52:12 Update to the latest versions of the GL and EGL headers. Add GLES 3.1 and 3.2 headers. Remove GLES 3.0 extension headers and entry point files. Re-land fixes double define from different style defines in libGLESv2.gypi and other projects. Change-Id: I6204dc767bd83b7aa7e4d6e2fa338b2ce7f304d8 Reviewed-on: https://chromium-review.googlesource.com/299401 Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang e12150fe 2015-09-11T20:06:27 Revert "Update to the latest versions of the GL and EGL headers." Linux compile failures to do gyp defines. This reverts commit 8bbeabc1795473f7b3141219be3970fea3b95a71. Change-Id: Icb31dd817414b3a9ab36e88cedab9c725af26b6b Reviewed-on: https://chromium-review.googlesource.com/299173 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 8bbeabc1 2015-09-11T13:52:12 Update to the latest versions of the GL and EGL headers. Add GLES 3.1 and 3.2 headers. Remove GLES 3.0 extension headers and entry point files. Change-Id: Icaa444efa52f3b9d1497189da92bc364545a6e3a Reviewed-on: https://chromium-review.googlesource.com/299172 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 2511d064 2015-09-11T15:19:56 Default test window size to 16x16. This fixes a crash on Linux whenever we try to create a test without specifying a default width and height. Did not seem to have a problem on Windows. TEST=angle_end2end_tests (Windows/Linux) BUG=angleproject:1123 Change-Id: I1afcea9e833208d8a67d363678b9736c2a222066 Reviewed-on: https://chromium-review.googlesource.com/298835 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 7aef6020 2015-09-11T19:04:00 Revert "Update to the latest versions of the GL and EGL headers." Broke the Clang compile. In file included from ../../third_party/angle/include/GLSLANG/ShaderLang.h:28: ../../third_party/angle/include/KHR/khrplatform.h:282:30: error: no newline at end of file [-Werror,-Wnewline-eof] #endif /* __khrplatform_h_ */ Several other similar errors. BUG=None This reverts commit aac2035d851fc92b159dc8e01cfd2ebb86e99e4a. Change-Id: I407e7e65bb6a46d1d941c54cdf14a14758e22d96 Reviewed-on: https://chromium-review.googlesource.com/298834 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang aac2035d 2015-09-11T13:52:12 Update to the latest versions of the GL and EGL headers. Add GLES 3.1 and 3.2 headers. Remove GLES 3.0 extension headers and entry point files. Change-Id: I8e9df6262dc1b2536a409c5791734e4a4d63b115 Reviewed-on: https://chromium-review.googlesource.com/299341 Tryjob-Request: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Cooper Partin d756145d 2015-09-10T10:23:29 Re-land "Added support for premultiplied alpha mode for composition swapchains" Change-Id: Ic0c863c3d4936947fc520a5394e38e458659df46 Reviewed-on: https://chromium-review.googlesource.com/298880 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 62d31cb6 2015-09-11T13:25:51 Re^6-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. Re^4-land with a fix for boolean uniform arrays and UBO uniforms. Re^5-land with a fix for a test warning on Linux. Re^6-land with a fix for transposed matrix uniform arrays. BUG=angleproject:1123 TEST=end2end_tests, bots, dEQP GLES3.ubo and GLES2.uniform_api Change-Id: Ie6fcde1c16eb05d67191b629338b88302a2563f5 Reviewed-on: https://chromium-review.googlesource.com/298971 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill fb53603c 2015-09-11T13:19:49 Revert "Re^5-land "Move Uniform and UBO info to the gl::Program layer."" Failing dEQP-GLES3.functional.uniform_api.random.22 and 23: There's a bug with arrays of tranpsosed matrix uniforms. BUG=angleproject:1123 This reverts commit 78d356929bd0441d81e2dd8a63130cd6788e2fde. Change-Id: If39b5908af39671dfe98965e6a1ba77fd18ea8fc Reviewed-on: https://chromium-review.googlesource.com/299320 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 78d35692 2015-09-11T08:32:51 Re^5-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. Re^4-land with a fix for boolean uniform arrays and UBO uniforms. Re^5-land with a fix for a test warning on Linux. BUG=angleproject:1123 TEST=end2end_tests, bots, dEQP GLES3.ubo and GLES2.uniform_api Change-Id: I03afcd446d9e74573c4d4c712ed7407b91d8001c Reviewed-on: https://chromium-review.googlesource.com/299180 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill a2eb02c9 2015-09-11T12:31:41 Revert "Re^4-land "Move Uniform and UBO info to the gl::Program layer."" Test has a warning on Linux: In file included from ../../third_party/angle/src/tests/test_utils/ANGLETest.h:13: ../../testing/gtest/include/gtest/gtest.h:1392:16: error: comparison of integers of different signs: 'const int' and 'const unsigned int' [-Werror,-Wsign-compare] if (expected == actual) { ~~~~~~~~ ^ ~~~~~~ ../../testing/gtest/include/gtest/gtest.h:1422:12: note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<int, unsigned int>' requested here return CmpHelperEQ(expected_expression, actual_expression, expected, ^ ../../third_party/angle/src/tests/gl_tests/UniformBufferTest.cpp:357:5: note: in instantiation of function template specialization 'testing::internal::EqHelper<false>::Compare<int, unsigned int>' requested here EXPECT_EQ(GL_FLOAT, type); ^ BUG=angleproject:1123 This reverts commit 2ae1ee6161c24aab065190b1528f6195e80e34d0. Change-Id: Ic3dabea54068377d1f2c5f722ba52966cf1a0491 Reviewed-on: https://chromium-review.googlesource.com/299170 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2ae1ee61 2015-09-10T10:04:24 Re^4-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. Re^4-land with a fix for boolean uniform arrays and UBO uniforms. BUG=angleproject:1123 TEST=end2end_tests, bots, dEQP GLES3.ubo and GLES2.uniform_api Change-Id: I4c9f5ed31b81380507bef7981f97086d642801ae Reviewed-on: https://chromium-review.googlesource.com/298451 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Dian Xiang 769769a7 2015-09-09T15:20:08 Adding in checks for program and shader names to return INVALID_OPERATION When a valid program is given instead of a shader, an INVALID_OPERATION is returned rather than INVALID_VALUE when a shader related function is called. The reverse happens when a program related function is called and a valid shader program is given to it. This commit also refactors other places that requires a similar check to use the same validation function and error message. BUG=angleproject:1029 dEQP-GLES2.functional.negative_api.state.get_shader_info_log dEQP-GLES2.functional.negative_api.state.get_shader_source dEQP-GLES2.functional.negative_api.state.get_programiv dEQP-GLES2.functional.negative_api.state.get_program_info_log BUG=angleproject:1101 dEQP-GLES3.functional.negative_api.state.get_shader_info_log dEQP-GLES3.functional.negative_api.state.get_shader_source dEQP-GLES3.functional.negative_api.state.get_programiv dEQP-GLES3.functional.negative_api.state.get_program_info_log Change-Id: I707b6ba10da0288128af185ce8dfb906fca0f766 Reviewed-on: https://chromium-review.googlesource.com/298604 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tryjob-Request: Dian Xiang <dianx@google.com> Tested-by: Dian Xiang <dianx@google.com>
Corentin Wallez 4a693565 2015-09-10T09:48:13 Fix the named parameter for the IndexConversion perftest It seems that the compiler didn't resolve the overloaded operator<< with the structure's grandparent structure. Fix it by explicitely casting to the grandparent before calling operator<<. Also provides slightly more information on the number of iterations/triangles. This wasn't caught with local testing as IndexConversion isn't compiled in angle_perftests on Linux. BUG=angleproject:1153 BUG=530226 Change-Id: Ifa602eb0728d052bc651f0dd030f9f880c00dc51 Reviewed-on: https://chromium-review.googlesource.com/298860 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 2aa3b436 2015-09-10T16:39:13 Revert "Added support for premultiplied alpha mode for composition swapchains" Unused member warning: ..\..\third_party\angle\src\libANGLE/renderer/d3d/d3d11/NativeWindow.h(68,24) : error: private field 'mConfig' is not used [-Werror,-Wunused-private-field] const egl::Config *mConfig; ^ BUG=None This reverts commit 9823337204555935804985c5b93a38adc69cb681. Change-Id: I8ed41770eb3fe70ab7e32ba9a0860e2c397e22c5 Reviewed-on: https://chromium-review.googlesource.com/298830 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang a6c95fc6 2015-09-09T13:02:52 Pass the texture unit to TextureGL::syncSamplerState. When syncing the texture's sampler state, make sure the correct texture unit is active. When StateManagerGL syncs the textures, it may not set the active texture if the texture ID has not changed. BUG=angleproject:884 BUG=angleproject:883 BUG=angleproject:1051 Change-Id: Ib22874c22a12b1b9bd68887ac5a449c507e7bdc6 Reviewed-on: https://chromium-review.googlesource.com/298482 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>