src/tests/gl_tests


Log

Author Commit Date CI Message
Brandon Schade a8c947c7 2020-02-06T08:53:16 Enabled GL_KHR_no_error Enabled GL_KHR_no_error added end2end tests for it Note that GL_KHR_no_error can only be enabled by setting the EGL attribute currently. Context flags are not currently supported. Bug: angleproject:1280 Test: angle_end2end_tests --gtest_filter=ContextNoErrorTest.* Change-Id: Ib5c73b8e284e3e4e5f800750ad6fcbef77be4285 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2068899 Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Brandon Schade 0c9b6abd 2020-02-06T08:53:16 Skip invalid end2end test for ES2 Previously, the incomplete framebuffer depth stencil attachment test would run on ES2 if GL_OES_packed_depth_stencil were present. This is insufficient since it uses the GL_DEPTH_STENCIL_ATTACHMENT enum, which is not introduced in any extension prior to ES3. The test has been disabled on ES2, regardless of extensions. Bug: angleproject:4454 Test: angle_end2end_tests --gtest_filter=StateChangeTest.FramebufferIncompleteDepthStencilAttachment/* Change-Id: Ic5a6a521e35b49c5d723b33f588fa608264d6390 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2090783 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Michael Spang 55228e53 2020-03-04T18:25:47 Add Chrome texture formats test for VulkanExternalImageTest This make sure the VkFormat/internalformat combinations that Chrome uses succeed import, which in particular requires the object size to match. Allowing VK_FORMAT_R8G8B8_UNORM VkFormat for GL_RGB8 will make this test fail when run on a native vulkan that supports that format. Bug: chromium:1058521 Change-Id: I91483568ba8552f40314f10215bfea59e5ca2b94 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2088652 Commit-Queue: Michael Spang <spang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Alexey Knyazev 605ab763 2020-02-24T19:43:32 D3D11: Implement OES_draw_buffers_indexed Existing CONSTANT_COLOR/CONSTANT_ALPHA limitation was generalized to independent blend states with draw call invalidation and a new end2end test. dEQP tests that are incompatible with this limitation result in INVALID_OPERATION and are marked as FAIL. D3D11 renderer always normalizes and deduplicates requested blend states based on their enabled features and bound framebuffer. Bug: angleproject:4394 Change-Id: I284796e18be71de1b5bfb087d36f6a45be4c3f70 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2070575 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Xiaoxuan Liu 27a81308 2020-02-29T12:53:45 Vulkan: Re-enable RobustResourceInitTest.Texture test Commit "Vulkan: Add robust init for NULL texture image." for angleproject:4255 also fixed angleproject:3416, re-enable the disabled test in 3416. Bug: angleproject:3416 Change-Id: I36c09d90eafe9dea0b477c49487284d4a305d992 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2086931 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Ancheng Qiao 028a7a72 2020-03-03T18:19:33 Skip if GL_EXT_texture_compression_dxt1 isn't supported If GL_EXT_texture_compression_dxt1 is not support, will be failed at glCompressedTexImage2D in CopyCompressedTextureTest.Immutable Bug: angleproject:1424 Change-Id: I287c6a40c1c09fa379088e5ad4bec06f0dfc2f59 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2086533 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Ancheng Qiao 90019cea 2020-02-26T18:04:25 Vulkan: Add depth to mipmap generation In generateMipmaps, remove hard coded depth of 1, shift depth like every other dimension. Remove MipmapsForTexture3D test pixel value check, in es spec3.2 8.14.4 "No particular filter algorithm is required, though a box filter is recommended." It's implementation-dependent. In current angle implementation, will choose VK_FILTER_LINEAR/VK_FILTER_NEAREST according to vkdeice support. Bug: angleproject:3983 Test: MipmapTestES3.MipmapsForTexture3D/ES3_Vulkan Test: dEQP-GLES3.functional.samplers.single_tex_3d.diff_max_lod Test: dEQP-GLES3.functional.samplers.single_tex_3d.diff_min_lod Test: dEQP-GLES3.functional.samplers.multi_tex_3d.diff_max_lod Test: dEQP-GLES3.functional.samplers.multi_tex_3d.diff_min_lod Change-Id: I5e73f8c743053aeb521b5e0b3e372bbe77e57ad2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2076740 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Ran Wang 35785308 2020-02-24T17:37:55 Vulkan: reserve extra varyings when basicGLLineRasterization or supportsTransformFeedbackExtension is enabled. updated with MaxVaryingWithFeedbackAndGLline adding test to validate pixel value (disabled for macos) Bug: angleproject:4273 Change-Id: Ie3d3516fd3806c0d622fb402ba8223d302206f73 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2071237 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill da2e65c0 2020-03-01T13:01:24 Test Runner: Add stub register function to white box tests. These tests use the same main function as end2end_tests. Add the register function stub so the compilation works correctly in standalone and component builds. Bug: angleproject:4449 Change-Id: Ib1558a596b9a558b16a7c5b7bfccc1e495a67e39 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2082135 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Xiaoxuan Liu b07816d6 2020-01-02T15:13:37 Vulkan: Add robust init for NULL texture image. In gl::ReadPixels(), ValidateReadPixels() will try to flush staged updates before readPixels. In the case where a texture was initialized with null RGBA data, no Framebuffer dirty bits are set, and thus the staged clear would never be flushed from the staged updates. 1. Add robust init in TextureVk::initImage to ensure image is initialized. Test: ./angle_end2end_tests --gtest_filter=\ RobustResourceInitTest*_Vulkan_AllocateNonZeroMemory 2. Update stageSubresourceRobustClear() to kEmulatedInitColorValue in the case where robust resource was initialized without full RGBA format to update init value of robust resource. Test: texture-attachment-formats.html in webgl_conformance_vulkan_passthrough_tests. 3. Revert "Suppress Vulkan RobustResourceInit tests." Revert commit a8e6a463121b9920564fb6efd7f2c857d7023fe3. Reason for revert: re-enable related robust tests. Bug: angleproject:4255 Change-Id: I79f20e0c02c2f1b1cd68ab590f0f765229f9e780 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1985503 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Brandon Schade 6c56c579 2020-01-21T11:08:36 Add Android boot animation and rounding error test This introduces an end2end test that makes the same GLES1 calls as Android's default boot animation. The test uses images of much smaller sizes, but we do the same thing with the images as the original code (it uses one image as a mask and moves the other along behind it). The original default boot animation code can be found here: https://android.googlesource.com/platform/frameworks/base/+/refs/heads/master/cmds/bootanimation/BootAnimation.cpp#422 This change also implements glTexParameterx since the default boot animation requires it. This function is part of OES_FIXED_POINT. This also includes a test to check for int to floating point cast errors when using GL_TEXTURE_CROP_RECT_OES. Tests: angle_end2end_tests --gtest_filter=*DefaultBootAnimation* angle_end2end_tests --gtest_filter=*TextureParameterTest.IntConversionsAndIntBounds* Bug: angleproject:3644 Change-Id: Ib7e99c9dc1c001c71543d03ea4dd76082192f6a7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2053506 Commit-Queue: Brandon Schade <b.schade@samsung.com> Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tobin Ehlis <tobine@google.com>
Jamie Madill da6d12d0 2020-02-27T14:20:32 Fix out-of-bounds read in test. The test wasn't reserving a large enough buffer when initializing the vertex data. Fix the test buffer limits. Bug: angleproject:4430 Change-Id: I4b9a98e1af1cc8088afb871816061d7ee4dd6a2c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2079153 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Geoff Lang 4d2040a6 2020-02-27T09:59:11 Make GLSLTest_ES31.MixOfAllResources more lenient. Lower precision in Vulkan caused off-by-one issues with this test. BUG=angleproject:4438 Change-Id: I17111a06133ef403be1f0c99321f1dbf8ab6083c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2078791 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill 660c0dd6 2020-02-25T13:30:33 Vulkan: Fix padding out Buffer allocations on AMD. We would often pad incorrectly given the constraints of the max stride. We shouldn't really be rounding up the buffer size, but we should instead be adding the max alignment size to the end of the buffer. Bug: angleproject:4428 Change-Id: Id2afc572c85985548a18f60b42cdc388d83d5c4c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2071235 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Xinyi He b185002d 2020-02-21T16:58:39 Fix the condition of glOrtho{fx} validation According to the OpenGL ES 1.1 spec, remove the conditions of glOrtho validation that n and f must be positive. Bug: angleproject:4281 Change-Id: I644a25408a026ce87211f2203b8e8203eeaf69bd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2067002 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Michael Spang c4197713 2019-06-03T19:23:02 Implement glImportMemoryZirconHandle & glImportSemaphoreZirconHandle Implement import of fuchsia external objects passed by zircon handle. This works exactly the same as with file descriptors. Bug: angleproject:3492 Change-Id: I4d46917dfc5902f00c94550158a9f8073097f0a4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1642334 Commit-Queue: Michael Spang <spang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill ce4918f1 2020-02-19T09:39:44 Vulkan: Sanitize Images & Buffers with non-zero values. Only enabled for specific tests at the moment. This CL allows our tests to sanitizes memory for the robust resource access extension. It is quite slow so should not be enabled by default. Only works for 1 level 2D color textures and buffers. Makes several flaky robust resource initialization tests consistently fail. Controlled via an angle::Feature in FeaturesVk. It works by initializing memory to an abitrary non-zero value: - if newly allocated memory is mappable, we map it in init and set it - if a buffer or texture can be a transfer destination, we use a staging resource - otherwise we don't attempt to initialize the resource. Bug: angleproject:4384 Change-Id: I9b4f347bfcddf3096f491ed0243bef86837feaa0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2043271 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Jeff Gilbert 166875eb 2019-03-27T13:52:04 Don't clamp in glBlendColor if context supports renderable [half-]float. Add test for glBlendColor >1.0, skipped on D3D9 since it's unsupportable there. Bug: angleproject:3323 Change-Id: I3fcf867dae96bdadf8a0183269d8f27b659d0baf Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1541723 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jeff Gilbert <jgilbert@mozilla.com>
Shahbaz Youssefi 1f5f7ea3 2020-02-14T23:39:11 Vulkan: Fix SPIR-V transformation name-info association Prior to this commit, when "OpName %id name" was encountered, the info corresponding to "name" was immediately associated with %id. This is not necessarily correct because there could be multiple ids with the same name. For example a sampler declaration and an unrelated function argument could have the same name. In this case, the sampler declaration and function argument name don't even need to be in the same shader stage. This change modifies the SPIR-V transformation such that the name-id mapping is tracked until the OpVariable instruction that actually declares the variable is visited. The mapping to variable info is only done if the storage class specified in this instruction corresponds to a shader interface variable. Bug: angleproject:3394 Change-Id: I35a1f6f8278e4b1ad81c9955a55e1b72d6f2e4ea Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2057248 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Yuly Novikov d5861a68 2020-02-13T15:46:49 Fix ASAN errors in end2end tests. 2 minor issues of reading from uninitialized memory in tests. Removes the suppressions from the fixed tests. Bug: chromium:1029378 Change-Id: I466ce231cfed1ce53a60732706c05b778b096805 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2055649 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 041ebfed 2020-02-10T13:39:34 Speed up InstancingTest.LineLoop. This test was taking 14-20 seconds in release mode. Likely because of the way we were issuing a ReadPixels and "std::endl" to a stream for every pixel of a 256x256 Framebuffer. Instead issue a single ReadPixels call and no stream flushes. Now runs in less than 500ms. Helps prevent timeouts when running tests multi-process. Also enables the test on D3D9. Bug: angleproject:3162 Change-Id: I27aad773040d6b6668cbde003802345e01044a7d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2047414 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 8257ac30 2020-02-07T14:17:08 Vulkan: Defer RenderPass image barriers. We accumulate image barriers in two places: * for GL sampler textures * for GL framebuffer attachments (Render Targets) Then we issue the barriers together in a single call before the RP. This fixes a bug where we were missing a layout transition in some cases when transitioning between a sampler and a render target. It should also be faster to issue a single barrier before a RP than issue several smaller barriers. Bug: angleproject:3539 Bug: angleproject:4029 Change-Id: I180b770f0df6b44d209e5c618ba36bcc1c6372e4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2044236 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Jamie Madill 788fa360 2020-02-10T14:07:12 Suppress two failing NVIDIA D3D11 tests. Bug: angleproject:4391 Bug: angleproject:4392 Change-Id: I81cbf261cf206cd2d38cff93d16056c21bf78557 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2047416 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill a8e6a463 2020-02-09T13:10:24 Suppress Vulkan RobustResourceInit tests. These tests are flaky because of a bug in ANGLE's Vulkan robust resource init. Mark them as failing until we can resolve the bug. Bug: angleproject:4255 Bug: angleproject:4384 Change-Id: I8e18a8532850848fc7a25e137dce27dd0d19fa55 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2046053 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill c3854ebc 2020-02-07T11:11:26 Vulkan: Clamp vertex buffer offsets. Vulkan mandates that vertex buffer offsets are within the size of the buffer even if robust buffer access is enabled. Do a check in VertexArrayVk::syncDirtyAttrib to guard against this. Bug: angleproject:3350 Change-Id: Ia01deb9b7335dd8f632f2cf9b32d2908ba55645c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2044491 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Jamie Madill 3a2522de 2020-02-06T10:05:23 Make TransformFeedbackTest deterministic. Instead of using rand(), use a fixed seed RNG. This can ensure runs use the same draw call counts no matter the time of day. Note: there may have been a setting somewhere that was seeding the RNG because I wasn't seeing variation between test runs locally. This change makes it explicit. Bug: angleproject:4029 Change-Id: Ic51bf2a6779da3b96a3357eed99c0f7fa9d81648 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2042210 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Brian Osman e9dc0201 2020-02-04T12:04:28 GL: Mark unused uniform locations that were explicitly bound as ignored If a uniform location is unused, but a call to glBindUniformLocation has explicitly bound the uniform, ANGLE validation still treated the uniform as unused and returned errors. The correct behavior is to ignore the uniform and silently fail. Bug: angleproject:4374 Change-Id: Ic7b97f23cf8bc2d5380129322595e51b3d4a9fcc Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2036676 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi e5385ea9 2020-01-27T13:40:18 Vulkan: Compile shaders at link time Since line raster emulation was changed to use specialization constants, it has been possible to compile shaders at link time. However, program pipeline objects would have required keeping the shader sources around for recompilation. Now that all necessary decorations are modified directly in SPIR-V, it's possible to compile the shaders at link time and forget about their sources. Program pipeline objects then simply "reconfigure" the generated SPIR-V. A next step could be to also create the Vulkan pipeline object at link time. A number of failures due to gaps in CTS testing prevent that work currently. In particular, in some situations the generated SPIR-V is not per spec, for example it may contain vertex attributes with aliasing locations, or have transform feedback capture of array elements misconfigured. Bug: angleproject:3394 Bug: angleproject:4253 Change-Id: I54c0884cf056b511a4a306225cc6ed2cef84d257 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2023186 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 20b1259a 2020-02-05T17:08:05 Vulkan: Command graph linearization (Step 2). ES 2.0 is feature complete. Passes all of the angle_end2end_tests with the new linear command recording method. Also runs the T-Rex benchmark without any obvious glitches. Likely has issues with creating too many RenderPasses. ES3 is mostly untouched. Bug: angleproject:4029 Change-Id: Ic5acf3d768495fbffd07b07bf0a6f2b5787c51f8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2012900 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi f764fc02 2020-02-03T10:33:58 Fix varying linking by location This change breaks the assumption everywhere that varyings can be identified uniquely by name throughout all stages of the pipeline. It further implements linking of varyings by location, if specified. Bug: angleproject:4355 Change-Id: Ie45e48879008c3f0c22d1da3d0d26f37c655e54e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2030026 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Tibor Dusnoki 4546c5ce 2020-01-31T15:05:35 Skip failing end2end tests on Windows on ARM There are multiple failing tests on Windows on ARM which are related to drawing differences. They seem to be similar to an already reported issue (anglebug.com/3748). Bug: angleproject:4356 Bug: angleproject:4357 Change-Id: Ide5cc2e6f42d4c4b6fb88352833d20e517005c14 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2033067 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Kenneth Russell 07795d47 2020-01-31T16:08:52 Disable rewriteRowMajorMatrices workaround. It's causing flaky crashes in tests. Leave the revised code in place so it's easier to debug. Disable test which required the workaround. Bug: angleproject:2273 Bug: angleproject:3843 Change-Id: Iebb682bd3c6282031cc57eda5d3d4d5636be7294 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2033870 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Shahbaz Youssefi c73475fb 2020-01-29T11:37:05 Vulkan: Fix UtilsVk dirtying driver uniforms descriptor set binding Most UtilsVk functions bind a descriptor set to index 0 (same as driver uniforms). If that happens to close a render pass, all is well as starting a new render pass ensures all descriptor sets are rebound. However, if the render pass is not closed, or if a dispatch call is issued (which never rebinds descriptor sets if not explicitly necessary), then the driver uniforms descriptor set may end up never rebound, causing a validation error (and possible crash or corruption). This change makes sure that UtilsVk notifies the context when it binds a descriptor set. The context then dirties the driver uniforms binding as appropriate. Bug: angleproject:4272 Change-Id: Ief20c7884fbe39712f844247489812afc70b30a9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2027938 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Kenneth Russell e196bc85 2020-01-17T13:11:20 Add driver bug workaround for rewriting row major matrices. Joint work with syoussefi@, who wrote the RewriteRowMajorMatrices pass, and revised it for this CL to not rely on the NameNamelessUniformBuffers pass - which was breaking it on the GL backend. Hook up previously written RewriteRowMajorMatrices transformation, and enable on all GPU types on macOS. It is needed at least for AMD and Intel GPUs. Add a new test which verifies the behavior of dynamically-indexed arrays of row-major matrices. Bug: angleproject:2273 Bug: angleproject:3843 Change-Id: Id582f9cf6b9b1a59091aab1786539174f360b705 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2008717 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Alexis Hetu 33027d3e 2020-01-28T16:08:02 Enable GL_OES_depth_texture_cube_map with Vulkan backend GL_OES_depth_texture_cube_map depends on depthTextureOES, but adds the same new texture format/type requirements as GL_OES_packed_depth_stencil, so instead of adding a specific check for GL_OES_depth_texture_cube_map, the Vulkan backend checks for a combination of GL_OES_depth_texture and GL_OES_depth_texture_cube_map to enable GL_OES_depth_texture_cube_map. ANGLE has no specific checks for whether a format is "cubemappable", but Vulkan has no restrictions of the format of cubemaps, so if the proper formats are supported, creating a cube of any of these formats should be implicitly supported. Bug: angleproject:4293 Change-Id: I968dbe8869ba0f50de18dd41f1195e847c06b520 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2026027 Commit-Queue: Alexis Hétu <sugoi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Michael Spang 09d51a57 2020-01-24T17:28:24 Fuchsia: Skip PointSpriteAlternatingDrawTypes on ARM Fuchsia This is not passing currently, skip it for now. Bug: angleproject:4349 Change-Id: If36a144e8d17cc94c2186a7a794358b14223349e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2023913 Commit-Queue: Michael Spang <spang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Courtney Goeltzenleuchter cb2b5136 2020-01-10T11:04:38 Vulkan: Simplify format table generation Remove the "override" table. That gets in the way of some solutions. If a format cannot be supported by a native Vulkan format as indicated in the "map" table, then check fallbacks. Also add support for native RGBA4 and R5G5B5A1 support. Previously those formats would be emulated with RGBA8 due to the override, but now code will check if the native format is available and use it. Bug: angleproject:4282 Change-Id: Ib33ea40543d91a2c2a95075b277f825a8822037c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1994538 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Shahbaz Youssefi f1f082e1 2020-01-17T14:53:38 Vulkan: Set varying location & xfb decorations in SPIR-V The shader translator outputs arbitrary location indices. Once compiled by glslang, the SPIR-V transformer modifies these decorations. If the transform feedback extension is used, it will also add the relevant decorations to the varyings that are captured. Bug: angleproject:3394 Change-Id: I5ecafd0536408612a5d4b920dbabbfabe650657c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2008468 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jeff Gilbert 05e08edf 2019-12-26T20:58:48 Disable skipValidation when context is lost. Lost no-error contexts should gracefully handle GetProgramiv, etc. Includes test that a lost no-error context doesn't crash on getProgramiv. Firefox bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1601703 Bug: angleproject:4244 Change-Id: I8c37df37e83308ab85ad958df6dab46b0ab348e1 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2003239 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi e28883de 2020-01-25T23:25:43 Vulkan: Fix handling of inactive fragment outputs These were never assigned a location. They are now removed by the translator similar to other inactive variables. Bug: angleproject:4313 Change-Id: I3398d06e1dea3f43b84f206cca07cde5b44b21a8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2021734 Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 7488a096 2020-01-27T22:17:59 Add a test to expose location'ed varying link bug Bug: angleproject:4355 Change-Id: I2b914d3e6bf74ccf5d3f42d7bd010e44e45645ea Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2023921 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 086aded3 2020-01-26T13:40:02 Return the correct location count for matrices in structs GetLocationCount() returned secondary size for fields of a struct. For matrices however, the correct value would be the primary size. This is a similar fix to 6423b7fc7ded02a702d24feb0730731ab9f6c061. Bug: angleproject:4200 Change-Id: I2c69b9454729993010766fcde0cabec986b7429d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2021738 Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 3712b2e4 2020-01-24T17:08:30 Vulkan: Command graph linearization (Step 1). This initial prototype introduces a new feature to the Vulkan back-end that disables the deferred command recording. The intent is to have a lower CPU overhead during submission calls which currently walk a DAG. The feature is not complete. Currently it only passes the ANGLE SimpleOperationTests. Moreover it is extremely simple and only allows use of one command buffer at a time. In the future we'll allow open command buffers for recording outside and inside render pass commands at the same time. We'll also support collapsing RenderPasses together for some use cases. Currently the prototype only passes "SimpleOperationTest". There are quite a few unimplemented features like queries, XFB, etc. Bug: angleproject:4029 Change-Id: I82760986683f55e37ac4ea559de6f4cffb6ef84e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1953485 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tobin Ehlis <tobine@google.com>
Jamie Madill 0a3f58f1 2020-01-24T09:54:31 Fix undefined behaviour in ClearTest. We were expecting an uninitialized texture to contain black. However the contents of the texture data may be undefined. Discovered when working with the Vulkan command stream refactor. Bug: angleproject:4029 Change-Id: Ia5d24707746819b116ac0053fabb48033574569a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2017978 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 24627fa4 2020-01-21T11:39:56 Row-major test: switch to compute Based on Nvidia's recommendation that the following: all(lessThan(gl_FragCoord.xy, vec2(1.0, 1.0))) isn't necessarily true for only a single FS invocation, even when not multisampling. The tests that do the above are changed to compute instead. Bug: angleproject:3831 Change-Id: I22d935f797c2e385218bc6af31e98a7f672a7707 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2012743 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Michael Spang abaeb415 2020-01-20T20:33:23 Vulkan: Fix setupDraw when VK_EXT_transform_feedback is not enabled There's no dirty bit handler if VK_EXT_transform_feedback disabled, but we're setting that dirty bit in syncState. This results in calling a null method pointer. Skip the invalidate if the extension is not enabled. gl::LogMessage::~LogMessage() at ./../../third_party/angle/src/common/debug.cpp:0 rx::ContextVk::setupDraw(gl::Context const*, gl::PrimitiveMode, int, int, int, gl::DrawElementsType, void const*, angle::BitSetT<11ul, unsigned long, unsigned long>, rx::vk::priv::SecondaryCommandBuffer**) at ./../../third_party/angle/src/libANGLE/renderer/vulkan/ContextVk.cpp:844 rx::ContextVk::drawArrays(gl::Context const*, gl::PrimitiveMode, int, int) at ./../../third_party/angle/src/libANGLE/renderer/vulkan/ContextVk.cpp:1698 gl::Context::drawArrays(gl::PrimitiveMode, int, int) at ./../../third_party/angle/src/libANGLE/Context.inl.h:112 gl::DrawArrays(unsigned int, int, int) at ./../../third_party/angle/src/libGLESv2/entry_points_gles_2_0_autogen.cpp:926 (anonymous namespace)::AttributeLayoutNonIndexed::Draw(int, unsigned int, unsigned short const*) at ./../../third_party/angle/src/tests/gl_tests/AttributeLayoutTest.cpp:431 (anonymous namespace)::AttributeLayoutTest::Run(bool) at ./../../third_party/angle/src/tests/gl_tests/AttributeLayoutTest.cpp:305 [This stack is from the added assert; calling a null function pointer crashes without producing a useful stack trace.] Bug: angleproject:4326 Change-Id: I036ae322bddc4865229fa3fe7ea72a4344b99f83 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2011408 Commit-Queue: Michael Spang <spang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 01e28144 2020-01-21T13:15:18 Row-major test: Clarify std140's stride calculation Bug: angleproject:3830 Change-Id: I5fa213927b609ef33c729ded5d42add8f148dcb1 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2012622 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 2e1beb40 2020-01-14T12:08:02 Add a test to expose translator bug w.r.t short circuiting Bug: angleproject:3829 Change-Id: I872118f145886eecaed1680268e95419385b9d9e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2001237 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi feb3b6cc 2020-01-13T22:58:59 Vulkan: Remove row->col major shader transformation This was done based on the incorrect assumption that Vulkan GLSL doesn't allow layout qualifiers on interface block fields. This was due to glslang compile failures in some shaders that included mixed row- and column-major fields in interface blocks. However, the failures were only in the case the interface block is inactive, in which case glslang wrapper previously replaced the layout/qualifier of the interface block with |struct|, which left the shader with an unused struct definition with fields that have layout qualifiers; an invalid shader. The change introduced in https://chromium-review.googlesource.com/c/angle/angle/+/1951523 removes inactive shader interface declarations. The above scenario thus never occurs, rendering the row- to column-major transformation unnecessary. Bug: angleproject:3443 Change-Id: Ice34a0fc6e047b79a4d44f04b730ec59bdfafe33 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1961098 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 680a7d3b 2019-12-09T16:07:43 Vulkan: Add test that exposes sampler refactor bug Bug: angleproject:4211 Change-Id: I9e9cdacd4f24131101029d17932625e2e3c7d7e0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1957836 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Shahbaz Youssefi f0be7c81 2019-12-02T15:42:33 Fix GLSLTest_ES3.MixedRowAndColumnMajorMatrices_ReadSideEffect The test had two array sizes swapped, causing failure on vendors that statically verified index-out-of-bound accesses. Bug: angleproject:3831 Change-Id: I8ec32e9c11b38b69f03b1a22e60dfb6c6e82c2a4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1947123 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 6b275406 2020-01-09T11:14:47 Vulkan: Workaround vertex attributes vs stride issue on AMD Under robustBufferAccess, Vulkan states that: Vertex input attributes are considered out of bounds if the offset of the attribute in the bound vertex buffer range plus the size of the attribute is greater than either: - vertexBufferRangeSize, if bindingStride == 0; or - (vertexBufferRangeSize - (vertexBufferRangeSize % bindingStride)) The latter implies that if the buffer size is not a multiple of the vertex attribute stride, what lies beyond the last multiple of stride is considered out of bounds. It also says: Out-of-bounds buffer loads will return any of the following values: - Values from anywhere within the memory range(s) bound to the buffer (possibly including bytes of memory past the end of the buffer, up to the end of the bound range). - Zero values, or (0,0,0,x) vectors for vector reads where x is a valid value represented in the type of the vector components and may be any of ... The first bullet point indicates that the driver is allowed to load the attribute values from the buffer if its range still lies within the buffer size. Take the following example: - Buffer size = 12 - Attribute stride = 8 - Attribute offset = 0 - Attribute size = 4 Basically the buffer is thus laid out as follows: attr stride _________/\_________ / \ +----------+----------+----------+ | vertex 0 | padding | vertex 1 | +----------+----------+----------+ \___ ____/ V attr size In the above example, the attribute for vertex 1 is considered out of bounds, but the driver is allowed to either read it correctly, or return (0, 0, 0, 1) for it. Most drivers implement the former, while AMD implements the latter. This change introduces a workaround for AMD where GL_MAX_VERTEX_ATTRIB_STRIDE is limited to 2048 (the common value for it according to gpuinfo.org) and conservatively rounds up every buffer allocation to that size. While technically, this workaround should be applied on any device with the robustBufferAccess feature enabled, it is currently limited to AMD to avoid the inefficiency. A possible future revision of Vulkan may relax the above restrictions. Bug: angleproject:2848 Change-Id: Ida5ae5d777da10f22ce8be5a09a7644b5bbd778e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1991709 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 8fde1151 2020-01-09T14:22:35 Vulkan: fix default uniform descriptor rebind on program change When the program binding changes, we set the descriptor sets binding dirty bit if the program had any textures, UBOs, SSBOs, images or atomic counters. The check for default uniforms was missing. So if the two programs had no resources and were only using default uniforms, then drawing with one after the other didn't update the descriptor set binding of the default uniforms for the second draw. Bug: angleproject:4277 Change-Id: I631a1619658ee713484cfaee99fe1e39987e16e7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1993408 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Kenneth Russell 7a37d3ac 2020-01-05T13:52:03 Work around Intel driver bug with CopyTex{Sub}Image2D/DeleteTextures. Dependencies seem to be incorrectly tracked in some Intel OpenGL drivers (on macOS specifically), causing crashes in glDeleteTextures if a GL command buffer is being constructed where those textures are destinations of CopyTexImage2D/CopyTexSubImage2D. Work around this bug by flushing before texture deletion if CopyTex{Sub}Image have been called recently. The tracking is only done on a per-context rather than a per-device basis, but seems sufficient to work around the problem as identified. Tested both with new ANGLE test on affected hardware, and in WebKit's ANGLE backend for WebGL. Works around the crash reported in https://bugs.webkit.org/show_bug.cgi?id=205707 . Bug: angleproject:4267 Change-Id: I2266a5590759f6a3f19080def08710ef4b66d463 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1987932 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Eric Binet b84cdffe 2020-01-06T14:59:44 Fix colored indexed point tests not using color in vertex buffer. In the previous version, the IndexedPointsTestUInt tests named VertexWithColorUnsignedIntOffset* were redundant with UnsignedIntOffset*. Bug: angleproject:3923 Change-Id: I6b9b8f2bd78882bcac7c3b89e798291ee94eea70 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1988998 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Corentin Wallez cbbb3aaf 2020-01-07T15:03:20 Suppress VertexAttributeTest.DrawArraysWithBufferOffset on Mac NVIDIA The test fails with the following at a very low flake rate: ../../third_party/angle/src/tests/gl_tests/VertexAttributeTest.cpp:230: Failure Expected equality of these values: angle::MakeGLColor(255, 255, 255, 255) Which is: White angle::ReadColor((midPixelX + viewportSize[2]) / 2, midPixelY) Which is: Transparent Black TBR=jmadill@chromium.org Bug: angleproject:4269 Change-Id: I82752acfbcb2a067ccb35a7a456def03299c359f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1987258 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Shahbaz Youssefi 806d812e 2020-01-03T13:48:30 Vulkan: Reorder descriptor sets This change moves driver uniforms to a set with a lower id than the one that includes (emulation) transform feedback buffers. Imagine the following: - Program 1 with xfb: UniformsSet: 1 VS uniforms buffer, 1 FS uniforms buffer, 1 xfb buffer - Program 2 without xfb: UniformsSet: 1 VS uniforms bufer, 1 FS uniforms buffer. Previously, UniformsSet was index 0, and DriverUniformsSet was index 3. When switching from Program 1 to Program 2, the layout of UniformsSet changes, which means every subsequent set needs to be rebound. This is a Vulkan pipeline layout compatibility rule. This is done with invalidateCurrentTextures() and invalidateCurrentShaderResources() already when handling gl::State::DIRTY_BIT_PROGRAM_EXECUTABLE. The bug is that the driver uniforms are not invalidated. This is normally not an issue, because usually when switching from Program 1 to Program 2, transform feedback is paused, and this state change does invalidate driver uniforms. However, the following scenario doesn't do this: - Begin Xfb - Pause Xfb - Use Program 1 - Draw - Use Program 2 - Draw - End Xfb There is no driver state change between the two draw calls, which means the second draw will attempt to draw using the driver uniforms bound for the first draw call. There is a Vulkan validation error here due to the above pipeline layout validation rule. The issue manifests itself only when the second draw call actually uses driver uniforms, as otherwise that set is inactive and not validated; i.e. when line raster emulation is used. In summary, the validation error manifests itself when: - Transform feedback and line raster both use emulation - Transform feedback is paused - A draw with an xfb program is followed by a non-xfb program - The second draw is a line draw A test is added for this. The solution is to reorder the sets so that DriverUniformsSet is placed before UniformsSet. This way, changes to the layout of UniformsSet don't invalidate DriverUniformsSet. In fact, based on the above, any change in the layout of the program should have required an invalidation of the driver uniforms. This bug is probably masked by the fact that ContextVk::handleDirtyDescriptorSetsImpl() always rebinds the graphics driver every time any descriptor set needs rebinding. That should be removed in a follow up change. Bug: angleproject:4261 Change-Id: I21ad4152b454a1fe70554be02e18a9c94fb3e7a8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1986927 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
shrekshao 51e653f0 2020-01-02T13:53:03 Suppress flaky failure with MacOS/NVIDIA/OPENGL Seeing intermittent failure on this test only on MacOS/NVIDIA/OPENGL. Suppress for now. Bug: angleproject:4258 Change-Id: Ibda30954019410e3b6d069986b2cd0ad26533c00 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1984850 Reviewed-by: Shrek Shao <shrekshao@google.com> Commit-Queue: Shrek Shao <shrekshao@google.com>
Le Hoang Quyen ab42afa6 2019-11-21T10:13:44 Metal: fix vertex attribute's conversion lost after changing buffer binding. After vertex buffer's attribute is converted and stored in conversion buffer. Binding the same attribute to another buffer, then binding it back to previous buffer will result in previous conversion information lost. The conversion method would skip the conversion due to buffer's content hadn't been changed, however it didn't reuse the old conversion result. This CL also changed the way binding offset is used in Metal backend. - Previous, the offset would be assigned to the offset field of MTLVertexAttributeDescriptor, then the buffer would simply be bound to the command encoder with offset=0 i.e. setVertexBuffer(buffer, index, 0) - However this approach has several disadvantages. Since Metal doesn't allow MTLVertexAttributeDescriptor's offset to be larger than the vertex attribute's stride, the old approach would force the back-end to convert the attribute and store in conversion buffer. New approach: - MTLVertexAttributeDescriptor's offset will be zero. The offset will be used to bind the buffer itself to the render command encoder. i.e. setVertexBuffer(buffer, index, offset) This way the "offset <= stride" restriction no longer exists. The only restriction is the offset must be multiple of attribute's size. Added 3 new tests: - SimpleStateChangeTest.RebindTranslatedAttribute - VertexAttributeTest.DrawWithLargeBufferOffset - VertexAttributeTest.DrawWithLargeBufferOffsetAndLessComponents Bug: angleproject:2634 Change-Id: I6c2fa8091436e4a24405d791f86d17d97df02d64 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1940009 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
shrekshao 81ee4d29 2019-12-04T17:05:11 Workaround EXT_texture_norm16 for OpenGL ES drivers Implement a workaround for widespread bugs calling glReadPixels with RGBA/UNSIGNED_SHORT against R16/RG16 color attachments. Read back the data using the GL_IMPLEMENTATION_COLOR_READ_FORMAT, and then rearrange the read back pixels to fit the RGBA layout. Also skip RGB16/RGB16_SNORM texture sample test on Nexus 5X/Nexus 6P due to a another driver bug. Bug: chromium:1000354, angleproject:4214, angleproject:4215, angleproject:4245 Change-Id: Iedea6f4136878cac5ad0dec3757c77b73502e1cd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1952166 Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Shrek Shao <shrekshao@google.com>
Xinghua Cao 1fdf6ca5 2019-12-31T14:25:35 D3D11: Restrict to translate uniform block to StructuredBuffer Only translate uniform block to StructuredBuffer when system is Windows 10 and later. Bug: angleproject:3682 Change-Id: I27e3f4503392791883a44e1d486ffe9512e04bd8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1984863 Commit-Queue: Xinghua Cao <xinghua.cao@intel.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 87607526 2019-12-23T22:48:06 Disable flaky test on Metal Bug: chromium:1037665 Bug: angleproject:4177 Change-Id: I38f05f1567803e7ac0c631d94056f26dc122a4f2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1980278 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Khushal c41f2e56 2019-12-23T13:33:58 Disable UniformBufferTests on Windows 7 / D3D11 / NVIDIA. Bug: chromium:1037644 Change-Id: Ic8bf76bb0c1b8bdcf36f6af5a8d91ac815334917 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1981070 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Xinghua Cao 0af8b596 2019-09-03T16:24:45 D3D11: Translate uniform blocks to StructuredBuffer when necessary fxc exhibits slow compile performance with dynamic cbuffer indexing. So when a uniform block contains only one large array member, which is an array of structures, translate this uniform block to a StructuredBuffer instead. Bug: angleproject:3682 TEST=angle_end2end_tests.UniformBufferTest.* Change-Id: Ife80dba8aae65b761737e095895e00a570230f88 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1782046 Commit-Queue: Xinghua Cao <xinghua.cao@intel.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Tim Van Patten 6423b7fc 2019-12-04T18:45:24 Return the correct location count for Matrices GetLocationCount() is currently returning the number of rows in the matrix, rather than the columns, which leads to shader validation errors (and test failures). This fix returns the number of columns in a matrix. Bug: angleproject:4200 Test: dEQP-GLES31.functional.separate_shader.random.63 Change-Id: I8d25eb3733c2ddbe53ff54794f480c1d43e22a88 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1952173 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Commit-Queue: Tim Van Patten <timvp@google.com>
Yan 17b3c2f3 2019-10-14T14:13:59 Implement SamplerVideoWEBGL for WEBGL_video_texture extension on desktop WEBGL_video_texture is an extension that will improve uploading video frame to WebGL performance. (https://www.khronos.org/registry/webgl/extensions/proposals/WEBGL_video_texture/) This extension introduced a new texture type TEXTURE_VIDEO_IMAGE_WEBGL and a new sampler type samplerVideoWEBGL to sample it. In chromium implementation, TEXTURE_VIDEO_IMAGE_WEBGL maps to different native texture type based on platform. On desktop, it maps to GL_TEXTURE2D(Currently supported). On Android, it should map to GL_TEXTURE_EXTERNAL(TODO). SamplerVideoWEBGL needs to be mapped to sampler2D or samplerExternalOES according to TEXTURE_VIDEO_IMAGE_WEBGL implementation. This patch implements samplerVideoWEBGL in Angle to support WEBGL_video_texture on desktop. In this case, samplerVideoWEBGL should map to sampler2D. Bug: chromium:776222, angleproject:3889 Change-Id: Idb0a5fcde37ca75ccc1181226b91f257212e7500 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1866274 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 17217c6e 2019-12-17T17:31:17 Vulkan: Fix layers being disabled in tests. The ANGLE_ENABLE_VULKAN_VALIDATION_LAYERS_BY_DEFAULT define shouldn't be being checked in tests. Enable the debug layers by default. Bug: angleproject:4227 Bug: angleproject:4229 Change-Id: I9717cb1c611ebd585a5c03ba2057036e1b086001 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1972497 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Shahbaz Youssefi 44722daa 2019-12-06T22:31:08 Vulkan: Enable inactive SSBO with unsized array tests The change introduced in https://chromium-review.googlesource.com/c/angle/angle/+/1951523 removes inactive shader interface declarations. That automatically resolves an issue where glslang wrapper doesn't handle inactive SSBO declarations with unsized arrays, by removing those declarations at translation time altogether. Bug: angleproject:3714 Change-Id: I710d59546d716bfb5bc0112b5152fed20a810a52 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1954615 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi a5dd3888 2019-12-04T14:31:57 Vulkan: fix handling of inactive atomic counters The translator emulates atomic counters with a storage buffer array during translation to Vulkan GLSL. Glslang wrapper then should assign set/binding to this buffer. However, if the atomic counters are actually unused in the shader, this assignment is never done. This change adds a small tree transformation for Vulkan that removes any uniform or interface block declaration that's not active. In particular, this makes atomic counter emulation a no-op if no atomic counters are used. It also has the benefit of not requiring glslang wrapper to remove such inactive resources. Bug: angleproject:4190 Change-Id: I286c199854ec2379558ad1ec48b4d2c4bf5544d0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1951523 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Brandon Schade 5cfab195 2019-10-28T09:12:53 Vulkan: Add test that logs supported texture formats Add a whitebox test to log all supported GLES formats for the active Vulkan ICD. The test object is dependent on libANGLE's gl_enum_util.* files as we need it to print out human readable values in the PrintAllFormatSupport test. Test: angle_white_box_tests --gtest_filter=*PrintAllSupportedFormats* Bug: angleproject:4093 Change-Id: I99d74935b705b2984f6320ed80a0e977c8fcd4be Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1930607 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Tobin Ehlis 5fd73782 2019-08-09T11:46:46 Vulkan: Use volk to load vk* func ptrs Thanks to Jamie Madill for some fixes to get all CI test passing w/ volk. This change updates all ANGLE targets that use Vulkan to dyanmically link all of the VK entrypoints using the volk OSS library from https://github.com/zeux/volk. It's only two source files so baking them directly into ANGLE repo. Also it's used in both the tests and libANGLE trees so added to src/common/third_party/volk dir. Updated volk and the renderer to track latest instance and device that were loaded and renderer will refresh vk* function pointers if the current and previous device and/or instance don't match. This prevents errors in the test framework as we transition between backends, especially between VK HW & SwiftShader ICDs. This change rolls the Vulkan Loader forward to use the latest loader version which no longer allows static linking but requires dynamic linking. Bug: angleproject:3740 Bug: angleproject:4092 Bug: angleproject:4162 Bug: angleproject:4210 Bug: angleproject:4225 Change-Id: I8a0b7d24c9545bbfdfaa4b9357a9bfe6793e0140 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1965640 Commit-Queue: Tobin Ehlis <tobine@google.com> Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Le Hoang Quyen d1860ea1 2019-11-19T23:04:00 Metal: support OES_depth_texture Also added Depth32 & Depth16 texture data upload tests. Bug: angleproject:2634 Change-Id: I103f1cda1dc915f0dc8b04f7aaa2d8c0f9220cda Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1919281 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Hyunchang Kim caa6eccd 2019-10-27T13:46:56 Vulkan: Implement Transform Feedback support via extension Implemented transform feedback extension path. Where VK_EXT_transform_feedback is supported, extension path will be taken over an emulation path. Extension path has advantages in terms of performance. BUG=angleproject:3206 Test: dEQP-GLES3.functional.transform_feedback.* angle_end2end_tests --gtest_filter=TransformFeedbackTest* Change-Id: Ia07c23afb289d9c67073469a97b714ec96f5265a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1882767 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
David Benjamin f60da874 2019-11-19T18:45:45 Fix out-of-bounds access bug in ANGLE tests When not filled in, as in Android, activeGPUIndex is -1. This is fine for Android because it doesn't use vendorID, but the function computed vendorID unconditionally without checking for -1. Default activeGPUIndex to 0 instead of -1. Note code still needs to check for systemInfo.gpus.empty(). This caused crashes when _LIBCPP_DEBUG=0 was enabled. Bug: chromium:923166 Change-Id: If4d1dff9553a580fd92bc0497fc092789d07ed93 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1925031 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Ian Elliott c6458072 2019-12-05T11:45:10 Fix multisample renderbuffer compliance (e.g. 3->4 samples) This change ensures that the following spec language is correctly implemented: the resulting value for RENDERBUFFER_SAMPLES is guaranteed to be greater than or equal to samples and no more than the next larger sample count supported by the implementation. For example, if 2, 4, and 8 samples are supported, and if 5 samples are requested, ANGLE should use 8 samples, and return 8 when GL_RENDERBUFFER_SAMPLES is queried. Note: There is a known problem with NVIDIA OpenGL driver that causes another test to be expected to fail. Bug: angleproject:2222 Bug: angleproject:4196 Change-Id: I28921badf9568427799b0af347198b5df06c2aaa Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1954444 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Ian Elliott <ianelliott@google.com>
Shahbaz Youssefi d68bf3e2 2019-12-04T12:30:56 Fix image/sampler uniform range in presence of atomic counters The change that introduced images to the front-end placed them at the end of the uniforms list, so the loop that was calculating the image range was starting from the end of that list. The change that introduced atomic counters to the front-end placed them at the end of the uniforms list too, but the image range loop was not adjusted to take this fact into account (neither was the sampler range loop for that matter). If a shader used both images and atomic counter buffers, the image range was calculated as empty. Similar issues would arise if the shader used both samplers and atomic counters. A test is added where a shader has a default uniform, a UBO, an SSBO, an image and an atomic counter, to make sure any combination of these resources doesn't result in a bug. Bug: angleproject:4190 Change-Id: I7818ee5258dd964215a18acfd7c3d6515b61c595 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1950655 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Shahbaz Youssefi 795a3559 2019-12-03T11:31:18 Vulkan: EXT_gpu_shader5 support: precise The precise keyword is used in tessellation shaders but introduced in this extension. EXT_gpu_shader5 introduces a handful of features to shaders. This change only implements the `precise` keyword. Bug: angleproject:3569 Change-Id: I2252b79098eb8ba2d2faa040d7eaed7548b7051e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1939851 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi af52f9c6 2019-12-03T14:11:17 Fix tests checking for major version > 3 The tests meant to do getClientMajorVersion() >= 3, but in a few locations accidentally did > 3. Bug: angleproject:3569 Change-Id: Ie69898348982c6aae7dac265a18229c257dbfbda Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1947458 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Ian Elliott 5f857839 2019-12-04T15:30:50 Improve current multisampled renderbuffer/texture support This is split off from a change to implement multisampled textures for the Vulkan back-end, and will come before that change. The changes include: - Make a common utility rx::GetSamplePosition() function. D3D11 and Vulkan use the same standard sample positions/locations for 1, 2, 4, 8, and 16 samples. The D3D11 back-end has a utility function for this, which is being moved to a common location--for use by both the D3D11 and Vulkan back-ends. - Texture::setStorageMultisample() handles converting the "requested number of samples" to the actual number of samples used (e.g. converting 3 to 4), supported by the underlying back-end). The actual number used is stored in gl::TextureState::mImageDescs, for use by other GLES commands. - Change some end2end tests to not make assumptions about the supported number of samples, but to properly query what is supported. Bug: angleproject:3565 Bug: angleproject:4196 Change-Id: I1dc12fedd0f8fb4975f90d87486e443b069b7141 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1948535 Commit-Queue: Ian Elliott <ianelliott@google.com> Reviewed-by: Ian Elliott <ianelliott@google.com>
Shahbaz Youssefi c3f0352d 2019-12-04T12:13:00 Re-enable atomic counter tests on !windows There is a bug that prevents us from running these tests on the windows bots. This change enables them on other platforms so we don't lose coverage. Bug: angleproject:3738 Change-Id: I9b546c3223499af88b347f8a01be8edb245c19a7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1950654 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang ff83dabf 2019-12-03T10:10:53 Skip flaky BlendMinMaxTest.RGBA16F/ES2_Metal. BUG=angleproject:4185 Change-Id: I236d4372ab22e9083d00cf13fa2ad682a1d42f14 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1947447 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Shahbaz Youssefi 190d9a81 2019-11-29T09:57:40 Fix RenderingLimitToDefaultFBOSizeWithNoAttachments test MAX_DRAW_BUFFERS has a minimum value of 4. This test was unconditionally using 6 draw buffers. Bug: angleproject:4092 Bug: angleproject:4180 Change-Id: I069874a6402da1cb007bf9504e68b9910951cf63 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1944527 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Alexis Hétu <sugoi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 745999a9 2019-11-19T12:59:02 Add test for multithreaded shared-context resource The test does this: 1. Context 1: Read Texture 1 and draw into Framebuffer 1 2. Context 2: Read Texture 1 and draw into Framebuffer 2 3. Context 1: Delete Framebuffer 1 4. Context 1: Flush 5. Context 2: Modify Texture 1 Issue is Texture 1's mCurrentReadingNodes contains one node from each context's command graph, one of which is deleted at step 4. At step 5, a dependency is added from both nodes (one already deleted) to a new node, causing use-after-free. Bug: angleproject:4130 Change-Id: I06720aec20d0b49114937f1cd9b193a4f1df9d8d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1924790 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Xinyi He 19f9f414 2019-11-29T10:30:25 Vulkan: Textures incorrect on Android maps with Vulkan Backend The issue was fixed, but adding a regression test to avoid it again. glMemoryBarrier inserts a memory barrier and breaks the submission order, which causes the copyBufferToImage happens before copyImageToBuffer and image corruption. This test fails on commit 052167b, and can pass on the latest build. Bug: angleproject:4074 Change-Id: Icc42dd7b2ba167815b223085ce933682654ce760 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1943848 Commit-Queue: Ian Elliott <ianelliott@google.com> Reviewed-by: Ian Elliott <ianelliott@google.com>
Jonah Ryan-Davis bc82fb14 2019-11-28T16:58:19 Suppress failing end2end tests for ASAN builds GLSLTest_ES31.StructArraySample and ComputeShaderTest.DispatchComputeIndirect both hit stack-buffer-overflow errors with ASAN enabled, using the vulkan backend. Right now ASAN is only tested on Mac, so these are only hit when Mac is using swiftshader-vulkan. Bug: 1029378 Change-Id: Ie590f73c29be44f683fd47fe4da139e1b5f96289 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1943408 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Corentin Wallez 39f3ccda 2019-11-28T17:45:01 Suppress SimpleStateChange failure on Metal NVIDIA BUG=angleproject:4177 TBR=geofflang@chromium.org Change-Id: I642e4bd3650b5b6beb6d9b18106d787c5dbc14f6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1942348 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Jamie Madill fc3ec57d 2019-11-27T21:43:22 Reland "Vulkan: Accelerate Texture PBO updates" This reverts commit 27d3c9399925d23726880ef910b9068fa39307cf. Reason for revert: Investigation is unable to reproduce the regresion. Shows up on the perf CI. Original change's description: > Revert "Vulkan: Accelerate Texture PBO updates" > > This reverts commit efb45edaefc07fc7120ebbde83bbc84876afda1a. > > Reason for revert: Significant perf regression on several benchmarks. > See bug for more details. > > Bug: chromium:1027098 > > Original change's description: > > Vulkan: Accelerate Texture PBO updates > > > > If the format of the image and the PBO match, > > use a vkCmdCopyBufferToImage transfer operation. > > > > Test: angle_end2end_tests --gtest_filter=*PBOCompressedSubImage* > > angle_end2end_tests --gtest_filter=*PBOWithMultipleDraws* > > dEQP-GLES3.functional.texture.specification.tex*image*d_pbo* > > Bug: angleproject:3777 > > Change-Id: I3f271024a635be113202a16f8893a199c194172d > > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1906203 > > Reviewed-by: Cody Northrop <cnorthrop@google.com> > > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > > TBR=cnorthrop@google.com,syoussefi@chromium.org,jmadill@chromium.org,m.maiya@samsung.com,b.schade@samsung.com > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: angleproject:3777 > Change-Id: I774655962e9ab5a866b9324002fb8edae8550834 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1939927 > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Commit-Queue: Jamie Madill <jmadill@chromium.org> TBR=cnorthrop@google.com,syoussefi@chromium.org,jmadill@chromium.org,m.maiya@samsung.com,b.schade@samsung.com Change-Id: I8560a2e70de230eac3256a1df5eb2ecaa6f26bcf No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: chromium:1027098, angleproject:3777 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1939852 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Le Hoang Quyen b6148c3a 2019-11-21T10:13:44 Metal: re-enable end2end tests Bug: angleproject:4157 Change-Id: Ia7e29c32696c84556e9ea527fc48b086b1bc4766 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1940007 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 27d3c939 2019-11-27T11:39:41 Revert "Vulkan: Accelerate Texture PBO updates" This reverts commit efb45edaefc07fc7120ebbde83bbc84876afda1a. Reason for revert: Significant perf regression on several benchmarks. See bug for more details. Bug: chromium:1027098 Original change's description: > Vulkan: Accelerate Texture PBO updates > > If the format of the image and the PBO match, > use a vkCmdCopyBufferToImage transfer operation. > > Test: angle_end2end_tests --gtest_filter=*PBOCompressedSubImage* > angle_end2end_tests --gtest_filter=*PBOWithMultipleDraws* > dEQP-GLES3.functional.texture.specification.tex*image*d_pbo* > Bug: angleproject:3777 > Change-Id: I3f271024a635be113202a16f8893a199c194172d > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1906203 > Reviewed-by: Cody Northrop <cnorthrop@google.com> > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> TBR=cnorthrop@google.com,syoussefi@chromium.org,jmadill@chromium.org,m.maiya@samsung.com,b.schade@samsung.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: angleproject:3777 Change-Id: I774655962e9ab5a866b9324002fb8edae8550834 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1939927 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi f8482560 2019-11-26T15:47:48 Don't use too many color attachments in clear test GL_MAX_COLOR_ATTACHMENTS has a minimum value of 4. The test was unconditionally using 5 attachments. Bug: angleproject:4172 Change-Id: I793c297b50e3fdc54f75e2c5608508279028359f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1937808 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Mohan Maiya c373dfd8 2019-11-22T08:48:22 Vulkan : Handle dirty state correctly when there are muiltiple VAOs If vertex array object binding is changed, we need to update the pipeline cache with the attribute information of the newly bound VAO. We cache the strides of attributes because emulated attributes will have strides that don't match the stride info cached in its binding struct. Also added a test case that switches between multiple VAOs. Bug: angleproject:4127 Test: angle_end2end_tests.exe --gtest_filter=SimpleStateChangeTestES31.MultipleVertexArrayObjectRendering Change-Id: I4f23aec33d5aa5988baa41f3c63db5534daf75ca Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1917453 Reviewed-by: Tobin Ehlis <tobine@google.com> Commit-Queue: Tobin Ehlis <tobine@google.com>
Shahbaz Youssefi 88752889 2019-11-20T14:09:52 Vulkan: Fix barriers w.r.t sampled->storage image update df415528411f97454e765ff6a83ed1cbc90a7d13 implemented a feature where images are not created with the storage flag until needed. This is a necessary optimization. There were a few misuses of the BufferHelper::onRead/Write helpers that set up the appropriate barriers that this change fixes. Bug: angleproject:3816 Change-Id: I7e62d98b7325f938152a1972f4ebee083ed319c2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1924989 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Xinyi He <xinyi.he@arm.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Sunny Sun <sunny.sun@arm.com>
Le Hoang Quyen e5b474c6 2019-11-19T23:04:00 Metal: support ANGLE_instance_arrays/EXT_instance_arrays Also added TRIANGLE_FAN & LINE_LOOP instanced draws test cases. Bug: angleproject:2634 Change-Id: I84740a7221ab49710cf23767c81fa2d303aad364 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1919280 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
shrekshao fb1c2fe8 2019-11-13T11:10:39 EXT_texture_norm16 readpixels fix Adding validation logic for RGBA16 readpixels. Change readPixels format from UNSIGNED_BYTE to UNSIGNED_SHORT in the test. FYI: According to https://www.khronos.org/registry/OpenGL/extensions/EXT/EXT_texture_norm16.txt ReadPixels format and type used during CopyTex* are limited to RGBA Bug: 1024387, 1000354, angleproject:1365, angleproject:4089 Change-Id: I70517f255fe335f60e55bdf15f7ebf82e3de0800 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1914127 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shrek Shao <shrekshao@google.com>
Courtney Goeltzenleuchter f3d35f8f 2019-11-22T14:24:52 Suppress flaky failure with Win7/NVIDIA/D3D11 Seeing intermittent failure on this test only on Win7/NVIDIA/D3D11. Suppress for now. Bug: angleproject:4163 Change-Id: Idfa44516a194dcd5710622d11801ce089c1e829d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1931338 Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Xinyi He 4c7db77e 2019-10-31T15:42:31 Vulkan: Set limitation on maxComputeWorkGroupCount According to Table 20.45 and Chapter 17 in the ES 3.1 spec, MAX_COMPUTE_WORK_GROUP_COUNT is get as a GLint by using GetIntegeri_v. However, it is an unsigned integer in the Vulkan. It needs to set limitation on maxComputeWorkGroupCount[] during translating. 1. Change the data type to GLint stored in Caps. 2. Ensure that the limitation is set during initialization. 3. Add workaround for angleproject:4120 Bug: angleproject:4066 Change-Id: I1659ba1d560e30b9599cace0feeab8a18890c3ff Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1890586 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Le Hoang Quyen 6fcc0bb8 2019-11-21T01:19:40 Metal: Re-add end2end test configs (running test is still disabled) angle_test_instantiate.cpp & angle_test_instantiate_apple.mm: - Disabled metal platform selection on pre-10.13 mac devices for Bug: angleproject:4153 Explicitly disabled tests on metal: - DifferentStencilMasksTest.DrawWithDifferentMask - PointSpritesTest.PointSizeAboveMaxIsClamped - WebGL2ReadOutsideFramebufferTest.CopyTexSubImage3D This requires the crash fix in http://crrev.com/c/1924101 Bug: angleproject:4153 Bug: angleproject:2634 Change-Id: I95046d731a8ba7414cf1a1f4b6f2940282725872 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1926389 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Le Hoang Quyen 05af7590 2019-11-20T01:04:00 Metal: Fix FramebufferMtl's read-after-delete Due to late verification, ContextMtl might call onFinishedDrawingToFrameBuffer() on a deleted framebuffer object inside syncState() Fix: - Switch to call onStartedDrawingToFrameBuffer() on new FBO instead of calling onFinishedDrawingToFrameBuffer() on old (and possibly deleted) FBO. - Also discard framebuffer only takes effect per render pass. The discard flag will be reset when render pass starts. Bug: angleproject:4144 Change-Id: I7c6c96862892f1c241ce4af3b61862fa4b710a94 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1924101 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tobin Ehlis c1776c61 2019-11-13T11:36:35 Vulkan:Add Swiftshader configs Add Swiftshader configs to existing test instantiation macros for all ESX variants. This causes Swiftshader to be used to run end2end tests. Added detection code to know when tests are running on Swiftshader and skipping a number of fails initially. Note that when running ANGLE end2end tests within Chromium build on Win32 bots there were crashes with Swiftshader config for tests that should have been skipped. Due to this, just skipping Swiftshader configs on Win32 for now. Bug: angleproject:4081 Bug: angleproject:4092 Change-Id: I32527a62304c5fad90f645b372edf9411ca2b212 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1914126 Commit-Queue: Tobin Ehlis <tobine@google.com> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Brandon Schade efb45eda 2019-09-24T09:23:53 Vulkan: Accelerate Texture PBO updates If the format of the image and the PBO match, use a vkCmdCopyBufferToImage transfer operation. Test: angle_end2end_tests --gtest_filter=*PBOCompressedSubImage* angle_end2end_tests --gtest_filter=*PBOWithMultipleDraws* dEQP-GLES3.functional.texture.specification.tex*image*d_pbo* Bug: angleproject:3777 Change-Id: I3f271024a635be113202a16f8893a199c194172d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1906203 Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>